← Back
Editing: index493.js
import{u as t,n as e,L as a,l,k as o,j as n,b as i,p as s,K as r}from"./utils-lib.js?v=VERSION_NUMBER";import{_ as c}from"./index117.js?v=VERSION_NUMBER";import{_ as p}from"./index103.js?v=VERSION_NUMBER";import{c as d,r as u,k as m,e as _,B as f,p as w,G as h,q as y,v as b,x as g,M as v,A as j,H as k,y as V,P,D as x,a9 as D,a7 as E}from"./base-lib.js?v=VERSION_NUMBER";import{_ as C}from"./index123.js?v=VERSION_NUMBER";import{d as A,u as O}from"./column.js?v=VERSION_NUMBER";import{getSingleSiteContentMonitorList as S,searchFiles as T,delContentMonitorInfo as R,scanning as I}from"./site.js?v=VERSION_NUMBER";import{u as L}from"./useStore4.js?v=VERSION_NUMBER";import"./__commonjsHelpers__.js?v=VERSION_NUMBER";import"./validator.js?v=VERSION_NUMBER";import"./index104.js?v=VERSION_NUMBER";const F={class:"p-[20px]"},U={class:"p-[20px]"},q=d({__name:"index",props:{compData:{default:{}}},setup(d){const{siteInfo:q}=L(),H=i(),{payment:J}=t(),N=u([]),B=u(!1),G=m({word:""}),K=u([A(),{label:"违规词",prop:"key"}]),M=u([]),z=u(!1),Q=u(!1),W=u(!1),X=u(),Y=m({title:"违规词检测-功能介绍",ps:"违规词检测能帮助检测网站内容中的合法及非法字段,并输出对应的检测结果,利用图表充分展示各个域名的风险历史、检测情况、敏感词排行等,并实时输出风险动态。",source:111,desc:["违规词内容检测","网页内容修改检测","输出检测报告"],tabImgs:[{title:"概览",imgSrc:"https://www.bt.cn/Public/new/plugin/introduce/firewall/content_detect_detail_1.png"},{title:"监控列表",imgSrc:"https://www.bt.cn/Public/new/plugin/introduce/firewall/content_detect_detail_2.png"},{title:"检测历史",imgSrc:"https://www.bt.cn/Public/new/plugin/introduce/firewall/content_detect_detail_3.png"},{title:"风险列表",imgSrc:"https://www.bt.cn/Public/new/plugin/introduce/firewall/content_detect_detail_4.png"},{title:"检测报告",imgSrc:"https://www.bt.cn/Public/new/plugin/introduce/firewall/content_detect_detail_5.png"}]}),Z=async()=>{if("ltd"===J.value.authType){B.value=!0;try{const t=await S({site_name:q.value.name});N.value=t.data}catch(t){}finally{B.value=!1}}},$=async()=>{tt({...q.value,id:!1})},tt=t=>{e({title:"".concat(t.id?"编辑":"添加","监控").concat(t.id?"【".concat(t.name,"】"):""),area:68,showFooter:!0,compData:{...t,refreshEvent:Z,isSite:!0},component:()=>a((()=>import("./add-monitor2.js?v=VERSION_NUMBER")),__vite__mapDeps([]),import.meta.url)})},et=()=>{e({isAsync:!0,title:"自定义词库",area:[44,39],component:()=>a((()=>import("./own-thesaurus2.js?v=VERSION_NUMBER")),__vite__mapDeps([]),import.meta.url)})},at=()=>{e({isAsync:!0,title:"检测历史",area:80,component:()=>a((()=>import("./detect-history.js?v=VERSION_NUMBER")),__vite__mapDeps([]),import.meta.url),compData:{isPopup:!0,...q.value}})},lt=()=>{e({isAsync:!0,title:"风险列表",area:80,component:()=>a((()=>import("./risk-list.js?v=VERSION_NUMBER")),__vite__mapDeps([]),import.meta.url),compData:{isPopup:!0}})},ot=()=>{var t;null==(t=X.value)||t.resetFields(),Q.value=!1},nt=async()=>{let t=H.load("正在扫描,请稍后...");try{const t=await T({search:G.word,path:q.value.path});M.value=t.data.result.map((t=>({path:t.name,key:G.word}))),ot(),W.value=!0}catch(e){}finally{Q.value=!1,t.close()}},it=u([{label:"监控名称",prop:"name",showOverflowTooltip:!0},{label:"网站/URL",prop:"url"},{label:"状态",prop:"content",render:t=>{if(1===t.crontab_status)return"正常"}},{label:"发送告警",prop:"send_msg",render:t=>1===t.send_msg?_("span",{class:"text-primary"},[f("已开启")]):"未开启"},{label:"检测频率",prop:"crontab_info.cycle",showOverflowTooltip:!0},O([{onClick:async t=>{try{const l=H.load("正在检测,请稍后..."),o=await I({data:JSON.stringify({id:t.id})}),n={name:t.name,id:t.id,path_info:o.data.path_info};l.close(),e({title:"检测日志",area:[64,50],btn:["停止检测"],component:()=>a((()=>import("./scan-details2.js?v=VERSION_NUMBER")),__vite__mapDeps([]),import.meta.url),compData:n,showFooter:!0})}catch(l){}},title:"检测"},{onClick:t=>{tt(t)},title:"编辑"},{onClick:async t=>{await s({title:"删除违规词检测",content:"删除后无法继续监控该网站,是否继续?"}),r({loading:"正在删除,请稍后...",request:R({data:JSON.stringify({id:t.id})}),message:!0,success:t=>{t.status&&Z()}})},title:"删除"}])]);return w((()=>{Z()})),(t,e)=>{const a=x,i=C,s=l,r=o,d=D,u=E,m=n,w=p,A=c,O=h("bt-loading");return y(),b("div",null,["ltd"===g(J).authType?(y(),v(w,{key:0},{"header-left":j((()=>[_(a,{type:"primary",onClick:$},{default:j((()=>e[4]||(e[4]=[f("添加监控")]))),_:1}),_(a,{type:"default",onClick:e[0]||(e[0]=t=>Q.value=!0)},{default:j((()=>e[5]||(e[5]=[f(" 自定义扫描 ")]))),_:1}),_(a,{type:"default",onClick:et},{default:j((()=>e[6]||(e[6]=[f(" 自定义词库 ")]))),_:1}),_(a,{type:"default",onClick:at},{default:j((()=>e[7]||(e[7]=[f(" 检测历史 ")]))),_:1}),_(a,{type:"default",onClick:lt},{default:j((()=>e[8]||(e[8]=[f("风险列表")]))),_:1})])),"header-right":j((()=>[_(i,{onRefresh:Z})])),content:j((()=>[k(_(s,{column:g(it),data:g(N)},null,8,["column","data"]),[[O,g(B)]])])),popup:j((()=>[_(m,{title:"自定义扫描",modelValue:g(Q),"onUpdate:modelValue":e[2]||(e[2]=t=>P(Q)?Q.value=t:null),area:42,onConfirm:nt,onCancel:ot,showFooter:""},{default:j((()=>[V("div",F,[_(u,{"label-position":"right",model:g(G),ref_key:"scanRef",ref:X},{default:j((()=>[_(d,{label:"扫描违规词",prop:"word"},{default:j((()=>[_(r,{modelValue:g(G).word,"onUpdate:modelValue":e[1]||(e[1]=t=>g(G).word=t),placeholder:"请输入要扫描的词汇",width:"24rem"},null,8,["modelValue"])])),_:1})])),_:1},8,["model"])])])),_:1},8,["modelValue"]),_(m,{title:"扫描结果",modelValue:g(W),"onUpdate:modelValue":e[3]||(e[3]=t=>P(W)?W.value=t:null),area:52},{default:j((()=>[V("div",U,[_(w,null,{content:j((()=>[k(_(s,{column:g(K),data:g(M),"max-height":400},null,8,["column","data"]),[[O,g(z)]])])),_:1})])])),_:1},8,["modelValue"])])),_:1})):(y(),v(A,{key:1,data:g(Y),class:""},null,8,["data"]))])}}});export{q as default}; function __vite__mapDeps(indexes) { if (!__vite__mapDeps.viteFileDeps) { __vite__mapDeps.viteFileDeps = [] } return indexes.map((i) => __vite__mapDeps.viteFileDeps[i]) }
Save File
Cancel