From af2223688b4a8e9487e66b3ad2a9e1e02c14c466 Mon Sep 17 00:00:00 2001 From: src48597962 <48597962@qq.com> Date: Wed, 2 Nov 2022 20:06:04 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=20'SrcJyXunmi.js'?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- SrcJyXunmi.js | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/SrcJyXunmi.js b/SrcJyXunmi.js index 34ccb7d8..5d3b5068 100644 --- a/SrcJyXunmi.js +++ b/SrcJyXunmi.js @@ -1171,6 +1171,39 @@ function xunmierji(type,ua) { } } setTabs(tabs, MY_URL); + //推送tvbox + let push = { + "name":MY_PARAMS.title||'聚影', + "pic":pic, + "content":desc + }; + d.push({ + title: '推送当前列表至TVBOX', + url: $("#noLoading#").lazyRule((push,list) => { + let oneurl = list[0].split('$')[1]; + if(/^http/.test(oneurl)){ + push['url'] = list.join('#').replace(/\&/g, '&&'); + var state = request('http://192.168.3.2:9978' + '/action', { + headers: { + 'Content-Type': 'application/x-www-form-urlencoded', + //'X-Requested-With': 'XMLHttpRequest', + 'Referer': 'http://192.168.3.2:9978' + }, + timeout: 2000, + body: 'do=push&url=' + JSON.stringify(push), + method: 'POST' + }); + //log(state); + if (state == 'ok') { + return 'toast://推送成功,如果tvbox显示“没找到数据”可能是该链接需要密码或者当前的jar不支持。'; + } else { + return 'toast://推送失败' + } + } + return 'toast://当前线路不支持推送选集列表'; + }, push, lists[parseInt(getMyVar(vari, '0'))]), + col_type: 'scroll_button' + }) //选集部份 function setLists(lists, index) {