From 2fff0794b446aac136641c7db6381c3353af7dce Mon Sep 17 00:00:00 2001 From: hjdhnx Date: Wed, 19 Oct 2022 10:43:04 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=8E=9F=E5=A7=8Bjs=E6=B5=8B?= =?UTF-8?q?=E8=AF=95=E6=A1=88=E4=BE=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- base/custom.conf | 3 + "txt/js/\345\216\237\345\247\213JS.js" | 90 ++++++++++++++++++++++++++ 2 files changed, 93 insertions(+) create mode 100644 "txt/js/\345\216\237\345\247\213JS.js" diff --git a/base/custom.conf b/base/custom.conf index 4c4b426..6524494 100644 --- a/base/custom.conf +++ b/base/custom.conf @@ -20,6 +20,9 @@ "filterable":0 }, # 缓存js +# {"key":"js_origin","name":"JS(原始)","type":3,"api":"{{host}}/txt/js/原始JS.js","searchable":1,"quickSearch":1,"filterable":1,"ext":""}, + {"key":"js_origin_puto","name":"原始JS(pluto)","type":3,"api":"js_origin_test","searchable":1,"quickSearch":1,"filterable":1,"ext":"{{host}}/txt/js/原始JS.js"}, + {"key":"js_origin_tvb","name":"原始JS(俊tvb)","type":3,"api":"{{host}}/txt/js/原始JS.js","searchable":1,"quickSearch":1,"filterable":1,"ext":"{}"}, {"key":"drpy_zbk","name":"真不卡(drpy)","type":3,"api":"js_drpy_zbk","searchable":1,"quickSearch":1,"filterable":1,"ext":"{{host}}/txt/pluto/drpy.js"}, {"key": "dr_MXONE", "name": "MXONE(道长)", "type": 1, "api": "{{host}}/vod?rule=MXONE&ext=txt/js/tg/MXONE.js", "searchable": 2, "quickSearch": 0, "filterable": 0}, {"key": "dr_Nike影视", "name": "Nike影视(道长)", "type": 1, "api": "{{host}}/vod?rule=Nike影视&ext=txt/js/tg/Nike影视.js", "searchable": 2, "quickSearch": 0, "filterable": 0}, diff --git "a/txt/js/\345\216\237\345\247\213JS.js" "b/txt/js/\345\216\237\345\247\213JS.js" new file mode 100644 index 0000000..d6c8209 --- /dev/null +++ "b/txt/js/\345\216\237\345\247\213JS.js" @@ -0,0 +1,90 @@ +function init(ext) { + console.log('init'); +} + +function home(filter) { + console.log("home"); + let classes = []; + classes.push({ + 'type_id': 'test', + 'type_name': '测试分类' + }); + let res = { + 'class': classes + }; + return JSON.stringify(res); +} + +function homeVod(params) { + console.log("homeVod"); + let d = []; + d.push({ + vod_name:'测试', + vod_id:'index.html', + vod_pic:'https://gitee.com/CherishRx/imagewarehouse/raw/master/image/13096725fe56ce9cf643a0e4cd0c159c.gif', + vod_remarks:'原始JS', + }); + return JSON.stringify({ + list:d + }) +} + +function category(tid, pg, filter, extend) { + console.log("category"); + let d = []; + d.push({ + vod_name:'测试', + vod_id:'index.html', + vod_pic:'https://gitee.com/CherishRx/imagewarehouse/raw/master/image/13096725fe56ce9cf643a0e4cd0c159c.gif', + vod_remarks:'类型:'+tid, + }); + return JSON.stringify({ + list:d + }) +} + +function detail(vod_url) { + console.log("detail"); + let vod = { + // vod_id:id, + vod_name:'测试二级', + type_name:vod_url, + vod_pic:'https://gitee.com/CherishRx/imagewarehouse/raw/master/image/13096725fe56ce9cf643a0e4cd0c159c.gif', + vod_content:'这是一个原始js的测试案例', + vod_play_from:'测试线路1$$$测试线路2', + vod_play_url:'选集播放1$1.mp4#选集播放2$2.mp4$$$选集播放3$3.mp4#选集播放4$4.mp4', + }; + return JSON.stringify({ + list: [vod] + }) +} + +function play(flag, id, flags) { + console.log("play"); + return '{}' +} + +function search(wd, quick) { + console.log("search"); + let d = []; + d.push({ + vod_name:wd, + vod_id:'index.html', + vod_pic:'https://gitee.com/CherishRx/imagewarehouse/raw/master/image/13096725fe56ce9cf643a0e4cd0c159c.gif', + vod_remarks:'测试搜索', + }); + return JSON.stringify({ + list:d + }) +} + +// 导出函数对象 +export default { + init: init, + home: home, + homeVod: homeVod, + category: category, + detail: detail, + play: play, + search: search, +} \ No newline at end of file -- GitLab