Subversion Repositories SmartDukaan

Rev

Rev 7611 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 7611 Rev 19443
Line 147... Line 147...
147
        txnObj.setCustomer_id(userId);
147
        txnObj.setCustomer_id(userId);
148
        txnObj.setCreatedOn(Calendar.getInstance().getTimeInMillis());
148
        txnObj.setCreatedOn(Calendar.getInstance().getTimeInMillis());
149
        txnObj.setTransactionStatus(TransactionStatus.INIT);
149
        txnObj.setTransactionStatus(TransactionStatus.INIT);
150
        txnObj.setStatusDescription("New Store Order");
150
        txnObj.setStatusDescription("New Store Order");
151
        txnObj.setCoupon_code("");
151
        txnObj.setCoupon_code("");
152
        txnObj.setEmiSchemeId(0);
152
        //txnObj.setPayment_option(payment_option)(0);
153
        
153
        log.info("UserId : " + userId);
154
        Order order = createOrder(userId);
154
        Order order = createOrder(userId);
155
        
155
        
156
        if(order ==  null) {
156
        if(order ==  null) {
157
            log.error("Unable to create transaction");
157
            log.error("Unable to create transaction");
158
            setErrorMsg("Unable to create order. Please try again.");
158
            setErrorMsg("Unable to create order. Please try again.");
Line 246... Line 246...
246
            log.error("Unable to create transaction", e);
246
            log.error("Unable to create transaction", e);
247
            setErrorMsg("Unable to create order. Please try again.");
247
            setErrorMsg("Unable to create order. Please try again.");
248
            return "error-result";
248
            return "error-result";
249
        }
249
        }
250
        
250
        
-
 
251
        //No mail is required to sent.
251
        try {
252
        /*try {
252
         
253
         
253
            tcl = new TransactionClient();
254
            tcl = new TransactionClient();
254
            tcl.getClient().enqueueTransactionInfoEmail(txnId);
255
            tcl.getClient().enqueueTransactionInfoEmail(txnId);
255
        } catch (Exception e) {
256
        } catch (Exception e) {
256
            log.error("Unable to send email", e);
257
            log.error("Unable to send email", e);
257
        }
258
        }*/
258
        
259
        
259
        return "order-success-redirect";
260
        return "order-success-redirect";
260
    }
261
    }
261
    
262
    
262
    String validateAddress() {
263
    String validateAddress() {