Subversion Repositories SmartDukaan

Rev

Rev 18578 | Rev 18634 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
68 ashish 1
namespace java in.shop2020.model.v1.order
95 ashish 2
namespace py shop2020.thriftpy.model.v1.order
3374 rajveer 3
 
4
include "GenericService.thrift"
5
 
68 ashish 6
/***
7
	Order objects.
8
*/
11173 vikram.rag 9
 
10
enum AmazonFCWarehouseLocation {
11
	Mumbai = 0,
12872 amit.gupta 12
	Bangalore = 1,
13
	Gurgaon = 2
11173 vikram.rag 14
}
15
 
13584 manish.sha 16
enum FlipkartFCWarehouseLocation {
17
	Delhi = 0
18
}
19
 
483 rajveer 20
enum OrderStatus{
845 chandransh 21
	PAYMENT_PENDING,
22
	PAYMENT_FAILED,
4661 rajveer 23
	COD_VERIFICATION_PENDING,
483 rajveer 24
	SUBMITTED_FOR_PROCESSING,
25
	ACCEPTED,
26
	INVENTORY_LOW,
495 rajveer 27
	REJECTED,
483 rajveer 28
	BILLED,
4245 rajveer 29
	PAYMENT_FLAGGED, 
483 rajveer 30
	SHIPPED_FROM_WH,
31
	SHIPPED_TO_LOGST,
4245 rajveer 32
	PAYMENT_FLAGGED_DENIED,      
483 rajveer 33
	DELIVERY_SUCCESS,
4245 rajveer 34
	CANCEL_REQUEST_RECEIVED,
35
	CANCEL_REQUEST_CONFIRMED,
36
	CANCELLED_ON_CUSTOMER_REQUEST,
4910 phani.kuma 37
	SHIPPED_TO_DESTINATION_CITY,
38
	REACHED_DESTINATION_CITY,
4682 rajveer 39
	COD_VERIFICATION_FAILED,
2537 chandransh 40
	FAILED,
4484 rajveer 41
	RTO_IN_TRANSIT,
42
	RTO_RECEIVED_PRESTINE,
4452 rajveer 43
	DOA_PICKUP_REQUEST_RAISED,
44
	DOA_PICKUP_CONFIRMED,
2537 chandransh 45
	DOA_RETURN_IN_TRANSIT,
4452 rajveer 46
	DOA_RECEIVED_PRESTINE,
2537 chandransh 47
	DOA_CERT_INVALID,
2614 chandransh 48
	DOA_CERT_VALID,
4484 rajveer 49
	RTO_RESHIPPED,
2614 chandransh 50
	DOA_INVALID_RESHIPPED,
4452 rajveer 51
	DOA_VALID_RESHIPPED,
4484 rajveer 52
	RTO_REFUNDED,
2614 chandransh 53
	DOA_VALID_REFUNDED,
54
	DOA_INVALID_REFUNDED,
4682 rajveer 55
	CANCELLED_DUE_TO_LOW_INVENTORY,
4303 rajveer 56
	LOW_INV_PO_RAISED,
57
	LOW_INV_REVERSAL_IN_PROCESS,
4369 rajveer 58
	LOW_INV_NOT_AVAILABLE_AT_HOTSPOT,
59
	LOW_INV_PO_RAISED_TIMEOUT,
4410 rajveer 60
	LOW_INV_REVERSAL_TIMEOUT,
4910 phani.kuma 61
	FIRST_DELIVERY_ATTEMPT_MADE,
4452 rajveer 62
	CAPTURE_IN_PROCESS,
63
	DOA_REQUEST_RECEIVED,
64
	DOA_REQUEST_AUTHORIZED,
65
	DOA_PICKUP_DENIED,
66
	DOA_RECEIVED_DAMAGED,
67
	DOA_LOST_IN_TRANSIT,
4459 rajveer 68
	DOA_RESHIPPED_RCVD_DAMAGED,
69
	DOA_REFUNDED_RCVD_DAMAGED,
70
	DOA_RESHIPPED_LOST_IN_TRANSIT,
4486 rajveer 71
	DOA_REFUNDED_LOST_IN_TRANSIT,
72
	RTO_RECEIVED_DAMAGED,
73
	RTO_LOST_IN_TRANSIT,
74
	RTO_DAMAGED_RESHIPPED,
75
	RTO_DAMAGED_REFUNDED,
76
	RTO_LOST_IN_TRANSIT_RESHIPPED,
77
	RTO_LOST_IN_TRANSIT_REFUNDED,
4488 rajveer 78
	RTO_INVENTORY_REVERSED,
79
	RET_REQUEST_RECEIVED,
80
	RET_REQUEST_AUTHORIZED,
81
	RET_PICKUP_REQUEST_RAISED,
82
	RET_PICKUP_DENIED,
83
	RET_PICKUP_CONFIRMED,
84
	RET_RETURN_IN_TRANSIT,
85
	RET_RECEIVED_PRESTINE,
86
	RET_RECEIVED_DAMAGED,
87
	RET_LOST_IN_TRANSIT,
88
	RET_PRODUCT_USABLE,
89
	RET_PRODUCT_UNUSABLE,
90
	RET_PRODUCT_USABLE_RESHIPPED,
91
	RET_PRODUCT_USABLE_REFUNDED,
92
	RET_PRODUCT_UNUSABLE_RESHIPPED,
93
	RET_PRODUCT_UNUSABLE_REFUNDED,
94
	RET_RESHIPPED_RCVD_DAMAGED,
95
	RET_REFUNDED_RCVD_DAMAGED,
96
	RET_RESHIPPED_LOST_IN_TRANSIT,
4661 rajveer 97
	RET_REFUNDED_LOST_IN_TRANSIT,
98
	LOST_IN_TRANSIT,
99
	LOST_IN_TRANSIT_RESHIPPED,
5553 rajveer 100
	LOST_IN_TRANSIT_REFUNDED,
101
	DELIVERED_AT_STORE,
18578 manish.sha 102
	RECEIVED_AT_STORE,
103
	APPROVAL_PENDING
483 rajveer 104
}
105
 
106
enum TransactionStatus{
107
	INIT,
108
	IN_PROCESS,
109
	COMPLETED,
2964 chandransh 110
	FAILED,
3060 chandransh 111
	AUTHORIZED,
4245 rajveer 112
	COD_IN_PROCESS,
113
	FLAGGED
483 rajveer 114
}
115
 
5527 anupam.sin 116
enum OrderType{
6055 rajveer 117
	B2C,
118
	B2Cbulk,
119
	B2B,
7096 anupam.sin 120
	RECHARGE,
121
	RCH4HOTSPOT,
122
	WALLETCREDIT
5527 anupam.sin 123
}
124
 
4008 mandeep.dh 125
enum ExtraTransactionProcessingType {
126
    COD_VERIFICATION,
4245 rajveer 127
    DELAYED_DELIVERY,
6104 rajveer 128
    PAYMENT_FLAGGED,
129
    RECHARGE_UNKNOWN
4008 mandeep.dh 130
}
131
 
6289 anupam.sin 132
enum DenominationType {
133
	TOPUP = 1,
134
    SPECIAL = 2,
135
    DATA = 3
136
}
137
 
9159 amar.kumar 138
enum TaxType {
139
	VAT = 0,
140
	CST = 1,
141
	CFORM = 2
142
}
143
 
483 rajveer 144
struct LineItem{
145
	1:i64 id,
698 chandransh 146
	2:i64 item_id,
4008 mandeep.dh 147
	3:string productGroup,
956 chandransh 148
	4:string brand,
149
	5:string model_number,
4586 mandeep.dh 150
	6:string color,
956 chandransh 151
	7:string model_name,
152
	8:string extra_info,
153
	9:double quantity,
12280 amit.gupta 154
	10:double mrp,
155
	11:double unit_price,
156
	12:double unit_weight,
157
	13:double total_price,
158
	14:double transfer_price,
159
	15:double total_weight,
160
	16:optional string serial_number,
161
	17:optional string item_number,
162
	18:optional string dealText,
163
	19:i64 warrantry_expiry_timestamp,
164
	20:double vatRate,
165
	21:double nlc
483 rajveer 166
}
167
 
3553 chandransh 168
enum DelayReason {
169
	INVENTORY_LOW_PHASED_OUT,
170
	INVENTORY_LOW_COLOR_NOT_AVAILABLE,
171
	INVENTORY_LOW_REVERSAL_NOT_ON_TIME,
172
	INVENTORY_LOW_PRODUCT_NOT_SEALED,
173
	COURIER_DELAY_NOT_DELIVERED_TO_COURIER_ON_TIME,
174
	COURIER_DELAY_DID_NOT_CONNECT,
175
	COURIER_DELAY_CUSTOMER_NOT_AVAILABLE,
9416 amar.kumar 176
	COURIER_DELAY_INCORRECT_ADDRESS,
3553 chandransh 177
	COURIER_DELAY_OCTROI_DELAY,
178
	COURIER_DELAY_FORCES_OF_NATURE,
179
	COD_VERIFICATION_DELAY,
180
	PAYMENT_FLAGGED,
181
	OTHERS
182
}
483 rajveer 183
 
8717 amar.kumar 184
enum ProductCondition{
185
	GOOD,
186
	BAD
187
}
188
 
483 rajveer 189
struct Order{
190
	1:i64 id,
191
	2:i64 warehouse_id,
192
	/**
193
		item info
194
	**/
195
	3:list<LineItem> lineitems,
196
	/**
197
	  logistics info
198
	**/
199
	4:i64 logistics_provider_id,
200
	5:string airwaybill_no,
201
	6:string tracking_id,
202
	7:i64 expected_delivery_time,
203
	/**
204
	  customer info
205
	**/
206
	8:i64 customer_id,
207
	9:string customer_name,
208
	10:string customer_mobilenumber,
209
	11:string customer_pincode,
735 chandransh 210
	12:string customer_address1,
211
	13:string customer_address2,
212
	14:string customer_email,
213
	15:string customer_city,
214
	16:string customer_state,
483 rajveer 215
 
216
	/**
217
		status and misc info
218
	**/
735 chandransh 219
	17:OrderStatus status,
220
	18:string statusDescription,
221
	19:double total_amount,
222
	20:double total_weight,
483 rajveer 223
	/**
224
		billing info
225
	**/
735 chandransh 226
	21:string invoice_number,
227
	22:string billed_by,
483 rajveer 228
	/**
229
		timestamps
230
	**/
735 chandransh 231
	23:i64 created_timestamp,
232
	24:i64 accepted_timestamp,
233
	25:i64 billing_timestamp,
234
	26:i64 shipping_timestamp,
1115 chandransh 235
	27:i64 pickup_timestamp,
236
	28:i64 delivery_timestamp,
1210 chandransh 237
	29:i64 outofstock_timestamp,
238
	30:i64 jacket_number,
1223 chandransh 239
	31:string receiver,
240
	32:i64 batchNo,
2537 chandransh 241
	33:i64 serialNo,
242
	34:bool doaFlag,
2675 vikas 243
	35:string pickupRequestNo,
2819 chandransh 244
	36:i64 transactionId,
3060 chandransh 245
	37:string purchaseOrderNo,
3553 chandransh 246
	38:bool cod,
4004 chandransh 247
	39:DelayReason delayReason,
248
	40:i64 promised_delivery_time,
249
	41:i64 expected_shipping_time,
4102 chandransh 250
	42:i64 verification_timestamp,
4192 anupam.sin 251
	43:i64 promised_shipping_time,
252
	44:optional i64 reship_timestamp,
253
	45:optional i64 refund_timestamp,
4245 rajveer 254
	46:optional i64 new_order_id,
4269 anupam.sin 255
	47:OrderStatus previousStatus,
4506 phani.kuma 256
	48:i64 vendorId,
4647 rajveer 257
	49:optional i64 doa_auth_timestamp,
4709 rajveer 258
	50:string delayReasonText,
4758 mandeep.dh 259
	51:string refundReason,
4815 phani.kuma 260
	52:i64 purchaseOrderId,
5062 varun.gupt 261
	53:optional i64 doa_logistics_provider_id,
5110 mandeep.dh 262
	54:i64 originalOrderId,
5189 varun.gupt 263
	55:i64 fulfilmentWarehouseId,
5354 anupam.sin 264
	56:bool vendorPaid,
265
	57:optional i64 received_return_timestamp,
5527 anupam.sin 266
	58:optional i64 first_attempt_timestamp,
5553 rajveer 267
	59:OrderType orderType,
268
	60:i64 pickupStoreId,
6318 rajveer 269
	61:bool logisticsCod,
6525 rajveer 270
	62:i64 gvAmount,
6726 rajveer 271
	63:bool otg,
272
	64:i64 courier_delivery_time
6903 anupam.sin 273
	65:i64 insurer,
274
	66:double insuranceAmount,
275
	67:string dob,
7190 amar.kumar 276
	68:string guardianName,
7293 anupam.sin 277
	69:i64 freebieItemId,
278
	70:i64 source,
279
	71:double advanceAmount,
8717 amar.kumar 280
	72:i64 storeId,
9299 kshitij.so 281
	73:ProductCondition productCondition,
282
	74:i64 dataProtectionInsurer,
9416 amar.kumar 283
	75:double dataProtectionAmount,
13148 manish.sha 284
	76:TaxType taxType,
17470 manish.sha 285
	77:string logisticsTransactionId,
286
	78:double shippingCost,
287
	79:double codCharges
483 rajveer 288
}
289
 
5527 anupam.sin 290
struct Attribute{
291
	1:string name,
292
	2:string value
293
}
294
 
