Subversion Repositories SmartDukaan

Rev

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

Rev 18041 Rev 18578
Line 97... Line 97...
97
	RET_REFUNDED_LOST_IN_TRANSIT,
97
	RET_REFUNDED_LOST_IN_TRANSIT,
98
	LOST_IN_TRANSIT,
98
	LOST_IN_TRANSIT,
99
	LOST_IN_TRANSIT_RESHIPPED,
99
	LOST_IN_TRANSIT_RESHIPPED,
100
	LOST_IN_TRANSIT_REFUNDED,
100
	LOST_IN_TRANSIT_REFUNDED,
101
	DELIVERED_AT_STORE,
101
	DELIVERED_AT_STORE,
102
	RECEIVED_AT_STORE
102
	RECEIVED_AT_STORE,
-
 
103
	APPROVAL_PENDING
103
}
104
}
104
 
105
 
105
enum TransactionStatus{
106
enum TransactionStatus{
106
	INIT,
107
	INIT,
107
	IN_PROCESS,
108
	IN_PROCESS,
Line 912... Line 913...
912
	9:string paymentMode,
913
	9:string paymentMode,
913
	10:string courierName,
914
	10:string courierName,
914
	11:i64 slaDays,
915
	11:i64 slaDays,
915
	12:string shippingName
916
	12:string shippingName
916
}
917
}
-
 
918
 
917
/*
919
/*
918
struct PaytmOrder {
920
struct PaytmOrder {
919
	1:i64 orderId,
921
	1:i64 orderId,
920
	2:string paytmOrderId,
922
	2:string paytmOrderId,
921
	3:string paytmSubOrderId,
923
	3:string paytmSubOrderId,
922
	4:
924
	4:
923
}*/
925
}*/
924
 
926
 
-
 
927
struct Creditor{
-
 
928
	1:i64 id,
-
 
929
	2:string name,
-
 
930
	3:bool active, 
-
 
931
	4:i64 created,
-
 
932
	5:i64 updated
-
 
933
}
-
 
934
 
-
 
935
struct UserSanction{
-
 
936
	1:i64 user_id, 
-
 
937
	2:i64 creditor_id, 
-
 
938
	3:string user_ref_id,
-
 
939
	4:double credit_limit, 
-
 
940
	5:double credit_blocked, 
-
 
941
	6:double loan, 
-
 
942
	7:bool active, 
-
 
943
	8:i64 created, 
-
 
944
	9:i64 updated
-
 
945
}
-
 
946
 
-
 
947
enum CreditTxnType{
-
 
948
	BLOCKED,
-
 
949
	BLOCK_REVERSED,
-
 
950
	LOAN,
-
 
951
	PAID
-
 
952
}
-
 
953
 
-
 
954
struct CreditHistory{
-
 
955
	1:i64 user_id,
-
 
956
	2:i64 creditor_id,
-
 
957
	3:i64 payment_id, 
-
 
958
	4:double  amount,
-
 
959
	5:CreditTxnType credittype, 
-
 
960
	6:i64 created, 
-
 
961
	7:i64 updated,  
-
 
962
	8:string loan_id, 
-
 
963
	9:string shipping_id,
-
 
964
	10:i64 dueDate
-
 
965
}
-
 
966
 
-
 
967
enum ReturnAction{
-
 
968
	REPLACEMENT,
-
 
969
	REFUND
-
 
970
}
-
 
971
 
-
 
972
enum ReturnPickupType{
-
 
973
	NOW,
-
 
974
	LATER,
-
 
975
	NOT_REQUIRED
-
 
976
}
-
 
977
 
-
 
978
enum RefundType{
-
 
979
	INIT,
-
 
980
	CHEQUE,
-
 
981
	WALLET,
-
 
982
	COUPON,
-
 
983
	GATEWAY,
-
 
984
	REPLACEMENT
-
 
985
}
-
 
986
 
-
 
987
enum ReplacementShippingType{
-
 
988
	IMMEDIATE,
-
 
989
	LATER
-
 
990
}
-
 
991
 
-
 
992
enum ReturnTxnPickupStatus{
-
 
993
	PENDING,
-
 
994
	PICKUP_REQUESTED,
-
 
995
	PICKUP_CONFIRMED,
-
 
996
	PICKUP_SCHEDULED,
-
 
997
	PICKUP_IN_TRANSIT,
-
 
998
	PICKUP_RECEIVED
-
 
999
}
-
 
1000
 
-
 
1001
struct ReturnPickupRequest{
-
 
1002
	1:i64 id,
-
 
1003
	2:i64 logisticsProviderId,
-
 
1004
	3:string pickupRequestNo,
-
 
1005
	4:i64 confirmedAt,
-
 
1006
	5:i64 promised_pickup_timestamp,
-
 
1007
	6:i64 pickedUpAt,
-
 
1008
	7:ReturnTxnPickupStatus pickupStatus
-
 
1009
}
-
 
1010
 
-
 
