Subversion Repositories SmartDukaan

Rev

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

Rev 6730 Rev 6736
Line 75... Line 75...
75
     - couponCode
75
     - couponCode
76
     - cartId
76
     - cartId
77
    """
77
    """
78
    pass
78
    pass
79
 
79
 
-
 
80
  def getEmiDiscount(self, cartId):
-
 
81
    """
-
 
82
    Parameters:
-
 
83
     - cartId
-
 
84
    """
-
 
85
    pass
-
 
86
 
80
  def applyRechargeCoupon(self, couponCode, totalAmount, userId):
87
  def applyRechargeCoupon(self, couponCode, totalAmount, userId):
81
    """
88
    """
82
    Parameters:
89
    Parameters:
83
     - couponCode
90
     - couponCode
84
     - totalAmount
91
     - totalAmount
Line 456... Line 463...
456
      return result.success
463
      return result.success
457
    if result.pex is not None:
464
    if result.pex is not None:
458
      raise result.pex
465
      raise result.pex
459
    raise TApplicationException(TApplicationException.MISSING_RESULT, "applyCoupon failed: unknown result");
466
    raise TApplicationException(TApplicationException.MISSING_RESULT, "applyCoupon failed: unknown result");
460
 
467
 
-
 
468
  def getEmiDiscount(self, cartId):
-
 
469
    """
-
 
470
    Parameters:
-
 
471
     - cartId
-
 
472
    """
-
 
473
    self.send_getEmiDiscount(cartId)
-
 
474
    return self.recv_getEmiDiscount()
-
 
475
 
-
 
476
  def send_getEmiDiscount(self, cartId):
-
 
477
    self._oprot.writeMessageBegin('getEmiDiscount', TMessageType.CALL, self._seqid)
-
 
478
    args = getEmiDiscount_args()
-
 
479
    args.cartId = cartId
-
 
480
    args.write(self._oprot)
-
 
481
    self._oprot.writeMessageEnd()
-
 
482
    self._oprot.trans.flush()
-
 
483
 
-
 
484
  def recv_getEmiDiscount(self, ):
-
 
485
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
-
 
486
    if mtype == TMessageType.EXCEPTION:
-
 
487
      x = TApplicationException()
-
 
488
      x.read(self._iprot)
-
 
489
      self._iprot.readMessageEnd()
-
 
490
      raise x
-
 
491
    result = getEmiDiscount_result()
-
 
492
    result.read(self._iprot)
-
 
493
    self._iprot.readMessageEnd()
-
 
494
    if result.success is not None:
-
 
495
      return result.success
-
 
496
    if result.pex is not None:
-
 
497
      raise result.pex
-
 
498
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getEmiDiscount failed: unknown result");
-
 
499
 
461
  def applyRechargeCoupon(self, couponCode, totalAmount, userId):
500
  def applyRechargeCoupon(self, couponCode, totalAmount, userId):
462
    """
501
    """
463
    Parameters:
502
    Parameters:
464
     - couponCode
503
     - couponCode
465
     - totalAmount
504
     - totalAmount
Line 930... Line 969...
930
    self._processMap["isCodApplicable"] = Processor.process_isCodApplicable
969
    self._processMap["isCodApplicable"] = Processor.process_isCodApplicable
931
    self._processMap["getAllPromotions"] = Processor.process_getAllPromotions
970
    self._processMap["getAllPromotions"] = Processor.process_getAllPromotions
932
    self._processMap["getPromotionById"] = Processor.process_getPromotionById
971
    self._processMap["getPromotionById"] = Processor.process_getPromotionById
933
    self._processMap["generateCouponsForPromotion"] = Processor.process_generateCouponsForPromotion
972
    self._processMap["generateCouponsForPromotion"] = Processor.process_generateCouponsForPromotion
934
    self._processMap["applyCoupon"] = Processor.process_applyCoupon
973
    self._processMap["applyCoupon"] = Processor.process_applyCoupon
-
 