4245 rajveer 295
struct OrderStatusAuditTrail{
296
	1:i64 id,
297
	2:i64 orderId,
298
	3:i64 status,
299
	4:i64 timestamp,
300
	5:i64 description
301
}
302
 
7442 vikram.rag 303
struct AmazonOrdersToAcknowledge{
304
	1:string amazonOrderId,
305
	2:string amazonOrderItemId,
306
	3:string status,
307
	4:i64 transaction_id,
308
	5:i32 count
309
}
310
 
483 rajveer 311
struct Transaction{
312
	1:i64 id,
313
	2:list<Order> orders,
680 rajveer 314
	3:i64 createdOn,
315
	4:TransactionStatus transactionStatus,
316
	5:string statusDescription,
317
	6:i64 shoppingCartid,
2219 varun.gupt 318
	7:i64 customer_id,
2814 vikas 319
	8:string coupon_code,
320
	9:string sessionSource,
3858 vikas 321
	10:i64 sessionStartTime,
322
	11:string firstSource,
6389 rajveer 323
    12:i64 firstSourceTime,
17470 manish.sha 324
    13:i64 emiSchemeId,
325
    14:double totalShippingCost,
326
    15:double totalCodCharges
483 rajveer 327
}
328
 
4393 rajveer 329
enum AlertType{
330
	NEW_INVENTORY_ALERT,
331
	ORDER_READY_TO_ACCEPT
332
}
333
 
483 rajveer 334
struct Alert{
335
	1:i64 id,
4393 rajveer 336
	2:AlertType type,
337
	3:i64 status,
338
	4:i64 timestamp,
339
	5:string description
4444 rajveer 340
	6:i64 warehouseId
483 rajveer 341
}
342
 
2688 chandransh 343
struct ReturnOrder{
344
	1:i64 orderId,
2697 chandransh 345
	2:i64 warehouseId,
346
    3:i64 jacketNumber,
347
    4:string invoiceNumber,
348
    5:i64 itemId,
349
    6:string productGroup,
350
    7:string brand,
351
    8:string modelNumber,
352
    9:string modelName,
353
    10:string color,
354
    11:double totalPrice,
355
    12:double transferPrice,
356
    13:bool processedStatus,
357
    14:i64 createdAt,
358
    15:i64 processedAt
2688 chandransh 359
}
360
 
4600 varun.gupt 361
struct PaymentSettlement	{
362
    2:i64 paymentGatewayId,
4905 varun.gupt 363
    3:i64 referenceId,
4600 varun.gupt 364
    4:i64 settlementDate,
365
    5:double serviceTax,
366
    6:double otherCharges,
367
    7:double netCollection
368
}
369
 
4875 varun.gupt 370
struct CODPaymentSettlement	{
371
    1:i64 orderId,
372
    2:i64 settlementDate,
373
    3:double collection
374
}
375
 
4303 rajveer 376
enum HotspotAction{
377
	PO_RAISED,
378
	REVERSAL_INITIATED,
379
	NOT_AVAILABLE
380
}
381
 
4369 rajveer 382
struct TimeoutSummary{
383
	1:i32 poRaised,
384
	2:i32 poEstimate
385
	3:i32 reversalInitiated,
386
	4:i32 reversalEstimate
387
}
388
 
5447 anupam.sin 389
struct CODVerificationAgent{
390
	1:i64 orderId,
391
	2:string agentEmailId
392
}
393
 
6000 mandeep.dh 394
enum RechargeType {
395
    MOBILE = 1,
396
    DTH = 2
397
}
398
 
399
enum RechargeOrderStatus {
400
    PAYMENT_PENDING = 1,
6031 rajveer 401
    PAYMENT_FAILED = 2,
402
    PAYMENT_SUCCESSFUL = 3,
6000 mandeep.dh 403
    RECHARGE_FAILED = 4,
6235 rajveer 404
    RECHARGE_SUCCESSFUL = 5,
6507 anupam.sin 405
    RECHARGE_FAILED_REFUNDED = 6,
406
    REFUNDED = 7,
7073 anupam.sin 407
    PARTIALLY_REFUNDED = 8,
408
    INIT = 9,
12979 kshitij.so 409
    RECHARGE_UNKNOWN = 10,
410
    RECHARGE_IN_PROCESS = 11
6000 mandeep.dh 411
}
412
 
7293 anupam.sin 413
enum OrderSource {
414
	WEBSITE = 1,
7355 vikram.rag 415
	STORE = 2,
7410 amar.kumar 416
	AMAZON =3,
417
	HOMESHOP18  = 4,
418
	NAAPTOL = 5,
8488 amar.kumar 419
	EBAY = 6,
8983 vikram.rag 420
	SNAPDEAL = 7,
11524 amit.gupta 421
	FLIPKART = 8,
12580 amit.gupta 422
	MOBILESITE = 9,
423
	JUNGLEE = 10	
7293 anupam.sin 424
}
425
 
12979 kshitij.so 426
enum RechargeMode {
427
	SYNC = 1,
428
	ASYNC = 2
429
}
430
 
13941 amit.gupta 431
 
432
enum WalletSource {
433
	RECHARGE = 1,
434
	PHYSICAL = 2,
435
	DTR = 3
436
}
437
 
6000 mandeep.dh 438
struct RechargeOrder {
6031 rajveer 439
    1:i64 id,
440
    2:string displayId,
441
    3:i64 totalAmount,
442
    4:i64 walletAmount,
443
    5:i64 transactionId,
6077 anupam.sin 444
    6:i64 invoiceNumber,
6031 rajveer 445
    7:OrderType orderType,
446
    8:i64 operatorId,
447
    9:RechargeType rechargeType,
448
   10:RechargeOrderStatus status,
449
   11:string deviceNumber,
450
   12:i64 userId,
451
   13:string userEmailId,
6048 rajveer 452
   14:i64 creationTimestamp,
453
   15:string spiceTID,
6094 rajveer 454
   16:i64 responseTimestamp,
6159 rajveer 455
   17:string description,
6433 anupam.sin 456
   18:string plan,
457
   19:string couponCode,
6515 anupam.sin 458
   20:i64 couponAmount,
6591 anupam.sin 459
   21:i64 refundTimestamp,
460
   22:string ipAddress
6000 mandeep.dh 461
}
462
 
6188 rajveer 463
struct RechargeStatistics{
6190 rajveer 464
	1:map<i64, i64> statusCounts,
465
	2:map<i64, i64> operatorCounts,
6188 rajveer 466
    3:map<string, list<RechargeOrder>> currentOrders,
467
    4:map<string, i64> amounts
468
}
469
 
6159 rajveer 470
struct RechargePlan {
471
	1:i64 operatorId,
472
    2:string name,
473
    3:string displayName,
474
    4:string description
475
}
476
 
6289 anupam.sin 477
struct RechargeDenomination {
478
	1:i64 operatorId,
479
	2:i64 circleId,
480
	3:DenominationType denominationType,
481
	4:i64 amount,
482
	5:string validity,
483
	6:string description
484
}
485
 
486
struct DeviceNumberInfo {
487
	1:i64 operatorId,
6336 anupam.sin 488
	2:string circleCode
6310 anupam.sin 489
	3:string operatorName
6289 anupam.sin 490
}
491
 
6031 rajveer 492
struct UserWallet {
6000 mandeep.dh 493
    1:i64 id,
494
    2:i64 amount,
6031 rajveer 495
    3:i64 userId   
6000 mandeep.dh 496
}
497
 
6031 rajveer 498
struct UserWalletHistory {
499
	1:i64 id,
500
    2:i64 walletId,
501
    3:i64 orderId,
502
    4:i64 amount,
503
    5:i64 timestamp    
6000 mandeep.dh 504
}
505
 
6389 rajveer 506
enum EmiChargeType {
507
    FIXED = 1,
508
    PERCENTAGE = 2
509
}
510
 
511
struct EmiScheme{
512
    1:i64 id,
513
    2:i64 gatewayId,
514
	3:i64 bankId,
515
    4:i64 tenure,
516
    5:string bankName,
6392 amit.gupta 517
    6:i64 minAmount,
6389 rajveer 518
    7:string tenureDescription,
519
    8:EmiChargeType	chargeType,
8942 rajveer 520
    9:double chargeValue,
521
    10:double interestRate    
6389 rajveer 522
}
523
 
483 rajveer 524
exception TransactionServiceException{
525
	1:i32 errorCode,
526
	2:string message
527
}
528
 
7073 anupam.sin 529
struct Company{
530
    1:i64 id,
531
    2:string name,
532
    3:string Address
533
}
534
 
535
struct WalletForCompany{
536
    1:i64 id,
537
    2:i64 companyId,
538
    3:double amount
539
}
540
 
541
struct WalletHistoryForCompany{
542
    1:i64 id,
543
    2:i64 walletId,
544
    3:double amount,
545
    4:i64 transactionTime,
546
    5:double openingBal,
547
    6:double closingBal,
548
    7:i64 referenceNumber,
549
    8:string description
550
}
551
 
552
enum PayMethod{
553
	CASH = 1,
8008 anupam.sin 554
	CARD = 2,
555
	CHEQUE = 3
7073 anupam.sin 556
}
557
 
7080 anupam.sin 558
struct FRC {
559
    1:i64 id,
560
    2:i64 operatorId,
561
    3:i64 circleId,
562
    4:i64 denomination,
563
    5:i64 maxDiscount
564
}
565
 
7096 anupam.sin 566
struct HotspotStore {
567
	1:i64 id,
568
    2:string hotspotId,	
569
    3:i64 companyId,
570
    4:string name,
571
    5:string city,
572
    6:i64 collectedAmount,
573
    7:i64 availableLimit,
574
    8:i64 creditLimit,
575
    9:string salt,
576
    10:string password,
577
    11:bool isActive,
7169 anupam.sin 578
    12:i64 circleId,
7308 rajveer 579
    13:string email,
580
    14:string line1,
581
    15:string line2,
582
    16:string state,
583
    17:string pin,
584
    18:string phone,
585
    19:string approvalEmail
7096 anupam.sin 586
}
587
 
7967 anupam.sin 588
struct HotspotServiceMatrix {
589
	1:i64 storeId,
590
	2:string hotspotId,
591
	3:bool pickupFromStoreService,
592
	4:bool storeWebsiteService,
593
	5:bool rechargeService
594
}
595
 
7073 anupam.sin 596
struct RechargeTransaction{
597
    1:i64 id,
598
    2:i64 storeId,
599
    3:double amount,
600
    4:i64 transactionTime,
601
    5:string deviceNum,
602
    6:RechargeType deviceType,
603
    7:bool isFrc,
604
    8:string email,
605
    9:double discount,
606
    10:double paymentAmount,
607
    11:PayMethod payMethod,
608
    12:RechargeOrderStatus status,
609
    13:string invoiceNumber,
610
    14:i64 circleId,
611
    15:i64 operatorId,
612
    16:string plan,
613
    17:string ipAddress,
614
    18:string name,
615
    19:string cafNum,
7080 anupam.sin 616
    20:string simNum,
7096 anupam.sin 617
    21:string alternateNumber,
7169 anupam.sin 618
    22:string description,
7369 rajveer 619
    23:i64 responseTime,
620
	24:string spiceTID,
621
    25:string aggTID,
622
    26:string providerTID
7073 anupam.sin 623
}
624
 
7096 anupam.sin 625
struct TelecomCircle {
626
	1:i64 id,
627
    2:string name,
628
    3:string code
629
}
630
 
7263 anupam.sin 631
struct SourceDetail {
632
	1:i64 id,
633
    2:string name,
7410 amar.kumar 634
    3:string email,
7530 kshitij.so 635
    4:string tinNumber,
636
    5:i64 lastUpdatedOn
7263 anupam.sin 637
}
638
 
7311 kshitij.so 639
struct AmazonOrder {
640
    1:i64 orderId,
7322 vikram.rag 641
    2:string amazonOrderCode,
642
    3:string amazonOrderItemCode,
7311 kshitij.so 643
    4:i64 transactionId,
7715 vikram.rag 644
    5:i64 item_id,
645
    6:string status,
646
    7:i64 purchaseDateOnAmazon
7311 kshitij.so 647
}
648
 
7386 anupam.sin 649
enum StorePaymentStatus{
650
	ADV_RECEIVED = 1,
651
	ADV_REFUNDED = 2,
652
	FULL_PAY_RECEIVED = 3,
653
	REFUNDED = 4,
7423 anupam.sin 654
	REFUND_REQUESTED = 5,
655
	REFUND_INITIATED = 6
7386 anupam.sin 656
}
657
 
658
struct StoreOrderDetail {
659
	1:i64 orderId,
660
	2:i64 storeId,
661
	3:double advanceAmount,
662
	4:double cashAmount,
663
	5:double cardAmount,
7393 anupam.sin 664
	6:StorePaymentStatus payStatus,
665
	7:string edcBank,
666
	8:double cashRefundAmount,
7423 anupam.sin 667
	9:double cardRefundAmount,
7611 anupam.sin 668
	10:string approvalCode,
669
	11:string cardType
7386 anupam.sin 670
}
671
 
7423 anupam.sin 672
struct StoreOrderCollection {
673
    1:string hotspotId,
674
    2:i64 orderId,
675
    3:string collectionType,
676
    4:string productName,
677
    5:i64 advanceAmount,
678
    6:i64 cash,
679
    7:i64 card,
680
    8:i64 addedAt,
681
    9:i64 pushedAt,
682
    10:bool pushedToOcr
683
}
684
 
8182 amar.kumar 685
struct EbayOrder {
686
	1:i64 orderId,
687
	2:i64 salesRecordNumber,
688
	3:string paisaPayId,
689
	4:string ebayListingId,
690
	5:double subsidyAmount,
691
	6:i64 ebayTxnDate,
692
	7:string transactionId,
693
	8:string listingName,
8241 amar.kumar 694
	9:double listingPrice,
8247 amar.kumar 695
	10:string bluedartPaisaPayRef	
8182 amar.kumar 696
}
697
 