1011
enum ReceivedReturnType{
-
 
1012
	PRESTINE,
-
 
1013
	DAMAGED,
-
 
1014
	LOST_IN_TRANSIT
-
 
1015
}
-
 
1016
 
-
 
1017
enum ReturnTxnResolutionStatus{
-
 
1018
	PENDING,
-
 
1019
	AWAITING_PICKUP,
-
 
1020
	QUALITY_CHECK,
-
 
1021
	REPLACEMENT_ORDER_CREATED,
-
 
1022
	REPLACEMENT_DONE,
-
 
1023
	REFUND_IN_PROCESS,
-
 
1024
	REFUND_DONE,
-
 
1025
	CLOSED
-
 
1026
}
-
 
1027
 
-
 
1028
struct ReturnOrderInfo{
-
 
1029
	1:i64 id,
-
 
1030
	2:i64 returnTransactionId,
-
 
1031
	3:string masterOrderId,
-
 
1032
	4:i64 orderId,
-
 
1033
	5:i64 lineItemId,
-
 
1034
	6:i64 logisticsRequestId,	
-
 
1035
	7:i64 returnQuantity,
-
 
1036
	8:i64 receivedQuantity,
-
 
1037
	9:i64 createdAt,
-
 
1038
	10:i64 processedAt,
-
 
1039
	11:string returnStatus,
-
 
1040
	12:i64 reshippedAt,
-
 
1041
	13:i64 receivedAt,
-
 
1042
	14:string refundReason,
-
 
1043
	15:string refundedBy,
-
 
1044
	16:i64 refundedAt,
-
 
1045
	17:i64 warehouse_id,
-
 
1046
	18:double refundAmount,
-
 
1047
	19:RefundType refundType,
-
 
1048
	20:string refundDescription,
-
 
1049
	21:ReturnPickupType returnPickupType,
-
 
1050
	22:ReplacementShippingType shippingType,
-
 
1051
	23:i64 replacementOrderId,
-
 
1052
	24:ReceivedReturnType receivedReturnType,
-
 
1053
	25:i64 freebieItemId,
-
 
1054
	26:ReturnAction returnAction,
-
 
1055
	27:ReturnTxnResolutionStatus returnTxnResolutionStatus,
-
 
1056
	28:LineItem lineitem,
-
 
1057
	29:ReturnPickupRequest returnPickUpRequest
-
 
1058
}
-
 
1059
 
-
 
1060
enum ReturnTransactionStatus{
-
 
1061
	INITIATED,
-
 
1062
	AUTHORIZED,
-
 
1063
	INPROCESS,
-
 
1064
	REJECTED,
-
 
1065
	PROCESSED,
-
 
1066
	COMPLETED,
-
 
1067
	CLOSED
-
 
1068
}
-
 
1069
 
-
 
1070
struct ReturnTransaction{
-
 
1071
	1:i64 id,
-
 
1072
	2:ReturnTransactionStatus status,
-
 
1073
	3:string customer_email,
-
 
1074
	4:string customer_name,
-
 
1075
	5:i64 customer_id,
-
 
1076
	6:i64 address_id,
-
 
1077
	7:i64 ticketId
-
 
1078
	8:i64 createdAt,
-
 
1079
	9:i64 processedAt,
-
 
1080
	10:i64 authorizedAt,
-
 
1081
	11:i64 closedAt,
-
 
1082
	12:string customerAddress,
-
 
1083
	13:string pincode,
-
 
1084
	14:string customerCity,
-
 
1085
	15:string customerState,
-
 
1086
	16:string customerPhone,
-
 
1087
	17:list<ReturnOrderInfo> returnOrders
-
 
1088
}
-
 
1089
 