974
    self._processMap["getEmiDiscount"] = Processor.process_getEmiDiscount
935
    self._processMap["applyRechargeCoupon"] = Processor.process_applyRechargeCoupon
975
    self._processMap["applyRechargeCoupon"] = Processor.process_applyRechargeCoupon
936
    self._processMap["trackCouponUsage"] = Processor.process_trackCouponUsage
976
    self._processMap["trackCouponUsage"] = Processor.process_trackCouponUsage
937
    self._processMap["getCouponUsageCountByUser"] = Processor.process_getCouponUsageCountByUser
977
    self._processMap["getCouponUsageCountByUser"] = Processor.process_getCouponUsageCountByUser
938
    self._processMap["getActiveCodes"] = Processor.process_getActiveCodes
978
    self._processMap["getActiveCodes"] = Processor.process_getActiveCodes
939
    self._processMap["deleteCoupon"] = Processor.process_deleteCoupon
979
    self._processMap["deleteCoupon"] = Processor.process_deleteCoupon
Line 1072... Line 1112...
1072
    oprot.writeMessageBegin("applyCoupon", TMessageType.REPLY, seqid)
1112
    oprot.writeMessageBegin("applyCoupon", TMessageType.REPLY, seqid)
1073
    result.write(oprot)
1113
    result.write(oprot)
1074
    oprot.writeMessageEnd()
1114
    oprot.writeMessageEnd()
1075
    oprot.trans.flush()
1115
    oprot.trans.flush()
1076
 
1116
 
-
 
1117
  def process_getEmiDiscount(self, seqid, iprot, oprot):
-
 
1118
    args = getEmiDiscount_args()
-
 
1119
    args.read(iprot)
-
 
1120
    iprot.readMessageEnd()
-
 
1121
    result = getEmiDiscount_result()
-
 
1122
    try:
-
 
1123
      result.success = self._handler.getEmiDiscount(args.cartId)
-
 
1124
    except PromotionException, pex:
-
 
1125
      result.pex = pex
-
 
1126
    oprot.writeMessageBegin("getEmiDiscount", TMessageType.REPLY, seqid)
-
 
1127
    result.write(oprot)
-
 
1128
    oprot.writeMessageEnd()
-
 
1129
    oprot.trans.flush()
-
 
1130
 
1077
  def process_applyRechargeCoupon(self, seqid, iprot, oprot):
1131
  def process_applyRechargeCoupon(self, seqid, iprot, oprot):
1078
    args = applyRechargeCoupon_args()
1132
    args = applyRechargeCoupon_args()
1079
    args.read(iprot)
1133
    args.read(iprot)
1080
    iprot.readMessageEnd()
1134
    iprot.readMessageEnd()
1081
    result = applyRechargeCoupon_result()
1135
    result = applyRechargeCoupon_result()
Line 2344... Line 2398...
2344
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2398
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2345
 
2399
 
2346
  def __ne__(self, other):
2400
  def __ne__(self, other):
2347
    return not (self == other)
2401
    return not (self == other)
2348
 
2402
 
-
 
2403
class getEmiDiscount_args:
-
 
2404
  """
-
 
2405
  Attributes:
-
 
2406
   - cartId
-
 
2407
  """
-
 
2408
 
-
 
2409
  thrift_spec = (
-
 
2410
    None, # 0
-
 
2411
    (1, TType.I64, 'cartId', None, None, ), # 1
-
 
2412
  )
-
 
2413
 
-
 
2414
  def __init__(self, cartId=None,):
-
 
2415
    self.cartId = cartId
-
 
2416
 
-
 
2417
  def read(self, iprot):
-
 
2418
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
-
 
2419
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
-
 
2420
      return
-
 
2421
    iprot.readStructBegin()
-
 
2422
    while True:
-
 
2423
      (fname, ftype, fid) = iprot.readFieldBegin()
-
 
2424
      if ftype == TType.STOP:
-
 
2425
        break
-
 
2426
      if fid == 1:
-
 
