Subversion Repositories SmartDukaan

Rev

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

Rev 4607 Rev 4647
Line 675... Line 675...
675
     - orderId
675
     - orderId
676
     - warehouseId
676
     - warehouseId
677
    """
677
    """
678
    pass
678
    pass
679
 
679
 
680
  def addDelayReason(self, orderId, delayReason, furtherDelay):
680
  def addDelayReason(self, orderId, delayReason, furtherDelay, delayReasonText):
681
    """
681
    """
682
    Adds the given delay reason to the given order.
682
    Adds the given delay reason to the given order.
683
    Increases the expected delivery time of the given order by the given no. of days.
683
    Increases the expected delivery time of the given order by the given no. of days.
684
    Raises an exception if no order with the given id can be found.
684
    Raises an exception if no order with the given id can be found.
685
 
685
 
686
    Parameters:
686
    Parameters:
687
     - orderId
687
     - orderId
688
     - delayReason
688
     - delayReason
689
     - furtherDelay
689
     - furtherDelay
-
 
690
     - delayReasonText
690
    """
691
    """
691
    pass
692
    pass
692
 
693
 
693
  def reconcileCodCollection(self, collectedAmountMap, xferBy, xferTxnId, xferDate):
694
  def reconcileCodCollection(self, collectedAmountMap, xferBy, xferTxnId, xferDate):
694
    """
695
    """
Line 3173... Line 3174...
3173
      return result.success
3174
      return result.success
3174
    if result.ex is not None:
3175
    if result.ex is not None:
3175
      raise result.ex
3176
      raise result.ex
3176
    raise TApplicationException(TApplicationException.MISSING_RESULT, "shiftToWarehouse failed: unknown result");
3177
    raise TApplicationException(TApplicationException.MISSING_RESULT, "shiftToWarehouse failed: unknown result");
3177
 
3178
 
3178
  def addDelayReason(self, orderId, delayReason, furtherDelay):
3179
  def addDelayReason(self, orderId, delayReason, furtherDelay, delayReasonText):
3179
    """
3180
    """
3180
    Adds the given delay reason to the given order.
3181
    Adds the given delay reason to the given order.
3181
    Increases the expected delivery time of the given order by the given no. of days.
3182
    Increases the expected delivery time of the given order by the given no. of days.
3182
    Raises an exception if no order with the given id can be found.
3183
    Raises an exception if no order with the given id can be found.
3183
 
3184
 
3184
    Parameters:
3185
    Parameters:
3185
     - orderId
3186
     - orderId
3186
     - delayReason
3187
     - delayReason
3187
     - furtherDelay
3188
     - furtherDelay
-
 
3189
     - delayReasonText
3188
    """
3190
    """
3189
    self.send_addDelayReason(orderId, delayReason, furtherDelay)
3191
    self.send_addDelayReason(orderId, delayReason, furtherDelay, delayReasonText)
3190
    return self.recv_addDelayReason()
3192
    return self.recv_addDelayReason()
3191
 
3193
 
3192
  def send_addDelayReason(self, orderId, delayReason, furtherDelay):
3194
  def send_addDelayReason(self, orderId, delayReason, furtherDelay, delayReasonText):
3193
    self._oprot.writeMessageBegin('addDelayReason', TMessageType.CALL, self._seqid)
3195
    self._oprot.writeMessageBegin('addDelayReason', TMessageType.CALL, self._seqid)
3194
    args = addDelayReason_args()
3196
    args = addDelayReason_args()
3195
    args.orderId = orderId
3197
    args.orderId = orderId
3196
    args.delayReason = delayReason
3198
    args.delayReason = delayReason
3197
    args.furtherDelay = furtherDelay
3199
    args.furtherDelay = furtherDelay
-
 
3200
    args.delayReasonText = delayReasonText
3198
    args.write(self._oprot)
3201
    args.write(self._oprot)
3199
    self._oprot.writeMessageEnd()
3202
    self._oprot.writeMessageEnd()
3200
    self._oprot.trans.flush()
3203
    self._oprot.trans.flush()
3201
 
3204
 
3202
  def recv_addDelayReason(self, ):
3205
  def recv_addDelayReason(self, ):
Line 5084... Line 5087...
5084
    args = addDelayReason_args()
5087
    args = addDelayReason_args()
5085
    args.read(iprot)
5088
    args.read(iprot)
5086
    iprot.readMessageEnd()
5089
    iprot.readMessageEnd()
5087
    result = addDelayReason_result()
5090
    result = addDelayReason_result()
5088
    try:
5091
    try:
