| Line 1... |
Line 1... |
| 1 |
package in.shop2020.serving.controllers;
|
1 |
package in.shop2020.serving.controllers;
|
| 2 |
|
2 |
|
| 3 |
import java.util.List;
|
3 |
import java.util.List;
|
| 4 |
|
4 |
|
| - |
|
5 |
import in.shop2020.datalogger.EventType;
|
| 5 |
import in.shop2020.model.v1.order.Order;
|
6 |
import in.shop2020.model.v1.order.Order;
|
| 6 |
import in.shop2020.model.v1.user.ShoppingCartException;
|
7 |
import in.shop2020.model.v1.user.ShoppingCartException;
|
| 7 |
import in.shop2020.serving.controllers.BaseController;
|
8 |
import in.shop2020.serving.controllers.BaseController;
|
| 8 |
import in.shop2020.serving.services.EbsPaymentService;
|
9 |
import in.shop2020.serving.services.EbsPaymentService;
|
| 9 |
import in.shop2020.serving.services.HdfcPaymentService;
|
10 |
import in.shop2020.serving.services.HdfcPaymentService;
|
| 10 |
import in.shop2020.serving.services.IPaymentService;
|
11 |
import in.shop2020.serving.services.IPaymentService;
|
| 11 |
import in.shop2020.serving.utils.DataLogger;
|
12 |
import in.shop2020.serving.utils.DataLogger;
|
| 12 |
import in.shop2020.serving.utils.DataLogger.Event;
|
- |
|
| 13 |
import in.shop2020.thrift.clients.TransactionServiceClient;
|
13 |
import in.shop2020.thrift.clients.TransactionServiceClient;
|
| 14 |
import in.shop2020.thrift.clients.UserContextServiceClient;
|
14 |
import in.shop2020.thrift.clients.UserContextServiceClient;
|
| 15 |
|
15 |
|
| 16 |
import org.apache.log4j.Logger;
|
16 |
import org.apache.log4j.Logger;
|
| 17 |
import org.apache.struts2.convention.annotation.InterceptorRef;
|
17 |
import org.apache.struts2.convention.annotation.InterceptorRef;
|
| Line 195... |
Line 195... |
| 195 |
TransactionServiceClient transactionServiceClient = null;
|
195 |
TransactionServiceClient transactionServiceClient = null;
|
| 196 |
try {
|
196 |
try {
|
| 197 |
transactionServiceClient = new TransactionServiceClient();
|
197 |
transactionServiceClient = new TransactionServiceClient();
|
| 198 |
List<Order> orders = transactionServiceClient.getClient().getOrdersForTransaction(txnId, userinfo.getUserId());
|
198 |
List<Order> orders = transactionServiceClient.getClient().getOrdersForTransaction(txnId, userinfo.getUserId());
|
| 199 |
for (Order order : orders) {
|
199 |
for (Order order : orders) {
|
| 200 |
DataLogger.logData(Event.ORDER_CREATION.name(), session.getId(),
|
200 |
DataLogger.logData(EventType.ORDER_CREATION.name(), session.getId(),
|
| 201 |
Long.toString(userinfo.getUserId()),
|
201 |
Long.toString(userinfo.getUserId()),
|
| 202 |
userinfo.getEmail(), Long.toString(order.getId()));
|
202 |
userinfo.getEmail(), Long.toString(order.getId()));
|
| 203 |
}
|
203 |
}
|
| 204 |
} catch (Exception e1) {
|
204 |
} catch (Exception e1) {
|
| 205 |
e1.printStackTrace();
|
205 |
e1.printStackTrace();
|