AlipayEcoCplifeBillSyncModel.py 3.1 KB

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