AlipayEbppInvoiceTitleDetailQueryModel.py 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. import json
  4. from alipay.aop.api.constant.ParamConstants import *
  5. class AlipayEbppInvoiceTitleDetailQueryModel(object):
  6. def __init__(self):
  7. self._enterprise_name = None
  8. self._m_short_name = None
  9. self._sub_m_short_name = None
  10. @property
  11. def enterprise_name(self):
  12. return self._enterprise_name
  13. @enterprise_name.setter
  14. def enterprise_name(self, value):
  15. self._enterprise_name = value
  16. @property
  17. def m_short_name(self):
  18. return self._m_short_name
  19. @m_short_name.setter
  20. def m_short_name(self, value):
  21. self._m_short_name = value
  22. @property
  23. def sub_m_short_name(self):
  24. return self._sub_m_short_name
  25. @sub_m_short_name.setter
  26. def sub_m_short_name(self, value):
  27. self._sub_m_short_name = value
  28. def to_alipay_dict(self):
  29. params = dict()
  30. if self.enterprise_name:
  31. if hasattr(self.enterprise_name, 'to_alipay_dict'):
  32. params['enterprise_name'] = self.enterprise_name.to_alipay_dict()
  33. else:
  34. params['enterprise_name'] = self.enterprise_name
  35. if self.m_short_name:
  36. if hasattr(self.m_short_name, 'to_alipay_dict'):
  37. params['m_short_name'] = self.m_short_name.to_alipay_dict()
  38. else:
  39. params['m_short_name'] = self.m_short_name
  40. if self.sub_m_short_name:
  41. if hasattr(self.sub_m_short_name, 'to_alipay_dict'):
  42. params['sub_m_short_name'] = self.sub_m_short_name.to_alipay_dict()
  43. else:
  44. params['sub_m_short_name'] = self.sub_m_short_name
  45. return params
  46. @staticmethod
  47. def from_alipay_dict(d):
  48. if not d:
  49. return None
  50. o = AlipayEbppInvoiceTitleDetailQueryModel()
  51. if 'enterprise_name' in d:
  52. o.enterprise_name = d['enterprise_name']
  53. if 'm_short_name' in d:
  54. o.m_short_name = d['m_short_name']
  55. if 'sub_m_short_name' in d:
  56. o.sub_m_short_name = d['sub_m_short_name']
  57. return o