更新 'SrcJuSet.js'

Ju
src48597962 1 year ago
parent 8b336d87af
commit 676e73e87a
  1. 29
      SrcJuSet.js

@ -550,7 +550,7 @@ function SRCSet() {
setResult(d); setResult(d);
} }
function jiekouapi(sourcefile, data) { function jiekouapi(sourcefile, data, look) {
addListener("onClose", $.toString(() => { addListener("onClose", $.toString(() => {
clearMyVar('SrcJu_jiekoudata'); clearMyVar('SrcJu_jiekoudata');
clearMyVar('SrcJu_jiekouname'); clearMyVar('SrcJu_jiekouname');
@ -648,7 +648,7 @@ function jiekouapi(sourcefile, data) {
titleVisible: false, titleVisible: false,
type: "textarea", type: "textarea",
highlight: true, highlight: true,
height: 2, height: 3,
onChange: $.toString(() => { onChange: $.toString(() => {
if (/{|}/.test(input) || !input) { if (/{|}/.test(input) || !input) {
storage0.putMyVar("SrcJu_jiekouerparse", input) storage0.putMyVar("SrcJu_jiekouerparse", input)
@ -665,7 +665,7 @@ function jiekouapi(sourcefile, data) {
titleVisible: false, titleVisible: false,
type: "textarea", type: "textarea",
highlight: true, highlight: true,
height: 1, height: 2,
onChange: $.toString(() => { onChange: $.toString(() => {
if (/{|}/.test(input) || !input) { if (/{|}/.test(input) || !input) {
storage0.putMyVar("SrcJu_jiekoupublic", input) storage0.putMyVar("SrcJu_jiekoupublic", input)
@ -683,6 +683,7 @@ function jiekouapi(sourcefile, data) {
} }
}); });
} }
if(!look){
d.push({ d.push({
title: '测试搜索', title: '测试搜索',
col_type: 'text_2', col_type: 'text_2',
@ -821,6 +822,7 @@ function jiekouapi(sourcefile, data) {
} }
}, sourcefile,data?data.type:"",runModes) }, sourcefile,data?data.type:"",runModes)
}); });
}
setResult(d); setResult(d);
} }
@ -884,19 +886,20 @@ function JYimport(input) {
datalist3.forEach(item=>{ datalist3.forEach(item=>{
d.push({ d.push({
title: (item.stop?`<font color=#f20c00>`:"") + item.name + (item.parse ? " [主页源]" : "") + (item.erparse ? " [搜索源]" : "") + (item.stop?`</font>`:""), title: (item.stop?`<font color=#f20c00>`:"") + item.name + (item.parse ? " [主页源]" : "") + (item.erparse ? " [搜索源]" : "") + (item.stop?`</font>`:""),
url: getMyVar('SrcJu_批量选择模式')?$('#noLoading#').lazyRule((data) => { url: $(["查看导入", "查看本地", "覆盖导入", "改名导入"], 2).select((sourcefile, data) => {
data = JSON.parse(base64Decode(data)); data = JSON.parse(base64Decode(data));
require(config.依赖.match(/http(s)?:\/\/.*\//)[0] + 'SrcJuMethod.js'); if (input == "查看本地") {
duoselect(data); return $('hiker://empty#noRecordHistory##noHistory#').rule((sourcefile, dataid) => {
return "hiker://empty"; require(config.依赖.match(/http(s)?:\/\/.*\//)[0] + 'SrcJuSet.js');
},base64Encode(JSON.stringify(item))):$(["编辑", "删除", "改名"], 2).select((sourcefile, data) => { let data = datalist.filter(d => d.name == dataid.name && d.type==dataid.type)[0];
data = JSON.parse(base64Decode(data)); jiekouapi(sourcefile, data, 1);
if (input == "编辑") { }, sourcefile, {type:item.type, name:item.name})
}else if (input == "查看导入") {
return $('hiker://empty#noRecordHistory##noHistory#').rule((sourcefile, data) => { return $('hiker://empty#noRecordHistory##noHistory#').rule((sourcefile, data) => {
setPageTitle('编辑 | 聚阅接口'); //setPageTitle('查看导入 | 聚阅接口');
require(config.依赖.match(/http(s)?:\/\/.*\//)[0] + 'SrcJuSet.js'); require(config.依赖.match(/http(s)?:\/\/.*\//)[0] + 'SrcJuSet.js');
jiekouapi(sourcefile, JSON.parse(base64Decode(data))); jiekouapi(sourcefile, data, 1);
}, sourcefile, base64Encode(JSON.stringify(data))) }, sourcefile, data)
} else if (input == "删除") { } else if (input == "删除") {
return $("确定删除:"+data.name).confirm((sourcefile,data)=>{ return $("确定删除:"+data.name).confirm((sourcefile,data)=>{
let sourcedata = fetch(sourcefile); let sourcedata = fetch(sourcefile);

Loading…
Cancel
Save