AlipayInsAutoAutoinsprodQuoteApplyResponse.py 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  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.QuoteInfo import QuoteInfo
  6. class AlipayInsAutoAutoinsprodQuoteApplyResponse(AlipayResponse):
  7. def __init__(self):
  8. super(AlipayInsAutoAutoinsprodQuoteApplyResponse, self).__init__()
  9. self._enquiry_biz_id = None
  10. self._quote_infos = None
  11. @property
  12. def enquiry_biz_id(self):
  13. return self._enquiry_biz_id
  14. @enquiry_biz_id.setter
  15. def enquiry_biz_id(self, value):
  16. self._enquiry_biz_id = value
  17. @property
  18. def quote_infos(self):
  19. return self._quote_infos
  20. @quote_infos.setter
  21. def quote_infos(self, value):
  22. if isinstance(value, list):
  23. self._quote_infos = list()
  24. for i in value:
  25. if isinstance(i, QuoteInfo):
  26. self._quote_infos.append(i)
  27. else:
  28. self._quote_infos.append(QuoteInfo.from_alipay_dict(i))
  29. def parse_response_content(self, response_content):
  30. response = super(AlipayInsAutoAutoinsprodQuoteApplyResponse, self).parse_response_content(response_content)
  31. if 'enquiry_biz_id' in response:
  32. self.enquiry_biz_id = response['enquiry_biz_id']
  33. if 'quote_infos' in response:
  34. self.quote_infos = response['quote_infos']