def __init__(self, **kwargs): self.body = fields.StringField(name=HightonConstants.BODY, required=True) self.author_id = fields.IntegerField(name=HightonConstants.AUTHOR_ID) self.subject_id = fields.IntegerField(name=HightonConstants.SUBJECT_ID, required=True) self.subject_type = fields.StringField( name=HightonConstants.SUBJECT_TYPE, required=True) self.subject_name = fields.StringField( name=HightonConstants.SUBJECT_NAME) self.collection_id = fields.IntegerField( name=HightonConstants.COLLECTION_ID) self.collection_type = fields.StringField( name=HightonConstants.COLLECTION_TYPE) self.visible_to = fields.StringField(name=HightonConstants.VISIBLE_TO) self.owner_id = fields.IntegerField(name=HightonConstants.OWNER_ID) self.group_id = fields.IntegerField(name=HightonConstants.GROUP_ID) self.updated_at = fields.DatetimeField( name=HightonConstants.UPDATED_AT) self.created_at = fields.DatetimeField( name=HightonConstants.CREATED_AT) self.attachments = fields.ListField(name=HightonConstants.ATTACHMENTS, init_class=Attachment) super().__init__(**kwargs)
def __init__(self, **kwargs): from highton.models import ( Tag, ContactData, SubjectData, ) self.author_id = fields.IntegerField(name=HightonConstants.AUTHOR_ID) self.background = fields.StringField(name=HightonConstants.BACKGROUND) self.created_at = fields.DatetimeField( name=HightonConstants.CREATED_AT) self.group_id = fields.IntegerField(name=HightonConstants.GROUP_ID) self.owner_id = fields.IntegerField(name=HightonConstants.OWNER_ID) self.updated_at = fields.DatetimeField( name=HightonConstants.UPDATED_AT) self.visible_to = fields.StringField(name=HightonConstants.VISIBLE_TO) self.linkedin_url = fields.StringField( name=HightonConstants.LINKEDIN_URL) self.avatar_url = fields.StringField(name=HightonConstants.AVATAR_URL) self.tags = fields.ListField(name=HightonConstants.TAGS, init_class=Tag) self.contact_data = fields.ObjectField( name=HightonConstants.CONTACT_DATA, init_class=ContactData) self.subject_datas = fields.ListField( name=HightonConstants.SUBJECT_DATAS, init_class=SubjectData) super().__init__(**kwargs)
def __init__(self, **kwargs): self.name = fields.StringField(name=HightonConstants.NAME) self.email_address = fields.StringField( name=HightonConstants.EMAIL_ADDRESS) self.admin = fields.BooleanField(name=HightonConstants.ADMIN) self.token = fields.StringField(name=HightonConstants.TOKEN) self.dropbox = fields.StringField(name=HightonConstants.DROPBOX) self.created_at = fields.DatetimeField( name=HightonConstants.CREATED_AT) self.updated_at = fields.DatetimeField( name=HightonConstants.UPDATED_AT) super().__init__(**kwargs)
def __init__(self, **kwargs): self.name = fields.StringField(name='name') self.created_date = fields.DateField(name='created-date') self.created_datetime = fields.DatetimeField(name='created-datetime') self.tags = fields.ListField(name='tags', init_class=Tag) self.category = fields.ObjectField(name='category', init_class=Category) super().__init__(**kwargs)
def __init__(self, **kwargs): self.parent_id = fields.IntegerField(name=HightonConstants.PARENT_ID, required=True) self.body = fields.StringField(name=HightonConstants.BODY, required=True) self.author_id = fields.IntegerField(name=HightonConstants.AUTHOR_ID) self.created_at = fields.DatetimeField( name=HightonConstants.CREATED_AT) super().__init__(**kwargs)
def __init__(self, **kwargs): """ Init a deal with the attributes :param kwargs: :type kwargs: """ from highton.models import ( Tag, ContactData, SubjectData, Party, AssociatedParty, Category, ) self.author_id = fields.IntegerField(name=HightonConstants.AUTHOR_ID) self.account_id = fields.IntegerField(name=HightonConstants.ACCOUNT_ID) self.background = fields.StringField(name=HightonConstants.BACKGROUND) self.category_id = fields.IntegerField(name=HightonConstants.CATEGORY_ID) self.created_at = fields.DatetimeField(name=HightonConstants.CREATED_AT) self.currency = fields.StringField(name=HightonConstants.CURRENCY) self.duration = fields.IntegerField(name=HightonConstants.DURATION) self.group_id = fields.IntegerField(name=HightonConstants.GROUP_ID) self.name = fields.StringField(name=HightonConstants.NAME) self.owner_id = fields.IntegerField(name=HightonConstants.OWNER_ID) self.party_id = fields.IntegerField(name=HightonConstants.PARTY_ID) self.price = fields.IntegerField(name=HightonConstants.PRICE) self.price_type = fields.StringField(name=HightonConstants.PRICE_TYPE) self.responsible_party_id = fields.IntegerField(name=HightonConstants.RESPONSIBLE_PARTY_ID) self.status = fields.StringField(name=HightonConstants.STATUS) self.status_changed_on = fields.DatetimeField(name=HightonConstants.STATUS_CHANGED_ON) self.updated_at = fields.DatetimeField(name=HightonConstants.UPDATED_AT) self.visible_to = fields.StringField(name=HightonConstants.VISIBLE_TO) self.party = fields.ObjectField(name=HightonConstants.PARTY, init_class=Party) self.category = fields.ObjectField(name=HightonConstants.CATEGORY, init_class=Category) self.tags = fields.ListField(name=HightonConstants.TAGS, init_class=Tag) self.parties = fields.ListField(name=HightonConstants.PARTIES, init_class=Party) self.contact_data = fields.ObjectField(name=HightonConstants.CONTACT_DATA, init_class=ContactData) self.subject_datas = fields.ListField(name=HightonConstants.SUBJECT_DATAS, init_class=SubjectData) self.associated_parties = fields.ListField(name=HightonConstants.ASSOCIATED_PARTIES, init_class=AssociatedParty) super().__init__(**kwargs)
def __init__(self, **kwargs): self.recording_id = fields.IntegerField(name=HightonConstants.RECORDING_ID) self.subject_id = fields.IntegerField(name=HightonConstants.SUBJECT_ID) self.subject_type = fields.StringField(name=HightonConstants.SUBJECT_TYPE) self.subject_name = fields.StringField(name=HightonConstants.SUBJECT_NAME) self.category_id = fields.IntegerField(name=HightonConstants.CATEGORY_ID, required=True) self.body = fields.StringField(name=HightonConstants.BODY, required=True) self.frame = fields.StringField(name=HightonConstants.FRAME, required=True) self.due_at = fields.DatetimeField(name=HightonConstants.DUE_AT, required=True) self.alert_at = fields.DatetimeField(name=HightonConstants.ALERT_AT) self.created_at = fields.DatetimeField(name=HightonConstants.CREATED_AT) self.author_id = fields.IntegerField(name=HightonConstants.AUTHOR_ID) self.updated_at = fields.DatetimeField(name=HightonConstants.UPDATED_AT) self.public = fields.BooleanField(name=HightonConstants.PUBLIC) self.recurring_period = fields.StringField(name=HightonConstants.RECURRING_PERIOD) self.anchor_type = fields.IntegerField(name=HightonConstants.ANCHOR_TYPE) self.done_at = fields.DatetimeField(name=HightonConstants.DONE_AT) self.owner_id = fields.IntegerField(name=HightonConstants.OWNER_ID) super().__init__(**kwargs)
def __init__(self, **kwargs): from highton.models import ( Party, AssociatedParty, ) self.author_id = fields.IntegerField(name=HightonConstants.AUTHOR_ID) self.closed_at = fields.DatetimeField(name=HightonConstants.CLOSED_AT) self.created_at = fields.DatetimeField( name=HightonConstants.CREATED_AT) self.updated_at = fields.DatetimeField( name=HightonConstants.UPDATED_AT) self.name = fields.StringField(name=HightonConstants.NAME) self.visible_to = fields.StringField(name=HightonConstants.VISIBLE_TO) self.group_id = fields.IntegerField(name=HightonConstants.GROUP_ID) self.owner_id = fields.IntegerField(name=HightonConstants.OWNER_ID) self.background = fields.StringField(name=HightonConstants.BACKGROUND) self.parties = fields.ListField(name=HightonConstants.PARTIES, init_class=Party) self.associated_parties = fields.ListField( name=HightonConstants.ASSOCIATED_PARTIES, init_class=AssociatedParty) super().__init__(**kwargs)