package dao import "server/global" type Program struct { global.GVA_MODEL Num1 string `json:"num1" gorm:"comment:显示内容编号1"` Effect1 string `json:"effect1" gorm:"comment:显示方式1"` Speed1 string `json:"speed1" gorm:"comment:移动速度1"` Stay1 string `json:"stay1" gorm:"comment:节目停留时间1"` Total1 string `json:"total1" gorm:"comment:预留1"` Color1 string `json:"color1" gorm:"comment:颜色1"` Content1 string `json:"content1" gorm:"comment:节目内容1"` Num2 string `json:"num2" gorm:"comment:显示内容编号2"` Effect2 string `json:"effect2" gorm:"comment:显示方式2"` Speed2 string `json:"speed2" gorm:"comment:移动速度2"` Stay2 string `json:"stay2" gorm:"comment:节目停留时间2"` Total2 string `json:"total2" gorm:"comment:预留2"` Color2 string `json:"color2" gorm:"comment:颜色2"` Content2 string `json:"content2" gorm:"comment:节目内容2"` Num3 string `json:"num3" gorm:"comment:显示内容编号3"` Effect3 string `json:"effect3" gorm:"comment:显示方式3"` Speed3 string `json:"speed3" gorm:"comment:移动速度3"` Stay3 string `json:"stay3" gorm:"comment:节目停留时间3"` Total3 string `json:"total3" gorm:"comment:预留3"` Color3 string `json:"color3" gorm:"comment:颜色3"` Content3 string `json:"content3" gorm:"comment:节目内容3"` Num4 string `json:"num4" gorm:"comment:显示内容编号4"` Effect4 string `json:"effect4" gorm:"comment:显示方式4"` Speed4 string `json:"speed4" gorm:"comment:移动速度4"` Stay4 string `json:"stay4" gorm:"comment:节目停留时间4"` Total4 string `json:"total4" gorm:"comment:预留4"` Color4 string `json:"color4" gorm:"comment:颜色4"` Content4 string `json:"content4" gorm:"comment:节目内容4"` Num5 string `json:"num5" gorm:"comment:显示内容编号5"` Effect5 string `json:"effect5" gorm:"comment:显示方式5"` Speed5 string `json:"speed5" gorm:"comment:移动速度5"` Stay5 string `json:"stay5" gorm:"comment:节目停留时间5"` Total5 string `json:"total5" gorm:"comment:预留5"` Color5 string `json:"color5" gorm:"comment:颜色5"` Content5 string `json:"content5" gorm:"comment:节目内容5"` } func (Program) TableName() string { return "dev_program" } func (p Program) CreateProgram() error { return global.GVA_DB.Create(&p).Error } func (p Program) UpdateProgram() error { return global.GVA_DB.Model(&Program{}).Where("id = ?", p.ID).Updates(&p).Error }