Documentation ¶
Index ¶
- type FirstCategory
- type SecondCategory
- type ThirdCategory
- type VtbDB
- func (vdb *VtbDB) Close() error
- func (vdb *VtbDB) GetAllFirstCategoryMessage() string
- func (vdb *VtbDB) GetAllSecondCategoryMessageByFirstIndex(firstIndex int) string
- func (vdb *VtbDB) GetAllThirdCategoryMessageByFirstIndexAndSecondIndex(firstIndex, secondIndex int) string
- func (vdb *VtbDB) GetFirstCategoryByFirstUid(firstUid string) FirstCategory
- func (vdb *VtbDB) GetThirdCategory(firstIndex, secondIndex, thirdIndex int) ThirdCategory
- func (vdb *VtbDB) GetVtbList() (uidList []string)
- func (vdb *VtbDB) RandomVtb() ThirdCategory
- func (vdb *VtbDB) StoreVtb(uid string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FirstCategory ¶
type FirstCategory struct { gorm.Model FirstCategoryIndex int64 `gorm:"column:first_category_index"` FirstCategoryName string `gorm:"column:first_category_name"` FirstCategoryUid string `gorm:"column:first_category_uid"` FirstCategoryDescription string `gorm:"column:first_category_description;type:varchar(1024)"` FirstCategoryIconPath string `gorm:"column:first_category_icon_path"` }
FirstCategory 第一品类
func (FirstCategory) TableName ¶
func (FirstCategory) TableName() string
type SecondCategory ¶
type SecondCategory struct { gorm.Model SecondCategoryIndex int64 `gorm:"column:second_category_index"` FirstCategoryUid string `gorm:"column:first_category_uid;association_foreignkey:first_category_uid"` SecondCategoryName string `gorm:"column:second_category_name"` SecondCategoryAuthor string `gorm:"column:second_category_author"` SecondCategoryDescription string `gorm:"column:second_category_description"` }
SecondCategory 第二品类
func (SecondCategory) TableName ¶
func (SecondCategory) TableName() string
type ThirdCategory ¶
type ThirdCategory struct { gorm.Model ThirdCategoryIndex int64 `gorm:"column:third_category_index"` SecondCategoryIndex int64 `gorm:"column:second_category_index"` FirstCategoryUid string `gorm:"column:first_category_uid"` ThirdCategoryName string `gorm:"column:third_category_name"` ThirdCategoryPath string `gorm:"column:third_category_path"` ThirdCategoryAuthor string `gorm:"column:third_category_author"` ThirdCategoryDescription string `gorm:"column:third_category_description"` }
ThirdCategory 第三品类
func (ThirdCategory) TableName ¶
func (ThirdCategory) TableName() string
type VtbDB ¶
func Initialize ¶
func (*VtbDB) GetAllFirstCategoryMessage ¶
GetAllFirstCategoryMessage 取出所有vtb
func (*VtbDB) GetAllSecondCategoryMessageByFirstIndex ¶
GetAllSecondCategoryMessageByFirstIndex 取得同一个vtb所有语录类别
func (*VtbDB) GetAllThirdCategoryMessageByFirstIndexAndSecondIndex ¶
func (vdb *VtbDB) GetAllThirdCategoryMessageByFirstIndexAndSecondIndex(firstIndex, secondIndex int) string
GetAllThirdCategoryMessageByFirstIndexAndSecondIndex 取得同一个vtb同个类别的所有语录
func (*VtbDB) GetFirstCategoryByFirstUid ¶
func (vdb *VtbDB) GetFirstCategoryByFirstUid(firstUid string) FirstCategory
func (*VtbDB) GetThirdCategory ¶
func (vdb *VtbDB) GetThirdCategory(firstIndex, secondIndex, thirdIndex int) ThirdCategory
GetThirdCategory
func (*VtbDB) GetVtbList ¶
func (*VtbDB) RandomVtb ¶
func (vdb *VtbDB) RandomVtb() ThirdCategory
Click to show internal directories.
Click to hide internal directories.