123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100 |
- #!/usr/bin/env python
- # -*- coding: utf-8 -*-
- import json
- from alipay.aop.api.constant.ParamConstants import *
- class AlipayOpenMiniInnerversionCreateModel(object):
- def __init__(self):
- self._app_version = None
- self._bundle_id = None
- self._inst_code = None
- self._mini_app_id = None
- self._target_bundle_id = None
- @property
- def app_version(self):
- return self._app_version
- @app_version.setter
- def app_version(self, value):
- self._app_version = value
- @property
- def bundle_id(self):
- return self._bundle_id
- @bundle_id.setter
- def bundle_id(self, value):
- self._bundle_id = value
- @property
- def inst_code(self):
- return self._inst_code
- @inst_code.setter
- def inst_code(self, value):
- self._inst_code = value
- @property
- def mini_app_id(self):
- return self._mini_app_id
- @mini_app_id.setter
- def mini_app_id(self, value):
- self._mini_app_id = value
- @property
- def target_bundle_id(self):
- return self._target_bundle_id
- @target_bundle_id.setter
- def target_bundle_id(self, value):
- self._target_bundle_id = value
- def to_alipay_dict(self):
- params = dict()
- if self.app_version:
- if hasattr(self.app_version, 'to_alipay_dict'):
- params['app_version'] = self.app_version.to_alipay_dict()
- else:
- params['app_version'] = self.app_version
- if self.bundle_id:
- if hasattr(self.bundle_id, 'to_alipay_dict'):
- params['bundle_id'] = self.bundle_id.to_alipay_dict()
- else:
- params['bundle_id'] = self.bundle_id
- if self.inst_code:
- if hasattr(self.inst_code, 'to_alipay_dict'):
- params['inst_code'] = self.inst_code.to_alipay_dict()
- else:
- params['inst_code'] = self.inst_code
- if self.mini_app_id:
- if hasattr(self.mini_app_id, 'to_alipay_dict'):
- params['mini_app_id'] = self.mini_app_id.to_alipay_dict()
- else:
- params['mini_app_id'] = self.mini_app_id
- if self.target_bundle_id:
- if hasattr(self.target_bundle_id, 'to_alipay_dict'):
- params['target_bundle_id'] = self.target_bundle_id.to_alipay_dict()
- else:
- params['target_bundle_id'] = self.target_bundle_id
- return params
- @staticmethod
- def from_alipay_dict(d):
- if not d:
- return None
- o = AlipayOpenMiniInnerversionCreateModel()
- if 'app_version' in d:
- o.app_version = d['app_version']
- if 'bundle_id' in d:
- o.bundle_id = d['bundle_id']
- if 'inst_code' in d:
- o.inst_code = d['inst_code']
- if 'mini_app_id' in d:
- o.mini_app_id = d['mini_app_id']
- if 'target_bundle_id' in d:
- o.target_bundle_id = d['target_bundle_id']
- return o
|