mirror of
https://github.com/ProudMuBai/GoFilm.git
synced 2026-02-21 10:04:41 +08:00
v2 Multiple play source
This commit is contained in:
@@ -20,6 +20,7 @@ type SearchInfo struct {
|
||||
Cid int64 `json:"cid"` //分类ID
|
||||
Pid int64 `json:"pid"` //上级分类ID
|
||||
Name string `json:"name"` // 片名
|
||||
SubTitle string `json:"subTitle"` // 影片子标题
|
||||
CName string `json:"CName"` // 分类名称
|
||||
ClassTag string `json:"classTag"` //类型标签
|
||||
Area string `json:"area"` // 地区
|
||||
@@ -44,8 +45,7 @@ type Page struct {
|
||||
}
|
||||
|
||||
func (s *SearchInfo) TableName() string {
|
||||
return "search_lz"
|
||||
//return "search_fs"
|
||||
return config.SearchTableName
|
||||
}
|
||||
|
||||
// ================================= Spider 数据处理(redis) =================================
|
||||
@@ -289,3 +289,11 @@ func GetRelateMovieBasicInfo(search SearchInfo, page *Page) []MovieBasicInfo {
|
||||
|
||||
return basicList
|
||||
}
|
||||
|
||||
// GetMultiplePlay 通过影片名hash值匹配播放源
|
||||
func GetMultiplePlay(siteName, key string) []MovieUrlInfo {
|
||||
data := db.Rdb.HGet(db.Cxt, fmt.Sprintf(config.MultipleSiteDetail, siteName), key).Val()
|
||||
var playList []MovieUrlInfo
|
||||
_ = json.Unmarshal([]byte(data), &playList)
|
||||
return playList
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user