2427
        if ftype == TType.I64:
-
 
2428
          self.cartId = iprot.readI64();
-
 
2429
        else:
-
 
2430
          iprot.skip(ftype)
-
 
2431
      else:
-
 
2432
        iprot.skip(ftype)
-
 
2433
      iprot.readFieldEnd()
-
 
2434
    iprot.readStructEnd()
-
 
2435
 
-
 
2436
  def write(self, oprot):
-
 
2437
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
-
 
2438
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
-
 
2439
      return
-
 
2440
    oprot.writeStructBegin('getEmiDiscount_args')
-
 
2441
    if self.cartId is not None:
-
 
2442
      oprot.writeFieldBegin('cartId', TType.I64, 1)
-
 
2443
      oprot.writeI64(self.cartId)
-
 
2444
      oprot.writeFieldEnd()
-
 
2445
    oprot.writeFieldStop()
-
 
2446
    oprot.writeStructEnd()
-
 
2447
 
-
 
2448
  def validate(self):
-
 
2449
    return
-
 
2450
 
-
 
2451
 
-
 
2452
  def __repr__(self):
-
 
2453
    L = ['%s=%r' % (key, value)
-
 
2454
      for key, value in self.__dict__.iteritems()]
-
 
2455
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
 
2456
 
-
 
2457
  def __eq__(self, other):
-
 
2458
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
 
2459
 
-
 
2460
  def __ne__(self, other):
-
 
2461
    return not (self == other)
-
 
2462
 
-
 
2463
class getEmiDiscount_result:
-
 
2464
  """
-
 
2465
  Attributes:
-
 
2466
   - success
-
 
2467
   - pex
-
 
2468
  """
-
 
2469
 
-
 
2470
  thrift_spec = (
-
 
2471
    (0, TType.MAP, 'success', (TType.I64,None,TType.DOUBLE,None), None, ), # 0
-
 
2472
    (1, TType.STRUCT, 'pex', (PromotionException, PromotionException.thrift_spec), None, ), # 1
-
 
2473
  )
-
 
2474
 
-
 
2475
  def __init__(self, success=None, pex=None,):
-
 
2476
    self.success = success
-
 
2477
    self.pex = pex
-
 
2478
 
-
 
2479
  def read(self, iprot):
-
 
2480
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
-
 
2481
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
-
 
2482
      return
-
 
2483
    iprot.readStructBegin()
-
 
2484
    while True:
-
 
2485
      (fname, ftype, fid) = iprot.readFieldBegin()
-
 
2486
      if ftype == TType.STOP:
-
 
2487
        break
-
 
2488
      if fid == 0:
-
 
2489
        if ftype == TType.MAP:
-
 
2490
          self.success = {}
-
 
2491
          (_ktype29, _vtype30, _size28 ) = iprot.readMapBegin() 
-
 
2492
          for _i32 in xrange(_size28):
-
 
2493
            _key33 = iprot.readI64();
-
 
2494
            _val34 = iprot.readDouble();
-
 
2495
            self.success[_key33] = _val34
-
 
2496
          iprot.readMapEnd()
-
 
2497
        else:
-
 
2498
          iprot.skip(ftype)
-
 
2499
      elif fid == 1:
-
 
2500
        if ftype == TType.STRUCT:
-
 
2501
          self.pex = PromotionException()
-
 
2502
          self.pex.read(iprot)
-
 
2503
        else:
-
 
2504
          iprot.skip(ftype)
-
 
2505
      else:
-
 
2506
        iprot.skip(ftype)
-
 
2507
      iprot.readFieldEnd()
-
 
2508
    iprot.readStructEnd()
-
 
2509
 
-
 
2510
  def write(self, oprot):
-
 
2511
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
-
 
2512
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
-
 
2513
      return
-
 
2514
    oprot.writeStructBegin('getEmiDiscount_result')
-
 
2515
    if self.success is not None:
-
 
2516
      oprot.writeFieldBegin('success', TType.MAP, 0)
