water-ldht/dist/static/js/chunk-d2ca8a60.70c3f8ae.js

7 lines
7.7 KiB
JavaScript
Raw Normal View History

2024-11-01 16:58:10 +08:00
/*!
* build: vue-admin-beautiful
* vue-admin-beautiful author: chuzhixin 1204505056@qq.com
* vue-admin-beautiful QQ Group(QQ群): 9724353191139183756
* time: 2024-10-10 11:14:28
*/
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-d2ca8a60","chunk-3541f7e5"],{"0ddc":function(t,e,a){"use strict";a.r(e),a.d(e,"getList",(function(){return o})),a.d(e,"doEdit",(function(){return d})),a.d(e,"doDelete",(function(){return c})),a.d(e,"doAdd",(function(){return r})),a.d(e,"selectDeviceInfo",(function(){return s})),a.d(e,"insertDictData",(function(){return l})),a.d(e,"updateDictData",(function(){return n})),a.d(e,"removeDictData",(function(){return u}));var i=a("b775");function o(t){const e="?page="+t.page+"&size="+t.size;return Object(i["default"])({url:"/sysDict/select"+e,method:"get",data:t})}function d(t){return Object(i["default"])({url:"/sysDict/updateDictType",method:"post",data:t})}function c(t){return Object(i["default"])({url:"/sysDict/removeDictType?dictTypeId="+t.dictTypeId,method:"post",data:t})}function r(t){return Object(i["default"])({url:"/sysDict/insertDictType",method:"post",data:t})}function s(t){return Object(i["default"])({url:"/iot/device/selectDeviceInfo?deviceId="+t.deviceId,method:"post",data:t})}function l(t){return Object(i["default"])({url:"/sysDict/insertDictData",method:"post",data:t})}function n(t){return Object(i["default"])({url:"/sysDict/updateDictData",method:"post",data:t})}function u(t){return Object(i["default"])({url:"/sysDict/removeDictData?dictDataId="+t.dictDataId,method:"post",data:t})}},"34c9":function(t,e,a){t.exports={"menu-color":"hsla(0,0%,27%,.95)","menu-color-active":"hsla(208,100%,55%,.95)","menu-background":"#fff","gallery-second-menu-background":"#fff"}},"38d44":function(t,e,a){"use strict";a.r(e);var i=a("f2bf");const o={class:"manage-container"};function d(t,e,a,d,c,r){const s=Object(i["resolveComponent"])("el-button"),l=Object(i["resolveComponent"])("vab-query-form"),n=Object(i["resolveComponent"])("el-table-column"),u=Object(i["resolveComponent"])("el-table"),f=Object(i["resolveComponent"])("dict-data");return Object(i["openBlock"])(),Object(i["createElementBlock"])("div",o,[Object(i["createVNode"])(l,null,{default:Object(i["withCtx"])(()=>[Object(i["createVNode"])(s,{type:"primary",size:"small",onClick:e[0]||(e[0]=t=>r.handleAdd())},{default:Object(i["withCtx"])(()=>e[1]||(e[1]=[Object(i["createTextVNode"])(" 添加数据 ")])),_:1})]),_:1}),Object(i["createVNode"])(u,{data:c.dictData,border:"",stripe:"",style:{width:"100%"}},{default:Object(i["withCtx"])(()=>[Object(i["createVNode"])(n,{prop:"id",label:"数据ID",width:"200",align:"center"}),Object(i["createVNode"])(n,{prop:"dataCode",label:"键",width:"300",align:"center"}),Object(i["createVNode"])(n,{prop:"dataValue",label:"值",width:"400",align:"center"}),Object(i["createVNode"])(n,{fixed:"right",label:t.$t("defalult.cz"),align:"center"},{default:Object(i["withCtx"])(({row:e})=>[Object(i["createVNode"])(s,{type:"text",onClick:t=>r.handleEdit(e)},{default:Object(i["withCtx"])(()=>[Object(i["createTextVNode"])(Object(i["toDisplayString"])(t.$t("defalult.bj")),1)]),_:2},1032,["onClick"]),Object(i["createVNode"])(s,{type:"text",onClick:t=>r.handleDelete(e)},{default:Object(i["withCtx"])(()=>[Object(i["createTextVNode"])(Object(i["toDisplayString"])(t.$t("defalult.sc")),1)]),_:2},1032,["onClick"])]),_:1},8,["label"])]),_:1},8,["data"]),Object(i["createVNode"])(f,{ref:"edit"},null,512)])}var c=a("0ddc"),r=a("e1e0"),s={name:"Index",components:{dictData:r["default"]},data(){return{dictId:"",dictData:[],data:[],queryForm:{page:1,size:20}}},computed:{height(){return 500}},created(){this.dictId=this.$route.query.dictId,this.queryForm.page=this.$route.query.page,this.queryForm.size=this.$route.query.size,this.fetchData()},methods:{async fetchData(){const t=this;t.listLoading=!0;const{data:e}=await Object(c["getList"])(this.queryForm),a=e.items;a.forEach((function(e){e.id==t.dictId&&(t.dictData=e.dictData)})),setTimeout(()=>{t.listLoading=!1},500)},handleAdd(){this.$refs["edit"].showEdit({dictId:this.dictId},0)},handleEdit(t){this.$refs["edit"].showEdit({row:t,dictId:this.dictId},1)},handleDelete(t){const e=this;t.id&&this.$confirm("你确定要删除当前项吗?","提示",{confirmButtonText