123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145 |
- #!/usr/bin/env python
- # -*- coding: utf-8 -*-
- import json
- from alipay.aop.api.constant.ParamConstants import *
- class AlipayOpenAppPropertyMessageSendModel(object):
- def __init__(self):
- self._biz_id = None
- self._community = None
- self._content = None
- self._date = None
- self._title = None
- self._type = None
- self._uid = None
- self._url = None
- @property
- def biz_id(self):
- return self._biz_id
- @biz_id.setter
- def biz_id(self, value):
- self._biz_id = value
- @property
- def community(self):
- return self._community
- @community.setter
- def community(self, value):
- self._community = value
- @property
- def content(self):
- return self._content
- @content.setter
- def content(self, value):
- self._content = value
- @property
- def date(self):
- return self._date
- @date.setter
- def date(self, value):
- self._date = value
- @property
- def title(self):
- return self._title
- @title.setter
- def title(self, value):
- self._title = value
- @property
- def type(self):
- return self._type
- @type.setter
- def type(self, value):
- self._type = value
- @property
- def uid(self):
- return self._uid
- @uid.setter
- def uid(self, value):
- self._uid = value
- @property
- def url(self):
- return self._url
- @url.setter
- def url(self, value):
- self._url = value
- def to_alipay_dict(self):
- params = dict()
- if self.biz_id:
- if hasattr(self.biz_id, 'to_alipay_dict'):
- params['biz_id'] = self.biz_id.to_alipay_dict()
- else:
- params['biz_id'] = self.biz_id
- if self.community:
- if hasattr(self.community, 'to_alipay_dict'):
- params['community'] = self.community.to_alipay_dict()
- else:
- params['community'] = self.community
- if self.content:
- if hasattr(self.content, 'to_alipay_dict'):
- params['content'] = self.content.to_alipay_dict()
- else:
- params['content'] = self.content
- if self.date:
- if hasattr(self.date, 'to_alipay_dict'):
- params['date'] = self.date.to_alipay_dict()
- else:
- params['date'] = self.date
- if self.title:
- if hasattr(self.title, 'to_alipay_dict'):
- params['title'] = self.title.to_alipay_dict()
- else:
- params['title'] = self.title
- if self.type:
- if hasattr(self.type, 'to_alipay_dict'):
- params['type'] = self.type.to_alipay_dict()
- else:
- params['type'] = self.type
- if self.uid:
- if hasattr(self.uid, 'to_alipay_dict'):
- params['uid'] = self.uid.to_alipay_dict()
- else:
- params['uid'] = self.uid
- if self.url:
- if hasattr(self.url, 'to_alipay_dict'):
- params['url'] = self.url.to_alipay_dict()
- else:
- params['url'] = self.url
- return params
- @staticmethod
- def from_alipay_dict(d):
- if not d:
- return None
- o = AlipayOpenAppPropertyMessageSendModel()
- if 'biz_id' in d:
- o.biz_id = d['biz_id']
- if 'community' in d:
- o.community = d['community']
- if 'content' in d:
- o.content = d['content']
- if 'date' in d:
- o.date = d['date']
- if 'title' in d:
- o.title = d['title']
- if 'type' in d:
- o.type = d['type']
- if 'uid' in d:
- o.uid = d['uid']
- if 'url' in d:
- o.url = d['url']
- return o
|