12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485 |
- #!/usr/bin/env python
- # -*- coding: utf-8 -*-
- import json
- from alipay.aop.api.constant.ParamConstants import *
- class KoubeiServindustryReservationResourceSyncModel(object):
- def __init__(self):
- self._channel = None
- self._industry = None
- self._out_shop_id = None
- self._shop_id = None
- @property
- def channel(self):
- return self._channel
- @channel.setter
- def channel(self, value):
- self._channel = value
- @property
- def industry(self):
- return self._industry
- @industry.setter
- def industry(self, value):
- self._industry = value
- @property
- def out_shop_id(self):
- return self._out_shop_id
- @out_shop_id.setter
- def out_shop_id(self, value):
- self._out_shop_id = value
- @property
- def shop_id(self):
- return self._shop_id
- @shop_id.setter
- def shop_id(self, value):
- self._shop_id = value
- def to_alipay_dict(self):
- params = dict()
- if self.channel:
- if hasattr(self.channel, 'to_alipay_dict'):
- params['channel'] = self.channel.to_alipay_dict()
- else:
- params['channel'] = self.channel
- if self.industry:
- if hasattr(self.industry, 'to_alipay_dict'):
- params['industry'] = self.industry.to_alipay_dict()
- else:
- params['industry'] = self.industry
- if self.out_shop_id:
- if hasattr(self.out_shop_id, 'to_alipay_dict'):
- params['out_shop_id'] = self.out_shop_id.to_alipay_dict()
- else:
- params['out_shop_id'] = self.out_shop_id
- if self.shop_id:
- if hasattr(self.shop_id, 'to_alipay_dict'):
- params['shop_id'] = self.shop_id.to_alipay_dict()
- else:
- params['shop_id'] = self.shop_id
- return params
- @staticmethod
- def from_alipay_dict(d):
- if not d:
- return None
- o = KoubeiServindustryReservationResourceSyncModel()
- if 'channel' in d:
- o.channel = d['channel']
- if 'industry' in d:
- o.industry = d['industry']
- if 'out_shop_id' in d:
- o.out_shop_id = d['out_shop_id']
- if 'shop_id' in d:
- o.shop_id = d['shop_id']
- return o
|