KoubeiRetailWmsOutboundorderQueryResponse.py 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. import json
  4. from alipay.aop.api.response.AlipayResponse import AlipayResponse
  5. from alipay.aop.api.domain.OutboundOrderLine import OutboundOrderLine
  6. from alipay.aop.api.domain.OutboundOrderVO import OutboundOrderVO
  7. class KoubeiRetailWmsOutboundorderQueryResponse(AlipayResponse):
  8. def __init__(self):
  9. super(KoubeiRetailWmsOutboundorderQueryResponse, self).__init__()
  10. self._outbound_order_line_list = None
  11. self._outbound_order_vo = None
  12. @property
  13. def outbound_order_line_list(self):
  14. return self._outbound_order_line_list
  15. @outbound_order_line_list.setter
  16. def outbound_order_line_list(self, value):
  17. if isinstance(value, list):
  18. self._outbound_order_line_list = list()
  19. for i in value:
  20. if isinstance(i, OutboundOrderLine):
  21. self._outbound_order_line_list.append(i)
  22. else:
  23. self._outbound_order_line_list.append(OutboundOrderLine.from_alipay_dict(i))
  24. @property
  25. def outbound_order_vo(self):
  26. return self._outbound_order_vo
  27. @outbound_order_vo.setter
  28. def outbound_order_vo(self, value):
  29. if isinstance(value, OutboundOrderVO):
  30. self._outbound_order_vo = value
  31. else:
  32. self._outbound_order_vo = OutboundOrderVO.from_alipay_dict(value)
  33. def parse_response_content(self, response_content):
  34. response = super(KoubeiRetailWmsOutboundorderQueryResponse, self).parse_response_content(response_content)
  35. if 'outbound_order_line_list' in response:
  36. self.outbound_order_line_list = response['outbound_order_line_list']
  37. if 'outbound_order_vo' in response:
  38. self.outbound_order_vo = response['outbound_order_vo']