ZhimaCustomerAuthMutualviewApplyModel.py 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. import json
  4. from alipay.aop.api.constant.ParamConstants import *
  5. class ZhimaCustomerAuthMutualviewApplyModel(object):
  6. def __init__(self):
  7. self._biz_type = None
  8. self._callback_url = None
  9. self._ext_biz_param = None
  10. self._identity_param = None
  11. self._product_param = None
  12. @property
  13. def biz_type(self):
  14. return self._biz_type
  15. @biz_type.setter
  16. def biz_type(self, value):
  17. self._biz_type = value
  18. @property
  19. def callback_url(self):
  20. return self._callback_url
  21. @callback_url.setter
  22. def callback_url(self, value):
  23. self._callback_url = value
  24. @property
  25. def ext_biz_param(self):
  26. return self._ext_biz_param
  27. @ext_biz_param.setter
  28. def ext_biz_param(self, value):
  29. self._ext_biz_param = value
  30. @property
  31. def identity_param(self):
  32. return self._identity_param
  33. @identity_param.setter
  34. def identity_param(self, value):
  35. self._identity_param = value
  36. @property
  37. def product_param(self):
  38. return self._product_param
  39. @product_param.setter
  40. def product_param(self, value):
  41. self._product_param = value
  42. def to_alipay_dict(self):
  43. params = dict()
  44. if self.biz_type:
  45. if hasattr(self.biz_type, 'to_alipay_dict'):
  46. params['biz_type'] = self.biz_type.to_alipay_dict()
  47. else:
  48. params['biz_type'] = self.biz_type
  49. if self.callback_url:
  50. if hasattr(self.callback_url, 'to_alipay_dict'):
  51. params['callback_url'] = self.callback_url.to_alipay_dict()
  52. else:
  53. params['callback_url'] = self.callback_url
  54. if self.ext_biz_param:
  55. if hasattr(self.ext_biz_param, 'to_alipay_dict'):
  56. params['ext_biz_param'] = self.ext_biz_param.to_alipay_dict()
  57. else:
  58. params['ext_biz_param'] = self.ext_biz_param
  59. if self.identity_param:
  60. if hasattr(self.identity_param, 'to_alipay_dict'):
  61. params['identity_param'] = self.identity_param.to_alipay_dict()
  62. else:
  63. params['identity_param'] = self.identity_param
  64. if self.product_param:
  65. if hasattr(self.product_param, 'to_alipay_dict'):
  66. params['product_param'] = self.product_param.to_alipay_dict()
  67. else:
  68. params['product_param'] = self.product_param
  69. return params
  70. @staticmethod
  71. def from_alipay_dict(d):
  72. if not d:
  73. return None
  74. o = ZhimaCustomerAuthMutualviewApplyModel()
  75. if 'biz_type' in d:
  76. o.biz_type = d['biz_type']
  77. if 'callback_url' in d:
  78. o.callback_url = d['callback_url']
  79. if 'ext_biz_param' in d:
  80. o.ext_biz_param = d['ext_biz_param']
  81. if 'identity_param' in d:
  82. o.identity_param = d['identity_param']
  83. if 'product_param' in d:
  84. o.product_param = d['product_param']
  85. return o