AlipayCommerceMedicalInformationUploadModel.py 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. import json
  4. from alipay.aop.api.constant.ParamConstants import *
  5. class AlipayCommerceMedicalInformationUploadModel(object):
  6. def __init__(self):
  7. self._auth_code = None
  8. self._auth_type = None
  9. self._body = None
  10. self._buyer_id = None
  11. self._extend_params = None
  12. self._gmt_out_create = None
  13. self._industry = None
  14. self._is_insurance = None
  15. self._medical_card_id = None
  16. self._medical_card_inst_id = None
  17. self._org_name = None
  18. self._org_no = None
  19. self._out_trade_no = None
  20. self._patient_card_no = None
  21. self._patient_card_type = None
  22. self._patient_mobile = None
  23. self._patient_name = None
  24. self._request_content = None
  25. self._scene = None
  26. self._seller_id = None
  27. self._serial_no = None
  28. self._subject = None
  29. self._total_amount = None
  30. @property
  31. def auth_code(self):
  32. return self._auth_code
  33. @auth_code.setter
  34. def auth_code(self, value):
  35. self._auth_code = value
  36. @property
  37. def auth_type(self):
  38. return self._auth_type
  39. @auth_type.setter
  40. def auth_type(self, value):
  41. self._auth_type = value
  42. @property
  43. def body(self):
  44. return self._body
  45. @body.setter
  46. def body(self, value):
  47. self._body = value
  48. @property
  49. def buyer_id(self):
  50. return self._buyer_id
  51. @buyer_id.setter
  52. def buyer_id(self, value):
  53. self._buyer_id = value
  54. @property
  55. def extend_params(self):
  56. return self._extend_params
  57. @extend_params.setter
  58. def extend_params(self, value):
  59. self._extend_params = value
  60. @property
  61. def gmt_out_create(self):
  62. return self._gmt_out_create
  63. @gmt_out_create.setter
  64. def gmt_out_create(self, value):
  65. self._gmt_out_create = value
  66. @property
  67. def industry(self):
  68. return self._industry
  69. @industry.setter
  70. def industry(self, value):
  71. self._industry = value
  72. @property
  73. def is_insurance(self):
  74. return self._is_insurance
  75. @is_insurance.setter
  76. def is_insurance(self, value):
  77. self._is_insurance = value
  78. @property
  79. def medical_card_id(self):
  80. return self._medical_card_id
  81. @medical_card_id.setter
  82. def medical_card_id(self, value):
  83. self._medical_card_id = value
  84. @property
  85. def medical_card_inst_id(self):
  86. return self._medical_card_inst_id
  87. @medical_card_inst_id.setter
  88. def medical_card_inst_id(self, value):
  89. self._medical_card_inst_id = value
  90. @property
  91. def org_name(self):
  92. return self._org_name
  93. @org_name.setter
  94. def org_name(self, value):
  95. self._org_name = value
  96. @property
  97. def org_no(self):
  98. return self._org_no
  99. @org_no.setter
  100. def org_no(self, value):
  101. self._org_no = value
  102. @property
  103. def out_trade_no(self):
  104. return self._out_trade_no
  105. @out_trade_no.setter
  106. def out_trade_no(self, value):
  107. self._out_trade_no = value
  108. @property
  109. def patient_card_no(self):
  110. return self._patient_card_no
  111. @patient_card_no.setter
  112. def patient_card_no(self, value):
  113. self._patient_card_no = value
  114. @property
  115. def patient_card_type(self):
  116. return self._patient_card_type
  117. @patient_card_type.setter
  118. def patient_card_type(self, value):
  119. self._patient_card_type = value
  120. @property
  121. def patient_mobile(self):
  122. return self._patient_mobile
  123. @patient_mobile.setter
  124. def patient_mobile(self, value):
  125. self._patient_mobile = value
  126. @property
  127. def patient_name(self):
  128. return self._patient_name
  129. @patient_name.setter
  130. def patient_name(self, value):
  131. self._patient_name = value
  132. @property
  133. def request_content(self):
  134. return self._request_content
  135. @request_content.setter
  136. def request_content(self, value):
  137. self._request_content = value
  138. @property
  139. def scene(self):
  140. return self._scene
  141. @scene.setter
  142. def scene(self, value):
  143. self._scene = value
  144. @property
  145. def seller_id(self):
  146. return self._seller_id
  147. @seller_id.setter
  148. def seller_id(self, value):
  149. self._seller_id = value
  150. @property
  151. def serial_no(self):
  152. return self._serial_no
  153. @serial_no.setter
  154. def serial_no(self, value):
  155. self._serial_no = value
  156. @property
  157. def subject(self):
  158. return self._subject
  159. @subject.setter
  160. def subject(self, value):
  161. self._subject = value
  162. @property
  163. def total_amount(self):
  164. return self._total_amount
  165. @total_amount.setter
  166. def total_amount(self, value):
  167. self._total_amount = value
  168. def to_alipay_dict(self):
  169. params = dict()
  170. if self.auth_code:
  171. if hasattr(self.auth_code, 'to_alipay_dict'):
  172. params['auth_code'] = self.auth_code.to_alipay_dict()
  173. else:
  174. params['auth_code'] = self.auth_code
  175. if self.auth_type:
  176. if hasattr(self.auth_type, 'to_alipay_dict'):
  177. params['auth_type'] = self.auth_type.to_alipay_dict()
  178. else:
  179. params['auth_type'] = self.auth_type
  180. if self.body:
  181. if hasattr(self.body, 'to_alipay_dict'):
  182. params['body'] = self.body.to_alipay_dict()
  183. else:
  184. params['body'] = self.body
  185. if self.buyer_id:
  186. if hasattr(self.buyer_id, 'to_alipay_dict'):
  187. params['buyer_id'] = self.buyer_id.to_alipay_dict()
  188. else:
  189. params['buyer_id'] = self.buyer_id
  190. if self.extend_params:
  191. if hasattr(self.extend_params, 'to_alipay_dict'):
  192. params['extend_params'] = self.extend_params.to_alipay_dict()
  193. else:
  194. params['extend_params'] = self.extend_params
  195. if self.gmt_out_create:
  196. if hasattr(self.gmt_out_create, 'to_alipay_dict'):
  197. params['gmt_out_create'] = self.gmt_out_create.to_alipay_dict()
  198. else:
  199. params['gmt_out_create'] = self.gmt_out_create
  200. if self.industry:
  201. if hasattr(self.industry, 'to_alipay_dict'):
  202. params['industry'] = self.industry.to_alipay_dict()
  203. else:
  204. params['industry'] = self.industry
  205. if self.is_insurance:
  206. if hasattr(self.is_insurance, 'to_alipay_dict'):
  207. params['is_insurance'] = self.is_insurance.to_alipay_dict()
  208. else:
  209. params['is_insurance'] = self.is_insurance
  210. if self.medical_card_id:
  211. if hasattr(self.medical_card_id, 'to_alipay_dict'):
  212. params['medical_card_id'] = self.medical_card_id.to_alipay_dict()
  213. else:
  214. params['medical_card_id'] = self.medical_card_id
  215. if self.medical_card_inst_id:
  216. if hasattr(self.medical_card_inst_id, 'to_alipay_dict'):
  217. params['medical_card_inst_id'] = self.medical_card_inst_id.to_alipay_dict()
  218. else:
  219. params['medical_card_inst_id'] = self.medical_card_inst_id
  220. if self.org_name:
  221. if hasattr(self.org_name, 'to_alipay_dict'):
  222. params['org_name'] = self.org_name.to_alipay_dict()
  223. else:
  224. params['org_name'] = self.org_name
  225. if self.org_no:
  226. if hasattr(self.org_no, 'to_alipay_dict'):
  227. params['org_no'] = self.org_no.to_alipay_dict()
  228. else:
  229. params['org_no'] = self.org_no
  230. if self.out_trade_no:
  231. if hasattr(self.out_trade_no, 'to_alipay_dict'):
  232. params['out_trade_no'] = self.out_trade_no.to_alipay_dict()
  233. else:
  234. params['out_trade_no'] = self.out_trade_no
  235. if self.patient_card_no:
  236. if hasattr(self.patient_card_no, 'to_alipay_dict'):
  237. params['patient_card_no'] = self.patient_card_no.to_alipay_dict()
  238. else:
  239. params['patient_card_no'] = self.patient_card_no
  240. if self.patient_card_type:
  241. if hasattr(self.patient_card_type, 'to_alipay_dict'):
  242. params['patient_card_type'] = self.patient_card_type.to_alipay_dict()
  243. else:
  244. params['patient_card_type'] = self.patient_card_type
  245. if self.patient_mobile:
  246. if hasattr(self.patient_mobile, 'to_alipay_dict'):
  247. params['patient_mobile'] = self.patient_mobile.to_alipay_dict()
  248. else:
  249. params['patient_mobile'] = self.patient_mobile
  250. if self.patient_name:
  251. if hasattr(self.patient_name, 'to_alipay_dict'):
  252. params['patient_name'] = self.patient_name.to_alipay_dict()
  253. else:
  254. params['patient_name'] = self.patient_name
  255. if self.request_content:
  256. if hasattr(self.request_content, 'to_alipay_dict'):
  257. params['request_content'] = self.request_content.to_alipay_dict()
  258. else:
  259. params['request_content'] = self.request_content
  260. if self.scene:
  261. if hasattr(self.scene, 'to_alipay_dict'):
  262. params['scene'] = self.scene.to_alipay_dict()
  263. else:
  264. params['scene'] = self.scene
  265. if self.seller_id:
  266. if hasattr(self.seller_id, 'to_alipay_dict'):
  267. params['seller_id'] = self.seller_id.to_alipay_dict()
  268. else:
  269. params['seller_id'] = self.seller_id
  270. if self.serial_no:
  271. if hasattr(self.serial_no, 'to_alipay_dict'):
  272. params['serial_no'] = self.serial_no.to_alipay_dict()
  273. else:
  274. params['serial_no'] = self.serial_no
  275. if self.subject:
  276. if hasattr(self.subject, 'to_alipay_dict'):
  277. params['subject'] = self.subject.to_alipay_dict()
  278. else:
  279. params['subject'] = self.subject
  280. if self.total_amount:
  281. if hasattr(self.total_amount, 'to_alipay_dict'):
  282. params['total_amount'] = self.total_amount.to_alipay_dict()
  283. else:
  284. params['total_amount'] = self.total_amount
  285. return params
  286. @staticmethod
  287. def from_alipay_dict(d):
  288. if not d:
  289. return None
  290. o = AlipayCommerceMedicalInformationUploadModel()
  291. if 'auth_code' in d:
  292. o.auth_code = d['auth_code']
  293. if 'auth_type' in d:
  294. o.auth_type = d['auth_type']
  295. if 'body' in d:
  296. o.body = d['body']
  297. if 'buyer_id' in d:
  298. o.buyer_id = d['buyer_id']
  299. if 'extend_params' in d:
  300. o.extend_params = d['extend_params']
  301. if 'gmt_out_create' in d:
  302. o.gmt_out_create = d['gmt_out_create']
  303. if 'industry' in d:
  304. o.industry = d['industry']
  305. if 'is_insurance' in d:
  306. o.is_insurance = d['is_insurance']
  307. if 'medical_card_id' in d:
  308. o.medical_card_id = d['medical_card_id']
  309. if 'medical_card_inst_id' in d:
  310. o.medical_card_inst_id = d['medical_card_inst_id']
  311. if 'org_name' in d:
  312. o.org_name = d['org_name']
  313. if 'org_no' in d:
  314. o.org_no = d['org_no']
  315. if 'out_trade_no' in d:
  316. o.out_trade_no = d['out_trade_no']
  317. if 'patient_card_no' in d:
  318. o.patient_card_no = d['patient_card_no']
  319. if 'patient_card_type' in d:
  320. o.patient_card_type = d['patient_card_type']
  321. if 'patient_mobile' in d:
  322. o.patient_mobile = d['patient_mobile']
  323. if 'patient_name' in d:
  324. o.patient_name = d['patient_name']
  325. if 'request_content' in d:
  326. o.request_content = d['request_content']
  327. if 'scene' in d:
  328. o.scene = d['scene']
  329. if 'seller_id' in d:
  330. o.seller_id = d['seller_id']
  331. if 'serial_no' in d:
  332. o.serial_no = d['serial_no']
  333. if 'subject' in d:
  334. o.subject = d['subject']
  335. if 'total_amount' in d:
  336. o.total_amount = d['total_amount']
  337. return o