8532 vikram.rag 698
struct FbaItemPrices{
699
	 1:i64 item_id	
700
     2:double minFbaPrice,
701
     3:double minMfnPrice,
702
     4:double ourPrice,
703
     5:double salePrice,
704
     6:i64 minFbaPriceSnapshotDate
705
     7:i64 minMfnPriceSnapshotDate
706
     8:i64 ourPriceSnapshotDate
707
     9:i64 salePriceSnapshotDate
708
 
709
} 
710
 
8488 amar.kumar 711
struct SnapdealOrder {
712
	1:i64 orderId,
713
	2:string referenceCode,
9627 vikram.rag 714
	3:string subOrderId,
8488 amar.kumar 715
	4:double listingPrice,
716
	5:string productName,
717
	6:i64 snapdealTxnDate
9456 vikram.rag 718
	7:double maxNlc
8488 amar.kumar 719
}
720
 
8961 vikram.rag 721
struct FlipkartOrder {
722
	1:string flipkartOrderId,
723
	2:string flipkartSubOrderId,
724
	3:i64 flipkartTxnDate,
725
	4:i64 orderId,
726
	5:double shippingPrice,
727
	6:double octroiFee,  
728
	7:double emiFee
9456 vikram.rag 729
	8:double maxNlc 
8961 vikram.rag 730
}
731
 
4815 phani.kuma 732
struct OrderStatusGroups{
733
	1:list<OrderStatus> codCancellable = [OrderStatus.COD_VERIFICATION_PENDING,
734
										OrderStatus.SUBMITTED_FOR_PROCESSING,
735
										OrderStatus.ACCEPTED,
736
										OrderStatus.INVENTORY_LOW,
737
										OrderStatus.LOW_INV_PO_RAISED,
738
										OrderStatus.LOW_INV_REVERSAL_IN_PROCESS,
739
										OrderStatus.LOW_INV_NOT_AVAILABLE_AT_HOTSPOT,
740
										OrderStatus.BILLED,
741
										OrderStatus.PAYMENT_FLAGGED],
4837 varun.gupt 742
 
4815 phani.kuma 743
	2:list<OrderStatus> prepaidCancellableBeforeBilled = [OrderStatus.COD_VERIFICATION_PENDING,
744
										OrderStatus.SUBMITTED_FOR_PROCESSING,
745
										OrderStatus.ACCEPTED,
746
										OrderStatus.INVENTORY_LOW,
747
										OrderStatus.LOW_INV_PO_RAISED,
748
										OrderStatus.LOW_INV_REVERSAL_IN_PROCESS,
749
										OrderStatus.LOW_INV_NOT_AVAILABLE_AT_HOTSPOT],
4837 varun.gupt 750
 
751
	3:list<OrderStatus> prepaidCancellableAfterBilled = [OrderStatus.BILLED, OrderStatus.PAYMENT_FLAGGED],
752
 
753
	4:list<OrderStatus> openOrders = [
754
										OrderStatus.PAYMENT_PENDING,			OrderStatus.COD_VERIFICATION_PENDING,
755
										OrderStatus.SUBMITTED_FOR_PROCESSING,	OrderStatus.ACCEPTED,
756
										OrderStatus.INVENTORY_LOW,				OrderStatus.BILLED,
757
										OrderStatus.PAYMENT_FLAGGED,			OrderStatus.SHIPPED_FROM_WH,
758
										OrderStatus.SHIPPED_TO_LOGST,			OrderStatus.PAYMENT_FLAGGED_DENIED,
4910 phani.kuma 759
										OrderStatus.SHIPPED_TO_DESTINATION_CITY,	OrderStatus.REACHED_DESTINATION_CITY,
4837 varun.gupt 760
										OrderStatus.CANCEL_REQUEST_RECEIVED,	OrderStatus.CANCEL_REQUEST_CONFIRMED,
761
										OrderStatus.RTO_IN_TRANSIT,				OrderStatus.RTO_RECEIVED_PRESTINE,
762
										OrderStatus.DOA_PICKUP_REQUEST_RAISED,	OrderStatus.DOA_PICKUP_CONFIRMED,
763
										OrderStatus.DOA_RETURN_IN_TRANSIT,		OrderStatus.DOA_RECEIVED_PRESTINE,
764
										OrderStatus.DOA_CERT_INVALID,			OrderStatus.DOA_CERT_VALID,
765
										OrderStatus.LOW_INV_PO_RAISED,			OrderStatus.LOW_INV_REVERSAL_IN_PROCESS,
766
										OrderStatus.LOW_INV_NOT_AVAILABLE_AT_HOTSPOT,	OrderStatus.LOW_INV_PO_RAISED_TIMEOUT,
4910 phani.kuma 767
										OrderStatus.LOW_INV_REVERSAL_TIMEOUT,	OrderStatus.FIRST_DELIVERY_ATTEMPT_MADE,
4837 varun.gupt 768
										OrderStatus.CAPTURE_IN_PROCESS,			OrderStatus.DOA_REQUEST_RECEIVED,
769
										OrderStatus.DOA_REQUEST_AUTHORIZED,		OrderStatus.DOA_RECEIVED_DAMAGED,
770
										OrderStatus.DOA_LOST_IN_TRANSIT,		OrderStatus.RTO_RECEIVED_DAMAGED,
771
										OrderStatus.RTO_LOST_IN_TRANSIT,		OrderStatus.RTO_INVENTORY_REVERSED,
772
										OrderStatus.RET_REQUEST_RECEIVED,		OrderStatus.RET_REQUEST_AUTHORIZED,
773
										OrderStatus.RET_PICKUP_REQUEST_RAISED,	OrderStatus.RET_PICKUP_DENIED,
774
										OrderStatus.RET_PICKUP_CONFIRMED,		OrderStatus.RET_RETURN_IN_TRANSIT,
775
										OrderStatus.RET_RECEIVED_PRESTINE,		OrderStatus.RET_RECEIVED_DAMAGED,
776
										OrderStatus.RET_LOST_IN_TRANSIT,		OrderStatus.RET_PRODUCT_USABLE,
5867 rajveer 777
										OrderStatus.DELIVERED_AT_STORE,			OrderStatus.RECEIVED_AT_STORE
4983 phani.kuma 778
									],
5031 varun.gupt 779
	5:list<OrderStatus> refundedOrders = [
780
										OrderStatus.CANCELLED_ON_CUSTOMER_REQUEST,	OrderStatus.RTO_REFUNDED,
781
										OrderStatus.DOA_VALID_REFUNDED,				OrderStatus.DOA_INVALID_REFUNDED,
782
										OrderStatus.CANCELLED_DUE_TO_LOW_INVENTORY,	OrderStatus.DOA_REFUNDED_RCVD_DAMAGED,
783
										OrderStatus.DOA_REFUNDED_LOST_IN_TRANSIT,	OrderStatus.RTO_DAMAGED_REFUNDED,
784
										OrderStatus.RTO_LOST_IN_TRANSIT_REFUNDED,	OrderStatus.RET_PRODUCT_USABLE_REFUNDED,
785
										OrderStatus.RET_PRODUCT_UNUSABLE_REFUNDED,	OrderStatus.RET_REFUNDED_LOST_IN_TRANSIT,
786
										OrderStatus.RET_REFUNDED_RCVD_DAMAGED,		OrderStatus.LOST_IN_TRANSIT_REFUNDED
787
									],
788
	6:list<OrderStatus> shippedOrders = [
4983 phani.kuma 789
										OrderStatus.SHIPPED_FROM_WH,			OrderStatus.SHIPPED_TO_LOGST,
790
										OrderStatus.SHIPPED_TO_DESTINATION_CITY,	OrderStatus.REACHED_DESTINATION_CITY,
791
										OrderStatus.RTO_IN_TRANSIT,				OrderStatus.RTO_RECEIVED_PRESTINE,
792
										OrderStatus.DOA_PICKUP_REQUEST_RAISED,	OrderStatus.DOA_PICKUP_CONFIRMED,
793
										OrderStatus.DOA_RETURN_IN_TRANSIT,		OrderStatus.DOA_RECEIVED_PRESTINE,
794
										OrderStatus.DOA_CERT_INVALID,			OrderStatus.DOA_CERT_VALID,
795
										OrderStatus.FIRST_DELIVERY_ATTEMPT_MADE,OrderStatus.DOA_REQUEST_RECEIVED,
796
										OrderStatus.DOA_REQUEST_AUTHORIZED,		OrderStatus.DOA_RECEIVED_DAMAGED,
797
										OrderStatus.DOA_LOST_IN_TRANSIT,		OrderStatus.RTO_RECEIVED_DAMAGED,
798
										OrderStatus.RTO_LOST_IN_TRANSIT,		OrderStatus.RTO_INVENTORY_REVERSED,
799
										OrderStatus.RET_REQUEST_RECEIVED,		OrderStatus.RET_REQUEST_AUTHORIZED,
800
										OrderStatus.RET_PICKUP_REQUEST_RAISED,	OrderStatus.RET_PICKUP_DENIED,
801
										OrderStatus.RET_PICKUP_CONFIRMED,		OrderStatus.RET_RETURN_IN_TRANSIT,
802
										OrderStatus.RET_RECEIVED_PRESTINE,		OrderStatus.RET_RECEIVED_DAMAGED,
803
										OrderStatus.RET_LOST_IN_TRANSIT,		OrderStatus.RET_PRODUCT_USABLE,
5867 rajveer 804
										OrderStatus.RET_PRODUCT_UNUSABLE,		OrderStatus.LOST_IN_TRANSIT,
805
										OrderStatus.DELIVERED_AT_STORE,			OrderStatus.RECEIVED_AT_STORE
4983 phani.kuma 806
									],
5031 varun.gupt 807
	7:list<OrderStatus> failedOrders = [
4983 phani.kuma 808
										OrderStatus.PAYMENT_FAILED,				OrderStatus.CANCELLED_DUE_TO_LOW_INVENTORY,
809
										OrderStatus.REJECTED,					OrderStatus.DOA_INVALID_REFUNDED,
810
										OrderStatus.DOA_INVALID_RESHIPPED,		OrderStatus.DOA_VALID_REFUNDED,
811
										OrderStatus.DOA_VALID_RESHIPPED,		OrderStatus.RTO_REFUNDED,
6566 amit.gupta 812
										OrderStatus.RTO_RESHIPPED, OrderStatus.COD_VERIFICATION_FAILED
4837 varun.gupt 813
									]
4815 phani.kuma 814
}
815
 
8282 kshitij.so 816
struct AmazonFbaSalesSnapshot {
817
	1:i64 dateOfSale
818
	2:i64 item_id
8363 vikram.rag 819
	3:i32 totalOrderCount
8282 kshitij.so 820
	4:i64 amazonFbaInventory
821
	5:bool isOutOfStock
822
    6:double salePrice
823
    7:double minFbaPrice
8363 vikram.rag 824
    8:double minMfnPrice
825
    9:double totalSale
826
    10:double promotionSale
8445 vikram.rag 827
    11:i32 promotionOrderCount
828
    12:double ourPrice
8532 vikram.rag 829
    13:i64 minFbaPriceSnapshotDate
830
    14:i64 minMfnPriceSnapshotDate
831
    15:i64 ourPriceSnapshotDate
832
    16:i64 salePriceSnapshotDate
11173 vikram.rag 833
    17:AmazonFCWarehouseLocation fcLocation
8282 kshitij.so 834
}
835
 
12103 manish.sha 836
struct AmazonFbaOrderReturns {
837
	1:string amazonOrderId,
838
	2:i64 insertionTimestamp,
839
	3:i64 sku,
840
	4:i64 creationTimestamp,
841
	5:i64 shippedQuantity,
842
	6:i64 sellableReturnQuantity,
843
	7:i64 nonSellableReturnQuantity
844
}
845
 
12589 manish.sha 846
struct FlipkartAdvantageOrder {
847
	1:string fkOrderId,
848
	2:string fkOrderItemId,
12772 manish.sha 849
	3:i64 sku,
12589 manish.sha 850
	4:i64 creationTimestamp
851
	5:string customerName,
852
	6:string customerAddress,
853
	7:string pincode,
854
	8:string customerCity,
855
	9:string customerState
856
	10:string customerPhone
857
	11:string status,
858
	12:i64 quantity,
859
	13:double totalPrice,
860
	14:double listPrice,
861
	15:i64 modifiedDate,
862
	16:string listingId,
863
	17:string cancelReason,
864
	18:string returnReason,
865
	19:string freebieItemId,
866
	20:string productTitle
867
}
868
 
13148 manish.sha 869
struct FlipkartFaSalesSnapshot {
870
	1:i64 dateOfSale
871
	2:i64 item_id
872
	3:i32 totalOrderCount
873
	4:bool isOutOfStock
874
    5:double totalSale
875
    6:double ourPrice
13584 manish.sha 876
    7:FlipkartFCWarehouseLocation fcLocation
877
    8:i32 returnQuantity
878
    9:double returnValue
13148 manish.sha 879
}
880
 
13114 kshitij.so 881
struct AmazonHourlySaleSnapshot {
882
	1:i64 snapshotTime
883
	2:i64 item_id
884
	3:i32 totalOrderCount
885
	4:i64 amazonFbaInventory
886
	5:bool isOutOfStock
887
    6:double totalSale
888
    7:double promotionSale
889
    8:i32 promotionOrderCount
890
    9:AmazonFCWarehouseLocation fcLocation
891
}
892
 
