2023-11-25 18:17:31 +08:00
|
|
|
import{B as z,C as Q,R as W,S as X,w as Y,D as Z,H as ee,I as te,J as ae,G as oe,K as le}from"./element-plus.c4a2af8a.js";import{_ as ie}from"./index.vue_vue_type_script_setup_true_lang.2a46e71f.js";import{_ as ue}from"./index.vue_vue_type_script_setup_true_lang.23d19169.js";import{_ as ne}from"./index.vue_vue_type_script_setup_true_lang.d8a052c5.js";import{u as se}from"./vue-router.12d45bc3.js";import{u as re}from"./usePaging.160b82b8.js";import{u as me}from"./useDictOptions.9319430e.js";import{_ as pe,a as de,b as _e}from"./edit.vue_vue_type_script_setup_true_name_monitorAlarmEdit_lang.a586ccb3.js";import{t as ce,f as fe}from"./index.2b468485.js";import{d as x,s as ve,r as C,$ as k,af as Be,o as m,c as V,a as v,U as e,L as o,M as T,u,K as B,R as De,V as A,a7 as ye,T as be,k as ge,S as D}from"./@vue.e8706010.js";import"./@vueuse.1e5a6e21.js";import"./@element-plus.196c7323.js";import"./lodash-es.29c53eac.js";import"./dayjs.ff93117e.js";import"./axios.eb055ccc.js";import"./async-validator.fb49d0f5.js";import"./@ctrl.82a509e0.js";import"./@popperjs.36402333.js";import"./escape-html.e5dfadb9.js";import"./normalize-wheel-es.8aeb3683.js";import"./index.2c826b32.js";import"./lodash.ec5da75f.js";import"./pinia.dfca86b4.js";import"./vue-demi.ebc8116b.js";import"./css-color-function.31dc130b.js";import"./color.b6d632a4.js";import"./clone.7a47b02c.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./debug.3a33898e.js";import"./ms.a9ae1d6d.js";import"./nprogress.fa64f2fc.js";import"./vue-clipboard3.be0dfeee.js";import"./clipboard.824ba320.js";import"./echarts.8d7a50ae.js";import"./zrender.1084fa23.js";import"./tslib.60310f1a.js";import"./highlight.js.4ebdf9a4.js";import"./@highlightjs.2cdc8407.js";const Ce=D("\u67E5\u8BE2"),Ee=D("\u91CD\u7F6E"),he={class:"mt-4"},we=D(" \u8BE6\u60C5 "),Fe=D(" \u5220\u9664 "),ke={class:"flex mt-4 justify-end"},Ve=x({name:"monitorAlarmLists"}),Bt=x({...Ve,setup(Te){const{query:I}=se(),S=ve(),E=C(!1);var y=I.device_id;typeof y>"u"&&(y="");const n=k({device_id:y,type:"",start_time:"",end_time:""}),$=C([]),R=l=>{$.value=l.map(({id:a})=>a)},{dictData:r}=me("alarm_type"),{pager:p,getLists:d,resetParams:U,resetPage:L}=re({fetchFun:de,params:n}),b=C(!1),s=k({gridData:[{}]}),M=l=>{s.gridData=[{}];let a="";for(const _ in r.alarm_type)r.alarm_type[_].value==l.type&&(a=r.alarm_type[_].name);s.gridData.unshift({item:"\u89E3\u51B3\u65B9\u6848",value:l.solution}),s.gridData.unshift({item:"\u62A5\u8B66\u6570\u503C",value:l.value}),s.gridData.unshift({item:"\u62A5\u8B66\u5185\u5BB9",value:l.content}),s.gridData.unshift({item:"\u76D1\u6D4B\u7C7B\u578B",value:a}),s.gridData.unshift({item:"\u8BBE\u5907\u540D\u79F0",value:l.device.name}),s.gridData.unshift({item:"\u8BBE\u5907ID",value:l.device_id}),b.value=!0},N=async l=>{await fe.confirm("\u786E\u5B9A\u8981\u5220\u9664\uFF1F"),await _e({id:l}),d()};return d(),(l,a)=>{const _=z,c=Q,h=W,P=X,q=ne,f=Y,K=Z,w=ee,i=te,j=ue,F=ae,G=ie,H=oe,J=Be("perms"),O=le;return m(),V(A,null,[v("div",null,[e(w,{class:"!border-none mb-4",shadow:"never"},{default:o(()=>[e(K,{class:"mb-[-16px]",model:n,inline:""},{default:o(()=>[e(c,{label:"\u8BBE\u5907ID",prop:"device_id"},{default:o(()=>[e(_,{class:"w-[280px]",modelValue:n.device_id,"onUpdate:modelValue":a[0]||(a[0]=t=>n.device_id=t),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u8BBE\u5907ID"},null,8,["modelValue"])]),_:1}),e(c,{label:"\u76D1\u6D4B\u7C7B\u578B",prop:"type"},{default:o(()=>[e(P,{class:"w-[280px]",modelValue:n.type,"onUpdate:modelValue":a[1]||(a[1]=t=>n.type=t),clearable:"",placeholder:"\u8BF7\u9009\u62E9\u76D1\u6D4B\u7C7B\u578B"},{default:o(()=>[e(h,{label:"\u5168\u90E8",value:""}),(m(!0),V(A,null,ye(u(r).alarm_type,(t,g)=>(m(),B(h,{key:g,label:t.name,value:t.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),e(c,{label:"\u521B\u5EFA\u65F6\u95F4",prop:"create_time"},{default:o(()=>[e(q,{startTime:n.start_time,"onUpdate:startTime":a[2]||(a[2]=t=>n.start_time=t),endTime:n.end_time,"onUpdate:endTime":a[3]||
|