water-ldht/dist/static/js/chunk-bb1e21f4.95ae88aa.js

7 lines
5.2 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-bb1e21f4"],{"365c":function(t,e,a){"use strict";a.r(e),a.d(e,"getBasicData",(function(){return r})),a.d(e,"getConsumptionData",(function(){return o})),a.d(e,"getInspectionData",(function(){return i})),a.d(e,"getAlarmData",(function(){return s})),a.d(e,"getTaskData",(function(){return c})),a.d(e,"getAttendanceData",(function(){return d}));var n=a("b775");function r(t){var e="?month="+t.month;return void 0!=t.projectId&&(e+="&projectId="+t.projectId),Object(n["default"])({url:"/overview/basic"+e,method:"get",data:t})}function o(t){var e="?start="+t.start+"&end="+t.end;return void 0!=t.projectId&&(e+="&projectId="+t.projectId),Object(n["default"])({url:"/overview/energyConsumption"+e,method:"get",data:t})}function i(t){var e="?start="+t.start+"&end="+t.end;return void 0!=t.projectId&&(e+="&projectId="+t.projectId),Object(n["default"])({url:"/overview/inspection"+e,method:"get",data:t})}function s(t){var e="?start="+t.start+"&end="+t.end;return void 0!=t.projectId&&(e+="&projectId="+t.projectId),Object(n["default"])({url:"/overview/alarm"+e,method:"get",data:t})}function c(t){var e="?start="+t.start+"&end="+t.end;return void 0!=t.projectId&&(e+="&projectId="+t.projectId),Object(n["default"])({url:"/overview/task"+e,method:"get",data:t})}function d(t){var e="?start="+t.start+"&end="+t.end;return void 0!=t.projectId&&(e+="&projectId="+t.projectId),Object(n["default"])({url:"/overview/attendance"+e,method:"get",data:t})}},"5f99":function(t,e,a){"use strict";function n(t,e){const a=parseInt(t),n=new Date,r=n.getDate(),o=new Date(n.setDate(r+a)),i=o.getFullYear(),s=o.getMonth()+1,c=o.getDate();let d,u;d=s<10?"0"+s:s,u=c<10?"0"+c:c;const l=e||"-";return i+l+d+l+u}function r(t=""){var e=new Date;""!=t&&(e=new Date(t));const a=e.getFullYear();let n=e.getMonth(),r=e.getDate();return n+=1,n=n.toString().padStart(2,"0"),r=r.toString().padStart(2,"0"),`${a}-${n}-${r}`}function o(t=""){var e=new Date;""!=t&&(e=new Date(t));const a=e.getFullYear();let n=e.getMonth();return n+=1,n=n.toString().padStart(2,"0"),`${a}-${n}`}function i(t=""){var e=new Date;""!=t&&(e=new Date(t));const a=e.getFullYear();return""+a}function s(t){const e=new Date,a=e.getFullYear(),n=e.getMonth()+1,r=e.getDate(),o=n-t,i=o<0?o+12:o>10?o:"0"+o,s=n>9?n:"0"+n,c=r>9?r:"0"+r,d=a+"-"+i+"-"+c,u=a+"-"+s+"-"+c;return[d,u]}function c(){const t=new Date,e=t.getFullYear(),a=t.getMonth()+1,n=t.getDate(),r=new Date(t);r.setDate(t.getDate()-1);const o=r.getFullYear(),i=(r.getMonth()+1).toString().padStart(2,"0"),s=r.getDate().toString().padStart(2,"0"),c=a>9?a:"0"+a,d=n>9?n:"0"+n,u=o+"-"+i+"-"+s,l=e+"-"+c+"-"+d;return[u,l]}function d(t){var e=new Date;""!=t&&(e=new Date(t));const a=e.getFullYear();let n=e.getMonth()+1;n=n<10?"0"+n:n;let r=e.getDate();r=r<10?"0"+r:r;let o=e.getHours();o=o<10?"0"+o:o;let i=e.getMinutes();i=i<10?"0"+i:i;let s=e.getSeconds();return s=s<10?"0"+s:s,a+"-"+n+"-"+r+" "+o+":"+i+":"+s}a.r(e),a.d(e,"getFMdate",(function(){return n})),a.d(e,"getDate",(function(){return r})),a.d(e,"getDate1",(function(){return o})),a.d(e,"getDate2",(function(){return i})),a.d(e,"getPastTime",(function(){return s})),a.d(e,"getPastTime1",(function(){return c})),a.d(e,"formatDateTime",(function(){return d}))},d400:function(t,e,a){"use strict";a.r(e);var n=a("f2bf");const r={id:"personnel-site",style:{width:"100%",height:"300px"}};function o(t,e,a,o,i,s){return Object(n["openBlock"])(),Object(n["createElementBlock"])("div",r)}a("14d9");var i=a("365c"),s=a("5f99"),c=a("313e"),d={props:{time:{type:Array},all:{type:Boolean,default:!1}},data(){return{chartPie:null,yData:[],xData:[],seriesData:[],isAllProject:!1}},watch:{time(t){this.maintenanceTime=t,this.getInspectionData(),setTimeout(()=>{this.drawCharts()},2e3)},all(t){this.isAllProject=t,this.getInspectionData(),setTimeout(()=>{this.drawCharts()},2e3)}},mounted:function(){},methods:{async getInspectionData(){var t=sessionStorage.getItem("projectId"),e={};e=0==this.isAllProject?{start:Object(s["getDate"])(this.maintenanceTime[0]),end:Object(s["getDate"])(this.mainte