engineering/public/admin/assets/Custom.6ddc5d51.js
2024-03-04 15:04:21 +08:00

2 lines
3.0 KiB
JavaScript

import{J as g,C as k}from"./element-plus.258bf9e7.js";import{i as w}from"./echarts.50cbfcc9.js";import{a as b}from"./statistics.e06923ca.js";import{_ as V}from"./index.ec401e3b.js";import{r as d,a0 as B,a5 as I,o as l,L as _,M as c,n as N,a,V as S,c as v,a8 as Y,W as D,S as E,U as h,b7 as q,b6 as L}from"./@vue.ab566ce7.js";import"./@vueuse.8fcae4c2.js";import"./@element-plus.b89f1627.js";import"./lodash-es.49f4af13.js";import"./dayjs.4afe12d3.js";import"./axios.37fc980d.js";import"./async-validator.fb49d0f5.js";import"./@ctrl.82a509e0.js";import"./escape-html.e5dfadb9.js";import"./normalize-wheel-es.8aeb3683.js";import"./tslib.60310f1a.js";import"./zrender.a255a587.js";import"./lodash.1d82ee7c.js";import"./vue-router.87ebc608.js";import"./pinia.b6700c26.js";import"./vue-demi.ebc8116b.js";import"./css-color-function.d0bec2c9.js";import"./color.ea90db3f.js";import"./clone.cbd692e6.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./debug.ad6bc3c0.js";import"./ms.a9ae1d6d.js";import"./nprogress.bcdf1f46.js";import"./vue-clipboard3.c45111bf.js";import"./clipboard.1cb79a0d.js";import"./highlight.js.4ebdf9a4.js";import"./@highlightjs.62ff6725.js";const O=i=>(q("data-v-efa05a32"),i=i(),L(),i),A=O(()=>a("div",{class:"card-header"},[a("span",null,"\u5BA2\u6237\u7EDF\u8BA1")],-1)),F={style:{height:"40px"}},P={style:{display:"flex","justify-content":"space-around"}},T={key:0,id:"customNum",class:"chart"},U={__name:"Custom",setup(i){const o=d(""),n=d(!0);o.value=new Date().getFullYear();const m=B([{name:"\u5BA2\u6237\u603B\u6570",value:3,url:"/construction/client/myClient/custom"},{name:"\u4ECA\u5E74\u589E\u52A0",value:3,url:"/construction/client/myClient/custom",query:!0}]),y={show:!0,rich:{name:{}}},f=(t,r)=>{var s=document.getElementById(t),p=w(s);p.setOption(r)},x=(t,r,s)=>({tooltip:{trigger:"axis",axisPointer:{type:"shadow"}},legend:t,toolbox:{show:!0,orient:"vertical",left:"right",top:"center"},xAxis:[{type:"category",axisTick:{show:!1},data:r}],yAxis:[{type:"value"}],series:s}),u=async()=>{n.value=!1;let t=await b({year:o.value});n.value=!0,await N(),f("customNum",x({data:[t.series.name]},t.column,[{name:t.series.name,type:"bar",barGap:0,label:y,emphasis:{focus:"series"},data:t.series.data}])),m[0].value=t.custom_total,m[1].value=t.this_year_add};return u(),(t,r)=>{const s=g,p=I("router-link"),C=k;return l(),_(C,{style:{width:"49.9%"}},{header:c(()=>[A]),default:c(()=>[a("div",F,[S(s,{modelValue:o.value,"onUpdate:modelValue":r[0]||(r[0]=e=>o.value=e),onChange:u,"value-format":"YYYY",type:"year",style:{float:"right"},placeholder:o.value},null,8,["modelValue","placeholder"])]),a("div",P,[(l(!0),v(D,null,Y(m,e=>(l(),_(p,{to:{path:e.url,query:e.query?{year:o.value}:null},key:e,class:"header-btn"},{default:c(()=>[a("div",null,[a("div",null,h(e.value),1),a("div",null,h(e.name),1)])]),_:2},1032,["to"]))),128))]),n.value?(l(),v("div",T)):E("",!0)]),_:1})}}},gt=V(U,[["__scopeId","data-v-efa05a32"]]);export{gt as default};