// Code generated by gorm.io/gen. DO NOT EDIT.
// Code generated by gorm.io/gen. DO NOT EDIT.
// Code generated by gorm.io/gen. DO NOT EDIT.

package model

import (
	"time"
)

const TableNameCache = "cache"

// Cache mapped from table <cache>
type Cache struct {
	ID        int64     `gorm:"column:id;type:bigint(20);primaryKey;autoIncrement:true" json:"id"`
	Key       string    `gorm:"column:key;type:varchar(255);not null;uniqueIndex:key,priority:1" json:"key"`
	Value     string    `gorm:"column:value;type:json" json:"value"`
	ExpiAt    int64     `gorm:"column:expi_at;type:bigint(20)" json:"expi_at"`     // 过期时间
	CreatedAt time.Time `gorm:"column:created_at;type:datetime" json:"created_at"` // 创建时间
}

// TableName Cache's table name
func (*Cache) TableName() string {
	return TableNameCache
}