-
 
2517
      oprot.writeMapBegin(TType.I64, TType.DOUBLE, len(self.success))
-
 
2518
      for kiter35,viter36 in self.success.items():
-
 
2519
        oprot.writeI64(kiter35)
-
 
2520
        oprot.writeDouble(viter36)
-
 
2521
      oprot.writeMapEnd()
-
 
2522
      oprot.writeFieldEnd()
-
 
2523
    if self.pex is not None:
-
 
2524
      oprot.writeFieldBegin('pex', TType.STRUCT, 1)
-
 
2525
      self.pex.write(oprot)
-
 
2526
      oprot.writeFieldEnd()
-
 
2527
    oprot.writeFieldStop()
-
 
2528
    oprot.writeStructEnd()
-
 
2529
 
-
 
2530
  def validate(self):
-
 
2531
    return
-
 
2532
 
-
 
2533
 
-
 
2534
  def __repr__(self):
-
 
2535
    L = ['%s=%r' % (key, value)
-
 
2536
      for key, value in self.__dict__.iteritems()]
-
 
2537
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
 
2538
 
-
 
2539
  def __eq__(self, other):
-
 
2540
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
 
2541
 
-
 
2542
  def __ne__(self, other):
-
 
2543
    return not (self == other)
-
 
2544
 
2349
class applyRechargeCoupon_args:
2545
class applyRechargeCoupon_args:
2350
  """
2546
  """
2351
  Attributes:
2547
  Attributes:
2352
   - couponCode
2548
   - couponCode
2353
   - totalAmount
2549
   - totalAmount
Line 2456... Line 2652...
2456
      if ftype == TType.STOP:
2652
      if ftype == TType.STOP:
2457
        break
2653
        break
2458
      if fid == 0:
2654
      if fid == 0:
2459
        if ftype == TType.MAP:
2655
        if ftype == TType.MAP:
2460
          self.success = {}
2656
          self.success = {}
2461
          (_ktype29, _vtype30, _size28 ) = iprot.readMapBegin() 
2657
          (_ktype38, _vtype39, _size37 ) = iprot.readMapBegin() 
2462
          for _i32 in xrange(_size28):
2658
          for _i41 in xrange(_size37):
2463
            _key33 = iprot.readI64();
2659
            _key42 = iprot.readI64();
2464
            _val34 = iprot.readString();
2660
            _val43 = iprot.readString();
2465
            self.success[_key33] = _val34
2661
            self.success[_key42] = _val43
2466
          iprot.readMapEnd()
2662
          iprot.readMapEnd()
2467
        else:
2663
        else:
2468
          iprot.skip(ftype)
2664
          iprot.skip(ftype)
2469
      elif fid == 1:
2665
      elif fid == 1:
2470
        if ftype == TType.STRUCT:
2666
        if ftype == TType.STRUCT:
Line 2483... Line 2679...
2483
      return
2679
      return
2484
    oprot.writeStructBegin('applyRechargeCoupon_result')
2680
    oprot.writeStructBegin('applyRechargeCoupon_result')
2485
    if self.success is not None:
2681
    if self.success is not None:
2486
      oprot.writeFieldBegin('success', TType.MAP, 0)
2682
      oprot.writeFieldBegin('success', TType.MAP, 0)
2487
      oprot.writeMapBegin(TType.I64, TType.STRING, len(self.success))
2683
      oprot.writeMapBegin(TType.I64, TType.STRING, len(self.success))
2488
      for kiter35,viter36 in self.success.items():
2684
      for kiter44,viter45 in self.success.items():
2489
        oprot.writeI64(kiter35)
2685
        oprot.writeI64(kiter44)
2490
        oprot.writeString(viter36)
2686
        oprot.writeString(viter45)
2491
      oprot.writeMapEnd()
2687
      oprot.writeMapEnd()
2492
      oprot.writeFieldEnd()
2688
      oprot.writeFieldEnd()
2493
    if self.pex is not None:
