import{ag as n,a5 as h,r as l,ah as f,o as u,y as T,q as c,p as b,c as N,P as _,x as S,F as V,t as x,aj as D,bv as P}from"./index.8d733f79.js";function k(e){return n({url:"/temperatureComp/tempCompPage",method:"get",params:e})}function z(e){return n({url:"/temperatureComp/tempCompLogPage",method:"get",params:e})}function I(e){return n({url:"/temperatureComp/saveTempComp",method:"post",data:e})}function B(e){return n({url:"/temperatureComp/importTempComp",method:"post",data:e,headers:{"Content-Type":"multipart/form-data"}})}function E(e){return n({url:"/temperatureComp/exportTempComp",method:"get",headers:{"Content-Type":"application/octet-stream",Accept:"*/*"},responseType:"blob",params:e})}const L=h({__name:"historyDialog",setup(e,{expose:g}){const r=l(!1),s=l([]),m=l(0);l(null);const d=[{prop:"createTime",label:"modifyTime"},{prop:"sensorSn",label:"sensorSn"},{prop:"channelNo",label:"channel",type:"action",width:100},{prop:"tempCompValue",label:"tempCompVal"}],t=f({pageNo:1,pageSize:10,pointId:null}),i=async()=>{if(!t.pointId)return;const o=await z(t);s.value=o.data.content||[],m.value=o.data.totalElements||0},C=o=>{t.pointId=o,t.pageNo=1,r.value=!0,i()},y=()=>{s.value=[],m.value=0,t.pointId=null};return g({open:C}),(o,p)=>{const v=P;return u(),T(v,{modelValue:r.value,"onUpdate:modelValue":p[2]||(p[2]=a=>r.value=a),title:o.$t("configHistory"),width:"800px",class:"history-comp-dialog",onClosed:y},{default:c(()=>[b(D,{class:"history-table",columns:d,tableData:s.value,total:m.value,pageNum:t.pageNo,"onUpdate:pageNum":p[0]||(p[0]=a=>t.pageNo=a),pageSize:t.pageSize,"onUpdate:pageSize":p[1]||(p[1]=a=>t.pageSize=a),onPagination:i},{action:c(({scope:a})=>[a.column.property==="channelNo"?(u(),N(V,{key:0},[_(S(o.$t("channel")+a.row.channelNo),1)],64)):x("",!0)]),_:2},1032,["tableData","total","pageNum","pageSize"])]),_:1},8,["modelValue","title"])}}});export{L as _,E as e,k as g,B as i,I as s};
