| Line 534... |
Line 534... |
| 534 |
if(exit){
|
534 |
if(exit){
|
| 535 |
continue;
|
535 |
continue;
|
| 536 |
}
|
536 |
}
|
| 537 |
txn.setOrders(orderlist);
|
537 |
txn.setOrders(orderlist);
|
| 538 |
try {
|
538 |
try {
|
| 539 |
transaction_client = new TransactionClient().getClient();
|
- |
|
| 540 |
transactionId = String.valueOf(transaction_client.createTransaction(txn));
|
539 |
transactionId = String.valueOf(transaction_client.createTransaction(txn));
|
| 541 |
logger.info("Transaction id is : " + transactionId);
|
540 |
logger.info("Transaction id is : " + transactionId);
|
| 542 |
} catch (TransactionServiceException e) {
|
541 |
} catch (TransactionServiceException e) {
|
| 543 |
logger.error(orderId+" "+subOrderId + " Could not create transaction " , e);
|
542 |
logger.error(orderId+" "+subOrderId + " Could not create transaction " , e);
|
| 544 |
sb.append(orderId+" "+subOrderId + " Could not create transaction" +"\n");
|
543 |
sb.append(orderId+" "+subOrderId + " Could not create transaction" +"\n");
|
| Line 568... |
Line 567... |
| 568 |
e.printStackTrace();
|
567 |
e.printStackTrace();
|
| 569 |
continue;
|
568 |
continue;
|
| 570 |
}
|
569 |
}
|
| 571 |
Transaction transaction = null;
|
570 |
Transaction transaction = null;
|
| 572 |
try {
|
571 |
try {
|
| 573 |
transaction_client = new TransactionClient().getClient();
|
- |
|
| 574 |
transaction = transaction_client.getTransaction(Long.parseLong(transactionId));
|
572 |
transaction = transaction_client.getTransaction(Long.parseLong(transactionId));
|
| 575 |
} catch (NumberFormatException e) {
|
573 |
} catch (NumberFormatException e) {
|
| 576 |
logger.error("Problem parsing transaction id " + transactionId +" ", e);
|
574 |
logger.error("Problem parsing transaction id " + transactionId +" ", e);
|
| 577 |
sb.append(orderId+" "+subOrderId + " Problem parsing transaction id "+ transactionId +"\n");
|
575 |
sb.append(orderId+" "+subOrderId + " Problem parsing transaction id "+ transactionId +"\n");
|
| 578 |
e.printStackTrace();
|
576 |
e.printStackTrace();
|
| Line 605... |
Line 603... |
| 605 |
in.shop2020.model.v1.order.Attribute attribute = new in.shop2020.model.v1.order.Attribute();
|
603 |
in.shop2020.model.v1.order.Attribute attribute = new in.shop2020.model.v1.order.Attribute();
|
| 606 |
attribute.setName("Buyer Name");
|
604 |
attribute.setName("Buyer Name");
|
| 607 |
attribute.setValue(buyerName);
|
605 |
attribute.setValue(buyerName);
|
| 608 |
attributeList.add(attribute);
|
606 |
attributeList.add(attribute);
|
| 609 |
try {
|
607 |
try {
|
| 610 |
//if(transaction_client == null){
|
- |
|
| 611 |
transaction_client = new TransactionClient().getClient();
|
- |
|
| 612 |
//}
|
- |
|
| 613 |
transaction_client.createFlipkartOrder(flipkartOrder);
|
608 |
transaction_client.createFlipkartOrder(flipkartOrder);
|
| 614 |
transaction_client.setOrderAttributes(flipkartOrder.getOrderId(),attributeList);
|
609 |
transaction_client.setOrderAttributes(flipkartOrder.getOrderId(),attributeList);
|
| 615 |
logger.info("transaction id : " + Long.valueOf(transactionId) + " Payment id : " + paymentId);
|
610 |
logger.info("transaction id : " + Long.valueOf(transactionId) + " Payment id : " + paymentId);
|
| 616 |
new PaymentClient().getClient().updatePaymentDetails(paymentId, null, null, null, null, null, null, subOrderId, null, PaymentStatus.SUCCESS, null, null);
|
611 |
new PaymentClient().getClient().updatePaymentDetails(paymentId, null, null, null, null, null, null, subOrderId, null, PaymentStatus.SUCCESS, null, null);
|
| 617 |
orders_processed++;
|
612 |
orders_processed++;
|