InboundOrderVO.py 5.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. import json
  4. from alipay.aop.api.constant.ParamConstants import *
  5. class InboundOrderVO(object):
  6. def __init__(self):
  7. self._ext_info = None
  8. self._gmt_create = None
  9. self._gmt_modified = None
  10. self._inbound_order_id = None
  11. self._inbound_type = None
  12. self._notice_date = None
  13. self._operator_id = None
  14. self._operator_type = None
  15. self._out_biz_no = None
  16. self._status = None
  17. self._warehouse_code = None
  18. @property
  19. def ext_info(self):
  20. return self._ext_info
  21. @ext_info.setter
  22. def ext_info(self, value):
  23. self._ext_info = value
  24. @property
  25. def gmt_create(self):
  26. return self._gmt_create
  27. @gmt_create.setter
  28. def gmt_create(self, value):
  29. self._gmt_create = value
  30. @property
  31. def gmt_modified(self):
  32. return self._gmt_modified
  33. @gmt_modified.setter
  34. def gmt_modified(self, value):
  35. self._gmt_modified = value
  36. @property
  37. def inbound_order_id(self):
  38. return self._inbound_order_id
  39. @inbound_order_id.setter
  40. def inbound_order_id(self, value):
  41. self._inbound_order_id = value
  42. @property
  43. def inbound_type(self):
  44. return self._inbound_type
  45. @inbound_type.setter
  46. def inbound_type(self, value):
  47. self._inbound_type = value
  48. @property
  49. def notice_date(self):
  50. return self._notice_date
  51. @notice_date.setter
  52. def notice_date(self, value):
  53. self._notice_date = value
  54. @property
  55. def operator_id(self):
  56. return self._operator_id
  57. @operator_id.setter
  58. def operator_id(self, value):
  59. self._operator_id = value
  60. @property
  61. def operator_type(self):
  62. return self._operator_type
  63. @operator_type.setter
  64. def operator_type(self, value):
  65. self._operator_type = value
  66. @property
  67. def out_biz_no(self):
  68. return self._out_biz_no
  69. @out_biz_no.setter
  70. def out_biz_no(self, value):
  71. self._out_biz_no = value
  72. @property
  73. def status(self):
  74. return self._status
  75. @status.setter
  76. def status(self, value):
  77. self._status = value
  78. @property
  79. def warehouse_code(self):
  80. return self._warehouse_code
  81. @warehouse_code.setter
  82. def warehouse_code(self, value):
  83. self._warehouse_code = value
  84. def to_alipay_dict(self):
  85. params = dict()
  86. if self.ext_info:
  87. if hasattr(self.ext_info, 'to_alipay_dict'):
  88. params['ext_info'] = self.ext_info.to_alipay_dict()
  89. else:
  90. params['ext_info'] = self.ext_info
  91. if self.gmt_create:
  92. if hasattr(self.gmt_create, 'to_alipay_dict'):
  93. params['gmt_create'] = self.gmt_create.to_alipay_dict()
  94. else:
  95. params['gmt_create'] = self.gmt_create
  96. if self.gmt_modified:
  97. if hasattr(self.gmt_modified, 'to_alipay_dict'):
  98. params['gmt_modified'] = self.gmt_modified.to_alipay_dict()
  99. else:
  100. params['gmt_modified'] = self.gmt_modified
  101. if self.inbound_order_id:
  102. if hasattr(self.inbound_order_id, 'to_alipay_dict'):
  103. params['inbound_order_id'] = self.inbound_order_id.to_alipay_dict()
  104. else:
  105. params['inbound_order_id'] = self.inbound_order_id
  106. if self.inbound_type:
  107. if hasattr(self.inbound_type, 'to_alipay_dict'):
  108. params['inbound_type'] = self.inbound_type.to_alipay_dict()
  109. else:
  110. params['inbound_type'] = self.inbound_type
  111. if self.notice_date:
  112. if hasattr(self.notice_date, 'to_alipay_dict'):
  113. params['notice_date'] = self.notice_date.to_alipay_dict()
  114. else:
  115. params['notice_date'] = self.notice_date
  116. if self.operator_id:
  117. if hasattr(self.operator_id, 'to_alipay_dict'):
  118. params['operator_id'] = self.operator_id.to_alipay_dict()
  119. else:
  120. params['operator_id'] = self.operator_id
  121. if self.operator_type:
  122. if hasattr(self.operator_type, 'to_alipay_dict'):
  123. params['operator_type'] = self.operator_type.to_alipay_dict()
  124. else:
  125. params['operator_type'] = self.operator_type
  126. if self.out_biz_no:
  127. if hasattr(self.out_biz_no, 'to_alipay_dict'):
  128. params['out_biz_no'] = self.out_biz_no.to_alipay_dict()
  129. else:
  130. params['out_biz_no'] = self.out_biz_no
  131. if self.status:
  132. if hasattr(self.status, 'to_alipay_dict'):
  133. params['status'] = self.status.to_alipay_dict()
  134. else:
  135. params['status'] = self.status
  136. if self.warehouse_code:
  137. if hasattr(self.warehouse_code, 'to_alipay_dict'):
  138. params['warehouse_code'] = self.warehouse_code.to_alipay_dict()
  139. else:
  140. params['warehouse_code'] = self.warehouse_code
  141. return params
  142. @staticmethod
  143. def from_alipay_dict(d):
  144. if not d:
  145. return None
  146. o = InboundOrderVO()
  147. if 'ext_info' in d:
  148. o.ext_info = d['ext_info']
  149. if 'gmt_create' in d:
  150. o.gmt_create = d['gmt_create']
  151. if 'gmt_modified' in d:
  152. o.gmt_modified = d['gmt_modified']
  153. if 'inbound_order_id' in d:
  154. o.inbound_order_id = d['inbound_order_id']
  155. if 'inbound_type' in d:
  156. o.inbound_type = d['inbound_type']
  157. if 'notice_date' in d:
  158. o.notice_date = d['notice_date']
  159. if 'operator_id' in d:
  160. o.operator_id = d['operator_id']
  161. if 'operator_type' in d:
  162. o.operator_type = d['operator_type']
  163. if 'out_biz_no' in d:
  164. o.out_biz_no = d['out_biz_no']
  165. if 'status' in d:
  166. o.status = d['status']
  167. if 'warehouse_code' in d:
  168. o.warehouse_code = d['warehouse_code']
  169. return o