Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
wchjxyzj
dr_py
提交
d88bcdc3
D
dr_py
项目概览
wchjxyzj
/
dr_py
与 Fork 源项目一致
Fork自
晚风拂柳颜 / dr_py
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
dr_py
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
d88bcdc3
编写于
9月 09, 2022
作者:
H
hjdhnx
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
修复了360正版源后面?带参数导致的解析失败问题(感谢antod提点)
上级
d5067902
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
25 addition
and
7 deletion
+25
-7
controllers/cms.py
controllers/cms.py
+1
-1
js/360影视.js
js/360影视.js
+3
-1
libs/pre.js
libs/pre.js
+16
-0
py/360二级.js
py/360二级.js
+3
-3
py/360二级.min.js
py/360二级.min.js
+2
-2
未找到文件。
controllers/cms.py
浏览文件 @
d88bcdc3
...
...
@@ -842,7 +842,7 @@ class CMS:
'list'
:
[]
}
logger
.
info
(
f
'
{
self
.
getName
()
}
获取详情页耗时:
{
get_interval
(
t1
)
}
毫秒,发生错误:
{
e
}
'
)
#
print(result)
print
(
result
)
return
result
def
searchContent
(
self
,
key
,
fypage
=
1
):
...
...
js/360影视.js
浏览文件 @
d88bcdc3
...
...
@@ -24,7 +24,8 @@ var rule = {
一级
:
'
json:data.movies;title;cover;pubdate;id;description
'
,
// 二级:{is_json:1,"title":"data.title;data.moviecategory[0]+data.moviecategory[1]","img":"data.cdncover","desc":"data.area[0];data.director[0]","content":"data.description","tabs":"data.playlink_sites;data.playlinksdetail.#idv.quality","lists":"data.playlinksdetail.#idv.default_url"},
// 二级:{is_json:1,"title":"data.title;data.moviecategory[0]+data.moviecategory[1]","img":"data.cdncover","desc":"data.area[0];data.director[0]","content":"data.description","tabs":"data.playlink_sites","lists":"data.playlinksdetail.#idv.default_url"},
二级
:
'
js:let html=JSON.parse(fetch(input,fetch_params));let data=html.data;let tilte=data.title;let img=data.cdncover;let vod_type=data.moviecategory.join(",");let area=data.area.join(",");let director=data.director.join(",");let actor=data.actor.join(",");let content=data.description;base_vod={vod_id:input,vod_name:tilte,type_name:vod_type,vod_actor:actor,vod_director:director,vod_content:content,vod_remarks:area,vod_pic:urljoin2(input,img)};let delta=200;let vod_play={};let sites=data.playlink_sites;for(let i in sites){let site=sites[i];let playList="";let vodItems=[];if(data.allupinfo){let total=parseInt(data.allupinfo[site]);for(let j=1;j<total;j+=delta){let end=Math.min(total,j+delta-1);let url2=buildUrl(input,{start:j,end:end,site:site});let vod_data=JSON.parse(fetch(url2),fetch_params).data;if(vod_data.allepidetail){vod_data=vod_data.allepidetail[site];vod_data.forEach(function(item,index){vodItems.push((item.playlink_num||"")+"$"+(item.url||""))})}else{vod_data=vod_data.defaultepisode;vod_data.forEach(function(item,index){vodItems.push((item.period||"")+(item.name||"")+"$"+item.url||"")})}}}else{let item=data.playlinksdetail[site];vodItems.push((item.sort||"")+"$"+(item.default_url||""))}if(vodItems.length>0){playList=vodItems.join("#")}if(playList.length<1){continue}vod_play[site]=playList}let tabs=Object.keys(vod_play);let playUrls=[];for(let id in tabs){playUrls.push(vod_play[tabs[id]])}if(tabs.length>0){vod_play_from=tabs.join("$$$");vod_play_url=playUrls.join("$$$");base_vod.vod_play_from=vod_play_from;base_vod.vod_play_url=vod_play_url}vod=base_vod;
'
,
二级
:
'
js:let html=JSON.parse(fetch(input,fetch_params));let data=html.data;let tilte=data.title;let img=data.cdncover;let vod_type=data.moviecategory.join(",");let area=data.area.join(",");let director=data.director.join(",");let actor=data.actor.join(",");let content=data.description;base_vod={vod_id:input,vod_name:tilte,type_name:vod_type,vod_actor:actor,vod_director:director,vod_content:content,vod_remarks:area,vod_pic:urljoin2(input,img)};let delta=200;let vod_play={};let sites=data.playlink_sites;for(let i in sites){let site=sites[i];let playList="";let vodItems=[];if(data.allupinfo){let total=parseInt(data.allupinfo[site]);for(let j=1;j<total;j+=delta){let end=Math.min(total,j+delta-1);let url2=buildUrl(input,{start:j,end:end,site:site});let vod_data=JSON.parse(fetch(url2),fetch_params).data;if(vod_data.allepidetail){vod_data=vod_data.allepidetail[site];vod_data.forEach(function(item,index){vodItems.push((item.playlink_num||"")+"$"+urlDeal(item.url||""))})}else{vod_data=vod_data.defaultepisode;vod_data.forEach(function(item,index){vodItems.push((item.period||"")+(item.name||"")+"$"+urlDeal(item.url)||"")})}}}else{let item=data.playlinksdetail[site];vodItems.push((item.sort||"")+"$"+urlDeal(item.default_url||""))}if(vodItems.length>0){playList=vodItems.join("#")}if(playList.length<1){continue}vod_play[site]=playList}let tabs=Object.keys(vod_play);let playUrls=[];for(let id in tabs){playUrls.push(vod_play[tabs[id]])}if(tabs.length>0){vod_play_from=tabs.join("$$$");vod_play_url=playUrls.join("$$$");base_vod.vod_play_from=vod_play_from;base_vod.vod_play_url=vod_play_url}vod=base_vod;
'
,
// 二级:'js:let html=JSON.parse(fetch(input,fetch_params));let data=html.data;let tilte=data.title;let img=data.cdncover;let vod_type=data.moviecategory.join(",");let area=data.area.join(",");let director=data.director.join(",");let actor=data.actor.join(",");let content=data.description;base_vod={vod_id:input,vod_name:tilte,type_name:vod_type,vod_actor:actor,vod_director:director,vod_content:content,vod_remarks:area,vod_pic:urljoin2(input,img)};let delta=200;let vod_play={};let sites=data.playlink_sites;for(let i in sites){let site=sites[i];let playList="";let vodItems=[];if(data.allupinfo){let total=parseInt(data.allupinfo[site]);for(let j=1;j<total;j+=delta){let end=Math.min(total,j+delta-1);let url2=buildUrl(input,{start:j,end:end,site:site});let vod_data=JSON.parse(fetch(url2),fetch_params).data;if(vod_data.allepidetail){vod_data=vod_data.allepidetail[site];vod_data.forEach(function(item,index){vodItems.push((item.playlink_num||"")+"$"+(item.url||""))})}else{vod_data=vod_data.defaultepisode;vod_data.forEach(function(item,index){vodItems.push((item.period||"")+(item.name||"")+"$"+item.url||"")})}}}else{let item=data.playlinksdetail[site];vodItems.push((item.sort||"")+"$"+(item.default_url||""))}if(vodItems.length>0){playList=vodItems.join("#")}if(playList.length<1){continue}vod_play[site]=playList}let tabs=Object.keys(vod_play);let playUrls=[];for(let id in tabs){playUrls.push(vod_play[tabs[id]])}if(tabs.length>0){vod_play_from=tabs.join("$$$");vod_play_url=playUrls.join("$$$");base_vod.vod_play_from=vod_play_from;base_vod.vod_play_url=vod_play_url}vod=base_vod;',
// 搜索:'json:data.longData.rows;titleTxt;cover;cat_name;cat_id+en_id;description',
搜索
:
'
json:data.longData.rows;titleTxt||titlealias;cover;cat_name;cat_id+en_id;description
'
,
}
\ No newline at end of file
libs/pre.js
浏览文件 @
d88bcdc3
...
...
@@ -81,6 +81,22 @@ Array.prototype.join = function (emoji) {
}
return
str
;
};
function
是否正版
(
vipUrl
){
let
flag
=
new
RegExp
(
'
qq
\
.com|iqiyi
\
.com|youku
\
.com|mgtv
\
.com|bilibili
\
.com|sohu
\
.com|ixigua
\
.com|pptv
\
.com|miguvideo
\
.com|le
\
.com|1905
\
.com|fun
\
.tv
'
);
return
flag
.
test
(
vipUrl
);
}
function
urlDeal
(
vipUrl
){
if
(
!
vipUrl
){
return
''
}
if
(
!
是否正版
(
vipUrl
)){
return
vipUrl
}
if
(
!
/miguvideo/
.
test
(
vipUrl
)){
vipUrl
=
vipUrl
.
split
(
'
#
'
)[
0
].
split
(
'
?
'
)[
0
];
}
return
vipUrl
}
function
setResult
(
d
){
if
(
!
Array
.
isArray
(
d
)){
return
[]
...
...
py/360二级.js
浏览文件 @
d88bcdc3
...
...
@@ -53,19 +53,19 @@ for(let i in sites){
if
(
vod_data
.
allepidetail
){
//电视剧或者动漫
vod_data
=
vod_data
.
allepidetail
[
site
];
vod_data
.
forEach
(
function
(
item
,
index
)
{
vodItems
.
push
((
item
.
playlink_num
||
""
)
+
"
$
"
+
(
item
.
url
||
""
));
vodItems
.
push
((
item
.
playlink_num
||
""
)
+
"
$
"
+
urlDeal
(
item
.
url
||
""
));
});
}
else
{
// 综艺
vod_data
=
vod_data
.
defaultepisode
;
vod_data
.
forEach
(
function
(
item
,
index
)
{
vodItems
.
push
((
item
.
period
||
""
)
+
(
item
.
name
||
""
)
+
"
$
"
+
item
.
url
||
""
);
vodItems
.
push
((
item
.
period
||
""
)
+
(
item
.
name
||
""
)
+
"
$
"
+
urlDeal
(
item
.
url
)
||
""
);
});
}
}
}
else
{
let
item
=
data
.
playlinksdetail
[
site
];
// print(item);
vodItems
.
push
((
item
.
sort
||
""
)
+
"
$
"
+
(
item
.
default_url
||
""
));
vodItems
.
push
((
item
.
sort
||
""
)
+
"
$
"
+
urlDeal
(
item
.
default_url
||
""
));
}
if
(
vodItems
.
length
>
0
){
playList
=
vodItems
.
join
(
"
#
"
);
...
...
py/360二级.min.js
浏览文件 @
d88bcdc3
js
:
let
html
=
JSON
.
parse
(
fetch
(
input
,
fetch_params
));
let
data
=
html
.
data
;
let
tilte
=
data
.
title
;
let
img
=
data
.
cdncover
;
let
vod_type
=
data
.
moviecategory
.
join
(
"
,
"
);
let
area
=
data
.
area
.
join
(
"
,
"
);
let
director
=
data
.
director
.
join
(
"
,
"
);
let
actor
=
data
.
actor
.
join
(
"
,
"
);
let
content
=
data
.
description
;
base_vod
=
{
vod_id
:
input
,
vod_name
:
tilte
,
type_name
:
vod_type
,
vod_actor
:
actor
,
vod_director
:
director
,
vod_content
:
content
,
vod_remarks
:
area
,
vod_pic
:
urljoin2
(
input
,
img
)};
let
delta
=
200
;
let
vod_play
=
{};
let
sites
=
data
.
playlink_sites
;
for
(
let
i
in
sites
){
let
site
=
sites
[
i
];
let
playList
=
""
;
let
vodItems
=
[];
if
(
data
.
allupinfo
){
let
total
=
parseInt
(
data
.
allupinfo
[
site
]);
for
(
let
j
=
1
;
j
<
total
;
j
+=
delta
){
let
end
=
Math
.
min
(
total
,
j
+
delta
-
1
);
let
url2
=
buildUrl
(
input
,{
start
:
j
,
end
:
end
,
site
:
site
});
let
vod_data
=
JSON
.
parse
(
fetch
(
url2
),
fetch_params
).
data
;
if
(
vod_data
.
allepidetail
){
vod_data
=
vod_data
.
allepidetail
[
site
];
vod_data
.
forEach
(
function
(
item
,
index
){
vodItems
.
push
((
item
.
playlink_num
||
""
)
+
"
$
"
+
(
item
.
url
||
""
))})}
else
{
vod_data
=
vod_data
.
defaultepisode
;
vod_data
.
forEach
(
function
(
item
,
index
){
vodItems
.
push
((
item
.
period
||
""
)
+
(
item
.
name
||
""
)
+
"
$
"
+
item
.
url
||
""
)})}}}
else
{
let
item
=
data
.
playlinksdetail
[
site
];
vodItems
.
push
((
item
.
sort
||
""
)
+
"
$
"
+
(
item
.
default_url
||
""
))}
if
(
vodItems
.
length
>
0
){
playList
=
vodItems
.
join
(
"
#
"
)}
if
(
playList
.
length
<
1
){
continue
}
vod_play
[
site
]
=
playList
}
let
tabs
=
Object
.
keys
(
vod_play
);
let
playUrls
=
[];
for
(
let
id
in
tabs
){
playUrls
.
push
(
vod_play
[
tabs
[
id
]])}
if
(
tabs
.
length
>
0
){
vod_play_from
=
tabs
.
join
(
"
$$$
"
);
vod_play_url
=
playUrls
.
join
(
"
$$$
"
);
base_vod
.
vod_play_from
=
vod_play_from
;
base_vod
.
vod_play_url
=
vod_play_url
}
vod
=
base_vod
;
\ No newline at end of file
js
:
let
html
=
JSON
.
parse
(
fetch
(
input
,
fetch_params
));
let
data
=
html
.
data
;
let
tilte
=
data
.
title
;
let
img
=
data
.
cdncover
;
let
vod_type
=
data
.
moviecategory
.
join
(
"
,
"
);
let
area
=
data
.
area
.
join
(
"
,
"
);
let
director
=
data
.
director
.
join
(
"
,
"
);
let
actor
=
data
.
actor
.
join
(
"
,
"
);
let
content
=
data
.
description
;
base_vod
=
{
vod_id
:
input
,
vod_name
:
tilte
,
type_name
:
vod_type
,
vod_actor
:
actor
,
vod_director
:
director
,
vod_content
:
content
,
vod_remarks
:
area
,
vod_pic
:
urljoin2
(
input
,
img
)};
let
delta
=
200
;
let
vod_play
=
{};
let
sites
=
data
.
playlink_sites
;
for
(
let
i
in
sites
){
let
site
=
sites
[
i
];
let
playList
=
""
;
let
vodItems
=
[];
if
(
data
.
allupinfo
){
let
total
=
parseInt
(
data
.
allupinfo
[
site
]);
for
(
let
j
=
1
;
j
<
total
;
j
+=
delta
){
let
end
=
Math
.
min
(
total
,
j
+
delta
-
1
);
let
url2
=
buildUrl
(
input
,{
start
:
j
,
end
:
end
,
site
:
site
});
let
vod_data
=
JSON
.
parse
(
fetch
(
url2
),
fetch_params
).
data
;
if
(
vod_data
.
allepidetail
){
vod_data
=
vod_data
.
allepidetail
[
site
];
vod_data
.
forEach
(
function
(
item
,
index
){
vodItems
.
push
((
item
.
playlink_num
||
""
)
+
"
$
"
+
urlDeal
(
item
.
url
||
""
))})}
else
{
vod_data
=
vod_data
.
defaultepisode
;
vod_data
.
forEach
(
function
(
item
,
index
){
vodItems
.
push
((
item
.
period
||
""
)
+
(
item
.
name
||
""
)
+
"
$
"
+
urlDeal
(
item
.
url
)
||
""
)})}}}
else
{
let
item
=
data
.
playlinksdetail
[
site
];
vodItems
.
push
((
item
.
sort
||
""
)
+
"
$
"
+
urlDeal
(
item
.
default_url
||
""
))}
if
(
vodItems
.
length
>
0
){
playList
=
vodItems
.
join
(
"
#
"
)}
if
(
playList
.
length
<
1
){
continue
}
vod_play
[
site
]
=
playList
}
let
tabs
=
Object
.
keys
(
vod_play
);
let
playUrls
=
[];
for
(
let
id
in
tabs
){
playUrls
.
push
(
vod_play
[
tabs
[
id
]])}
if
(
tabs
.
length
>
0
){
vod_play_from
=
tabs
.
join
(
"
$$$
"
);
vod_play_url
=
playUrls
.
join
(
"
$$$
"
);
base_vod
.
vod_play_from
=
vod_play_from
;
base_vod
.
vod_play_url
=
vod_play_url
}
vod
=
base_vod
;
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录