← Back
Editing: index496.js
import{u as t,o as e,K as a,n as l,l as o,k as n,b as i,q as s,J as r}from"./utils-lib.js?v=VERSION_NUMBER";import{_ as c}from"./index118.js?v=VERSION_NUMBER";import{_ as p}from"./index105.js?v=VERSION_NUMBER";import{c as d,r as u,h as m,e as _,y as f,o as w,B as h,k as y,l as b,p as g,J as v,x as j,C as k,q as V,M as P,A as x,a7 as C,a4 as E}from"./base-lib.js?v=VERSION_NUMBER";import{_ as D}from"./index124.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"./useStore5.js?v=VERSION_NUMBER";import"./__commonjsHelpers__.js?v=VERSION_NUMBER";import"./validator.js?v=VERSION_NUMBER";import"./index106.js?v=VERSION_NUMBER";const F={class:"p-[20px]"},J={class:"p-[20px]"},U=d({__name:"index",props:{compData:{default:{}}},setup(d){const{siteInfo:U}=L(),q=i(),{payment:N}=t(),B=u([]),H=u(!1),K=m({word:""}),M=u([A(),{label:"违规词",prop:"key"}]),z=u([]),G=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"===N.value.authType){H.value=!0;try{const t=await S({site_name:U.value.name});B.value=t.data}catch(t){}finally{H.value=!1}}},$=async()=>{tt({...U.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,...U.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=q.load("正在扫描,请稍后...");try{const t=await T({search:K.word,path:U.value.path});z.value=t.data.result.map((t=>({path:t.name,key:K.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=q.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=D,s=l,r=o,d=C,u=E,m=n,w=p,A=c,O=h("bt-loading");return y(),b("div",null,["ltd"===g(N).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(B)},null,8,["column","data"]),[[O,g(H)]])])),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(K),ref_key:"scanRef",ref:X},{default:j((()=>[_(d,{label:"扫描违规词",prop:"word"},{default:j((()=>[_(r,{modelValue:g(K).word,"onUpdate:modelValue":e[1]||(e[1]=t=>g(K).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",J,[_(w,null,{content:j((()=>[k(_(s,{column:g(M),data:g(z),"max-height":400},null,8,["column","data"]),[[O,g(G)]])])),_:1})])])),_:1},8,["modelValue"])])),_:1})):(y(),v(A,{key:1,data:g(Y),class:""},null,8,["data"]))])}}});export{U as default}; function __vite__mapDeps(indexes) { if (!__vite__mapDeps.viteFileDeps) { __vite__mapDeps.viteFileDeps = [] } return indexes.map((i) => __vite__mapDeps.viteFileDeps[i]) }
Save File
Cancel