2689
    if self.pex is not None:
2494
      oprot.writeFieldBegin('pex', TType.STRUCT, 1)
2690
      oprot.writeFieldBegin('pex', TType.STRUCT, 1)
2495
      self.pex.write(oprot)
2691
      self.pex.write(oprot)
Line 2887... Line 3083...
2887
      if ftype == TType.STOP:
3083
      if ftype == TType.STOP:
2888
        break
3084
        break
2889
      if fid == 0:
3085
      if fid == 0:
2890
        if ftype == TType.LIST:
3086
        if ftype == TType.LIST:
2891
          self.success = []
3087
          self.success = []
2892
          (_etype40, _size37) = iprot.readListBegin()
3088
          (_etype49, _size46) = iprot.readListBegin()
2893
          for _i41 in xrange(_size37):
3089
          for _i50 in xrange(_size46):
2894
            _elem42 = Coupon()
3090
            _elem51 = Coupon()
2895
            _elem42.read(iprot)
3091
            _elem51.read(iprot)
2896
            self.success.append(_elem42)
3092
            self.success.append(_elem51)
2897
          iprot.readListEnd()
3093
          iprot.readListEnd()
2898
        else:
3094
        else:
2899
          iprot.skip(ftype)
3095
          iprot.skip(ftype)
2900
      elif fid == 1:
3096
      elif fid == 1:
2901
        if ftype == TType.STRUCT:
3097
        if ftype == TType.STRUCT:
Line 2914... Line 3110...
2914
      return
3110
      return
2915
    oprot.writeStructBegin('getActiveCodes_result')
3111
    oprot.writeStructBegin('getActiveCodes_result')
2916
    if self.success is not None:
3112
    if self.success is not None:
2917
      oprot.writeFieldBegin('success', TType.LIST, 0)
3113
      oprot.writeFieldBegin('success', TType.LIST, 0)
2918
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3114
      oprot.writeListBegin(TType.STRUCT, len(self.success))
2919
      for iter43 in self.success:
3115
      for iter52 in self.success:
2920
        iter43.write(oprot)
3116
        iter52.write(oprot)
2921
      oprot.writeListEnd()
3117
      oprot.writeListEnd()
2922
      oprot.writeFieldEnd()
3118
      oprot.writeFieldEnd()
2923
    if self.pex is not None:
3119
    if self.pex is not None:
2924
      oprot.writeFieldBegin('pex', TType.STRUCT, 1)
3120
      oprot.writeFieldBegin('pex', TType.STRUCT, 1)
2925
      self.pex.write(oprot)
3121
      self.pex.write(oprot)
Line 3131... Line 3327...
3131
      if ftype == TType.STOP:
3327
      if ftype == TType.STOP:
3132
        break
3328
        break
3133
      if fid == 0:
3329
      if fid == 0:
3134
        if ftype == TType.LIST:
3330
        if ftype == TType.LIST:
3135
          self.success = []
3331
          self.success = []
3136
          (_etype47, _size44) = iprot.readListBegin()
3332
          (_etype56, _size53) = iprot.readListBegin()
3137
          for _i48 in xrange(_size44):
3333
          for _i57 in xrange(_size53):
3138
            _elem49 = Coupon()
3334
            _elem58 = Coupon()
3139
            _elem49.read(iprot)
3335
            _elem58.read(iprot)
3140
            self.success.append(_elem49)
3336
            self.success.append(_elem58)
3141
          iprot.readListEnd()
3337
          iprot.readListEnd()
3142
        else:
3338
        else:
3143
          iprot.skip(ftype)
3339
          iprot.skip(ftype)
3144
      elif fid == 1:
3340
      elif fid == 1:
3145
        if ftype == TType.STRUCT:
3341
        if ftype == TType.STRUCT:
Line 3158... Line 3354...
3158
      return
3354
      return
3159
    oprot.writeStructBegin('getActiveCoupons_result')
3355
    oprot.writeStructBegin('getActiveCoupons_result')
