// Code generated by db2go. DO NOT EDIT.
// https://github.com/civet148/sqlca

package models

const TableNameTag = "tag" //

const (
	TAG_COLUMN_ID           = "id"
	TAG_COLUMN_NAME         = "name"
	TAG_COLUMN_NAME_CN      = "name_cn"
	TAG_COLUMN_IS_INHERENT  = "is_inherent"
	TAG_COLUMN_IS_DELETED   = "is_deleted"
	TAG_COLUMN_CREATED_TIME = "created_time"
	TAG_COLUMN_UPDATED_TIME = "updated_time"
	TAG_COLUMN_EXTRA_DATA   = "extra_data"
)

type TagDO struct {
	Id          int64           `json:"id" db:"id" bson:"_id"`                                               //自增ID
	Name        string          `json:"name" db:"name" bson:"name"`                                          //标签名
	NameCn      string          `json:"name_cn" db:"name_cn" bson:"name_cn"`                                 //中文名
	IsInherent  bool            `json:"is_inherent" db:"is_inherent" bson:"is_inherent"`                     //是否为固有标签(0=否 1=是）
	IsDeleted   bool            `json:"is_deleted" db:"is_deleted" bson:"is_deleted"`                        //是否已删除(0=未删除 1=已删除)
	CreatedTime string          `json:"created_time" db:"created_time" sqlca:"readonly" bson:"created_time"` //创建时间
	UpdatedTime string          `json:"updated_time" db:"updated_time" sqlca:"readonly" bson:"updated_time"` //更新时间
	ExtraData   CommonExtraData `json:"extra_data" db:"extra_data" sqlca:"isnull" bson:"extra_data"`         //附带数据(JSON)
}

func (do *TagDO) GetId() int64                   { return do.Id }
func (do *TagDO) SetId(v int64)                  { do.Id = v }
func (do *TagDO) GetName() string                { return do.Name }
func (do *TagDO) SetName(v string)               { do.Name = v }
func (do *TagDO) GetNameCn() string              { return do.NameCn }
func (do *TagDO) SetNameCn(v string)             { do.NameCn = v }
func (do *TagDO) GetIsInherent() bool            { return do.IsInherent }
func (do *TagDO) SetIsInherent(v bool)           { do.IsInherent = v }
func (do *TagDO) GetIsDeleted() bool             { return do.IsDeleted }
func (do *TagDO) SetIsDeleted(v bool)            { do.IsDeleted = v }
func (do *TagDO) GetCreatedTime() string         { return do.CreatedTime }
func (do *TagDO) SetCreatedTime(v string)        { do.CreatedTime = v }
func (do *TagDO) GetUpdatedTime() string         { return do.UpdatedTime }
func (do *TagDO) SetUpdatedTime(v string)        { do.UpdatedTime = v }
func (do *TagDO) GetExtraData() CommonExtraData  { return do.ExtraData }
func (do *TagDO) SetExtraData(v CommonExtraData) { do.ExtraData = v }

/*
CREATE TABLE `tag` (
  `id` bigint NOT NULL AUTO_INCREMENT COMMENT '自增ID',
  `name` varchar(32) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '标签名',
  `name_cn` varchar(64) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '' COMMENT '中文名',
  `is_inherent` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否为固有标签(0=否 1=是）',
  `is_deleted` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否已删除(0=未删除 1=已删除)',
  `created_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
  `updated_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
  `extra_data` json DEFAULT NULL COMMENT '附带数据(JSON)',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
*/
