import{L as y,w as B,M as T,I as V,N as L}from"./element-plus.7a22678c.js";import{_ as P}from"./index.vue_vue_type_script_setup_true_lang.cabb2d32.js";import{u as N}from"./usePaging.2a59f422.js";import{a as R}from"./useDictOptions.f8827d58.js";import{_ as S,a as $}from"./edit.vue_vue_type_script_setup_true_name_monitorThresholdEdit_lang.7c6545e0.js";import"./lodash.ec5da75f.js";import"./index.2eb94ba0.js";import{d as h,s as j,r as c,_ as H,ae as M,o as r,c as q,L as d,u as a,J as _,K as n,Q as I,a as f,T as t,j as J,R as K,n as Q}from"./@vue.108c970a.js";import"./@vueuse.d3d080b7.js";import"./@element-plus.d6eabd08.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.8c7044a6.js";import"./vue-router.ed788fee.js";import"./pinia.eff1ffd5.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.241b9b5d.js";const U={class:"mt-4"},z=K(" \u7F16\u8F91 "),G={class:"flex mt-4 justify-end"},O=h({name:"monitorThresholdLists"}),Mo=h({...O,setup(W){const u=j(),p=c(!1),v=H({}),E=c([]),w=s=>{E.value=s.map(({id:e})=>e)},{dictData:F}=R(""),{pager:i,getLists:m,resetParams:X,resetPage:Y}=N({fetchFun:$,params:v}),C=async s=>{var e,o;p.value=!0,await Q(),(e=u.value)==null||e.open("edit"),(o=u.value)==null||o.setFormData(s)};return m(),(s,e)=>{const o=y,b=B,g=T,x=P,D=V,k=M("perms"),A=L;return r(),q("div",null,[d((r(),_(D,{class:"!border-none",shadow:"never"},{default:n(()=>[f("div",U,[t(g,{data:a(i).lists,onSelectionChange:w},{default:n(()=>[t(o,{label:"\u571F\u58E4\u6700\u9AD8\u6E29\u5EA6",prop:"soil_temp_max","show-overflow-tooltip":""}),t(o,{label:"\u571F\u58E4\u6700\u4F4E\u6E29\u5EA6",prop:"soil_temp_min","show-overflow-tooltip":""}),t(o,{label:"\u571F\u58E4\u6700\u9AD8\u6E7F\u5EA6",prop:"soil_mois_max","show-overflow-tooltip":""}),t(o,{label:"\u571F\u58E4\u6700\u4F4E\u6E7F\u5EA6",prop:"soil_mois_min","show-overflow-tooltip":""}),t(o,{label:"\u571F\u58E4\u6700\u9AD8PH\u503C",prop:"soil_ph_max","show-overflow-tooltip":""}),t(o,{label:"\u571F\u58E4\u6700\u4F4EPH\u503C",prop:"soil_ph_min","show-overflow-tooltip":""}),t(o,{label:"\u571F\u58E4\u6700\u9AD8\u6C2E\u542B\u91CF",prop:"soil_n_content_max","show-overflow-tooltip":""}),t(o,{label:"\u571F\u58E4\u6700\u4F4E\u6C2E\u542B\u91CF",prop:"soil_n_content_min","show-overflow-tooltip":""}),t(o,{label:"\u6700\u5927\u98CE\u901F",prop:"wind_speed_max","show-overflow-tooltip":""}),t(o,{label:"\u6700\u5C0F\u98CE\u901F",prop:"wind_speed_min","show-overflow-tooltip":""}),t(o,{label:"\u64CD\u4F5C",width:"120",align:"center",fixed:"right"},{default:n(({row:l})=>[d((r(),_(b,{type:"primary",link:"",onClick:Z=>C(l)},{default:n(()=>[z]),_:2},1032,["onClick"])),[[k,["device.monitor_threshold/edit"]]])]),_:1})]),_:1},8,["data"])]),f("div",G,[t(x,{modelValue:a(i),"onUpdate:modelValue":e[0]||(e[0]=l=>J(i)?i.value=l:null),onChange:a(m)},null,8,["modelValue","onChange"])])]),_:1})),[[A,a(i).loading]]),p.value?(r(),_(S,{key:0,ref_key:"editRef",ref:u,"dict-data":a(F),onSuccess:a(m),onClose:e[1]||(e[1]=l=>p.value=!1)},null,8,["dict-data","onSuccess"])):I("",!0)])}}});export{Mo as default};