13478 kshitij.so 893
struct AmazonFbaOrderItem {
894
	1:string amazonOrderId,
895
	2:i64 purchaseDate,
896
	3:string orderStatus,
897
	4:i64 item_id,
898
	5:AmazonFCWarehouseLocation fcLocation,
899
	6:double totalAmount,
900
	7:double promotionDiscount,
901
	8:i64 quantity
902
}
903
 
13691 manish.sha 904
struct HsOrder {
905
	1:i64 orderId,
906
	2:string hsOrderNo,
907
	3:string hsSubOrderNo,
908
	4:string catalogueName,
909
	5:i64 hsOrderDate,
910
	6:string hsProductId,
911
	7:string hsItemId,
912
	8:string sellerSku,
913
	9:string paymentMode,
914
	10:string courierName,
13734 manish.sha 915
	11:i64 slaDays,
916
	12:string shippingName
13691 manish.sha 917
}
18578 manish.sha 918
 
17470 manish.sha 919
/*
920
struct PaytmOrder {
921
	1:i64 orderId,
922
	2:string paytmOrderId,
923
	3:string paytmSubOrderId,
924
	4:
925
}*/
13691 manish.sha 926
 
18578 manish.sha 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,
18585 amit.gupta 951
	PAID,
952
	DEFAULTED
18578 manish.sha 953
}
954
 
955
struct CreditHistory{
956
	1:i64 user_id,
957
	2:i64 creditor_id,
958
	3:i64 payment_id, 
959
	4:double  amount,
18585 amit.gupta 960
	5:CreditTxnType credit_type, 
18578 manish.sha 961
	6:i64 created, 
962
	7:i64 updated,  
963
	8:string loan_id, 
964
	9:string shipping_id,
18585 amit.gupta 965
	10:i64 due_date
18578 manish.sha 966
}
967
 
968
enum ReturnAction{
969
	REPLACEMENT,
970
	REFUND
971
}
972
 
973
enum ReturnPickupType{
974
	NOW,
975
	LATER,
976
	NOT_REQUIRED
977
}
978
 
979
enum RefundType{
980
	INIT,
981
	CHEQUE,
982
	WALLET,
983
	COUPON,
984
	GATEWAY,
985
	REPLACEMENT
986
}
987
 
988
enum ReplacementShippingType{
989
	IMMEDIATE,
990
	LATER
991
}
992
 
993
enum ReturnTxnPickupStatus{
994
	PENDING,
995
	PICKUP_REQUESTED,
996
	PICKUP_CONFIRMED,
997
	PICKUP_SCHEDULED,
998
	PICKUP_IN_TRANSIT,
999
	PICKUP_RECEIVED
1000
}
1001
 
1002
struct ReturnPickupRequest{
1003
	1:i64 id,
1004
	2:i64 logisticsProviderId,
1005
	3:string pickupRequestNo,
1006
	4:i64 confirmedAt,
1007
	5:i64 promised_pickup_timestamp,
1008
	6:i64 pickedUpAt,
1009
	7:ReturnTxnPickupStatus pickupStatus
1010
}
1011
 
1012
enum ReceivedReturnType{
1013
	PRESTINE,
1014
	DAMAGED,
1015
	LOST_IN_TRANSIT
1016
}
1017
 
1018
enum ReturnTxnResolutionStatus{
1019
	PENDING,
1020
	AWAITING_PICKUP,
1021
	QUALITY_CHECK,
1022
	REPLACEMENT_ORDER_CREATED,
1023
	REPLACEMENT_DONE,
1024
	REFUND_IN_PROCESS,
1025
	REFUND_DONE,
1026
	CLOSED
1027
}
1028
 
1029
struct ReturnOrderInfo{
1030
	1:i64 id,
1031
	2:i64 returnTransactionId,
1032
	3:string masterOrderId,
1033
	4:i64 orderId,
1034
	5:i64 lineItemId,
1035
	6:i64 logisticsRequestId,	
1036
	7:i64 returnQuantity,
1037
	8:i64 receivedQuantity,
1038
	9:i64 createdAt,
1039
	10:i64 processedAt,
1040
	11:string returnStatus,
1041
	12:i64 reshippedAt,
1042
	13:i64 receivedAt,
1043
	14:string refundReason,
1044
	15:string refundedBy,
1045
	16:i64 refundedAt,
1046
	17:i64 warehouse_id,
1047
	18:double refundAmount,
1048
	19:RefundType refundType,
1049
	20:string refundDescription,
1050
	21:ReturnPickupType returnPickupType,
1051
	22:ReplacementShippingType shippingType,
1052
	23:i64 replacementOrderId,
1053
	24:ReceivedReturnType receivedReturnType,
1054
	25:i64 freebieItemId,
1055
	26:ReturnAction returnAction,
1056
	27:ReturnTxnResolutionStatus returnTxnResolutionStatus,
1057
	28:LineItem lineitem,
1058
	29:ReturnPickupRequest returnPickUpRequest
1059
}
1060
 
1061
enum ReturnTransactionStatus{
1062
	INITIATED,
1063
	AUTHORIZED,
1064
	INPROCESS,
1065
	REJECTED,
1066
	PROCESSED,
1067
	COMPLETED,
1068
	CLOSED
1069
}
1070
 
1071
struct ReturnTransaction{
1072
	1:i64 id,
1073
	2:ReturnTransactionStatus status,
1074
	3:string customer_email,
1075
	4:string customer_name,
1076
	5:i64 customer_id,
1077
	6:i64 address_id,
1078
	7:i64 ticketId
1079
	8:i64 createdAt,
1080
	9:i64 processedAt,
1081
	10:i64 authorizedAt,
1082
	11:i64 closedAt,
1083
	12:string customerAddress,
1084
	13:string pincode,
1085
	14:string customerCity,
1086
	15:string customerState,
1087
	16:string customerPhone,
1088
	17:list<ReturnOrderInfo> returnOrders
1089
}
1090
 
