From 40da78b9d06cce9f426922301bfbbef07d464dbe Mon Sep 17 00:00:00 2001 From: hjdhnx Date: Sat, 17 Sep 2022 19:46:49 +0800 Subject: [PATCH] =?UTF-8?q?drpy=E6=98=BE=E7=A4=BA=E7=9C=9F=E5=AE=9E?= =?UTF-8?q?=E6=9D=A5=E6=BA=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- base/rules.db | Bin 40960 -> 40960 bytes controllers/cms.py | 10 ++++++---- controllers/vod.py | 4 +++- js/version.txt | 2 +- readme.md | 1 + 5 files changed, 11 insertions(+), 6 deletions(-) diff --git a/base/rules.db b/base/rules.db index 3380ecfd2188f6a8cbef7cb938bfb791ec9409d0..aa53453a8600abd82c8fb517567065af4199f7e7 100644 GIT binary patch delta 90 zcmZoTz|?SnX@WE(<3t%}M#hZ^xx$V{hGu3K<_5+lCZ-mK7D*OqNy(NL#%7i#1}2F{ usflK`DMm@D7HKKTh9-%YNhy|=mIg+qmgb2TiKzw_CKkrYoB2dObprrp1Q}%j delta 90 zcmV~$u^B)x5C%{TprK<3$>s7#q3~IRyF_OPy@pYI7BG_uytlu_{uXDGXIDGr**$O7 txQ4|?15X{(!a;~7C_6RL`b2_3(4%LY*h7sa)zwL2%MpnHho`K+;|G348H@k` diff --git a/controllers/cms.py b/controllers/cms.py index ff6614a..c846477 100644 --- a/controllers/cms.py +++ b/controllers/cms.py @@ -763,7 +763,7 @@ class CMS: return result - def detailOneVod(self,id,fyclass=''): + def detailOneVod(self,id,fyclass='',show_name=False): detailUrl = str(id) vod = {} if not detailUrl.startswith('http') and not '/' in detailUrl: @@ -780,7 +780,7 @@ class CMS: vod['vod_play_from'] = '道长在线' vod['vod_remarks'] = detailUrl vod['vod_actor'] = '没有二级,只有一级链接直接嗅探播放' - vod['vod_content'] = url + vod['vod_content'] = url if not show_name else f'({self.id}) {url}' vod['vod_play_url'] = '嗅探播放$'+self.play_url+url print(vod) return vod @@ -958,9 +958,11 @@ class CMS: # print(vod_play_url) except Exception as e: logger.info(f'{self.getName()}获取单个详情页{detailUrl}出错{e}') + if show_name: + vod['vod_content'] = f'({self.id}){vod.get("vod_content","")}' return vod - def detailContent(self, fypage, array): + def detailContent(self, fypage, array,show_name=False): """ cms二级数据 :param array: @@ -978,7 +980,7 @@ class CMS: tmp = vod_url.split('$') vod_class = tmp[0] vod_url = tmp[1] - obj = thread_pool.submit(self.detailOneVod, vod_url,vod_class) + obj = thread_pool.submit(self.detailOneVod, vod_url,vod_class,show_name) obj_list.append(obj) thread_pool.shutdown(wait=True) # 等待所有子线程并行完毕 vod_list = [obj.result() for obj in obj_list] diff --git a/controllers/vod.py b/controllers/vod.py index e28c092..f201733 100644 --- a/controllers/vod.py +++ b/controllers/vod.py @@ -222,11 +222,13 @@ def vod_home(): return jsonify(data) if ac and ids: # 二级 id_list = ids.split(',') + show_name = False if ids.find('#') > -1: id_list = list(map(lambda x:x.split('#')[0],id_list)) + show_name = True # print('app:377',len(id_list)) # print(id_list) - data = cms.detailContent(pg,id_list) + data = cms.detailContent(pg,id_list,show_name) # print(data) return jsonify(data) if wd: # 搜索 diff --git a/js/version.txt b/js/version.txt index 81c117c..a7b0839 100644 --- a/js/version.txt +++ b/js/version.txt @@ -1 +1 @@ -3.6.12 \ No newline at end of file +3.6.13 \ No newline at end of file diff --git a/readme.md b/readme.md index 6f86395..21b03e5 100644 --- a/readme.md +++ b/readme.md @@ -49,6 +49,7 @@ ###### 2022/09/17 - [X] 1.pluto1.5.1最新beta版支持drpy首页推荐点击跳drpy内部聚搜(原理同T4) - [X] 2.pluto1.5.1最新beta版支持searchable为2的源忽略参与聚搜,正常单一搜索 +- [X] 3.drpy源增加内部聚搜进入二级详情页的简介签名备注真实来源规则名 ###### 2022/09/16 - [X] 1.规则headers合并优化 - [X] 2.基础js功能修复,如pdfh,request,Object.keys -- GitLab