package gorm_model

import (
	"time"
)

type YounggeeLocalLifeInfo struct {
	Id                  int        `gorm:"column:id;type:int(11);primary_key;AUTO_INCREMENT;comment:本地生活表主键ID" json:"id"`
	LocalId             string     `gorm:"column:local_id;type:varchar(10);comment:项目id;NOT NULL" json:"local_id"`
	LocalType           int64      `gorm:"column:local_type;type:tinyint(4);comment:项目类型，1代表公开项目，2代表定向项目" json:"local_type"`
	LocalPlatform       int        `gorm:"column:local_platform;type:tinyint(4);comment:项目平台，1-7分别代表小红书、抖音、微博、快手、b站、大众点评、知乎" json:"local_platform"`
	ServiceChargeRate   float64    `gorm:"column:service_charge_rate;type:decimal(10,2);default:0.00;comment:公开服务费率;NOT NULL" json:"service_charge_rate"`
	StoreId             int        `gorm:"column:store_id;type:int(11);comment:关联门店id" json:"store_id"`
	StoreRelatedAt      *time.Time `gorm:"column:store_related_at;type:timestamp;comment:关联门店时间" json:"store_related_at"`
	TeamBuyingId        int        `gorm:"column:team_buying_id;type:int(11);comment:关联团购id" json:"team_buying_id"`
	TeamBuyingRelatedAt *time.Time `gorm:"column:team_buying_related_at;type:timestamp;comment:关联团购时间" json:"team_buying_related_at"`
	PromoteBody         int        `gorm:"column:promote_body;type:int(11);comment:推广主体（1门店 2团购）" json:"promote_body"`
	Donate              int        `gorm:"column:donate;type:int(11);comment:赠送达人套餐（1有赠送 2无赠送）" json:"donate"`
	LocalName           string     `gorm:"column:local_name;type:varchar(50);comment:任务标题" json:"local_name"`
	TalentType          string     `gorm:"column:talent_type;type:text;comment:达人类型（,分隔）" json:"talent_type"`
	RecruitDdl          *time.Time `gorm:"column:recruit_ddl;type:timestamp;comment:招募截止时间" json:"recruit_ddl"`
	TaskForm            int        `gorm:"column:task_form;type:tinyint(4);comment:任务形式，1-2分别代表线下探店,素材分发" json:"task_form"`
	ContentType         int        `gorm:"column:content_type;type:tinyint(4);comment:内容形式，1代表图文，2代表视频" json:"content_type"`
	TaskDetail          string     `gorm:"column:task_detail;type:varchar(1000);comment:任务详情" json:"task_detail"`
	TaskStatus          int        `gorm:"column:task_status;type:tinyint(4);comment:项目状态，1-10分别代表创建中、待审核、审核通过、招募中、招募完毕、待支付、已支付、执行中、失效、已结案" json:"task_status"`
	EnterpriseId        string     `gorm:"column:enterprise_id;type:varchar(10);comment:所属企业id" json:"enterprise_id"`
	SubAccountId        int        `gorm:"column:sub_account_id;type:int(11);default:0;comment:子账号id;NOT NULL" json:"sub_account_id"`
	OperatorType        int        `gorm:"column:operator_type;type:int(11);comment:创建者类型，1商家主账号，2商家子账号" json:"operator_type"`
	ApplyNum            int64      `gorm:"column:apply_num;type:int(11);default:0;comment:报名人数;NOT NULL" json:"apply_num"`
	RecruitNum          int64      `gorm:"column:recruit_num;type:int(11);default:0;comment:已招募人数;NOT NULL" json:"recruit_num"`
	SettleNum           int64      `gorm:"column:settle_num;type:int(11);default:0;comment:结案人数;NOT NULL" json:"settle_num"`
	CreatedAt           *time.Time `gorm:"column:created_at;type:timestamp;comment:创建时间" json:"created_at"`
	UpdatedAt           *time.Time `gorm:"column:updated_at;type:timestamp;comment:修改时间" json:"updated_at"`
	AutoFailAt          *time.Time `gorm:"column:auto_fail_at;type:timestamp;comment:失效自动处理时间" json:"auto_fail_at"`
	AutoTaskId          int        `gorm:"column:auto_task_id;type:int(11);default:0;comment:定时任务id;NOT NULL" json:"auto_task_id"`
	AutoDefaultId       int        `gorm:"column:auto_default_id;type:int(11);default:0;comment:违约状态id;NOT NULL" json:"auto_default_id"`
	PaymentAmount       float64    `gorm:"column:payment_amount;type:float;comment:支付金额" json:"payment_amount"`
	PayAt               *time.Time `gorm:"column:pay_at;type:timestamp;comment:支付时间" json:"pay_at"`
	SubmitAt            *time.Time `gorm:"column:submit_at;type:timestamp;comment:提交审核时间" json:"submit_at"`
	PassAt              *time.Time `gorm:"column:pass_at;type:timestamp;comment:审核通过时间" json:"pass_at"`
	FinishAt            *time.Time `gorm:"column:finish_at;type:timestamp;comment:结案时间" json:"finish_at"`
	EstimatedCost       float64    `gorm:"column:estimated_cost;type:decimal(10,2);comment:预估成本" json:"estimated_cost"`
	SettlementAmount    float64    `gorm:"column:settlement_amount;type:decimal(10,2);comment:结算金额" json:"settlement_amount"`
	TotalRecruitNum     int        `gorm:"column:total_recruit_num;type:int(11);comment:此任务各策略招募人数总和" json:"total_recruit_num"`
	Tools               string     `gorm:"column:tools;type:varchar(255);comment:工具选择，1邀约招募 2样品物流 3审稿工具 4作品审查 5数据巡检 6结算账单（,分隔）;NOT NULL" json:"tools"`
	NeedReview          int        `gorm:"column:need_review;type:int(11);default:0;comment:待审稿;NOT NULL" json:"need_review"`
	NeedQuality         int        `gorm:"column:need_quality;type:int(11);default:0;comment:待质检;NOT NULL" json:"need_quality"`
	NeedCalculate       int        `gorm:"column:need_calculate;type:int(11);default:0;comment:待结算;NOT NULL" json:"need_calculate"`
	InvoiceStatus       int        `gorm:"column:invoice_status;type:int(11);default:0;comment:开票状态（1开票中 2已开票）;NOT NULL" json:"invoice_status"`
	NeedPay             float64    `gorm:"column:need_pay"`
}

func (m *YounggeeLocalLifeInfo) TableName() string {
	return "younggee_local_life_info"
}
