更新 'SrcLive.js'

master
src48597962 8 months ago
parent f86f917af1
commit 6c48dd69ba
  1. 95
      SrcLive.js

@ -350,38 +350,6 @@ function GroupEdit(groupname,mode,lists) {
}
function guanlidata(datalist) {
/*
function compare (attr,rev) {
if(rev == undefined){
rev = 1;
}else{
rev = (rev) ? 1 : -1;
}
return (a,b) => {
a = a[attr];
b = b[attr];
if(a.replace(/[^\d]/g, "")&&b.replace(/[^\d]/g, "")){
if(parseInt(a.replace(/[^\d]/g, "")) < parseInt(b.replace(/[^\d]/g, ""))){
return rev * -1;
}
if(parseInt(a.replace(/[^\d]/g, "")) > parseInt(b.replace(/[^\d]/g, ""))){
return rev * 1;
}
return 0;
}else{
if(a < b){
return rev * -1;
}
if(a > b){
return rev * 1;
}
return 0;
}
}
}
datalist = datalist.sort(compare('name',true));
*/
let list = [];
for (let i = 0; i < datalist.length; i++) {
let name = datalist[i].name;
@ -434,11 +402,6 @@ function LivePlay(name) {
var JYlives = [];
}
let urls = [];
/*
group-title="玩偶",一日女友的漂亮姐姐
https://ypmnkbb.saejeuj.com/api/app/media/m3u8/av/ph/gr/7v/78/af7b145ecae246b2ac79cecb6f47f6ad.m3u8?
*/
for (let i = 0; i < JYlives.length; i++) {
try {
if (JYlive.indexOf('#genre#') > -1) {
@ -573,12 +536,12 @@ function LiveSet() {
col_type: "line"
});
d.push({
title: '📺 订阅源管理',
title: "订阅源管理",
img: "https://hikerfans.com/juying/img/箭头.svg",
url: $('hiker://empty#noRecordHistory##noHistory#').rule(() => {
addListener("onClose", $.toString(() => {
//refreshPage(false);
}));
//setPageTitle("⚙直播设置⚙");
let livecfgfile = "hiker://files/rules/Src/Juying2/liveconfig.json";
let livecfg = fetch(livecfgfile);
if (livecfg != "") {
@ -788,11 +751,12 @@ function LiveSet() {
}
setHomeResult(d);
}),
col_type: "text_2"
col_type: "text_icon"
});
d.push({
title: '🎦 TVBox订阅',
col_type: 'text_2',
title: "TVBox订阅",
img: "https://hikerfans.com/juying/img/箭头.svg",
col_type: "text_icon",
url: $('hiker://empty#noRecordHistory##noHistory#').rule(() => {
addListener("onClose", $.toString(() => {
clearMyVar('importinput');
@ -971,39 +935,50 @@ function LiveSet() {
})
});
d.push({
col_type: "line"
col_type: "line",
});
d.push({
title: '🛠 编辑本地源',
col_type: 'text_2',
url: getMyVar('JYlivedyurl','juying')=="juying"?$('#noLoading#').lazyRule(() => {
if(getMyVar('JYlivenum','0')=="0"){
title: "编辑本地源",
img: "https://hikerfans.com/juying/img/箭头.svg",
col_type: "text_icon",
url:
getMyVar("JYlivedyurl", "juying") == "juying"
? $("#noLoading#").lazyRule(() => {
if (getMyVar("JYlivenum", "0") == "0") {
return "toast://本地数据源为空,无法进入编辑模式";
}
putMyVar('editmode','1');
putMyVar('isEdit','1');
putMyVar("editmode", "1");
putMyVar("isEdit", "1");
return "toast://进入编辑模式,长按分组或频道选择操作";
}):"toast://当前为远程订阅源,无法进入编辑模式"
})
: "toast://当前为远程订阅源,无法进入编辑模式",
});
d.push({
title: '♻ 清空直播源',
col_type: 'text_2',
title: "清空直播源",
img: "https://hikerfans.com/juying/img/箭头.svg",
col_type: "text_icon",
url: $("确定清空聚影直播本地文件?").confirm(() => {
writeFile(getMyVar('JY直播数据路径') + "live.txt", "");
if(getMyVar('JYlivedyurl','juying')=="juying"){
putMyVar('isEdit','1');
writeFile(getMyVar("JY直播数据路径") + "live.txt", "");
if (getMyVar("JYlivedyurl", "juying") == "juying") {
putMyVar("isEdit", "1");
}
clearMyVar('JYlivenum');
clearMyVar("JYlivenum");
refreshPage(false);
return "toast://已清空";
})
}),
});
d.push({
col_type: 'line'
col_type: "line_blank",
});
d.push({
title: "清理失效",
img: "https://hikerfans.com/juying/img/清理.svg",
col_type: "avatar",
url: "hiker://empty",
});
d.push({
title: '🔎清理失效的直播源地址',
desc: '此功能为实验性的,可能存在误删,谨慎操作!\n通过判断地址是否可以访问来甄别有效性\n聚影本地直播源地址有:'+getMyVar('JYlivenum','0'),
title: "‘‘实验功能可能存在误删,谨慎操作!’’",
desc: "通过判断地址是否可以访问来甄别有效性\n聚影本地直播源地址有:" + getMyVar("JYlivenum", "0"),
col_type: 'text_center_1',
url: $('#noLoading#').lazyRule(() => {
putMyVar('isEdit', '1');

Loading…
Cancel
Save