3374 rajveer 1091
service TransactionService extends GenericService.GenericService{
483 rajveer 1092
 
1093
	i64 createTransaction(1:Transaction transaction) throws (1:TransactionServiceException ex),
1094
 
1095
	//	Get transaction methods.
1096
	Transaction getTransaction(1:i64 id) throws (1:TransactionServiceException ex),
1097
	list<Transaction> getTransactionsForCustomer(1:i64 customerId, 2:i64 from_date, 3:i64 to_date, 4:TransactionStatus status) throws (1:TransactionServiceException ex),
1098
	list<Transaction> getTransactionsForShoppingCartId(1:i64 shoppingCartId) throws (1:TransactionServiceException ex),
1099
	TransactionStatus getTransactionStatus(1:i64 transactionId) throws (1:TransactionServiceException ex),
7293 anupam.sin 1100
	bool changeTransactionStatus(1:i64 transactionId, 2:TransactionStatus status, 3:string description, 4:i64 pickUp, 5:OrderType orderType, 6:OrderSource source) throws (1:TransactionServiceException ex),
1382 varun.gupt 1101
 
1398 varun.gupt 1102
	bool enqueueTransactionInfoEmail(1:i64 transactionId) throws (1:TransactionServiceException ex),
1382 varun.gupt 1103
 
4801 anupam.sin 1104
	list<Order> getAllOrders(1:list<OrderStatus> statuses, 2:i64 from_date, 3:i64 to_date, 4:i64 warehouse_id) throws (1:TransactionServiceException ex),
1111 varun.gupt 1105
 
1115 chandransh 1106
	/**
4133 chandransh 1107
	Returns at most 'limit' orders with the given statuses for the given warehouse starting from the given offset.
1108
	Pass the status as null and the limit as 0 to ignore them.
1109
	*/
8303 amar.kumar 1110
	list<Order> getOrdersInBatch(1:list<OrderStatus> statuses, 2:i64 offset, 3:i64 limit, 4:i64 warehouse_id, 5:i64 source) throws (1:TransactionServiceException ex),
4133 chandransh 1111
 
1112
	/**
1113
	Returns the count of orders with the given statuses assigned to the given warehouse.
1114
	*/
8303 amar.kumar 1115
	i32 getOrderCount(1:list<OrderStatus> statuses, 2:i64 warehouseId, 3:i64 source) throws (1:TransactionServiceException ex),
4133 chandransh 1116
 
1117
	/**
1115 chandransh 1118
	Returns orders within a range of their billing dates
1119
	*/
1000 varun.gupt 1120
	list<Order> getOrdersByBillingDate(1:OrderStatus status, 2:i64 start_billing_date, 3:i64 end_billing_date, 4:i64 warehouse_id) throws (1:TransactionServiceException ex),
1111 varun.gupt 1121
 
1382 varun.gupt 1122
	/**
3427 chandransh 1123
	Returns orders for a particular provider and warehouse which were shipped between the given dates.
3451 chandransh 1124
	Returned orders comprise of COD orders if cod parameter is true. It comprises of prepaid orders otherwise. 
1125
	Pass providerId and warehouseId as -1 to ignore both these parameters.
3427 chandransh 1126
	*/
3451 chandransh 1127
	list<Order> getOrdersByShippingDate(1:i64 fromShippingDate, 2:i64 toShippingDate, 3:i64 providerId, 4:i64 warehouseId, 5:bool cod) throws (1:TransactionServiceException ex),
3427 chandransh 1128
 
1129
	/**
1382 varun.gupt 1130
	Returns order ids for orders which can be returned
1131
	*/
1132
	list<i64> getReturnableOrdersForCustomer(1:i64 customer_id, 2:i64 limit) throws (1:TransactionServiceException ex),
1133
 
1134
	/**
1135
	Returns order ids for orders which can be cancelled
1136
	*/
1137
	list<i64> getCancellableOrdersForCustomer(1:i64 customer_id, 2:i64 limit) throws (1:TransactionServiceException ex),
1138
 
483 rajveer 1139
	bool changeOrderStatus(1:i64 orderId, 2:OrderStatus status, 3:string description) throws (1:TransactionServiceException ex),
1147 chandransh 1140
 
1141
	/**
1529 ankur.sing 1142
	Returns list of orders for given transaction Id. Also filters based on customer Id so that
1143
	only user who owns the transaction can view its order details.
1144
	*/
1145
	list<Order> getOrdersForTransaction(1:i64 transactionId 2:i64 customerId)  throws (1:TransactionServiceException ex),
3014 chandransh 1146
 
1147
	/**
1148
	Returns list of orders for the given customer created between the given dates and having the given statuses.
1149
	Pass and empty list to ignore filtering on statuses.
1150
	*/	
1151
	list<Order> getOrdersForCustomer(1:i64 customerId, 2:i64 from_date, 3:i64 to_date, 4:list<OrderStatus> statuses) throws (1:TransactionServiceException ex),
1529 ankur.sing 1152
 
483 rajveer 1153
	i64 createOrder(1:Order order) throws (1:TransactionServiceException ex),
1154
	Order getOrder(1:i64 id) throws (1:TransactionServiceException ex),
1155
	list<LineItem> getLineItemsForOrder(1:i64 orderId) throws (1:TransactionServiceException ex),
1156
 
4999 phani.kuma 1157
	list<Order> getOrderList(1:list<i64> order_ids),
1529 ankur.sing 1158
 
5386 phani.kuma 1159
	list<Order> getOrderListForVendor(1:list<i64> order_ids, 2:i64 vendorId),
1160
 
757 chandransh 1161
	/**
1529 ankur.sing 1162
	Returns an order for the order Id. Also checks if the order belongs to the customer whose Id is passed.
1163
	Throws exception if either order Id is invalid or order does not below to the customer whose Id is passed.
1164
	*/
1165
	Order getOrderForCustomer(1:i64 orderId, 2:i64 customerId) throws (1:TransactionServiceException ex),
1166
 
3060 chandransh 1167
	//Alerts apis 
4444 rajveer 1168
	list<Alert> getAlerts(1:i64 type, 2:i64 warehouseId, 3:i64 status, 4:i64 timestamp),
1169
	void addAlert(1:i64 type, 2:i64 warehouseId, 3:string description),
1170
	void markAlertsAsSeen(1:i64 warehouseId),
3060 chandransh 1171
 
1529 ankur.sing 1172
	/**
3060 chandransh 1173
	Return the number of valid orders. (OrderStatus >= OrderStatus.SUBMITTED_FOR_PROCESSING)
1174
	*/
1175
	i64 getValidOrderCount(),
1176
 
1177
	/**
1178
	Returns the number of distinct customers who have done successful transactions
1179
	*/
1180
	i64 getNoOfCustomersWithSuccessfulTransaction(),
1181
 
1182
	/**
1183
	Returns the minimum and maximum amounts of a valid order. (OrderStatus >= OrderStatus.SUBMITTED_FOR_PROCESSING)
1184
	List contains two values, first minimum amount and second maximum amount.	
1185
	*/
1186
	list<double> getValidOrdersAmountRange(),
1187
 
1188
	/**
1189
	Returns list of Orders in descending order by Order creation date. List is restricted to limit Orders.
1190
	If limit is passed as 0, then all valid Orders are returned. 
1191
	*/
5874 rajveer 1192
	list<Order> getValidOrders(1:i64 limit, 2:bool onlyStore),
3060 chandransh 1193
 
1194
	/**
1195
	Create a batch of all the pending orders for the given warehouse.
1196
	The returned list is orderd by created_timestamp.
1197
	If there are no pending orders, an empty list is returned.
1198
	*/
1223 chandransh 1199
	list<Order> batchOrders(1:i64 warehouseId) throws (1:TransactionServiceException ex),
1200
 
1201
	/**
1202
	Mark the given order as out of stock. Throws an exception if the order with the given Id couldn't be found. 
1244 chandransh 1203
	*/
1210 chandransh 1204
	bool markOrderAsOutOfStock(1:i64 orderId) throws (1:TransactionServiceException ex),
1205
 
1206
	/**
3060 chandransh 1207
	Marks the given order as SUBMITTED_FOR_PROCESSING and updates the verified
1208
	timestamp. It is intended to be used for COD orders but can be harmlessly 
1209
	used for all other orders as well.
1210
	Throws an exception if no such order exists.
757 chandransh 1211
	*/
3060 chandransh 1212
	bool verifyOrder(1:i64 orderId) throws (1:TransactionServiceException ex),
1115 chandransh 1213
 
1214
	/**
3060 chandransh 1215
	Marks the given order as ACCEPTED and updates the accepted timestamp. If the
1216
	given order is not a COD order, it also captures the payment if the same has
1217
	not been captured.
1218
	Throws an exception if no such order exists.
1219
	*/
1220
	bool acceptOrder(1:i64 orderId) throws (1:TransactionServiceException ex),
1221
 
1222
	/**
1223
	Add billing details such as the bill number and the biller to the Order.
4658 mandeep.dh 1224
	Adds jacket number, item number and Serial no. to the order. Doesn't update
3060 chandransh 1225
	the IMEI no. if a -1 is supplied.
1226
	Also, it generates an invoice number for the order, marks the order as
1227
	BILLED and sets the billing timestamp.
1228
	Returns false if it doesn't find the order with the given ID.
1229
	*/
7190 amar.kumar 1230
	bool addBillingDetails(1:i64 orderId, 2:string invoice_number, 3:list<string> serialNumber, 4:list<string> itemNumber, 5:i64 freebieWarehouseId, 6:string billed_by, 7:i64 jacketNumber, 8:i64 billingType, 9:i64 fulfilmentWarehouseId, 10:bool authorize) throws (1:TransactionServiceException ex),
4579 rajveer 1231
 
1232
	/**
1233
	Add the invoice number to the order.
1234
	*/	
6747 amar.kumar 1235
	void addInvoiceNumber(1:i64 orderId, 2:string invoiceNumber, 3:string color, 4:string serialNumber, 5:string itemNumber) throws (1:TransactionServiceException ex),
4910 phani.kuma 1236
 
3060 chandransh 1237
	/**
1238
	Depending on the third parameter, marks either all prepaid or all cod orders BILLED by the
4410 rajveer 1239
	given warehouse and were picked up by the given provider as SHIPPED_FROM_WH.
1240
	*/
4788 rajveer 1241
	bool markOrdersAsShippedFromWarehouse(1:i64 warehouseId, 2:i64 providerId, 3:bool cod, 4:list<i64> orderIds) throws (1:TransactionServiceException ex),
5676 rajveer 1242
 
5713 rajveer 1243
	bool markOrdersAsReturnedFromStore(1:i64 providerId, 2:list<i64> orderIds, 3:list<string> awbs) throws (1:TransactionServiceException ex),
4410 rajveer 1244
 
1245
	/**
1115 chandransh 1246
	Marks all SHIPPED_FROM_WH orders of the previous day for a provider as SHIPPED_TO_LOGISTICS.
4910 phani.kuma 1247
	Raises an exception if we encounter report for an AWB number that we did not ship.	
1248
	*/
1249
	void markOrdersAsPickedUp(1:i64 providerId, 2:map<string, string> pickupDetails) throws (1:TransactionServiceException ex),
1250
 
1251
	/**
1115 chandransh 1252
	Returns a list of orders that were shipped from warehouse but did not appear in the pick-up report.
1253
	*/
4910 phani.kuma 1254
	list<Order> getOrdersNotPickedUp(1:i64 providerId),
1134 chandransh 1255
 
1256
	/**
1257
	Marks all orders with AWBs in the given map as delivered. Also sets the delivery timestamp and
1258
	the name of the receiver.
1259
	Raises an exception if we encounter report for an AWB number that we did not ship.
1260
	*/
1261
	void markOrdersAsDelivered(1:i64 providerId, 2:map<string, string> deliveredOrders) throws (1:TransactionServiceException ex),
1262
 
1263
	/**
4910 phani.kuma 1264
	Mark all orders with AWBs in the given map as RTO. Also sets the delivery timestamp.
1134 chandransh 1265
	Raises an exception if we encounter report for an AWB number that we did not ship.
1266
	*/
4910 phani.kuma 1267
	void markAsRTOrders(1:i64 providerId, 2:map<string, string> returnedOrders) throws (1:TransactionServiceException ex),
1134 chandransh 1268
 
1244 chandransh 1269
	/**
4910 phani.kuma 1270
	Returns a list of orders that were returned by courier.
1271
	*/
1272
	list<Order> getRTOrders(1:i64 providerId),
1273
 
1274
	/**
1244 chandransh 1275
	Update the status description of orders whose AWB numbers are keys of the Map.
4910 phani.kuma 1276
	*/
1277
	void updateNonDeliveryReason(1:i64 providerId, 2:map<string, string> undeliveredOrders) throws (1:TransactionServiceException ex),
1278
 
1279
	/**
4581 phani.kuma 1280
	Returns a list of orders that were picked up or shipped four days ago but did not get delivered.
1244 chandransh 1281
	*/
4910 phani.kuma 1282
	list<Order> getNonDeliveredOrdersbyCourier(1:i64 providerId),
1244 chandransh 1283
 
1407 ankur.sing 1284
	/**
4910 phani.kuma 1285
	Mark all orders with AWBs in the given map as local connected. Also sets the local connected timestamp.
1286
	*/
1287
	void markOrdersAsLocalConnected(1:i64 providerId, 2:map<string, string> local_connected_orders) throws (1:TransactionServiceException ex),
1288
 
1289
	/**
1290
	Returns a list of orders that were picked up or shipped but pending local connection.
1291
	*/
1292
	list<Order> getOrdersNotLocalConnected(1:i64 providerId),
1293
 
1294
	/**
1295
	Mark all orders with AWBs in the given map as reached destination city. Also sets the reached destination timestamp.
1296
	*/
1297
	void markOrdersAsDestinationCityReached(1:i64 providerId, 2:map<string, string> destination_city_reached_orders) throws (1:TransactionServiceException ex),
1298
 
1299
	/**
1300
	Mark all orders with AWBs in the given map as first delivery attempt made. Also sets the first delivery attempted timestamp.
1301
	*/
1302
	void markOrdersAsFirstDeliveryAttempted(1:i64 providerId, 2:map<string, string> first_atdl_orders) throws (1:TransactionServiceException ex),
1303
 
1304
	/**
1407 ankur.sing 1305
	Returns the list of orders whose delivery time has passed but have not been
1306
	delivered yet for the given provider and warehouse. To get a complete list of
1307
	undelivered orders, pass them as -1. 
1308
	Returns an empty list if no such orders exist.
1309
	*/
1310
	list<Order> getUndeliveredOrders(1:i64 providerId, 2:i64 warehouseId),
1311
 
1599 ankur.sing 1312
	/**
4783 phani.kuma 1313
	Returns the list of orders whose expected delivery date has passed but have not been
1314
	delivered yet.
1315
	Returns an empty list if no such orders exist.
1316
	*/
1317
	list<Order> getUndeliveredOrdersExpectedDeliveryDateNotMet(),
1318
 
1319
	/**
2537 chandransh 1320
	Toggle the DOA flag of an order. This should be used to flag an order for follow-up and unflag it when the follow-up is complete.
1321
	Returns the final flag status.
1322
	Throws an exception if the order with the given id couldn't be found or if the order status is not DELVIERY_SUCCESS. 
1323
	*/
1324
	bool toggleDOAFlag(1:i64 orderId) throws (1:TransactionServiceException ex),
1325
 
4712 rajveer 1326
	void markOrderAsDelivered(1:i64 orderId, 2:i64 deliveryTimestamp, string receiver) throws (1:TransactionServiceException ex),
1327
 
5553 rajveer 1328
	void markOrderAsReceivedAtStore(1:i64 orderId, 2:i64 deliveryTimestamp) throws (1:TransactionServiceException ex),
1329
 
2537 chandransh 1330
	/**
4454 rajveer 1331
	 Once user raise the request for a DOA, order status will be changed from DELVIERY_SUCCESS to DOA_REQUEST_RECEIVED 
1332
	*/
1333
	bool markOrderDoaRequestReceived(1:i64 orderId) throws (1:TransactionServiceException ex),
1334
 
1335
	/**
1336
	 CRM person can authorize or deny the request reised by customer. If he authorizes order will change from DOA_REQUEST_RECEIVED 
1337
	 to DOA_REQUEST_AUTHORIZED. If he denies, status will be changed back to DELVIERY_SUCCESS. 
1338
	*/
7645 anupam.sin 1339
	bool markOrderDoaRequestAuthorized(1:i64 orderId, 2:bool isAuthorized, 3:bool fromStore, 4:bool isReship) throws (1:TransactionServiceException ex),
4454 rajveer 1340
 
1341
	/**
4488 rajveer 1342
	 Once user raise the request for a RET, order status will be changed from DELVIERY_SUCCESS to RET_REQUEST_RECEIVED 
1343
	*/
1344
	bool markOrderReturnRequestReceived(1:i64 orderId) throws (1:TransactionServiceException ex),
1345
 
1346
	/**
1347
	 CRM person can authorize or deny the request reised by customer. If he authorizes order will change from RET_REQUEST_RECEIVED 
1348
	 to RET_REQUEST_AUTHORIZED. If he denies, status will be changed back to DELVIERY_SUCCESS. 
1349
	*/
7645 anupam.sin 1350
	bool markOrderReturnRequestAuthorized(1:i64 orderId, 2:bool isAuthorized, 3:bool fromStore, 4:bool isReship) throws (1:TransactionServiceException ex),
4488 rajveer 1351
 
1352
	/**
2537 chandransh 1353
	Sends out an email to the account manager of the original courier provider used to ship the order.
4452 rajveer 1354
	If the order status was DELIVERY_SUCCESS, it is changed to be DOA_PICKUP_REQUEST_RAISED.
1355
	If the order status was DOA_PICKUP_REQUEST_RAISED, it is left unchanged.
2537 chandransh 1356
	For any other status, it returns false.
1357
	Throws an exception if the order with the given id couldn't be found.
1358
	*/
4579 rajveer 1359
	bool requestPickupNumber(1:i64 orderId, 2:i64 providerId) throws (1:TransactionServiceException ex),
2537 chandransh 1360
 
1361
	/**
4452 rajveer 1362
	If the order status is DOA_PICKUP_REQUEST_RAISED, it does the following
2537 chandransh 1363
		1. Sends out an email to the customer with the dispatch advice that he has to print as an attachment.
1364
		2. Changes order status to be DOA_PICKUP_AUTHORIZED.
1365
		3. Returns true
2589 chandransh 1366
	If the order is in any other status, it returns false.
2537 chandransh 1367
	Throws an exception if the order with the given id couldn't be found.
1368
	*/
4602 rajveer 1369
	bool authorizePickup(1:i64 orderId, 2:string pickupNumber, 3:i64 providerId) throws (1:TransactionServiceException ex),
2589 chandransh 1370
 
1371
	/**
2765 chandransh 1372
	Marks all DOA_PICKUP_AUTHORIZED orders of the previous day for a provider as DOA_RETURN_IN_TRANSIT.
4910 phani.kuma 1373
	*/
1374
	void markDoasAsPickedUp(1:i64 providerId, 2:map<string, string> pickupDetails),
1375
 
1376
	/**
2765 chandransh 1377
	Returns a list of orders that were authorized for pickup but did not appear in the pick-up report.
1378
	*/
4910 phani.kuma 1379
	list<Order> getDoasNotPickedUp(1:i64 providerId),
2765 chandransh 1380
 
1381
	/**
4741 phani.kuma 1382
	Marks all RET_PICKUP_CONFIRMED orders of the previous day for a provider as RET_RETURN_IN_TRANSIT.
4910 phani.kuma 1383
	*/
1384
	void markReturnOrdersAsPickedUp(1:i64 providerId, 2:map<string, string> pickupDetails),
1385
 
1386
	/**
4741 phani.kuma 1387
	Returns a list of orders that were authorized for pickup but did not appear in the pick-up report.
1388
	*/
4910 phani.kuma 1389
	list<Order> getReturnOrdersNotPickedUp(1:i64 providerId),
4741 phani.kuma 1390
 
1391
	/**
4452 rajveer 1392
	If the order status is DOA_PICKUP_CONFIRMED or DOA_RETURN_IN_TRANSIT, marks the order status as DOA_RECEIVED_PRESTINE and returns true.
4484 rajveer 1393
	If the order status is RTO_IN_TRANSIT, marks the order status as RTO_RECEIVED_PRESTINE and returns true.
2589 chandransh 1394
	If the order is in any other state, it returns false.
1395
	Throws an exception if the order with the given id couldn't be found.
1396
	*/
13276 manish.sha 1397
	bool receiveReturn(1:i64 orderId, 2:i64 receiveCondition, 3:bool receiveFreebie, 4:string serialNumbers) throws (1:TransactionServiceException ex),
2589 chandransh 1398
 
1399
	/**
4452 rajveer 1400
	Used to validate the DOA certificate for an order in the DOA_RECEIVED_PRESTINE state. If the certificate is valid,
2614 chandransh 1401
	the order state is changed to DOA_CERT_VALID. If the certificate is invalid, the order state is changed to DOA_CERT_INVALID.
2589 chandransh 1402
	If the order is in any other state, it returns false.
1403
	Throws an exception if the order with the given id couldn't be found.
1404
	*/
1405
	bool validateDoa(1:i64 orderId, 2:bool isValid) throws (1:TransactionServiceException ex),
2614 chandransh 1406
 
4495 rajveer 1407
	bool validateReturnProduct(1:i64 orderId, 2:bool isUsable) throws (1:TransactionServiceException ex),
1408
 
2614 chandransh 1409
	/**
4484 rajveer 1410
	If the order is in RTO_RECEIVED_PRESTINE or DOA_CERT_INVALID state, it does the following:
2614 chandransh 1411
		1. Creates a new order for processing in the BILLED state. All billing information is saved.
4484 rajveer 1412
		2. Marks the current order as one of the final states RTO_RESHIPPED and DOA_INVALID_RESHIPPED depending on what state the order started in.
2614 chandransh 1413
 
1414
	If the order is in DOA_CERT_VALID state, it does the following:
1415
		1. Creates a new order for processing in the SUBMITTED_FOR_PROCESSING state.
1416
		2. Creates a return order for the warehouse executive to return the DOA material.
4452 rajveer 1417
		3. Marks the current order as the final DOA_VALID_RESHIPPED state.
2614 chandransh 1418
 
1419
	Returns the id of the newly created order.
1420
 
1421
	Throws an exception if the order with the given id couldn't be found.
1422
	*/
1423
	i64 reshipOrder(1:i64 orderId) throws (1:TransactionServiceException ex),
1424
 
1425
	/**
4484 rajveer 1426
	If the order is in RTO_RECEIVED_PRESTINE, DOA_CERT_VALID or DOA_CERT_INVALID state, it does the following:
2614 chandransh 1427
		1. Creates a refund request for batch processing.
1428
		2. Creates a return order for the warehouse executive to return the shipped material.
4484 rajveer 1429
		3. Marks the current order as RTO_REFUNDED, DOA_VALID_REFUNDED or DOA_INVALID_REFUNDED final states.
2614 chandransh 1430
 
1431
	If the order is in SUBMITTED_FOR_PROCESSING or INVENTORY_LOW state, it does the following:
1432
		1. Creates a refund request for batch processing.
3226 chandransh 1433
		2. Cancels the reservation of the item in the warehouse.
1434
		3. Marks the current order as the REFUNDED final state.
2614 chandransh 1435
 
3226 chandransh 1436
	For all COD orders, if the order is in INIT, SUBMITTED_FOR_PROCESSING or INVENTORY_LOW state, it does the following:
1437
		1. Cancels the reservation of the item in the warehouse.
1438
		2. Marks the current order as CANCELED.	
1439
 
1440
	In all cases, it updates the reason for cancellation or refund and the person who performed the action.
1441
 
2614 chandransh 1442
	Returns True if it is successful, False otherwise.
1443
 
1444
	Throws an exception if the order with the given id couldn't be found.
1445
	*/
3226 chandransh 1446
	bool refundOrder(1:i64 orderId, 2:string refundedBy, 3:string reason) throws (1:TransactionServiceException ex),
2688 chandransh 1447
 
1448
	/**
1449
	Get all return orders created between the from and to dates for the given warehouse.
1450
	Ignores the warehouse if it is passed as -1.
1451
	*/
1452
	list<ReturnOrder> getReturnOrders(1:i64 warehouseId, 2:i64 fromDate, 3:i64 toDate),
1453
 
1454
	/**
5481 phani.kuma 1455
	Get all return orders created between the from and to dates.
1456
	*/
1457
	list<ReturnOrder> getAllReturnOrders(1:bool onlyNotProcessed, 2:i64 fromDate, 3:i64 toDate),
1458
 
1459
	/**
2700 chandransh 1460
	Returns the ReturnOrder corresponding to the given id.
1461
	Throws an exception if the return order with the given id couldn't be found.
1462
	*/
1463
	ReturnOrder getReturnOrder(1:i64 id) throws (1:TransactionServiceException ex),
1464
 
1465
	/**
2688 chandransh 1466
	Marks the return order with the given id as processed. Raises an exception if no such return order exists. 
1467
	*/
2819 chandransh 1468
	void processReturn(1:i64 returnOrderId) throws (1:TransactionServiceException ex),
1469
 
1470
	/**
3451 chandransh 1471
	Set the weight of the given order to the provided value. Will attempt to update the weight of the item in the catalog as well.
1472
	*/
3469 chandransh 1473
	Order updateWeight(1:i64 orderId, 2:double weight) throws (1:TransactionServiceException ex),
1474
 
1475
	/**
1476
	Change the item to be shipped for this order. Also adjusts the reservation in the inventory accordingly.
1477
	Currently, it also ensures that only a different color of the given item is shipped.
1478
	*/
1479
	Order changeItem(1:i64 orderId, 2:i64 itemId) throws (1:TransactionServiceException ex),
1480
 
7560 rajveer 1481
	Order changeCourierProvider(1:i64 orderId, 2:i64 providerId) throws (1:TransactionServiceException ex),
1482
 
3469 chandransh 1483
	/**
1484
	Moves the given order to the given warehouse. Also adjusts the inventory reservations accordingly.
1485
	*/
3553 chandransh 1486
	Order shiftToWarehouse(1:i64 orderId, 2:i64 warehouseId) throws (1:TransactionServiceException ex),
1487
 
1488
	/**
1489
	Adds the given delay reason to the given order.
3986 chandransh 1490
	Increases the expected delivery time of the given order by the given no. of days.
3553 chandransh 1491
	Raises an exception if no order with the given id can be found.
1492
	*/
4647 rajveer 1493
	bool addDelayReason(1:i64 orderId, 2:DelayReason delayReason, 3:i64 furtherDelay, 4:string delayReasonText) throws (1:TransactionServiceException ex),
3956 chandransh 1494
 
1495
	/**
1496
	Marks the COD orders with given AWB nos. as having been processed.
1497
	Updates the captured amount for the corresponding payment.
1498
 
1499
	Returns a map of AWBs which were not processed and the associated reason. An AWB is not processed if:
1500
	1. There is no order corresponding to an AWB number.
1501
	2. The captured amount for a payment exceeds the total payment.
1502
	3. The order corresponding to an AWB no. is in a state prior to DELIVERY_SUCCESS.
1503
	*/
4008 mandeep.dh 1504
	map<string, string> reconcileCodCollection(1:map<string, double> collectedAmountMap, 2:string xferBy, 3:string xferTxnId, 4:i64 xferDate) throws (1:TransactionServiceException ex),
1505
 
1506
    /**
4065 mandeep.dh 1507
     * Returns the list of transaction ids that require some extra processing and
4008 mandeep.dh 1508
     * which belong to a particular category. This is currently used by CRM
4065 mandeep.dh 1509
     * application. If no such transaction ids are present, it returns an empty list.
4008 mandeep.dh 1510
     */
1511
    list<i64> getTransactionsRequiringExtraProcessing(1:ExtraTransactionProcessingType category),
1512
 
1513
	/**
1514
	 * Marks a particular transaction as processed for a particular cateogory.
4065 mandeep.dh 1515
	 * It essentially deletes the transaction id record for a particular
1516
	 * processing type category (if present) from DB.
1517
	 * This is currently used by CRM application.
4008 mandeep.dh 1518
	 */
4018 chandransh 1519
	void markTransactionAsProcessed(1:i64 transactionId, 2:ExtraTransactionProcessingType category),
1520
 
1521
	/**
1522
	Returns a map containing the number of risky orders keyed by item id. A risky order
1523
	is defined as one whose shipping date is about to expire.
1524
	*/
4245 rajveer 1525
	map<i64, i64> getItemWiseRiskyOrdersCount(),
1526
 
1527
	/**
4295 varun.gupt 1528
	Returns a list of all orders which have items with given id
1529
	*/
1530
	list<Order> getOrdersForItemIds(1:list<i64> itemIds),
1531
 
1532
	/**
4245 rajveer 1533
	 * Mark order as cancellation request received. If customer sends request of cancellation of 
1534
	 * a particular order, this method will be called. It will just change status of the order 
1535
	 * depending on its current status. It also records the previous status, so that we can move 
1536
	 * back to that status if cancellation request is denied.
1537
	 */
1538
	void markOrderCancellationRequestReceived(1:i64 orderId) throws (1:TransactionServiceException ex),
1539
 
1540
	/**
1541
	 * If we decide to to cancel order, CRM will call this method to move the status of order to 
1542
	 * cancellation request confirmed. After this OM will be able to cancel the order. 	
1543
	 */
1544
	void markOrderCancellationRequestConfirmed(1:i64 orderId) throws (1:TransactionServiceException ex),
1545
 
1546
	/**
1547
	 * If we decide to not to cancel order, we will move the order ro previous status.	
1548
	 */
1549
	void markOrderCancellationRequestDenied(1:i64 orderId) throws (1:TransactionServiceException ex),
1550
 
1551
	/**
4258 rajveer 1552
	 * If we and/or payment gateway has decided to accept the payment, this method needs to be called.
1553
	 * Changed transaction and all orders status to payment accepted.  
4245 rajveer 1554
	 */
4285 rajveer 1555
	void markTransactionAsPaymentFlagRemoved(1:i64 transactionId) throws (1:TransactionServiceException ex),
4245 rajveer 1556
 
4259 anupam.sin 1557
	/**
1558
	* This method is called when a flagged payment is deemed unserviceable and the corresponding orders
1559
	* need to be cancelled
1560
	*/
4285 rajveer 1561
	void refundTransaction(1:i64 transactionId, 2:string refundedBy, 3:string reason) throws (1:TransactionServiceException ex),
4324 mandeep.dh 1562
 
1563
	/**
1564
	 * Updates shipment address of an order. Delivery and shipping date estimates
1565
	 * etc. are also updated here.
1566
	 *
1567
	 * Throws TransactionServiceException in case address change is not
1568
	 * possible due to certain reasons such as new pincode in address is
1569
	 * not serviceable etc.
1570
	 */
1571
	void updateShipmentAddress(1:i64 orderId, 2:i64 addressId) throws (1:TransactionServiceException ex)
4285 rajveer 1572
 
1573
	/**
1574
	Marks the orders as ACCEPTED for the given itemId and inventory. It also updates the accepted timestamp. If the
1575
	given order is not a COD order, it also captures the payment if the same has not been captured.
1576
	*/
4303 rajveer 1577
	bool acceptOrdersForItemId(1:i64 itemId, 2:i64 inventory) throws (1:TransactionServiceException ex),
4285 rajveer 1578
 
4369 rajveer 1579
	void markOrdersAsPORaised(1:i64 vendorId, 2:i64 itemId, 3:i64 quantity, 4:i64 estimate, 5:bool isReminder) throws (1:TransactionServiceException ex),
1580
	void markOrdersAsReversalInitiated(1:i64 vendorId, 2:i64 itemId, 3:i64 quantity, 4:i64 estimate, 5:bool isReminder) throws (1:TransactionServiceException ex),
1581
	void markOrdersAsNotAvailabke(1:i64 vendorId, 2:i64 itemId, 3:i64 quantity, 4:i64 estimate, 5:bool isReminder) throws (1:TransactionServiceException ex),
1582
 
4386 anupam.sin 1583
	map<i32, TimeoutSummary> markOrdersAsTimeout(1:i64 vendorId) throws (1:TransactionServiceException ex),
4661 rajveer 1584
 
4386 anupam.sin 1585
	/**
4661 rajveer 1586
	Mark order as LOST_IN_TRANSIT
1587
	*/
1588
	bool markOrderAsLostInTransit(1:i64 orderId) throws (1:TransactionServiceException ex),
1589
 
1590
	/**
4386 anupam.sin 1591
	Returns the order corresponding to an AWB number
1592
	*/
13276 manish.sha 1593
	list<Order> getOrderForAwb(1:string awb) throws (1:TransactionServiceException ex),
4506 phani.kuma 1594
 
1595
	/**
4910 phani.kuma 1596
	Returns the order corresponding to a logistics provider id for a given list of order status
4506 phani.kuma 1597
	*/
4910 phani.kuma 1598
	list<Order> getOrdersForProviderForStatus(1:i64 logistics_provider_id, 2:list<OrderStatus> order_status_list) throws (1:TransactionServiceException ex)
4600 varun.gupt 1599
 
1600
	/**
1601
	Returns list of orders fullfiled from a certain vendor and billed in a given date range
1602
	*/
1603
	list<Order> getBilledOrdersForVendor(1:i64 vendorId, 2:i64 billingDateFrom, 3:i64 billingDateTo) throws (1:TransactionServiceException ex),
1604
 
4607 rajveer 1605
	list<Order> getSlippedSippingDateOrders() throws (1:TransactionServiceException ex),
1606
 
4709 rajveer 1607
	list<Order> getCancelledOrders(1:i64 cancelDateFrom, 2:i64 cancelDateTo) throws (1:TransactionServiceException ex),
1608
 
4600 varun.gupt 1609
	void saveBluedartSettlements(1:map<i64, double> mapAWBAndAmount) throws (1:TransactionServiceException ex),
1610
 
4905 varun.gupt 1611
	void savePaymentSettlements(1:i64 settlementDate, 2:i64 paymentGatewayId, 3:i64 referenceId, 4:double serviceTax, 5:double otherCharges, 6:double netCollection) throws (1:TransactionServiceException ex),
4600 varun.gupt 1612
 
1613
	void saveEBSSettlementSummary(1:i64 settlementId, 2:i64 settlementDate, 3:i64 transactionDateFrom, 4:i64 transactionDateTo, 5:double amount) throws (1:TransactionServiceException ex),
1614
 
5386 phani.kuma 1615
	PaymentSettlement getSettlementForPrepaid(1:i64 referenceId, 2:bool isRefund) throws (1:TransactionServiceException ex),
4600 varun.gupt 1616
 
5386 phani.kuma 1617
	PaymentSettlement getSettlementForCod(1:i64 orderId, 2:bool isRefund) throws (1:TransactionServiceException ex),
1618
 
4600 varun.gupt 1619
	map<i64, string> getEBSSettlementSummaries() throws (1:TransactionServiceException ex),
1620
 
1621
	void markEBSSettlementUploaded(1:i64 settlementId) throws (1:TransactionServiceException ex),
1622
 
4715 varun.gupt 1623
	i64 getEBSSettlementDate(1:i64 settlementId) throws (1:TransactionServiceException ex),
1624
 
1625
	list<PaymentSettlement> getSettlementsByDate(1:i64 settlementDateFrom, 2:i64 settlementDateTo, 3:bool isRefund) throws (1:TransactionServiceException ex),
1626
 
1627
	/**
1628
	Returns list of Order Ids, which belong to reshiped orders, shortlisted from a given list of Order Ids 
1629
	*/
4875 varun.gupt 1630
	list<i64> getReshippedOrderIds(1:list<i64> orderIds) throws (1:TransactionServiceException ex),
1631
 
5481 phani.kuma 1632
	list<Order> getBilledOrders(1:i64 vendorId, 2:bool onlyVendorNotPaid, 3:i64 billingDateFrom, 4:i64 billingDateTo) throws (1:TransactionServiceException ex),
5031 varun.gupt 1633
 
5067 varun.gupt 1634
	map<i64, i64> getStatusDistributionOfOrders(1:i64 startDate, 2:i64 endDate) throws (1:TransactionServiceException ex),
1635
 
5099 varun.gupt 1636
	list<i64> getOrderIdsForStatus(1:i64 status, 2:i64 startDatetime, 3:i64 endDatetime) throws (1:TransactionServiceException ex),
1637
 
5348 anupam.sin 1638
	/**
1639
	 * Updates the agent who handled the COD verification call
1640
	 */
1641
	void updateCODAgent(1:string agent, 2:i64 orderId) throws (1:TransactionServiceException ex),
1642
 
5208 varun.gupt 1643
	void updateOrderAsPaidToVendor(1:i64 orderId) throws (1:TransactionServiceException ex),
1644
 
5386 phani.kuma 1645
	void updateOrderOnlyAsPaidToVendor(1:i64 orderId) throws (1:TransactionServiceException ex),
1646
 
5447 anupam.sin 1647
	list<Order> getRefundedOrdersMarkedPaid() throws (1:TransactionServiceException ex),
1648
 
1649
	/**
1650
	* gets all COD Verification Agents for all orderIds from a minId to maxId
1651
	*
1652
	*/
5527 anupam.sin 1653
	list<CODVerificationAgent> getAllVerificationAgents(1:i64 minOrderId, 2:i64 maxOrderId),
1654
 
1655
	/**
1656
	* gets all attributes for a given orderId
1657
	*/
1658
	list<Attribute> getAllAttributesForOrderId(1:i64 orderId),
1659
 
1660
	/**
5676 rajveer 1661
	* sets attributes for an order
1662
	*/
1663
	void setOrderAttributes(1:i64 orderId, list<Attribute> attributes),
1664
 
1665
	/**
5527 anupam.sin 1666
	* sets attributes for all orders in a transaction
1667
	*/
5553 rajveer 1668
	void setOrderAttributeForTransaction(1:i64 transactionId, Attribute attribute),
1669
 
1670
	list<Order> getReceivePendingOrders(1:i64 storeId),
1671
 
5593 mandeep.dh 1672
	list<Order> getReceivedAtStoreOrders(1:i64 storeId),
5713 rajveer 1673
 
1674
	list<Order> getOrdersCollectionAtStore(1:i64 storeId, 2:i64 fromDate, 3:i64 toDate, 4:bool onlyCod),
5593 mandeep.dh 1675
 
5833 rajveer 1676
	string getOrderAttributeValue(1:i64 orderId, string attributeName),
6019 rajveer 1677
 
1678
	bool changeJacketNumber(1:i64 orderId, 2:i64 jacketNumber),
1679
 
1680
	bool markOrderAsRtoInTransit(1:i64 orderId),
1681
 
5593 mandeep.dh 1682
	/**
1683
	 * Accepts appropriate order for an item in a given billingWarehouse. Usually
1684
	 * invoked while scanning IN of items.
1685
	 */
6000 mandeep.dh 1686
	 void acceptOrderForItem(1:i64 itemId, 2:i64 quantity, 3:i64 fulfilmentWarehouseId, 4:i64 billingWarehouseId);
1687
 
1688
	 RechargeOrder createRechargeOrder(1:RechargeOrder rechargeOrder) throws  (1:TransactionServiceException ex);
6031 rajveer 1689
	 RechargeOrder getRechargeOrder(1:i64 rechargeRrderId) throws  (1:TransactionServiceException ex);
1690
	 list<RechargeOrder> getRechargeOrders(1:i64 userId);
1691
 
1692
	 bool updateRechargeOrderStatus(1:i64 rechargeOrderId, 2:RechargeOrderStatus rechargeOrderStatus) throws  (1:TransactionServiceException ex);
1693
	 bool activateRechargeTxn(1:i64 rechargeOrderId) throws  (1:TransactionServiceException ex);
1694
	 UserWallet getUserWallet(1:i64 userId);
1695
	 list<UserWalletHistory> getUserWalletHistory(1:i64 userId);
6050 anupam.sin 1696
	 /**
1697
	 Returns a recharge order for a given transactionId
1698
	 */
1699
	 RechargeOrder getRechargeOrdersForTransaction(1:i64 txnId) throws (1:TransactionServiceException ex);
6206 rajveer 1700
	 map<i64, string> getServiceProviders(1:RechargeType rechargeType, 2:bool onlyActive);
6289 anupam.sin 1701
	 DeviceNumberInfo getServiceProviderForDevice(1:RechargeType rechargeType, 2:string deviceNumber);
6591 anupam.sin 1702
	 string validateRecharge(1:RechargeType rechargeType, 2:string deviceNumber, 3:i64 userSelectedProviderId, 4:string clientAddress);
6094 rajveer 1703
	 list<RechargeOrder> getRechargeOrdersForDevice(1:string deviceNumber);
1704
	 void addAmountToWallet(1:i64 userId, 2:i64 orderId, 3:i64 amount);
13941 amit.gupta 1705
	 void creditBatch(1:i64 batchId, 2:string userAmount);
6188 rajveer 1706
 
1707
	 RechargeStatistics getRechargeStatistics();
1708
 
6154 rajveer 1709
	 list<RechargeOrder> getRechargeOrdersForStatus(1:i64 status);
6159 rajveer 1710
	 list<RechargePlan> getPlansForOperator(1:i64 operatorId);
6289 anupam.sin 1711
 
1712
	 /**
1713
	 Returns denominations for a given operator and circle
1714
	 */
6307 anupam.sin 1715
	 list<RechargeDenomination> getRechargeDenominations(1:i64 operatorId, 2:string circleCode, 3:DenominationType denominationType) throws (1:TransactionServiceException ex);
6371 rajveer 1716
 
1717
	 void updateAvailabilityStatus(1:i64 operatorId, 2:i64 circleId, 3:bool isAvailable);
6389 rajveer 1718
 
1719
	 list<EmiScheme> getAvailableEmiSchemes();
1720
 
6412 rajveer 1721
	 map<i64, double> getMiscCharges(1:i64 transactionId);
6507 anupam.sin 1722
 
1723
	 bool refundRechargeOrder(1:i64 rechargeOrderId) throws (1:TransactionServiceException ex);
6821 amar.kumar 1724
 
6906 rajveer 1725
	 list<Order> getPhysicalOrders(1:i64 fromDate, 2:i64 toDate);
1726
 
1727
	 binary getDocument(1:i64 docType, 2:i64  docSource);
6985 anupam.sin 1728
 
1729
	 bool changeShippingAddress(1:i64 orderId, 2:string line1, 3:string line2, 4:string city, 5:string state, 6:string pin);
6988 rajveer 1730
 
7075 rajveer 1731
	 binary retrieveInvoice(1:i64 orderId, 2:i64 userId);
6988 rajveer 1732
 
7026 rajveer 1733
	 list<string> receiveUpdatesForRedExpress(1:string awbNumber);
7073 anupam.sin 1734
 
1735
	 RechargeTransaction createRechargeTransaction(1:RechargeTransaction thriftRechargeTransaction);
7080 anupam.sin 1736
 
7084 rajveer 1737
	 list<RechargeTransaction> getRechargeTransactions(1:i64 storeId);
7151 amit.gupta 1738
 
1739
	 list<RechargeTransaction> getRechargeTrans(1:i64 storeId, 2:i64 startDate, 3:i64 endDate, 4:RechargeOrderStatus status);
7084 rajveer 1740
 
7080 anupam.sin 1741
	 RechargeTransaction getRechargeTransaction(1:i64 rechargeId);
1742
 
1743
	 list<FRC> getFRCs(1:i64 circleId, 2:i64 operatorId);
7096 anupam.sin 1744
 
1745
	 HotspotStore getHotspotStore(1:i64 id, 2:string hotspotid);
1746
 
1747
	 TelecomCircle getTelecomCircle(1:i64 id, 2:string code);
7109 anupam.sin 1748
 
1749
	 binary retrieveHotspotRechargeInvoice(1:i64 rechargeId);
7169 anupam.sin 1750
 
7190 amar.kumar 1751
	 Order splitFreebieOrder(1:i64 orderId, 2:string splitReason, 3:i64 shippingDate);
1752
 
7172 anupam.sin 1753
	 list<RechargeTransaction> getRechargeTransactionsByNumber(1:string number, 2:i64 storeId);
7169 anupam.sin 1754
 
1755
	 bool updateHotspotStorePassword(1:i64 storeId, 2:string password);
7263 anupam.sin 1756
 
7285 rajveer 1757
	 i64 topupCompanyWallet(1:i64 companyId, 2:i64 amount);
1758
 
1759
	 i64 getWalletBalanceForCompany(1:i64 companyId);
7363 rajveer 1760
 
1761
	 i64 getSaholicRechargeBalance();
7285 rajveer 1762
 
7263 anupam.sin 1763
	 SourceDetail getSourceDetail(1:i64 source);
7267 anupam.sin 1764
 
1765
	 list<TelecomCircle> getAllCircles();
1766
 
1767
	 bool deleteFrcs(1:list<i64> frcIdsToDelete);
7311 kshitij.so 1768
 
1769
	 void addAmazonOrder(1:AmazonOrder amazonOrder);
1770
 
7322 vikram.rag 1771
	 bool updateAmazonOrderStatus(1:i64 orderId,2:string status);
7311 kshitij.so 1772
 
7686 vikram.rag 1773
	 list<Order> getAmazonOrdersShipped();
7311 kshitij.so 1774
 
1775
	 list<Order> getAmazonOrdersCancelled(1:i64 interval);
1776
 
7343 anupam.sin 1777
	 AmazonOrder getAmazonOrder(1:i64 orderId);
7322 vikram.rag 1778
 
7542 vikram.rag 1779
	 list<AmazonOrder> getAmazonOrderByAmazonOrderId(1:string amazonOrderId);
1780
 
7343 anupam.sin 1781
	 list<Order> getOrdersForStore(1:i64 id, 2:i64 storeId, 3:i64 startDate, 4:i64 endDate, 5:list<OrderStatus> statuses);
1782
 
7386 anupam.sin 1783
	 binary getStoreOrderAdvanceInvoice(1:i64 orderId, 2:i64 storeId);
7355 vikram.rag 1784
 
7370 anupam.sin 1785
	 bool addFrc(1:i64 circleId, 2:i64 operatorId, 3:i64 denomination, 4:i64 maxDiscount);
7371 anupam.sin 1786
 
1787
	 string addSeries(1:i64 circle, 2:i64 operatorId, 3:i64 series);
7386 anupam.sin 1788
 
1789
	 bool saveStoreOrderDetail(1:StoreOrderDetail storeOrderDetail);
1790
 
1791
	 StoreOrderDetail getStoreOrderDetail(1:i64 orderId, 2:i64 storeId);
1792
 
1793
	 list<string> getAllEdcBanks();
7393 anupam.sin 1794
 
1795
	 bool saveRefundAmountsForStoreOrder(1:i64 orderId, 2:i64 storeId, 3:double cashRefundAmount, 4:double cardRefundAmount);
7427 anupam.sin 1796
 
1797
	 list<StoreOrderCollection> getCollectionsForStore(1:i64 storeId, 2:i64 startDate, 3:i64 endDate);
7442 vikram.rag 1798
 
12614 amit.gupta 1799
	 list<AmazonOrdersToAcknowledge> getAmazonOrdersToAcknowledge(1:OrderSource source);
7442 vikram.rag 1800
 
7460 kshitij.so 1801
	 void changeAmazonOrderStatus(1:string amazonOrderCode,2:string status);
1802
 
7762 kshitij.so 1803
	 bool updateTimestampForAmazonOrder(1:map<i64, map<string,string>> amazonOrderDelivery);
7530 kshitij.so 1804
 
1805
	 bool updateSourceDetailTimestamp(1:i64 id , 2:i64 lastUpdatedOn);
7572 anupam.sin 1806
 
1807
	 list<Order> getOrdersByMobileNumber(1:string mobileNumber);
1808
 
7645 anupam.sin 1809
	 list<Order> getOrdersByAmazonOrderCode(1:string amazonId);
7730 anupam.sin 1810
 
1811
	 bool convertStoreToNormal(1:i64 orderId);
7822 amar.kumar 1812
 
1813
	 Order updateFreebieItem(1:i64 orderId, 2:i64 newFreebieItemId);
7939 manish.sha 1814
 
7967 anupam.sin 1815
	 list<HotspotServiceMatrix> getHotspotServiceMatrices();
1816
 
7939 manish.sha 1817
	 Order updateOrderAWB(1:i64 orderId, 2:string airwayBillNo);
8182 amar.kumar 1818
 
1819
	 list<Order> getOrdersByVendor(1:list<i64> vendors, 2:list<OrderStatus> statuses) throws (1:TransactionServiceException ex);
1820
 
1821
	 void createEbayOrder(1:EbayOrder ebayOrder);
1822
 
1823
	 EbayOrder getEbayOrderByOrderId(1:i64 orderId);
1824
 
1825
	 EbayOrder getEbayOrderBySalesRecNumber(1:i64 salesRecordNumber);
1826
 
8241 amar.kumar 1827
	 list<EbayOrder> getEbayOrder(1:i64 salesRecordNumber, 2:string listingId, 3:string paisapayId);
8182 amar.kumar 1828
 
1829
	 void updateEbayOrder(1:EbayOrder ebayOrder);
1830
 
1831
	 bool ebayOrderExists(1:i64 salesRecNumber, 2:string ebayListingId);
1832
 
1833
	 void updateOrderForEbay(1:Order order);
1834
 
1835
	 Order splitEbayOrder(1:i64 orderId, 2:i64 splitOrderQty, 3:i64 splitOrderItemId, 4:bool usePowerShip);
8282 kshitij.so 1836
 
1837
	 void addOrUpdateAmazonFbaSalesSnapshot(1:AmazonFbaSalesSnapshot amazonfbasalessnapshot);
1838
 
1839
	 list<AmazonFbaSalesSnapshot> getAmazonFbaSalesSnapshotForDays(1:i32 days);
1840
 
8488 amar.kumar 1841
     AmazonFbaSalesSnapshot getAmazonFbaSalesLatestSnapshotForItem(1:i64 item_id);
1842
 
1843
     void createSnapdealOrder(1:SnapdealOrder snapdealOrder);
1844
 
11424 kshitij.so 1845
     list<SnapdealOrder> getSnapdealOrder(1:i64 orderId, 2:string referenceCode, 3:string subrderId)
8488 amar.kumar 1846
 
9630 vikram.rag 1847
     bool snapdealOrderExists(1:string subOrderId, 2:string referenceCode);
8488 amar.kumar 1848
 
8532 vikram.rag 1849
     void updateLatestFbaPricesForItem(1:FbaItemPrices fbaitemprices)
1850
 
8961 vikram.rag 1851
     bool flipkartOrderExists(1:string flipkartOrderId, 2:string flipkartSubOrderId)
1852
 
1853
     void createFlipkartOrder(1:FlipkartOrder flipkartOrder)
1854
 
9107 vikram.rag 1855
     FlipkartOrder getFlipkartOrder(1:i64 orderId)
8990 vikram.rag 1856
 
9159 amar.kumar 1857
     FlipkartOrder getFlipkartOrderByOrderItemId(1:string flipkartOrderItemId)
1858
 
9107 vikram.rag 1859
     void updateFlipkartOrderDatesAndAWB(1:string flipkartOrderId,2:string flipkartSubOrderId,3:i64 date,4:string awb)
9404 vikram.rag 1860
 
9571 vikram.rag 1861
     map<i64,i64> getOrdersCreatedAfterTimestampForSource(1:i64 timestamp,2:i64 source)
9404 vikram.rag 1862
 
13276 manish.sha 1863
     list<Order> getOrderForAirwayBillNo(1:string airwaybillNo) throws (1:TransactionServiceException ex)
9651 manish.sha 1864
 
1865
	 i64 getMinCreatedTimeStampUndeliveredOrdersForSource(1:i32 source)
1866
 
9880 manish.sha 1867
	 void updateSnapdealOrdersStatus(1:map<string, list<list<string>>> orders)  throws (1:TransactionServiceException ex)
9651 manish.sha 1868
 
1869
	 void updateFlipkartOrdersStatus(1:list<list<string>> delivered_orders)  throws (1:TransactionServiceException ex)
9801 manish.sha 1870
 
1871
	 void bulkAddOrUpdateAmazonFbaSalesSnapshot(1:list<AmazonFbaSalesSnapshot> amazonfbasalessnapshotlist)
9945 vikram.rag 1872
 
1873
	 map<i64,i64> getCreatedOrdersForFlipkart(list<string> flipkartorderids)
1874
 
11896 amit.gupta 1875
	 bool isPrivateDealTransaction(1:i64 transactionId)
1876
 
12396 kshitij.so 1877
	 AmazonFbaSalesSnapshot getAmazonFbaSalesLatestSnapshotForItemLocationWise(1:i64 item_id,2:i64 location);
1878
 
12103 manish.sha 1879
	 bool changeEasyshipMfnOrderTxnStatus(1:i64 transactionId, 2:TransactionStatus status, 3:string description, 4:i64 pickUp, 5:OrderType orderType, 6:OrderSource source, 7:i64 shipTimestamp, 8:i64 deliveryTimeStamp) throws (1:TransactionServiceException ex)
1880
 
1881
	 void updateAmazonFbaOrdersReturns(1:list<AmazonFbaOrderReturns> fbaOrderReturns) throws (1:TransactionServiceException ex)
1882
 
1883
	 list<AmazonFbaOrderReturns> getAllAmazonFbaOrderReturnsByCurrentTime(1:i64 insertionTimestamp) throws (1:TransactionServiceException ex)
1884
 
1885
	 map<i64, map<string, i64>> getTotalSaleReturnsFbaSkusCurentTime(1:i64 insertionTimestamp) throws (1:TransactionServiceException ex)
1886
 
12589 manish.sha 1887
	 list<FlipkartOrder> getVerificationPendingOrdersFK() throws (1:TransactionServiceException ex)
1888
 
12772 manish.sha 1889
	 FlipkartAdvantageOrder getFAOrderByFkOrderId(1:string fkOrderId, 2:string fkOrderItemId) throws (1:TransactionServiceException ex)
12589 manish.sha 1890
 
12772 manish.sha 1891
	 list<FlipkartAdvantageOrder> getAllFAOrdersList(1:string status) throws (1:TransactionServiceException ex)
12589 manish.sha 1892
 
12653 manish.sha 1893
	 void addUpdateFaOrdersBulk(1:list<FlipkartAdvantageOrder> faOrdersList) throws (1:TransactionServiceException ex)
1894
 
1895
	 void addInvoiceDetailsToOrders(1:i64 transactionId, 2:i64 customerId) throws (1:TransactionServiceException ex)
12772 manish.sha 1896
 
12980 kshitij.so 1897
	 bool flipkartFaOrderExists(1:string fkOrderId, 2:string fkOrderItemId) throws (1:TransactionServiceException ex)
12979 kshitij.so 1898
 
1899
	 RechargeOrder getRcgOrderStatus(1:i64 rechargeOrderId,2:bool isFinal)
1900
 
1901
	 RechargeTransaction getRcgTransactionStatus(1:i64 rechargeTransactionId,2:bool isFinal)
13148 manish.sha 1902
 
1903
	 void bulkAddOrUpdateFlipkartFaSalesSnapshot(1:list<FlipkartFaSalesSnapshot> flipkartfasalessnapshotlist)
1904
 
1905
	 list<FlipkartFaSalesSnapshot> getFlipkartFaSalesSnapshotForDays(1:i32 days)
1906
 
1907
	 FlipkartFaSalesSnapshot getFlipkartFaSalesSnapshotBySkuAndSaleDate(1:i64 item_id, 2:i64 dateOfSale)
1908
 
1909
	 bool acceptPackageOrders(list<i64> orders) throws (1:TransactionServiceException ex)
1910
 
1911
	 list<Order> getGroupOrdersByLogisticsTxnId(1:string logisticsTxnId) throws (1:TransactionServiceException ex)
1912
 
13276 manish.sha 1913
	 bool addBillingDetailsForGrouppedOrders(1:list<i64> order_ids, 2:string invoice_number, 3:map<i64,list<string>> itemNumbersMap, 4:map<i64,list<string>> serialNumbersMap, 5:map<i64,list<i64>> freebieWarehouseIdMap, 6:string billed_by, 7:i64 jacketNumber, 8:i64 billingType, 9:bool authorize, 10:string invoiceType) throws (1:TransactionServiceException ex)
1914
 
1915
	 string getInvoiceFormatLogisticsTxnId(1:i64 transactionId, 2:i64 shipementSeq) throws (1:TransactionServiceException ex)
13691 manish.sha 1916
 
1917
	 void createHomeShopOrder(1:HsOrder snapdealOrder);
1918
 
1919
     list<HsOrder> getHomeShopOrder(1:i64 orderId, 2:string hsOrderNo, 3:string hsSubOrderNo);
1920
 
1921
     bool homeShopOrderExists(1:string hsOrderNo, 2:string hsSubOrderNo);
17470 manish.sha 1922
 
1923
     Order splitBulkOrder(1:i64 orderId, 2:i64 splitOrderQty);
18041 manish.sha 1924
 
1925
     string moveOrdersToCorrectWarehouse();
18578 manish.sha 1926
 
1927
     Creditor getCreditorInfo(1:i64 id, 2:string name)
1928
 
1929
    bool updateCreditorInfo(1:Creditor creditor) 
1930
 
1931
    list<UserSanction> getUserSanctionDetails(1:i64 userId)
1932
 
1933
    UserSanction getUserSanctionDetailsForCreditor(1:i64 userId, i64 creditorId)
1934
 
1935
    bool updateUserSanction(1:UserSanction userSanaction) throws (1:TransactionServiceException pe)
1936
 
1937
    list<CreditHistory> getCreditHistoryRecordsForTransaction(1:i64 paymentId, 2:i64 creditorId, 3:string creditTxnType)
1938
 
1939
    list<CreditHistory> getCreditHistoryRecordsForUserAndCreditor(1:i64 userId, 2:string creditTxnType)
1940
 
1941
    bool processCreditTransaction(1:i64 paymentId, 2:list<CreditHistory> creditTxns) throws (1:TransactionServiceException pe)
1942
 
1943
    list<CreditHistory> getLoanPayableForUserToCreditor(1:i64 userId, 2:i64 creditorId, 3:i64 dueDate)
1944
 
1945
    ReturnOrderInfo getReturnOrderInfo(1:i64 id) throws (1:TransactionServiceException ex);
1946
 
1947
     map<i64,list<ReturnOrderInfo>> getReturnOrderInfoList(1:list<i64> order_ids);
1948
 
1949
	 map<i64,list<ReturnOrderInfo>> getReturnOrderInfoListAsByStatus(1:list<i64> order_ids, 2:list<string> statuses);
1950
 
1951
     bool updateReturnOrderInfo(1:ReturnOrderInfo returnInfo) throws (1:TransactionServiceException ex);
1952
 
1953
     map<i64, bool> bulkUpdateReturnOrderInfo(1:map<i64,list<ReturnOrderInfo>> orderReturnInfosMap) throws (1:TransactionServiceException ex);
1954
 
1955
     list<ReturnOrderInfo> getReturnOrdersAsPerWarehouseId(1:i64 warehouseId);
1956
 
1957
     i64 createReturnTransaction(1:ReturnTransaction returnTransaction) throws (1:TransactionServiceException ex);
1958
 
1959
     ReturnTransaction getReturnTransaction(1:i64 id) throws (1:TransactionServiceException ex);
1960
 
1961
	 list<ReturnOrderInfo> getReturnOrdersForReturnTransaction(1:i64 returnTransactionId)  throws (1:TransactionServiceException ex);
1962
 
1963
	 bool changeReturnTransactionStatus(1:i64 returnTransactionId, 2:ReturnTransactionStatus status, 3:list<i64> returnOrderIds) throws (1:TransactionServiceException ex);
1964
 
1965
	 bool createReturnPickupRequest(1:list<i64> returnOrderIds, 2:i64 providerId) throws (1:TransactionServiceException ex);
1966
 
1967
	 bool updateReturnPickupRequest(1:ReturnPickupRequest returnPickupRequest) throws (1:TransactionServiceException ex);
1968
 
1969
	 list<ReturnOrderInfo> getAllReturnOrdersForReturnPickupRequest(1:i64 logisticsRequestId) throws (1:TransactionServiceException ex);
1970
 
1971
	 bool receiveReturnPickup(1:map<i64,map<string, string>> returnOrdersMap, 2:i64 id) throws (1:TransactionServiceException ex);
1972
 
1973
	 bool validateReturnPickup(1:i64 returnPickupId, 2:map<i64, bool>returnOrdersMap) throws (1:TransactionServiceException ex);
1974
 
1975
	 bool processReturnPickup(1:i64 returnPickupId, 2:map<i64, map<string, string>> returnOrdersMap) throws (1:TransactionServiceException ex);
1976
 
1977
	 bool markReturnTransactionComplete(1:i64 returnTransactionId) throws (1:TransactionServiceException ex);
1978
 
1979
	 bool refundReturnTransactionPayment(1:map<i64, map<string, string>> refundOrdersMap, 2:i64 returntransactionId) throws (1:TransactionServiceException ex);
1980
 
1981
	 list<ReturnTransaction> getReturnTransactionsForCustomer(1:list<ReturnTransactionStatus> statusList, 2:string customerMobile, 3:string customerEmail, 4:i64 returnTransactionId, 5:i64 customerId) throws (1:TransactionServiceException ex);
1982
 
1983
	 bool verifyOrderForTransaction(1:i64 transactionId) throws (1:TransactionServiceException ex);
1984
 
12103 manish.sha 1985
}