Documentation ¶
Index ¶
- Constants
- func KeyThirdp(typeC string) (key string, err error)
- type Dao
- func (d *Dao) DBeiPages(ctx context.Context, req *thirdp.ReqDBeiPages) (sids []int64, myLast int64, err error)
- func (d *Dao) GetSnCnt(c context.Context, isPGC bool, sid int64) (cnt int, err error)
- func (d *Dao) GetThirdpCnt(c context.Context, typeC string) (count int, err error)
- func (d *Dao) LoadPageID(c context.Context, req *thirdp.ReqDBeiPages) (biggestID int64, err error)
- func (d *Dao) LoadSnCnt(ctx context.Context, isPGC bool, sid int64) (cnt int, err error)
- func (d *Dao) MangoOrder(c context.Context) (s []int64, err error)
- func (d *Dao) MangoPages(ctx context.Context, req *thirdp.ReqDBeiPages) (sids []*thirdp.RespSid, myLast int64, err error)
- func (d *Dao) MangoRecom(c context.Context, ids []int64) (data []*model.MangoRecom, err error)
- func (d *Dao) MangoSnCnt(ctx context.Context, isPGC bool, sid int64) (cnt int, err error)
- func (d *Dao) MangoSnOffset(ctx context.Context, isPGC bool, sid int64, pageN, pagesize int) (epids []*thirdp.RespSid, err error)
- func (d *Dao) SetPageID(c context.Context, req *thirdp.ReqPageID) (err error)
- func (d *Dao) SetSnCnt(c context.Context, isPGC bool, sid int64, cnt int) (err error)
- func (d *Dao) SetThirdpCnt(c context.Context, count int, typeC string) (err error)
- func (d *Dao) ThirdpCnt(ctx context.Context, typeC string) (count int, err error)
Constants ¶
View Source
const ( // DBeiPGC is dangbei pgc typeC DBeiPGC = "pgc" // DBeiUGC is dangbei ugc typeC DBeiUGC = "ugc" )
View Source
const ( // MangoPGC is mango pgc typeC MangoPGC = "mango_pgc" // MangoUGC is mango ugc typeC MangoUGC = "mango_ugc" )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Dao ¶
type Dao struct {
// contains filtered or unexported fields
}
Dao .
func (*Dao) DBeiPages ¶
func (d *Dao) DBeiPages(ctx context.Context, req *thirdp.ReqDBeiPages) (sids []int64, myLast int64, err error)
DBeiPages picks a page for dangbei api, lastID is the last page's biggest ID
func (*Dao) GetThirdpCnt ¶
GetThirdpCnt get dangbei pgc data count
func (*Dao) LoadPageID ¶
LoadPageID picks the last page's biggest ID
func (*Dao) MangoOrder ¶
MangoOrder gets mango recom data.
func (*Dao) MangoPages ¶
func (d *Dao) MangoPages(ctx context.Context, req *thirdp.ReqDBeiPages) (sids []*thirdp.RespSid, myLast int64, err error)
MangoPages picks a page for dangbei api, lastID is the last page's biggest ID
func (*Dao) MangoRecom ¶
MangoRecom picks the mango recom data from DB
func (*Dao) MangoSnCnt ¶
MangoSnCnt counts ep/video number from DB
func (*Dao) MangoSnOffset ¶
func (d *Dao) MangoSnOffset(ctx context.Context, isPGC bool, sid int64, pageN, pagesize int) (epids []*thirdp.RespSid, err error)
MangoSnOffset picks season or arc's detail info by page ( limit + offset )
func (*Dao) SetPageID ¶
SetPageID is used to record each dangbei page's biggest ID, it's to ease the next page's pickup
func (*Dao) SetThirdpCnt ¶
SetThirdpCnt is used to record dangbei pgc data count
Click to show internal directories.
Click to hide internal directories.