3160
    if self.success is not None:
3356
    if self.success is not None:
3161
      oprot.writeFieldBegin('success', TType.LIST, 0)
3357
      oprot.writeFieldBegin('success', TType.LIST, 0)
3162
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3358
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3163
      for iter50 in self.success:
3359
      for iter59 in self.success:
3164
        iter50.write(oprot)
3360
        iter59.write(oprot)
3165
      oprot.writeListEnd()
3361
      oprot.writeListEnd()
3166
      oprot.writeFieldEnd()
3362
      oprot.writeFieldEnd()
3167
    if self.pex is not None:
3363
    if self.pex is not None:
3168
      oprot.writeFieldBegin('pex', TType.STRUCT, 1)
3364
      oprot.writeFieldBegin('pex', TType.STRUCT, 1)
3169
      self.pex.write(oprot)
3365
      self.pex.write(oprot)
Line 3641... Line 3837...
3641
      if ftype == TType.STOP:
3837
      if ftype == TType.STOP:
3642
        break
3838
        break
3643
      if fid == 1:
3839
      if fid == 1:
3644
        if ftype == TType.LIST:
3840
        if ftype == TType.LIST:
3645
          self.itemIds = []
3841
          self.itemIds = []
3646
          (_etype54, _size51) = iprot.readListBegin()
3842
          (_etype63, _size60) = iprot.readListBegin()
3647
          for _i55 in xrange(_size51):
3843
          for _i64 in xrange(_size60):
3648
            _elem56 = iprot.readI64();
3844
            _elem65 = iprot.readI64();
3649
            self.itemIds.append(_elem56)
3845
            self.itemIds.append(_elem65)
3650
          iprot.readListEnd()
3846
          iprot.readListEnd()
3651
        else:
3847
        else:
3652
          iprot.skip(ftype)
3848
          iprot.skip(ftype)
3653
      else:
3849
      else:
3654
        iprot.skip(ftype)
3850
        iprot.skip(ftype)
Line 3661... Line 3857...
3661
      return
3857
      return
3662
    oprot.writeStructBegin('getItemDiscountMap_args')
3858
    oprot.writeStructBegin('getItemDiscountMap_args')
3663
    if self.itemIds is not None:
3859
    if self.itemIds is not None:
3664
      oprot.writeFieldBegin('itemIds', TType.LIST, 1)
3860
      oprot.writeFieldBegin('itemIds', TType.LIST, 1)
3665
      oprot.writeListBegin(TType.I64, len(self.itemIds))
3861
      oprot.writeListBegin(TType.I64, len(self.itemIds))
3666
      for iter57 in self.itemIds:
3862
      for iter66 in self.itemIds:
3667
        oprot.writeI64(iter57)
3863
        oprot.writeI64(iter66)
3668
      oprot.writeListEnd()
3864
      oprot.writeListEnd()
3669
      oprot.writeFieldEnd()
3865
      oprot.writeFieldEnd()
3670
    oprot.writeFieldStop()
3866
    oprot.writeFieldStop()
3671
    oprot.writeStructEnd()
3867
    oprot.writeStructEnd()
3672
 
3868
 
Line 3711... Line 3907...
3711
      if ftype == TType.STOP:
3907
      if ftype == TType.STOP:
3712
        break
3908
        break
3713
      if fid == 0:
3909
      if fid == 0:
3714
        if ftype == TType.LIST:
3910
        if ftype == TType.LIST:
3715
          self.success = []
3911
          self.success = []
3716
          (_etype61, _size58) = iprot.readListBegin()
3912
          (_etype70, _size67) = iprot.readListBegin()
3717
          for _i62 in xrange(_size58):
3913
          for _i71 in xrange(_size67):
3718
            _elem63 = ItemCouponDiscount()
3914
            _elem72 = ItemCouponDiscount()
3719
            _elem63.read(iprot)
3915
            _elem72.read(iprot)
3720
            self.success.append(_elem63)
3916
            self.success.append(_elem72)
