PoiQueryResult.py 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. import json
  4. from alipay.aop.api.constant.ParamConstants import *
  5. from alipay.aop.api.domain.StructureBrandInfo import StructureBrandInfo
  6. from alipay.aop.api.domain.StructureServiceInfo import StructureServiceInfo
  7. class PoiQueryResult(object):
  8. def __init__(self):
  9. self._address = None
  10. self._address_en = None
  11. self._address_local = None
  12. self._alternative_phone = None
  13. self._bios = None
  14. self._brand_info = None
  15. self._business_hour = None
  16. self._category = None
  17. self._city = None
  18. self._commercial_circle = None
  19. self._consumption = None
  20. self._country_code = None
  21. self._country_name = None
  22. self._description = None
  23. self._extend_map = None
  24. self._gmt_create = None
  25. self._gmt_modified = None
  26. self._lat = None
  27. self._lng = None
  28. self._local_language = None
  29. self._local_name = None
  30. self._main_phone = None
  31. self._name = None
  32. self._name_alias = None
  33. self._name_en = None
  34. self._offline_reason_detail = None
  35. self._open_status = None
  36. self._open_time = None
  37. self._operator_type = None
  38. self._photo_urls = None
  39. self._poi_id = None
  40. self._postal_code = None
  41. self._province = None
  42. self._recommend_infos = None
  43. self._seller_id = None
  44. self._service_info = None
  45. self._shop_id = None
  46. self._shop_type = None
  47. self._source_biz_id = None
  48. self._store_id = None
  49. self._sub_seller_id = None
  50. self._telephone = None
  51. self._transport = None
  52. self._type = None
  53. self._video_url = None
  54. self._web_site_url = None
  55. @property
  56. def address(self):
  57. return self._address
  58. @address.setter
  59. def address(self, value):
  60. self._address = value
  61. @property
  62. def address_en(self):
  63. return self._address_en
  64. @address_en.setter
  65. def address_en(self, value):
  66. self._address_en = value
  67. @property
  68. def address_local(self):
  69. return self._address_local
  70. @address_local.setter
  71. def address_local(self, value):
  72. self._address_local = value
  73. @property
  74. def alternative_phone(self):
  75. return self._alternative_phone
  76. @alternative_phone.setter
  77. def alternative_phone(self, value):
  78. self._alternative_phone = value
  79. @property
  80. def bios(self):
  81. return self._bios
  82. @bios.setter
  83. def bios(self, value):
  84. self._bios = value
  85. @property
  86. def brand_info(self):
  87. return self._brand_info
  88. @brand_info.setter
  89. def brand_info(self, value):
  90. if isinstance(value, StructureBrandInfo):
  91. self._brand_info = value
  92. else:
  93. self._brand_info = StructureBrandInfo.from_alipay_dict(value)
  94. @property
  95. def business_hour(self):
  96. return self._business_hour
  97. @business_hour.setter
  98. def business_hour(self, value):
  99. self._business_hour = value
  100. @property
  101. def category(self):
  102. return self._category
  103. @category.setter
  104. def category(self, value):
  105. self._category = value
  106. @property
  107. def city(self):
  108. return self._city
  109. @city.setter
  110. def city(self, value):
  111. self._city = value
  112. @property
  113. def commercial_circle(self):
  114. return self._commercial_circle
  115. @commercial_circle.setter
  116. def commercial_circle(self, value):
  117. self._commercial_circle = value
  118. @property
  119. def consumption(self):
  120. return self._consumption
  121. @consumption.setter
  122. def consumption(self, value):
  123. self._consumption = value
  124. @property
  125. def country_code(self):
  126. return self._country_code
  127. @country_code.setter
  128. def country_code(self, value):
  129. self._country_code = value
  130. @property
  131. def country_name(self):
  132. return self._country_name
  133. @country_name.setter
  134. def country_name(self, value):
  135. self._country_name = value
  136. @property
  137. def description(self):
  138. return self._description
  139. @description.setter
  140. def description(self, value):
  141. self._description = value
  142. @property
  143. def extend_map(self):
  144. return self._extend_map
  145. @extend_map.setter
  146. def extend_map(self, value):
  147. self._extend_map = value
  148. @property
  149. def gmt_create(self):
  150. return self._gmt_create
  151. @gmt_create.setter
  152. def gmt_create(self, value):
  153. self._gmt_create = value
  154. @property
  155. def gmt_modified(self):
  156. return self._gmt_modified
  157. @gmt_modified.setter
  158. def gmt_modified(self, value):
  159. self._gmt_modified = value
  160. @property
  161. def lat(self):
  162. return self._lat
  163. @lat.setter
  164. def lat(self, value):
  165. self._lat = value
  166. @property
  167. def lng(self):
  168. return self._lng
  169. @lng.setter
  170. def lng(self, value):
  171. self._lng = value
  172. @property
  173. def local_language(self):
  174. return self._local_language
  175. @local_language.setter
  176. def local_language(self, value):
  177. self._local_language = value
  178. @property
  179. def local_name(self):
  180. return self._local_name
  181. @local_name.setter
  182. def local_name(self, value):
  183. self._local_name = value
  184. @property
  185. def main_phone(self):
  186. return self._main_phone
  187. @main_phone.setter
  188. def main_phone(self, value):
  189. self._main_phone = value
  190. @property
  191. def name(self):
  192. return self._name
  193. @name.setter
  194. def name(self, value):
  195. self._name = value
  196. @property
  197. def name_alias(self):
  198. return self._name_alias
  199. @name_alias.setter
  200. def name_alias(self, value):
  201. self._name_alias = value
  202. @property
  203. def name_en(self):
  204. return self._name_en
  205. @name_en.setter
  206. def name_en(self, value):
  207. self._name_en = value
  208. @property
  209. def offline_reason_detail(self):
  210. return self._offline_reason_detail
  211. @offline_reason_detail.setter
  212. def offline_reason_detail(self, value):
  213. self._offline_reason_detail = value
  214. @property
  215. def open_status(self):
  216. return self._open_status
  217. @open_status.setter
  218. def open_status(self, value):
  219. self._open_status = value
  220. @property
  221. def open_time(self):
  222. return self._open_time
  223. @open_time.setter
  224. def open_time(self, value):
  225. self._open_time = value
  226. @property
  227. def operator_type(self):
  228. return self._operator_type
  229. @operator_type.setter
  230. def operator_type(self, value):
  231. self._operator_type = value
  232. @property
  233. def photo_urls(self):
  234. return self._photo_urls
  235. @photo_urls.setter
  236. def photo_urls(self, value):
  237. if isinstance(value, list):
  238. self._photo_urls = list()
  239. for i in value:
  240. self._photo_urls.append(i)
  241. @property
  242. def poi_id(self):
  243. return self._poi_id
  244. @poi_id.setter
  245. def poi_id(self, value):
  246. self._poi_id = value
  247. @property
  248. def postal_code(self):
  249. return self._postal_code
  250. @postal_code.setter
  251. def postal_code(self, value):
  252. self._postal_code = value
  253. @property
  254. def province(self):
  255. return self._province
  256. @province.setter
  257. def province(self, value):
  258. self._province = value
  259. @property
  260. def recommend_infos(self):
  261. return self._recommend_infos
  262. @recommend_infos.setter
  263. def recommend_infos(self, value):
  264. self._recommend_infos = value
  265. @property
  266. def seller_id(self):
  267. return self._seller_id
  268. @seller_id.setter
  269. def seller_id(self, value):
  270. self._seller_id = value
  271. @property
  272. def service_info(self):
  273. return self._service_info
  274. @service_info.setter
  275. def service_info(self, value):
  276. if isinstance(value, StructureServiceInfo):
  277. self._service_info = value
  278. else:
  279. self._service_info = StructureServiceInfo.from_alipay_dict(value)
  280. @property
  281. def shop_id(self):
  282. return self._shop_id
  283. @shop_id.setter
  284. def shop_id(self, value):
  285. self._shop_id = value
  286. @property
  287. def shop_type(self):
  288. return self._shop_type
  289. @shop_type.setter
  290. def shop_type(self, value):
  291. self._shop_type = value
  292. @property
  293. def source_biz_id(self):
  294. return self._source_biz_id
  295. @source_biz_id.setter
  296. def source_biz_id(self, value):
  297. self._source_biz_id = value
  298. @property
  299. def store_id(self):
  300. return self._store_id
  301. @store_id.setter
  302. def store_id(self, value):
  303. self._store_id = value
  304. @property
  305. def sub_seller_id(self):
  306. return self._sub_seller_id
  307. @sub_seller_id.setter
  308. def sub_seller_id(self, value):
  309. self._sub_seller_id = value
  310. @property
  311. def telephone(self):
  312. return self._telephone
  313. @telephone.setter
  314. def telephone(self, value):
  315. self._telephone = value
  316. @property
  317. def transport(self):
  318. return self._transport
  319. @transport.setter
  320. def transport(self, value):
  321. self._transport = value
  322. @property
  323. def type(self):
  324. return self._type
  325. @type.setter
  326. def type(self, value):
  327. self._type = value
  328. @property
  329. def video_url(self):
  330. return self._video_url
  331. @video_url.setter
  332. def video_url(self, value):
  333. self._video_url = value
  334. @property
  335. def web_site_url(self):
  336. return self._web_site_url
  337. @web_site_url.setter
  338. def web_site_url(self, value):
  339. self._web_site_url = value
  340. def to_alipay_dict(self):
  341. params = dict()
  342. if self.address:
  343. if hasattr(self.address, 'to_alipay_dict'):
  344. params['address'] = self.address.to_alipay_dict()
  345. else:
  346. params['address'] = self.address
  347. if self.address_en:
  348. if hasattr(self.address_en, 'to_alipay_dict'):
  349. params['address_en'] = self.address_en.to_alipay_dict()
  350. else:
  351. params['address_en'] = self.address_en
  352. if self.address_local:
  353. if hasattr(self.address_local, 'to_alipay_dict'):
  354. params['address_local'] = self.address_local.to_alipay_dict()
  355. else:
  356. params['address_local'] = self.address_local
  357. if self.alternative_phone:
  358. if hasattr(self.alternative_phone, 'to_alipay_dict'):
  359. params['alternative_phone'] = self.alternative_phone.to_alipay_dict()
  360. else:
  361. params['alternative_phone'] = self.alternative_phone
  362. if self.bios:
  363. if hasattr(self.bios, 'to_alipay_dict'):
  364. params['bios'] = self.bios.to_alipay_dict()
  365. else:
  366. params['bios'] = self.bios
  367. if self.brand_info:
  368. if hasattr(self.brand_info, 'to_alipay_dict'):
  369. params['brand_info'] = self.brand_info.to_alipay_dict()
  370. else:
  371. params['brand_info'] = self.brand_info
  372. if self.business_hour:
  373. if hasattr(self.business_hour, 'to_alipay_dict'):
  374. params['business_hour'] = self.business_hour.to_alipay_dict()
  375. else:
  376. params['business_hour'] = self.business_hour
  377. if self.category:
  378. if hasattr(self.category, 'to_alipay_dict'):
  379. params['category'] = self.category.to_alipay_dict()
  380. else:
  381. params['category'] = self.category
  382. if self.city:
  383. if hasattr(self.city, 'to_alipay_dict'):
  384. params['city'] = self.city.to_alipay_dict()
  385. else:
  386. params['city'] = self.city
  387. if self.commercial_circle:
  388. if hasattr(self.commercial_circle, 'to_alipay_dict'):
  389. params['commercial_circle'] = self.commercial_circle.to_alipay_dict()
  390. else:
  391. params['commercial_circle'] = self.commercial_circle
  392. if self.consumption:
  393. if hasattr(self.consumption, 'to_alipay_dict'):
  394. params['consumption'] = self.consumption.to_alipay_dict()
  395. else:
  396. params['consumption'] = self.consumption
  397. if self.country_code:
  398. if hasattr(self.country_code, 'to_alipay_dict'):
  399. params['country_code'] = self.country_code.to_alipay_dict()
  400. else:
  401. params['country_code'] = self.country_code
  402. if self.country_name:
  403. if hasattr(self.country_name, 'to_alipay_dict'):
  404. params['country_name'] = self.country_name.to_alipay_dict()
  405. else:
  406. params['country_name'] = self.country_name
  407. if self.description:
  408. if hasattr(self.description, 'to_alipay_dict'):
  409. params['description'] = self.description.to_alipay_dict()
  410. else:
  411. params['description'] = self.description
  412. if self.extend_map:
  413. if hasattr(self.extend_map, 'to_alipay_dict'):
  414. params['extend_map'] = self.extend_map.to_alipay_dict()
  415. else:
  416. params['extend_map'] = self.extend_map
  417. if self.gmt_create:
  418. if hasattr(self.gmt_create, 'to_alipay_dict'):
  419. params['gmt_create'] = self.gmt_create.to_alipay_dict()
  420. else:
  421. params['gmt_create'] = self.gmt_create
  422. if self.gmt_modified:
  423. if hasattr(self.gmt_modified, 'to_alipay_dict'):
  424. params['gmt_modified'] = self.gmt_modified.to_alipay_dict()
  425. else:
  426. params['gmt_modified'] = self.gmt_modified
  427. if self.lat:
  428. if hasattr(self.lat, 'to_alipay_dict'):
  429. params['lat'] = self.lat.to_alipay_dict()
  430. else:
  431. params['lat'] = self.lat
  432. if self.lng:
  433. if hasattr(self.lng, 'to_alipay_dict'):
  434. params['lng'] = self.lng.to_alipay_dict()
  435. else:
  436. params['lng'] = self.lng
  437. if self.local_language:
  438. if hasattr(self.local_language, 'to_alipay_dict'):
  439. params['local_language'] = self.local_language.to_alipay_dict()
  440. else:
  441. params['local_language'] = self.local_language
  442. if self.local_name:
  443. if hasattr(self.local_name, 'to_alipay_dict'):
  444. params['local_name'] = self.local_name.to_alipay_dict()
  445. else:
  446. params['local_name'] = self.local_name
  447. if self.main_phone:
  448. if hasattr(self.main_phone, 'to_alipay_dict'):
  449. params['main_phone'] = self.main_phone.to_alipay_dict()
  450. else:
  451. params['main_phone'] = self.main_phone
  452. if self.name:
  453. if hasattr(self.name, 'to_alipay_dict'):
  454. params['name'] = self.name.to_alipay_dict()
  455. else:
  456. params['name'] = self.name
  457. if self.name_alias:
  458. if hasattr(self.name_alias, 'to_alipay_dict'):
  459. params['name_alias'] = self.name_alias.to_alipay_dict()
  460. else:
  461. params['name_alias'] = self.name_alias
  462. if self.name_en:
  463. if hasattr(self.name_en, 'to_alipay_dict'):
  464. params['name_en'] = self.name_en.to_alipay_dict()
  465. else:
  466. params['name_en'] = self.name_en
  467. if self.offline_reason_detail:
  468. if hasattr(self.offline_reason_detail, 'to_alipay_dict'):
  469. params['offline_reason_detail'] = self.offline_reason_detail.to_alipay_dict()
  470. else:
  471. params['offline_reason_detail'] = self.offline_reason_detail
  472. if self.open_status:
  473. if hasattr(self.open_status, 'to_alipay_dict'):
  474. params['open_status'] = self.open_status.to_alipay_dict()
  475. else:
  476. params['open_status'] = self.open_status
  477. if self.open_time:
  478. if hasattr(self.open_time, 'to_alipay_dict'):
  479. params['open_time'] = self.open_time.to_alipay_dict()
  480. else:
  481. params['open_time'] = self.open_time
  482. if self.operator_type:
  483. if hasattr(self.operator_type, 'to_alipay_dict'):
  484. params['operator_type'] = self.operator_type.to_alipay_dict()
  485. else:
  486. params['operator_type'] = self.operator_type
  487. if self.photo_urls:
  488. if isinstance(self.photo_urls, list):
  489. for i in range(0, len(self.photo_urls)):
  490. element = self.photo_urls[i]
  491. if hasattr(element, 'to_alipay_dict'):
  492. self.photo_urls[i] = element.to_alipay_dict()
  493. if hasattr(self.photo_urls, 'to_alipay_dict'):
  494. params['photo_urls'] = self.photo_urls.to_alipay_dict()
  495. else:
  496. params['photo_urls'] = self.photo_urls
  497. if self.poi_id:
  498. if hasattr(self.poi_id, 'to_alipay_dict'):
  499. params['poi_id'] = self.poi_id.to_alipay_dict()
  500. else:
  501. params['poi_id'] = self.poi_id
  502. if self.postal_code:
  503. if hasattr(self.postal_code, 'to_alipay_dict'):
  504. params['postal_code'] = self.postal_code.to_alipay_dict()
  505. else:
  506. params['postal_code'] = self.postal_code
  507. if self.province:
  508. if hasattr(self.province, 'to_alipay_dict'):
  509. params['province'] = self.province.to_alipay_dict()
  510. else:
  511. params['province'] = self.province
  512. if self.recommend_infos:
  513. if hasattr(self.recommend_infos, 'to_alipay_dict'):
  514. params['recommend_infos'] = self.recommend_infos.to_alipay_dict()
  515. else:
  516. params['recommend_infos'] = self.recommend_infos
  517. if self.seller_id:
  518. if hasattr(self.seller_id, 'to_alipay_dict'):
  519. params['seller_id'] = self.seller_id.to_alipay_dict()
  520. else:
  521. params['seller_id'] = self.seller_id
  522. if self.service_info:
  523. if hasattr(self.service_info, 'to_alipay_dict'):
  524. params['service_info'] = self.service_info.to_alipay_dict()
  525. else:
  526. params['service_info'] = self.service_info
  527. if self.shop_id:
  528. if hasattr(self.shop_id, 'to_alipay_dict'):
  529. params['shop_id'] = self.shop_id.to_alipay_dict()
  530. else:
  531. params['shop_id'] = self.shop_id
  532. if self.shop_type:
  533. if hasattr(self.shop_type, 'to_alipay_dict'):
  534. params['shop_type'] = self.shop_type.to_alipay_dict()
  535. else:
  536. params['shop_type'] = self.shop_type
  537. if self.source_biz_id:
  538. if hasattr(self.source_biz_id, 'to_alipay_dict'):
  539. params['source_biz_id'] = self.source_biz_id.to_alipay_dict()
  540. else:
  541. params['source_biz_id'] = self.source_biz_id
  542. if self.store_id:
  543. if hasattr(self.store_id, 'to_alipay_dict'):
  544. params['store_id'] = self.store_id.to_alipay_dict()
  545. else:
  546. params['store_id'] = self.store_id
  547. if self.sub_seller_id:
  548. if hasattr(self.sub_seller_id, 'to_alipay_dict'):
  549. params['sub_seller_id'] = self.sub_seller_id.to_alipay_dict()
  550. else:
  551. params['sub_seller_id'] = self.sub_seller_id
  552. if self.telephone:
  553. if hasattr(self.telephone, 'to_alipay_dict'):
  554. params['telephone'] = self.telephone.to_alipay_dict()
  555. else:
  556. params['telephone'] = self.telephone
  557. if self.transport:
  558. if hasattr(self.transport, 'to_alipay_dict'):
  559. params['transport'] = self.transport.to_alipay_dict()
  560. else:
  561. params['transport'] = self.transport
  562. if self.type:
  563. if hasattr(self.type, 'to_alipay_dict'):
  564. params['type'] = self.type.to_alipay_dict()
  565. else:
  566. params['type'] = self.type
  567. if self.video_url:
  568. if hasattr(self.video_url, 'to_alipay_dict'):
  569. params['video_url'] = self.video_url.to_alipay_dict()
  570. else:
  571. params['video_url'] = self.video_url
  572. if self.web_site_url:
  573. if hasattr(self.web_site_url, 'to_alipay_dict'):
  574. params['web_site_url'] = self.web_site_url.to_alipay_dict()
  575. else:
  576. params['web_site_url'] = self.web_site_url
  577. return params
  578. @staticmethod
  579. def from_alipay_dict(d):
  580. if not d:
  581. return None
  582. o = PoiQueryResult()
  583. if 'address' in d:
  584. o.address = d['address']
  585. if 'address_en' in d:
  586. o.address_en = d['address_en']
  587. if 'address_local' in d:
  588. o.address_local = d['address_local']
  589. if 'alternative_phone' in d:
  590. o.alternative_phone = d['alternative_phone']
  591. if 'bios' in d:
  592. o.bios = d['bios']
  593. if 'brand_info' in d:
  594. o.brand_info = d['brand_info']
  595. if 'business_hour' in d:
  596. o.business_hour = d['business_hour']
  597. if 'category' in d:
  598. o.category = d['category']
  599. if 'city' in d:
  600. o.city = d['city']
  601. if 'commercial_circle' in d:
  602. o.commercial_circle = d['commercial_circle']
  603. if 'consumption' in d:
  604. o.consumption = d['consumption']
  605. if 'country_code' in d:
  606. o.country_code = d['country_code']
  607. if 'country_name' in d:
  608. o.country_name = d['country_name']
  609. if 'description' in d:
  610. o.description = d['description']
  611. if 'extend_map' in d:
  612. o.extend_map = d['extend_map']
  613. if 'gmt_create' in d:
  614. o.gmt_create = d['gmt_create']
  615. if 'gmt_modified' in d:
  616. o.gmt_modified = d['gmt_modified']
  617. if 'lat' in d:
  618. o.lat = d['lat']
  619. if 'lng' in d:
  620. o.lng = d['lng']
  621. if 'local_language' in d:
  622. o.local_language = d['local_language']
  623. if 'local_name' in d:
  624. o.local_name = d['local_name']
  625. if 'main_phone' in d:
  626. o.main_phone = d['main_phone']
  627. if 'name' in d:
  628. o.name = d['name']
  629. if 'name_alias' in d:
  630. o.name_alias = d['name_alias']
  631. if 'name_en' in d:
  632. o.name_en = d['name_en']
  633. if 'offline_reason_detail' in d:
  634. o.offline_reason_detail = d['offline_reason_detail']
  635. if 'open_status' in d:
  636. o.open_status = d['open_status']
  637. if 'open_time' in d:
  638. o.open_time = d['open_time']
  639. if 'operator_type' in d:
  640. o.operator_type = d['operator_type']
  641. if 'photo_urls' in d:
  642. o.photo_urls = d['photo_urls']
  643. if 'poi_id' in d:
  644. o.poi_id = d['poi_id']
  645. if 'postal_code' in d:
  646. o.postal_code = d['postal_code']
  647. if 'province' in d:
  648. o.province = d['province']
  649. if 'recommend_infos' in d:
  650. o.recommend_infos = d['recommend_infos']
  651. if 'seller_id' in d:
  652. o.seller_id = d['seller_id']
  653. if 'service_info' in d:
  654. o.service_info = d['service_info']
  655. if 'shop_id' in d:
  656. o.shop_id = d['shop_id']
  657. if 'shop_type' in d:
  658. o.shop_type = d['shop_type']
  659. if 'source_biz_id' in d:
  660. o.source_biz_id = d['source_biz_id']
  661. if 'store_id' in d:
  662. o.store_id = d['store_id']
  663. if 'sub_seller_id' in d:
  664. o.sub_seller_id = d['sub_seller_id']
  665. if 'telephone' in d:
  666. o.telephone = d['telephone']
  667. if 'transport' in d:
  668. o.transport = d['transport']
  669. if 'type' in d:
  670. o.type = d['type']
  671. if 'video_url' in d:
  672. o.video_url = d['video_url']
  673. if 'web_site_url' in d:
  674. o.web_site_url = d['web_site_url']
  675. return o