AlipayEcoMycarMaintainShopModifyModel.py 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. import json
  4. from alipay.aop.api.constant.ParamConstants import *
  5. class AlipayEcoMycarMaintainShopModifyModel(object):
  6. def __init__(self):
  7. self._address = None
  8. self._alipay_account = None
  9. self._brand_ids = None
  10. self._city_code = None
  11. self._close_time = None
  12. self._contact_email = None
  13. self._contact_mobile_phone = None
  14. self._contact_name = None
  15. self._district_code = None
  16. self._ext_param = None
  17. self._industry_app_category_id = None
  18. self._industry_category_id = None
  19. self._lat = None
  20. self._lon = None
  21. self._main_image = None
  22. self._merchant_branch_id = None
  23. self._open_time = None
  24. self._other_images = None
  25. self._out_shop_id = None
  26. self._province_code = None
  27. self._shop_branch_name = None
  28. self._shop_id = None
  29. self._shop_name = None
  30. self._shop_tel = None
  31. self._shop_type = None
  32. self._status = None
  33. @property
  34. def address(self):
  35. return self._address
  36. @address.setter
  37. def address(self, value):
  38. self._address = value
  39. @property
  40. def alipay_account(self):
  41. return self._alipay_account
  42. @alipay_account.setter
  43. def alipay_account(self, value):
  44. self._alipay_account = value
  45. @property
  46. def brand_ids(self):
  47. return self._brand_ids
  48. @brand_ids.setter
  49. def brand_ids(self, value):
  50. if isinstance(value, list):
  51. self._brand_ids = list()
  52. for i in value:
  53. self._brand_ids.append(i)
  54. @property
  55. def city_code(self):
  56. return self._city_code
  57. @city_code.setter
  58. def city_code(self, value):
  59. self._city_code = value
  60. @property
  61. def close_time(self):
  62. return self._close_time
  63. @close_time.setter
  64. def close_time(self, value):
  65. self._close_time = value
  66. @property
  67. def contact_email(self):
  68. return self._contact_email
  69. @contact_email.setter
  70. def contact_email(self, value):
  71. self._contact_email = value
  72. @property
  73. def contact_mobile_phone(self):
  74. return self._contact_mobile_phone
  75. @contact_mobile_phone.setter
  76. def contact_mobile_phone(self, value):
  77. self._contact_mobile_phone = value
  78. @property
  79. def contact_name(self):
  80. return self._contact_name
  81. @contact_name.setter
  82. def contact_name(self, value):
  83. self._contact_name = value
  84. @property
  85. def district_code(self):
  86. return self._district_code
  87. @district_code.setter
  88. def district_code(self, value):
  89. self._district_code = value
  90. @property
  91. def ext_param(self):
  92. return self._ext_param
  93. @ext_param.setter
  94. def ext_param(self, value):
  95. self._ext_param = value
  96. @property
  97. def industry_app_category_id(self):
  98. return self._industry_app_category_id
  99. @industry_app_category_id.setter
  100. def industry_app_category_id(self, value):
  101. if isinstance(value, list):
  102. self._industry_app_category_id = list()
  103. for i in value:
  104. self._industry_app_category_id.append(i)
  105. @property
  106. def industry_category_id(self):
  107. return self._industry_category_id
  108. @industry_category_id.setter
  109. def industry_category_id(self, value):
  110. if isinstance(value, list):
  111. self._industry_category_id = list()
  112. for i in value:
  113. self._industry_category_id.append(i)
  114. @property
  115. def lat(self):
  116. return self._lat
  117. @lat.setter
  118. def lat(self, value):
  119. self._lat = value
  120. @property
  121. def lon(self):
  122. return self._lon
  123. @lon.setter
  124. def lon(self, value):
  125. self._lon = value
  126. @property
  127. def main_image(self):
  128. return self._main_image
  129. @main_image.setter
  130. def main_image(self, value):
  131. self._main_image = value
  132. @property
  133. def merchant_branch_id(self):
  134. return self._merchant_branch_id
  135. @merchant_branch_id.setter
  136. def merchant_branch_id(self, value):
  137. self._merchant_branch_id = value
  138. @property
  139. def open_time(self):
  140. return self._open_time
  141. @open_time.setter
  142. def open_time(self, value):
  143. self._open_time = value
  144. @property
  145. def other_images(self):
  146. return self._other_images
  147. @other_images.setter
  148. def other_images(self, value):
  149. if isinstance(value, list):
  150. self._other_images = list()
  151. for i in value:
  152. self._other_images.append(i)
  153. @property
  154. def out_shop_id(self):
  155. return self._out_shop_id
  156. @out_shop_id.setter
  157. def out_shop_id(self, value):
  158. self._out_shop_id = value
  159. @property
  160. def province_code(self):
  161. return self._province_code
  162. @province_code.setter
  163. def province_code(self, value):
  164. self._province_code = value
  165. @property
  166. def shop_branch_name(self):
  167. return self._shop_branch_name
  168. @shop_branch_name.setter
  169. def shop_branch_name(self, value):
  170. self._shop_branch_name = value
  171. @property
  172. def shop_id(self):
  173. return self._shop_id
  174. @shop_id.setter
  175. def shop_id(self, value):
  176. self._shop_id = value
  177. @property
  178. def shop_name(self):
  179. return self._shop_name
  180. @shop_name.setter
  181. def shop_name(self, value):
  182. self._shop_name = value
  183. @property
  184. def shop_tel(self):
  185. return self._shop_tel
  186. @shop_tel.setter
  187. def shop_tel(self, value):
  188. self._shop_tel = value
  189. @property
  190. def shop_type(self):
  191. return self._shop_type
  192. @shop_type.setter
  193. def shop_type(self, value):
  194. self._shop_type = value
  195. @property
  196. def status(self):
  197. return self._status
  198. @status.setter
  199. def status(self, value):
  200. self._status = value
  201. def to_alipay_dict(self):
  202. params = dict()
  203. if self.address:
  204. if hasattr(self.address, 'to_alipay_dict'):
  205. params['address'] = self.address.to_alipay_dict()
  206. else:
  207. params['address'] = self.address
  208. if self.alipay_account:
  209. if hasattr(self.alipay_account, 'to_alipay_dict'):
  210. params['alipay_account'] = self.alipay_account.to_alipay_dict()
  211. else:
  212. params['alipay_account'] = self.alipay_account
  213. if self.brand_ids:
  214. if isinstance(self.brand_ids, list):
  215. for i in range(0, len(self.brand_ids)):
  216. element = self.brand_ids[i]
  217. if hasattr(element, 'to_alipay_dict'):
  218. self.brand_ids[i] = element.to_alipay_dict()
  219. if hasattr(self.brand_ids, 'to_alipay_dict'):
  220. params['brand_ids'] = self.brand_ids.to_alipay_dict()
  221. else:
  222. params['brand_ids'] = self.brand_ids
  223. if self.city_code:
  224. if hasattr(self.city_code, 'to_alipay_dict'):
  225. params['city_code'] = self.city_code.to_alipay_dict()
  226. else:
  227. params['city_code'] = self.city_code
  228. if self.close_time:
  229. if hasattr(self.close_time, 'to_alipay_dict'):
  230. params['close_time'] = self.close_time.to_alipay_dict()
  231. else:
  232. params['close_time'] = self.close_time
  233. if self.contact_email:
  234. if hasattr(self.contact_email, 'to_alipay_dict'):
  235. params['contact_email'] = self.contact_email.to_alipay_dict()
  236. else:
  237. params['contact_email'] = self.contact_email
  238. if self.contact_mobile_phone:
  239. if hasattr(self.contact_mobile_phone, 'to_alipay_dict'):
  240. params['contact_mobile_phone'] = self.contact_mobile_phone.to_alipay_dict()
  241. else:
  242. params['contact_mobile_phone'] = self.contact_mobile_phone
  243. if self.contact_name:
  244. if hasattr(self.contact_name, 'to_alipay_dict'):
  245. params['contact_name'] = self.contact_name.to_alipay_dict()
  246. else:
  247. params['contact_name'] = self.contact_name
  248. if self.district_code:
  249. if hasattr(self.district_code, 'to_alipay_dict'):
  250. params['district_code'] = self.district_code.to_alipay_dict()
  251. else:
  252. params['district_code'] = self.district_code
  253. if self.ext_param:
  254. if hasattr(self.ext_param, 'to_alipay_dict'):
  255. params['ext_param'] = self.ext_param.to_alipay_dict()
  256. else:
  257. params['ext_param'] = self.ext_param
  258. if self.industry_app_category_id:
  259. if isinstance(self.industry_app_category_id, list):
  260. for i in range(0, len(self.industry_app_category_id)):
  261. element = self.industry_app_category_id[i]
  262. if hasattr(element, 'to_alipay_dict'):
  263. self.industry_app_category_id[i] = element.to_alipay_dict()
  264. if hasattr(self.industry_app_category_id, 'to_alipay_dict'):
  265. params['industry_app_category_id'] = self.industry_app_category_id.to_alipay_dict()
  266. else:
  267. params['industry_app_category_id'] = self.industry_app_category_id
  268. if self.industry_category_id:
  269. if isinstance(self.industry_category_id, list):
  270. for i in range(0, len(self.industry_category_id)):
  271. element = self.industry_category_id[i]
  272. if hasattr(element, 'to_alipay_dict'):
  273. self.industry_category_id[i] = element.to_alipay_dict()
  274. if hasattr(self.industry_category_id, 'to_alipay_dict'):
  275. params['industry_category_id'] = self.industry_category_id.to_alipay_dict()
  276. else:
  277. params['industry_category_id'] = self.industry_category_id
  278. if self.lat:
  279. if hasattr(self.lat, 'to_alipay_dict'):
  280. params['lat'] = self.lat.to_alipay_dict()
  281. else:
  282. params['lat'] = self.lat
  283. if self.lon:
  284. if hasattr(self.lon, 'to_alipay_dict'):
  285. params['lon'] = self.lon.to_alipay_dict()
  286. else:
  287. params['lon'] = self.lon
  288. if self.main_image:
  289. if hasattr(self.main_image, 'to_alipay_dict'):
  290. params['main_image'] = self.main_image.to_alipay_dict()
  291. else:
  292. params['main_image'] = self.main_image
  293. if self.merchant_branch_id:
  294. if hasattr(self.merchant_branch_id, 'to_alipay_dict'):
  295. params['merchant_branch_id'] = self.merchant_branch_id.to_alipay_dict()
  296. else:
  297. params['merchant_branch_id'] = self.merchant_branch_id
  298. if self.open_time:
  299. if hasattr(self.open_time, 'to_alipay_dict'):
  300. params['open_time'] = self.open_time.to_alipay_dict()
  301. else:
  302. params['open_time'] = self.open_time
  303. if self.other_images:
  304. if isinstance(self.other_images, list):
  305. for i in range(0, len(self.other_images)):
  306. element = self.other_images[i]
  307. if hasattr(element, 'to_alipay_dict'):
  308. self.other_images[i] = element.to_alipay_dict()
  309. if hasattr(self.other_images, 'to_alipay_dict'):
  310. params['other_images'] = self.other_images.to_alipay_dict()
  311. else:
  312. params['other_images'] = self.other_images
  313. if self.out_shop_id:
  314. if hasattr(self.out_shop_id, 'to_alipay_dict'):
  315. params['out_shop_id'] = self.out_shop_id.to_alipay_dict()
  316. else:
  317. params['out_shop_id'] = self.out_shop_id
  318. if self.province_code:
  319. if hasattr(self.province_code, 'to_alipay_dict'):
  320. params['province_code'] = self.province_code.to_alipay_dict()
  321. else:
  322. params['province_code'] = self.province_code
  323. if self.shop_branch_name:
  324. if hasattr(self.shop_branch_name, 'to_alipay_dict'):
  325. params['shop_branch_name'] = self.shop_branch_name.to_alipay_dict()
  326. else:
  327. params['shop_branch_name'] = self.shop_branch_name
  328. if self.shop_id:
  329. if hasattr(self.shop_id, 'to_alipay_dict'):
  330. params['shop_id'] = self.shop_id.to_alipay_dict()
  331. else:
  332. params['shop_id'] = self.shop_id
  333. if self.shop_name:
  334. if hasattr(self.shop_name, 'to_alipay_dict'):
  335. params['shop_name'] = self.shop_name.to_alipay_dict()
  336. else:
  337. params['shop_name'] = self.shop_name
  338. if self.shop_tel:
  339. if hasattr(self.shop_tel, 'to_alipay_dict'):
  340. params['shop_tel'] = self.shop_tel.to_alipay_dict()
  341. else:
  342. params['shop_tel'] = self.shop_tel
  343. if self.shop_type:
  344. if hasattr(self.shop_type, 'to_alipay_dict'):
  345. params['shop_type'] = self.shop_type.to_alipay_dict()
  346. else:
  347. params['shop_type'] = self.shop_type
  348. if self.status:
  349. if hasattr(self.status, 'to_alipay_dict'):
  350. params['status'] = self.status.to_alipay_dict()
  351. else:
  352. params['status'] = self.status
  353. return params
  354. @staticmethod
  355. def from_alipay_dict(d):
  356. if not d:
  357. return None
  358. o = AlipayEcoMycarMaintainShopModifyModel()
  359. if 'address' in d:
  360. o.address = d['address']
  361. if 'alipay_account' in d:
  362. o.alipay_account = d['alipay_account']
  363. if 'brand_ids' in d:
  364. o.brand_ids = d['brand_ids']
  365. if 'city_code' in d:
  366. o.city_code = d['city_code']
  367. if 'close_time' in d:
  368. o.close_time = d['close_time']
  369. if 'contact_email' in d:
  370. o.contact_email = d['contact_email']
  371. if 'contact_mobile_phone' in d:
  372. o.contact_mobile_phone = d['contact_mobile_phone']
  373. if 'contact_name' in d:
  374. o.contact_name = d['contact_name']
  375. if 'district_code' in d:
  376. o.district_code = d['district_code']
  377. if 'ext_param' in d:
  378. o.ext_param = d['ext_param']
  379. if 'industry_app_category_id' in d:
  380. o.industry_app_category_id = d['industry_app_category_id']
  381. if 'industry_category_id' in d:
  382. o.industry_category_id = d['industry_category_id']
  383. if 'lat' in d:
  384. o.lat = d['lat']
  385. if 'lon' in d:
  386. o.lon = d['lon']
  387. if 'main_image' in d:
  388. o.main_image = d['main_image']
  389. if 'merchant_branch_id' in d:
  390. o.merchant_branch_id = d['merchant_branch_id']
  391. if 'open_time' in d:
  392. o.open_time = d['open_time']
  393. if 'other_images' in d:
  394. o.other_images = d['other_images']
  395. if 'out_shop_id' in d:
  396. o.out_shop_id = d['out_shop_id']
  397. if 'province_code' in d:
  398. o.province_code = d['province_code']
  399. if 'shop_branch_name' in d:
  400. o.shop_branch_name = d['shop_branch_name']
  401. if 'shop_id' in d:
  402. o.shop_id = d['shop_id']
  403. if 'shop_name' in d:
  404. o.shop_name = d['shop_name']
  405. if 'shop_tel' in d:
  406. o.shop_tel = d['shop_tel']
  407. if 'shop_type' in d:
  408. o.shop_type = d['shop_type']
  409. if 'status' in d:
  410. o.status = d['status']
  411. return o