5089
      result.success = self._handler.addDelayReason(args.orderId, args.delayReason, args.furtherDelay)
5092
      result.success = self._handler.addDelayReason(args.orderId, args.delayReason, args.furtherDelay, args.delayReasonText)
5090
    except TransactionServiceException, ex:
5093
    except TransactionServiceException, ex:
5091
      result.ex = ex
5094
      result.ex = ex
5092
    oprot.writeMessageBegin("addDelayReason", TMessageType.REPLY, seqid)
5095
    oprot.writeMessageBegin("addDelayReason", TMessageType.REPLY, seqid)
5093
    result.write(oprot)
5096
    result.write(oprot)
5094
    oprot.writeMessageEnd()
5097
    oprot.writeMessageEnd()
Line 14317... Line 14320...
14317
  """
14320
  """
14318
  Attributes:
14321
  Attributes:
14319
   - orderId
14322
   - orderId
14320
   - delayReason
14323
   - delayReason
14321
   - furtherDelay
14324
   - furtherDelay
-
 
14325
   - delayReasonText
14322
  """
14326
  """
14323
 
14327
 
14324
  thrift_spec = (
14328
  thrift_spec = (
14325
    None, # 0
14329
    None, # 0
14326
    (1, TType.I64, 'orderId', None, None, ), # 1
14330
    (1, TType.I64, 'orderId', None, None, ), # 1
14327
    (2, TType.I32, 'delayReason', None, None, ), # 2
14331
    (2, TType.I32, 'delayReason', None, None, ), # 2
14328
    (3, TType.I64, 'furtherDelay', None, None, ), # 3
14332
    (3, TType.I64, 'furtherDelay', None, None, ), # 3
-
 
14333
    (4, TType.STRING, 'delayReasonText', None, None, ), # 4
14329
  )
14334
  )
14330
 
14335
 
14331
  def __init__(self, orderId=None, delayReason=None, furtherDelay=None,):
14336
  def __init__(self, orderId=None, delayReason=None, furtherDelay=None, delayReasonText=None,):
14332
    self.orderId = orderId
14337
    self.orderId = orderId
14333
    self.delayReason = delayReason
14338
    self.delayReason = delayReason
14334
    self.furtherDelay = furtherDelay
14339
    self.furtherDelay = furtherDelay
-
 
14340
    self.delayReasonText = delayReasonText
14335
 
14341
 
14336
  def read(self, iprot):
14342
  def read(self, iprot):
14337
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
14343
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
14338
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
14344
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
14339
      return
14345
      return
Line 14355... Line 14361...
14355
      elif fid == 3:
14361
      elif fid == 3:
14356
        if ftype == TType.I64:
14362
        if ftype == TType.I64:
14357
          self.furtherDelay = iprot.readI64();
14363
          self.furtherDelay = iprot.readI64();
14358
        else:
14364
        else:
14359
          iprot.skip(ftype)
14365
          iprot.skip(ftype)
-
 
14366
      elif fid == 4:
-
 
14367
        if ftype == TType.STRING:
-
 
14368
          self.delayReasonText = iprot.readString();
-
 
14369
        else:
-
 
14370
          iprot.skip(ftype)
14360
      else:
14371
      else:
14361
        iprot.skip(ftype)
14372
        iprot.skip(ftype)
14362
      iprot.readFieldEnd()
14373
      iprot.readFieldEnd()
14363
    iprot.readStructEnd()
14374
    iprot.readStructEnd()
14364
 
14375
 
Line 14377... Line 14388...
14377
      oprot.writeFieldEnd()
14388
      oprot.writeFieldEnd()
14378
    if self.furtherDelay is not None:
14389
    if self.furtherDelay is not None:
14379
      oprot.writeFieldBegin('furtherDelay', TType.I64, 3)
14390
      oprot.writeFieldBegin('furtherDelay', TType.I64, 3)
14380
      oprot.writeI64(self.furtherDelay)
14391
      oprot.writeI64(self.furtherDelay)
14381
      oprot.writeFieldEnd()
14392
      oprot.writeFieldEnd()
-
 
14393
    if self.delayReasonText is not None:
-
 
14394
      oprot.writeFieldBegin('delayReasonText', TType.STRING, 4)
-
 
14395
      oprot.writeString(self.delayReasonText)
-
 
14396
      oprot.writeFieldEnd()
14382
    oprot.writeFieldStop()
14397
    oprot.writeFieldStop()
14383
    oprot.writeStructEnd()
14398
    oprot.writeStructEnd()
14384
 
14399
 
14385
  def validate(self):
14400
  def validate(self):
14386
    return
14401
    return