925
service TransactionService extends GenericService.GenericService{
1090
service TransactionService extends GenericService.GenericService{
926
	
1091
	
927
	i64 createTransaction(1:Transaction transaction) throws (1:TransactionServiceException ex),
1092
	i64 createTransaction(1:Transaction transaction) throws (1:TransactionServiceException ex),
928
	
1093
	
929
	//	Get transaction methods.
1094
	//	Get transaction methods.
Line 1755... Line 1920...
1755
     bool homeShopOrderExists(1:string hsOrderNo, 2:string hsSubOrderNo);
1920
     bool homeShopOrderExists(1:string hsOrderNo, 2:string hsSubOrderNo);
1756
     
1921
     
1757
     Order splitBulkOrder(1:i64 orderId, 2:i64 splitOrderQty);
1922
     Order splitBulkOrder(1:i64 orderId, 2:i64 splitOrderQty);
1758
     
1923
     
1759
     string moveOrdersToCorrectWarehouse();
1924
     string moveOrdersToCorrectWarehouse();
-
 
1925
     
-
 
1926
     Creditor getCreditorInfo(1:i64 id, 2:string name)
-
 
1927
    
-
 
1928
    bool updateCreditorInfo(1:Creditor creditor) 
-
 
1929
    
-
 
1930
    list<UserSanction> getUserSanctionDetails(1:i64 userId)
-
 
1931
    
-
 
1932
    UserSanction getUserSanctionDetailsForCreditor(1:i64 userId, i64 creditorId)
-
 
1933
    
-
 
1934
    bool updateUserSanction(1:UserSanction userSanaction) throws (1:TransactionServiceException pe)
-
 
1935
    
-
 
1936
    list<CreditHistory> getCreditHistoryRecordsForTransaction(1:i64 paymentId, 2:i64 creditorId, 3:string creditTxnType)
-
 
1937
    
-
 
1938
    list<CreditHistory> getCreditHistoryRecordsForUserAndCreditor(1:i64 userId, 2:string creditTxnType)
-
 
1939
    
-
 
1940
    bool processCreditTransaction(1:i64 paymentId, 2:list<CreditHistory> creditTxns) throws (1:TransactionServiceException pe)
-
 
1941
    
-
 
1942
    list<CreditHistory> getLoanPayableForUserToCreditor(1:i64 userId, 2:i64 creditorId, 3:i64 dueDate)
-
 
1943
    
-
 
1944
    ReturnOrderInfo getReturnOrderInfo(1:i64 id) throws (1:TransactionServiceException ex);
-
 
1945
     
-
 
1946
     map<i64,list<ReturnOrderInfo>> getReturnOrderInfoList(1:list<i64> order_ids);
-
 
1947
	
-
 
1948
	 map<i64,list<ReturnOrderInfo>> getReturnOrderInfoListAsByStatus(1:list<i64> order_ids, 2:list<string> statuses);
-
 
1949
     
-
 
1950
     bool updateReturnOrderInfo(1:ReturnOrderInfo returnInfo) throws (1:TransactionServiceException ex);
-
 
1951
     
-
 
1952
     map<i64, bool> bulkUpdateReturnOrderInfo(1:map<i64,list<ReturnOrderInfo>> orderReturnInfosMap) throws (1:TransactionServiceException ex);
-
 
1953
     
-
 
1954
     list<ReturnOrderInfo> getReturnOrdersAsPerWarehouseId(1:i64 warehouseId);
-
 
1955
     
-
 
1956
     i64 createReturnTransaction(1:ReturnTransaction returnTransaction) throws (1:TransactionServiceException ex);
-
 
1957
     
-
 
1958
     ReturnTransaction getReturnTransaction(1:i64 id) throws (1:TransactionServiceException ex);
-
 
1959
	 
-
 
1960
	 list<ReturnOrderInfo> getReturnOrdersForReturnTransaction(1:i64 returnTransactionId)  throws (1:TransactionServiceException ex);
-
 
1961
	 
-
 
1962
	 bool changeReturnTransactionStatus(1:i64 returnTransactionId, 2:ReturnTransactionStatus status, 3:list<i64> returnOrderIds) throws (1:TransactionServiceException ex);
-
 
1963
	 
-
 
1964
	 bool createReturnPickupRequest(1:list<i64> returnOrderIds, 2:i64 providerId) throws (1:TransactionServiceException ex);
-
 
1965
	 
-
 
1966
	 bool updateReturnPickupRequest(1:ReturnPickupRequest returnPickupRequest) throws (1:TransactionServiceException ex);
-
 
1967
	 
-
 
1968
	 list<ReturnOrderInfo> getAllReturnOrdersForReturnPickupRequest(1:i64 logisticsRequestId) throws (1:TransactionServiceException ex);
-
 
1969
	 
-
 
1970
	 bool receiveReturnPickup(1:map<i64,map<string, string>> returnOrdersMap, 2:i64 id) throws (1:TransactionServiceException ex);
-
 
1971
	 
-
 
1972
	 bool validateReturnPickup(1:i64 returnPickupId, 2:map<i64, bool>returnOrdersMap) throws (1:TransactionServiceException ex);
-
 
1973
	 
-
 
1974
	 bool processReturnPickup(1:i64 returnPickupId, 2:map<i64, map<string, string>> returnOrdersMap) throws (1:TransactionServiceException ex);
-
 
1975
	 
-
 
1976
	 bool markReturnTransactionComplete(1:i64 returnTransactionId) throws (1:TransactionServiceException ex);
-
 
1977
	 
-
 
1978
	 bool refundReturnTransactionPayment(1:map<i64, map<string, string>> refundOrdersMap, 2:i64 returntransactionId) throws (1:TransactionServiceException ex);
-
 
1979
	 
-
 
1980
	 list<ReturnTransaction> getReturnTransactionsForCustomer(1:list<ReturnTransactionStatus> statusList, 2:string customerMobile, 3:string customerEmail, 4:i64 returnTransactionId, 5:i64 customerId) throws (1:TransactionServiceException ex);
-
 
1981
	 
-
 
1982
	 bool verifyOrderForTransaction(1:i64 transactionId) throws (1:TransactionServiceException ex);
-
 
1983
 
1760
}
1984
}
1761
1985