3721
          iprot.readListEnd()
3917
          iprot.readListEnd()
3722
        else:
3918
        else:
3723
          iprot.skip(ftype)
3919
          iprot.skip(ftype)
3724
      elif fid == 1:
3920
      elif fid == 1:
3725
        if ftype == TType.STRUCT:
3921
        if ftype == TType.STRUCT:
Line 3738... Line 3934...
3738
      return
3934
      return
3739
    oprot.writeStructBegin('getItemDiscountMap_result')
3935
    oprot.writeStructBegin('getItemDiscountMap_result')
3740
    if self.success is not None:
3936
    if self.success is not None:
3741
      oprot.writeFieldBegin('success', TType.LIST, 0)
3937
      oprot.writeFieldBegin('success', TType.LIST, 0)
3742
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3938
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3743
      for iter64 in self.success:
3939
      for iter73 in self.success:
3744
        iter64.write(oprot)
3940
        iter73.write(oprot)
3745
      oprot.writeListEnd()
3941
      oprot.writeListEnd()
3746
      oprot.writeFieldEnd()
3942
      oprot.writeFieldEnd()
3747
    if self.pex is not None:
3943
    if self.pex is not None:
3748
      oprot.writeFieldBegin('pex', TType.STRUCT, 1)
3944
      oprot.writeFieldBegin('pex', TType.STRUCT, 1)
3749
      self.pex.write(oprot)
3945
      self.pex.write(oprot)
Line 3849... Line 4045...
3849
      if ftype == TType.STOP:
4045
      if ftype == TType.STOP:
3850
        break
4046
        break
3851
      if fid == 0:
4047
      if fid == 0:
3852
        if ftype == TType.MAP:
4048
        if ftype == TType.MAP:
3853
          self.success = {}
4049
          self.success = {}
3854
          (_ktype66, _vtype67, _size65 ) = iprot.readMapBegin() 
4050
          (_ktype75, _vtype76, _size74 ) = iprot.readMapBegin() 
3855
          for _i69 in xrange(_size65):
4051
          for _i78 in xrange(_size74):
3856
            _key70 = iprot.readString();
4052
            _key79 = iprot.readString();
3857
            _val71 = iprot.readDouble();
4053
            _val80 = iprot.readDouble();
3858
            self.success[_key70] = _val71
4054
            self.success[_key79] = _val80
3859
          iprot.readMapEnd()
4055
          iprot.readMapEnd()
3860
        else:
4056
        else:
3861
          iprot.skip(ftype)
4057
          iprot.skip(ftype)
3862
      else:
4058
      else:
3863
        iprot.skip(ftype)
4059
        iprot.skip(ftype)
Line 3870... Line 4066...
3870
      return
4066
      return
3871
    oprot.writeStructBegin('getDiscountsForEntity_result')
4067
    oprot.writeStructBegin('getDiscountsForEntity_result')
3872
    if self.success is not None:
4068
    if self.success is not None:
3873
      oprot.writeFieldBegin('success', TType.MAP, 0)
4069
      oprot.writeFieldBegin('success', TType.MAP, 0)
3874
      oprot.writeMapBegin(TType.STRING, TType.DOUBLE, len(self.success))
4070
      oprot.writeMapBegin(TType.STRING, TType.DOUBLE, len(self.success))
3875
      for kiter72,viter73 in self.success.items():
4071
      for kiter81,viter82 in self.success.items():
3876
        oprot.writeString(kiter72)
4072
        oprot.writeString(kiter81)
3877
        oprot.writeDouble(viter73)
4073
        oprot.writeDouble(viter82)
3878
      oprot.writeMapEnd()
4074
      oprot.writeMapEnd()
3879
      oprot.writeFieldEnd()
4075
      oprot.writeFieldEnd()
3880
    oprot.writeFieldStop()
4076
    oprot.writeFieldStop()
3881
    oprot.writeStructEnd()
4077
    oprot.writeStructEnd()
3882
 
4078