🐛 fix(bookSource): 短剧搜索结果字段归一化
- video_data 字段与 book_data 完全不同(title/series_id/cover/video_detail.actor),name 规则取 book_name 为空导致搜索 0 结果 - bookList 中将短剧项归一化为书籍结构:book_id←series_id(已验证走通 detail/catalog)、book_name←title、封面←cover、作者←演员
This commit is contained in:
1 parent
8afa152e39
commit
29ee0b3c46
1 file changed
+2
-2
+2
-2
@@ -11,13 +11,13 @@
|
|||||||
"enabledExplore": true,
|
"enabledExplore": true,
|
||||||
"header": "{\"User-Agent\": \"Mozilla/5.0 (Linux; Android 13; 2210132C Build/TP1A.220624.014; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/116.0.5845.92 Mobile Safari/537.36\"}",
|
"header": "{\"User-Agent\": \"Mozilla/5.0 (Linux; Android 13; 2210132C Build/TP1A.220624.014; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/116.0.5845.92 Mobile Safari/537.36\"}",
|
||||||
"jsLib": "// ============ 源变量配置(照光遇模式:defaultConfig 兜底,全 try-catch) ============\nconst defaultConfig = {\n 模式: \"小说\",\n 音色: \"0\",\n 清晰度: \"max\",\n 段评: \"开\",\n 图片: \"保留\"\n};\n\nconst fqVarsKey = 'fq_vars';\n\nfunction getVariable(k) {\n if (k == undefined) k = \"\";\n var parsed = {};\n try {\n var raw = String(cache.get(fqVarsKey) || '');\n if (raw) parsed = JSON.parse(raw);\n } catch (e) {}\n if (k == \"\") return parsed;\n var value = parsed[k];\n if (value == undefined) value = defaultConfig[k];\n return value != undefined ? value : \"\";\n}\n\nfunction setVariable(k, v, t) {\n if (t == undefined) t = true;\n var parsed = {};\n try {\n var raw = String(cache.get(fqVarsKey) || '');\n if (raw) parsed = JSON.parse(raw);\n } catch (e) {}\n parsed[k] = v;\n try { cache.put(fqVarsKey, JSON.stringify(parsed)); } catch (e) {}\n if (t) java.toast('\\n设置 ' + k + ' 为 ' + v);\n}\n\n// 发现页筛选按钮回调:存变量并刷新发现页\nfunction show(m, t) {\n setVariable(t, m, false);\n java.toast('\\n已设置' + t + ':' + m + '\\n已在书架的书切换模式后需刷新目录');\n try { java.refreshExplore(); } catch (e) {}\n}\n\nfunction createFilter(title, chars, defaultVal, paramKey, size, viewName) {\n if (viewName == undefined) viewName = \"'请选择类型'\";\n return {\n title: title,\n type: \"select\",\n chars: chars,\n default: defaultVal,\n \"viewName\": viewName,\n action: `show(infoMap['${title}'],'${paramKey}')`,\n style: {\n layout_flexGrow: 1,\n layout_flexBasisPercent: size\n }\n };\n}\n\n// ============ 基础工具 ============\nfunction BaseUrl() {\n var u = '';\n try {\n if (typeof source != 'undefined' && source && source.getKey) u = String(source.getKey());\n } catch (e) {}\n if (!u) {\n try {\n if (typeof book != 'undefined' && book && book.origin) u = String(book.origin);\n } catch (e) {}\n }\n if (!u) {\n try {\n if (typeof baseUrl != 'undefined') {\n var m = String(baseUrl).match(/^https?:\\/\\/[^\\/]+/);\n if (m) u = m[0];\n }\n } catch (e) {}\n }\n return u.replace(/\\/+$/, '');\n}\n\nfunction request(url) {\n let urla = url;\n if (!url.includes('http')) urla = this.BaseUrl() + url;\n return java.ajax(urla);\n}\n\nfunction parseJsonSafely(str, defaultValue) {\n if (defaultValue == null) defaultValue = null;\n try {\n return JSON.parse(str);\n } catch (e) {\n return defaultValue;\n }\n}\n\nfunction isIOS() {\n try {\n java.deviceID();\n return true;\n } catch (e) {\n return false;\n }\n}\n\nfunction isMod() {\n try {\n if (typeof java.reLoginView == 'function') return true;\n new Packages.io.legato.kazusa.utils.TimeoutCancellationException('');\n return true;\n } catch (e) {\n return false;\n }\n}\n\n// 纯 JS base64(UTF-8),规避部分阅读版本 base64 编码 API 不可用\nfunction b64encode(str) {\n var chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';\n var bytes = [];\n str = String(str);\n for (var i = 0; i < str.length; i++) {\n var c = str.charCodeAt(i);\n if (c < 0x80) {\n bytes.push(c);\n } else if (c < 0x800) {\n bytes.push(0xC0 | (c >> 6), 0x80 | (c & 63));\n } else {\n bytes.push(0xE0 | (c >> 12), 0x80 | ((c >> 6) & 63), 0x80 | (c & 63));\n }\n }\n var out = '';\n for (var j = 0; j < bytes.length; j += 3) {\n var b1 = bytes[j];\n var b2 = j + 1 < bytes.length ? bytes[j + 1] : undefined;\n var b3 = j + 2 < bytes.length ? bytes[j + 2] : undefined;\n out += chars[b1 >> 2];\n out += chars[((b1 & 3) << 4) | (b2 == undefined ? 0 : b2 >> 4)];\n out += b2 == undefined ? '=' : chars[((b2 & 15) << 2) | (b3 == undefined ? 0 : b3 >> 6)];\n out += b3 == undefined ? '=' : chars[b3 & 63];\n }\n return out;\n}\n\n// ============ 段评气泡(/content?review=keep 注入 <comment> 标记,点击打开 /review_html 页面) ============\nfunction createSvg(number, url) {\n var t = number > 99 ? '99+' : String(number);\n var svg = `<svg xmlns='http://www.w3.org/2000/svg' width='100' height='90' viewBox='0 0 25 17' fill='none'><path stroke='currentColor' stroke-width='1.00' stroke-linecap='round' stroke-linejoin='round' stroke-miterlimit='4.00' style='stroke:#A7A7A7;stroke-opacity:0.5;stroke-width:1px;stroke-linejoin:round;fill:transparent;fill-opacity:0.5;' d='M 7.5 0.5 L 16.5 0.5 A 7 7 0 0 1 23.5 7.5 L 23.5 7.5 A 7 7 0 0 1 16.5 14.5 L 8.5 14.5 L 5.192 16.5 L 5.5 14.5 A 7 7 30 0 1 0.5 7.5 L 0.5 7.5 A 7 7 0 0 1 7.5 0Line truncated
|
"jsLib": "// ============ 源变量配置(照光遇模式:defaultConfig 兜底,全 try-catch) ============\nconst defaultConfig = {\n 模式: \"小说\",\n 音色: \"0\",\n 清晰度: \"max\",\n 段评: \"开\",\n 图片: \"保留\"\n};\n\nconst fqVarsKey = 'fq_vars';\n\nfunction getVariable(k) {\n if (k == undefined) k = \"\";\n var parsed = {};\n try {\n var raw = String(cache.get(fqVarsKey) || '');\n if (raw) parsed = JSON.parse(raw);\n } catch (e) {}\n if (k == \"\") return parsed;\n var value = parsed[k];\n if (value == undefined) value = defaultConfig[k];\n return value != undefined ? value : \"\";\n}\n\nfunction setVariable(k, v, t) {\n if (t == undefined) t = true;\n var parsed = {};\n try {\n var raw = String(cache.get(fqVarsKey) || '');\n if (raw) parsed = JSON.parse(raw);\n } catch (e) {}\n parsed[k] = v;\n try { cache.put(fqVarsKey, JSON.stringify(parsed)); } catch (e) {}\n if (t) java.toast('\\n设置 ' + k + ' 为 ' + v);\n}\n\n// 发现页筛选按钮回调:存变量并刷新发现页\nfunction show(m, t) {\n setVariable(t, m, false);\n java.toast('\\n已设置' + t + ':' + m + '\\n已在书架的书切换模式后需刷新目录');\n try { java.refreshExplore(); } catch (e) {}\n}\n\nfunction createFilter(title, chars, defaultVal, paramKey, size, viewName) {\n if (viewName == undefined) viewName = \"'请选择类型'\";\n return {\n title: title,\n type: \"select\",\n chars: chars,\n default: defaultVal,\n \"viewName\": viewName,\n action: `show(infoMap['${title}'],'${paramKey}')`,\n style: {\n layout_flexGrow: 1,\n layout_flexBasisPercent: size\n }\n };\n}\n\n// ============ 基础工具 ============\nfunction BaseUrl() {\n var u = '';\n try {\n if (typeof source != 'undefined' && source && source.getKey) u = String(source.getKey());\n } catch (e) {}\n if (!u) {\n try {\n if (typeof book != 'undefined' && book && book.origin) u = String(book.origin);\n } catch (e) {}\n }\n if (!u) {\n try {\n if (typeof baseUrl != 'undefined') {\n var m = String(baseUrl).match(/^https?:\\/\\/[^\\/]+/);\n if (m) u = m[0];\n }\n } catch (e) {}\n }\n return u.replace(/\\/+$/, '');\n}\n\nfunction request(url) {\n let urla = url;\n if (!url.includes('http')) urla = this.BaseUrl() + url;\n return java.ajax(urla);\n}\n\nfunction parseJsonSafely(str, defaultValue) {\n if (defaultValue == null) defaultValue = null;\n try {\n return JSON.parse(str);\n } catch (e) {\n return defaultValue;\n }\n}\n\nfunction isIOS() {\n try {\n java.deviceID();\n return true;\n } catch (e) {\n return false;\n }\n}\n\nfunction isMod() {\n try {\n if (typeof java.reLoginView == 'function') return true;\n new Packages.io.legato.kazusa.utils.TimeoutCancellationException('');\n return true;\n } catch (e) {\n return false;\n }\n}\n\n// 纯 JS base64(UTF-8),规避部分阅读版本 base64 编码 API 不可用\nfunction b64encode(str) {\n var chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';\n var bytes = [];\n str = String(str);\n for (var i = 0; i < str.length; i++) {\n var c = str.charCodeAt(i);\n if (c < 0x80) {\n bytes.push(c);\n } else if (c < 0x800) {\n bytes.push(0xC0 | (c >> 6), 0x80 | (c & 63));\n } else {\n bytes.push(0xE0 | (c >> 12), 0x80 | ((c >> 6) & 63), 0x80 | (c & 63));\n }\n }\n var out = '';\n for (var j = 0; j < bytes.length; j += 3) {\n var b1 = bytes[j];\n var b2 = j + 1 < bytes.length ? bytes[j + 1] : undefined;\n var b3 = j + 2 < bytes.length ? bytes[j + 2] : undefined;\n out += chars[b1 >> 2];\n out += chars[((b1 & 3) << 4) | (b2 == undefined ? 0 : b2 >> 4)];\n out += b2 == undefined ? '=' : chars[((b2 & 15) << 2) | (b3 == undefined ? 0 : b3 >> 6)];\n out += b3 == undefined ? '=' : chars[b3 & 63];\n }\n return out;\n}\n\n// ============ 段评气泡(/content?review=keep 注入 <comment> 标记,点击打开 /review_html 页面) ============\nfunction createSvg(number, url) {\n var t = number > 99 ? '99+' : String(number);\n var svg = `<svg xmlns='http://www.w3.org/2000/svg' width='100' height='90' viewBox='0 0 25 17' fill='none'><path stroke='currentColor' stroke-width='1.00' stroke-linecap='round' stroke-linejoin='round' stroke-miterlimit='4.00' style='stroke:#A7A7A7;stroke-opacity:0.5;stroke-width:1px;stroke-linejoin:round;fill:transparent;fill-opacity:0.5;' d='M 7.5 0.5 L 16.5 0.5 A 7 7 0 0 1 23.5 7.5 L 23.5 7.5 A 7 7 0 0 1 16.5 14.5 L 8.5 14.5 L 5.192 16.5 L 5.5 14.5 A 7 7 30 0 1 0.5 7.5 L 0.5 7.5 A 7 7 0 0 1 7.5 0Line truncated
|
||||||
"lastUpdateTime": 1791568829218,
|
"lastUpdateTime": 1791569042509,
|
||||||
"respondTime": 180000,
|
"respondTime": 180000,
|
||||||
"exploreUrl": "<js>\nvar groups = {\"🔥 男频精选\": [{\"title\": \"玄幻\", \"url\": \"/category-landing?category_id=7&offset={{(page-1)*20}}\"}, {\"title\": \"都市\", \"url\": \"/category-landing?category_id=1&offset={{(page-1)*20}}\"}, {\"title\": \"历史\", \"url\": \"/category-landing?category_id=12&offset={{(page-1)*20}}\"}, {\"title\": \"悬疑\", \"url\": \"/category-landing?category_id=10&offset={{(page-1)*20}}\"}, {\"title\": \"衍生\", \"url\": \"/category-landing?category_id=1079&offset={{(page-1)*20}}\"}, {\"title\": \"同人\", \"url\": \"/category-landing?category_id=538&offset={{(page-1)*20}}\"}, {\"title\": \"科幻末世\", \"url\": \"/category-landing?category_id=8&offset={{(page-1)*20}}\"}, {\"title\": \"奇幻仙侠\", \"url\": \"/category-landing?category_id=259&offset={{(page-1)*20}}\"}, {\"title\": \"种田\", \"url\": \"/category-landing?category_id=23&offset={{(page-1)*20}}\"}, {\"title\": \"游戏体育\", \"url\": \"/category-landing?category_id=746&offset={{(page-1)*20}}\"}, {\"title\": \"系统\", \"url\": \"/category-landing?category_id=19&offset={{(page-1)*20}}\"}, {\"title\": \"重生\", \"url\": \"/category-landing?category_id=36&offset={{(page-1)*20}}\"}, {\"title\": \"穿越\", \"url\": \"/category-landing?category_id=37&offset={{(page-1)*20}}\"}, {\"title\": \"多女主\", \"url\": \"/category-landing?category_id=91&offset={{(page-1)*20}}\"}, {\"title\": \"修仙\", \"url\": \"/category-landing?category_id=517&offset={{(page-1)*20}}\"}, {\"title\": \"二次元\", \"url\": \"/category-landing?category_id=39&offset={{(page-1)*20}}\"}, {\"title\": \"搞笑轻松\", \"url\": \"/category-landing?category_id=778&offset={{(page-1)*20}}\"}, {\"title\": \"单女主\", \"url\": \"/category-landing?category_id=389&offset={{(page-1)*20}}\"}, {\"title\": \"悬疑灵异\", \"url\": \"/category-landing?category_id=751&offset={{(page-1)*20}}\"}, {\"title\": \"末日求生\", \"url\": \"/category-landing?category_id=515&offset={{(page-1)*20}}\"}, {\"title\": \"娱乐圈\", \"url\": \"/category-landing?category_id=43&offset={{(page-1)*20}}\"}, {\"title\": \"末世\", \"url\": \"/category-landing?category_id=68&offset={{(page-1)*20}}\"}], \"🌸 女频精选\": [{\"title\": \"现代言情\", \"url\": \"/category-landing?category_id=3&offset={{(page-1)*20}}\"}, {\"title\": \"古代言情\", \"url\": \"/category-landing?category_id=5&offset={{(page-1)*20}}\"}, {\"title\": \"纯爱\", \"url\": \"/category-landing?category_id=1012&offset={{(page-1)*20}}\"}, {\"title\": \"甜宠\", \"url\": \"/category-landing?category_id=96&offset={{(page-1)*20}}\"}, {\"title\": \"总裁\", \"url\": \"/category-landing?category_id=29&offset={{(page-1)*20}}\"}, {\"title\": \"幻想言情\", \"url\": \"/category-landing?category_id=32&offset={{(page-1)*20}}\"}, {\"title\": \"双男主\", \"url\": \"/category-landing?category_id=275&offset={{(page-1)*20}}\"}, {\"title\": \"双女主\", \"url\": \"/category-landing?category_id=704&offset={{(page-1)*20}}\"}, {\"title\": \"年代\", \"url\": \"/category-landing?category_id=79&offset={{(page-1)*20}}\"}, {\"title\": \"快穿\", \"url\": \"/category-landing?category_id=24&offset={{(page-1)*20}}\"}, {\"title\": \"豪门总裁\", \"url\": \"/category-landing?category_id=748&offset={{(page-1)*20}}\"}, {\"title\": \"追妻火葬场\", \"url\": \"/category-landing?category_id=616&offset={{(page-1)*20}}\"}, {\"title\": \"无CP\", \"url\": \"/category-landing?category_id=392&offset={{(page-1)*20}}\"}, {\"title\": \"大女主\", \"url\": \"/category-landing?category_id=760&offset={{(page-1)*20}}\"}, {\"title\": \"女强\", \"url\": \"/category-landing?category_id=86&offset={{(page-1)*20}}\"}], \"🏷️ 男频标签\": [{\"title\": \"古代\", \"url\": \"/category-landing?category_id=758&offset={{(page-1)*20}}\"}, {\"title\": \"历史古代\", \"url\": \"/category-landing?category_id=273&offset={{(page-1)*20}}\"}, {\"title\": \"轻小说\", \"url\": \"/category-landing?category_id=858&offset={{(page-1)*20}}\"}, {\"title\": \"都市生活\", \"url\": \"/category-landing?category_id=2&offset={{(page-1)*20}}\"}, {\"title\": \"都市高武\", \"url\": \"/category-landing?category_id=1014&offset={{(page-1)*20}}\"}, {\"title\": \"游戏动漫\", \"url\": \"/category-landing?category_id=57&offset={{(page-1)*20}}\"}, {\"title\": \"抗战谍战\", \"url\": \"/category-landing?category_id=504&offset={{(page-1)*20}}\"}, {\"title\": \"体育\", \"url\": \"/category-landing?category_id=15&offset={{(page-1)*20}}\"}, {\"title\": \"都市异能\", \"url\": \"/category-landing?category_id=516&offset={{(page-1)*20}}\"}, {\"title\": \"武侠\", \"url\": \"/category-landing?category_id=16&offset={{(page-1)*20}}\"}, {\"title\": \"东方仙侠\", \"url\": \"/category-landing?category_id=1140&offset={{(page-1)*20}}\"}, {\"title\": \"东方玄幻\", \"url\": \"/category-landing?category_id=511&offset={{(page-1)*20}}\"}, {\"title\": \"男频衍生\", \"url\": \"/category-landing?categorLine truncated
|
"exploreUrl": "<js>\nvar groups = {\"🔥 男频精选\": [{\"title\": \"玄幻\", \"url\": \"/category-landing?category_id=7&offset={{(page-1)*20}}\"}, {\"title\": \"都市\", \"url\": \"/category-landing?category_id=1&offset={{(page-1)*20}}\"}, {\"title\": \"历史\", \"url\": \"/category-landing?category_id=12&offset={{(page-1)*20}}\"}, {\"title\": \"悬疑\", \"url\": \"/category-landing?category_id=10&offset={{(page-1)*20}}\"}, {\"title\": \"衍生\", \"url\": \"/category-landing?category_id=1079&offset={{(page-1)*20}}\"}, {\"title\": \"同人\", \"url\": \"/category-landing?category_id=538&offset={{(page-1)*20}}\"}, {\"title\": \"科幻末世\", \"url\": \"/category-landing?category_id=8&offset={{(page-1)*20}}\"}, {\"title\": \"奇幻仙侠\", \"url\": \"/category-landing?category_id=259&offset={{(page-1)*20}}\"}, {\"title\": \"种田\", \"url\": \"/category-landing?category_id=23&offset={{(page-1)*20}}\"}, {\"title\": \"游戏体育\", \"url\": \"/category-landing?category_id=746&offset={{(page-1)*20}}\"}, {\"title\": \"系统\", \"url\": \"/category-landing?category_id=19&offset={{(page-1)*20}}\"}, {\"title\": \"重生\", \"url\": \"/category-landing?category_id=36&offset={{(page-1)*20}}\"}, {\"title\": \"穿越\", \"url\": \"/category-landing?category_id=37&offset={{(page-1)*20}}\"}, {\"title\": \"多女主\", \"url\": \"/category-landing?category_id=91&offset={{(page-1)*20}}\"}, {\"title\": \"修仙\", \"url\": \"/category-landing?category_id=517&offset={{(page-1)*20}}\"}, {\"title\": \"二次元\", \"url\": \"/category-landing?category_id=39&offset={{(page-1)*20}}\"}, {\"title\": \"搞笑轻松\", \"url\": \"/category-landing?category_id=778&offset={{(page-1)*20}}\"}, {\"title\": \"单女主\", \"url\": \"/category-landing?category_id=389&offset={{(page-1)*20}}\"}, {\"title\": \"悬疑灵异\", \"url\": \"/category-landing?category_id=751&offset={{(page-1)*20}}\"}, {\"title\": \"末日求生\", \"url\": \"/category-landing?category_id=515&offset={{(page-1)*20}}\"}, {\"title\": \"娱乐圈\", \"url\": \"/category-landing?category_id=43&offset={{(page-1)*20}}\"}, {\"title\": \"末世\", \"url\": \"/category-landing?category_id=68&offset={{(page-1)*20}}\"}], \"🌸 女频精选\": [{\"title\": \"现代言情\", \"url\": \"/category-landing?category_id=3&offset={{(page-1)*20}}\"}, {\"title\": \"古代言情\", \"url\": \"/category-landing?category_id=5&offset={{(page-1)*20}}\"}, {\"title\": \"纯爱\", \"url\": \"/category-landing?category_id=1012&offset={{(page-1)*20}}\"}, {\"title\": \"甜宠\", \"url\": \"/category-landing?category_id=96&offset={{(page-1)*20}}\"}, {\"title\": \"总裁\", \"url\": \"/category-landing?category_id=29&offset={{(page-1)*20}}\"}, {\"title\": \"幻想言情\", \"url\": \"/category-landing?category_id=32&offset={{(page-1)*20}}\"}, {\"title\": \"双男主\", \"url\": \"/category-landing?category_id=275&offset={{(page-1)*20}}\"}, {\"title\": \"双女主\", \"url\": \"/category-landing?category_id=704&offset={{(page-1)*20}}\"}, {\"title\": \"年代\", \"url\": \"/category-landing?category_id=79&offset={{(page-1)*20}}\"}, {\"title\": \"快穿\", \"url\": \"/category-landing?category_id=24&offset={{(page-1)*20}}\"}, {\"title\": \"豪门总裁\", \"url\": \"/category-landing?category_id=748&offset={{(page-1)*20}}\"}, {\"title\": \"追妻火葬场\", \"url\": \"/category-landing?category_id=616&offset={{(page-1)*20}}\"}, {\"title\": \"无CP\", \"url\": \"/category-landing?category_id=392&offset={{(page-1)*20}}\"}, {\"title\": \"大女主\", \"url\": \"/category-landing?category_id=760&offset={{(page-1)*20}}\"}, {\"title\": \"女强\", \"url\": \"/category-landing?category_id=86&offset={{(page-1)*20}}\"}], \"🏷️ 男频标签\": [{\"title\": \"古代\", \"url\": \"/category-landing?category_id=758&offset={{(page-1)*20}}\"}, {\"title\": \"历史古代\", \"url\": \"/category-landing?category_id=273&offset={{(page-1)*20}}\"}, {\"title\": \"轻小说\", \"url\": \"/category-landing?category_id=858&offset={{(page-1)*20}}\"}, {\"title\": \"都市生活\", \"url\": \"/category-landing?category_id=2&offset={{(page-1)*20}}\"}, {\"title\": \"都市高武\", \"url\": \"/category-landing?category_id=1014&offset={{(page-1)*20}}\"}, {\"title\": \"游戏动漫\", \"url\": \"/category-landing?category_id=57&offset={{(page-1)*20}}\"}, {\"title\": \"抗战谍战\", \"url\": \"/category-landing?category_id=504&offset={{(page-1)*20}}\"}, {\"title\": \"体育\", \"url\": \"/category-landing?category_id=15&offset={{(page-1)*20}}\"}, {\"title\": \"都市异能\", \"url\": \"/category-landing?category_id=516&offset={{(page-1)*20}}\"}, {\"title\": \"武侠\", \"url\": \"/category-landing?category_id=16&offset={{(page-1)*20}}\"}, {\"title\": \"东方仙侠\", \"url\": \"/category-landing?category_id=1140&offset={{(page-1)*20}}\"}, {\"title\": \"东方玄幻\", \"url\": \"/category-landing?category_id=511&offset={{(page-1)*20}}\"}, {\"title\": \"男频衍生\", \"url\": \"/category-landing?categorLine truncated
|
||||||
"searchUrl": "<js>\nvar tab = getVariable('模式');\nvar m = String(key).match(/^([xtmdXTMD])[:::]/);\nvar q = String(key);\nif (m) {\n tab = {x: '小说', t: '听书', m: '漫画', d: '短剧'}[m[1].toLowerCase()];\n q = q.slice(2);\n}\njava.put('fq_search_tab', tab);\nvar typeMap = {'小说': 3, '听书': 2, '漫画': 8, '短剧': 11};\n`/search?query=${encodeURIComponent(q)}&tab_type=${typeMap[tab] || 3}&offset=${(page - 1) * 10}`;\n</js>",
|
"searchUrl": "<js>\nvar tab = getVariable('模式');\nvar m = String(key).match(/^([xtmdXTMD])[:::]/);\nvar q = String(key);\nif (m) {\n tab = {x: '小说', t: '听书', m: '漫画', d: '短剧'}[m[1].toLowerCase()];\n q = q.slice(2);\n}\njava.put('fq_search_tab', tab);\nvar typeMap = {'小说': 3, '听书': 2, '漫画': 8, '短剧': 11};\n`/search?query=${encodeURIComponent(q)}&tab_type=${typeMap[tab] || 3}&offset=${(page - 1) * 10}`;\n</js>",
|
||||||
"ruleSearch": {
|
"ruleSearch": {
|
||||||
"author": "author",
|
"author": "author",
|
||||||
"bookList": "<js>\nvar tab = java.get('fq_search_tab') || getVariable('模式');\nvar d = parseJsonSafely(result, {});\nvar list = [];\n(d.data || []).forEach(function (b) {\n (b.book_data || b.video_data || []).forEach(function (x) {\n x.fq_tab = tab;\n list.push(x);\n });\n});\nJSON.stringify({data: list});\n</js>$.data",
|
"bookList": "<js>\nvar tab = java.get('fq_search_tab') || getVariable('模式');\nvar d = parseJsonSafely(result, {});\nvar list = [];\n(d.data || []).forEach(function (b) {\n if (b.book_data) {\n b.book_data.forEach(function (x) {\n x.fq_tab = tab;\n list.push(x);\n });\n } else if (b.video_data) {\n // 短剧字段与书籍不同,归一化为 book_data 结构(book_id 用 series_id 走通 detail/catalog)\n b.video_data.forEach(function (v) {\n list.push({\n book_id: v.series_id || v.vid,\n book_name: v.title || v.raw_book_name,\n author: (v.video_detail && v.video_detail.actor) || '',\n thumb_url: v.cover || '',\n abstract: v.sub_title || '',\n category: v.sub_title || '',\n fq_tab: tab\n });\n });\n }\n});\nJSON.stringify({data: list});\n</js>$.data",
|
||||||
"bookUrl": "<js>\n'/detail?book_id=' + result.book_id + '&tab=' + (result.fq_tab || getVariable('模式'));\n</js>",
|
"bookUrl": "<js>\n'/detail?book_id=' + result.book_id + '&tab=' + (result.fq_tab || getVariable('模式'));\n</js>",
|
||||||
"checkKeyWord": "十日终焉",
|
"checkKeyWord": "十日终焉",
|
||||||
"coverUrl": "thumb_url",
|
"coverUrl": "thumb_url",
|
||||||
|
|||||||
Reference in new issue
Block a user