You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2 line
10KB

  1. var F=(d,j,h)=>new Promise((_,g)=>{var v=i=>{try{w(h.next(i))}catch(C){g(C)}},R=i=>{try{w(h.throw(i))}catch(C){g(C)}},w=i=>i.done?_(i.value):Promise.resolve(i.value).then(v,R);w((h=h.apply(d,j)).next())});import{N as D,d as ie,u as de,y as ce,r as m,M as y,o as me,f as c,g as fe,c as _e,e as t,w as s,b as e,t as p,v as L,h as A,C as K,D as Q}from"./index.32194486.js";import{_ as ue,a as pe,i as S,L as f}from"./index.b0dc2dad.js";import he from"./index.d1f278bd.js";import ve from"./index.3dffe3ce.js";import"./orderManage.aae74c26.js";import"./orderDetailDrawer.ab0ba3fa.js";import"./uploadAction.25c9789a.js";import"./editOrderForm.03fae96b.js";import"./projectManage.b222baef.js";import"./queryAddressDialog.8db92efd.js";import"./locationTransform.e2d22cb6.js";import"./tiandimap.2786bb09.js";import"./driverAssignmentDialog.9e42b80a.js";import"./cancelOrderDialog.8033c8fc.js";import"./confirmOrderDialog.30b780b9.js";import"./orderCompletionDialog.b3008fab.js";import"./confirmBoardingDialog.2bd4d544.js";import"./trajectoryDialog.22949a17.js";import"./useExportExc.3bf14c9f.js";import"./useTreeSelectData.58a8ac6c.js";import"./confirmDialog.85cba7c0.js";const ye="/assets/xzdd.f34e483b.png",be="/assets/djsdd.bd9d3a20.png",xe="/assets/yjsdd.0d3d554a.png",ge=d=>D.get("/api/v1/dashboard/enterprise/orderCostStatistics",{params:d}),we=d=>D.get("/api/v1/dashboard/enterprise/settledOrderCountByProject",{params:d}),Ce=d=>D.get("/api/v1/dashboard/enterprise/settledOrderCostByProject",{params:d}),Ye=d=>D.get("/api/v1/dashboard/enterprise/orderCountByJobType",{params:d}),Be=d=>D.get("/api/v1/dashboard/orderCountByCarType",{params:d});const Fe={class:"companyHome"},De={class:"flex justify-between items-center"},Me={class:"flex items-center"},ke={class:"flex items-center text-18 text-303133"},Oe={class:"mr-8 font-bold"},Te={class:"text-14 text-818488"},Ee=A("\u672C\u6708"),Ve=A("\u4E0A\u6708"),Le={class:"flex"},je={class:"mr-5"},Re={class:"subtotal"},ze=e("img",{src:ue,class:"subtotalIcon mr-8",alt:""},null,-1),Se={class:"overflow-hidden"},Ae={class:"text-primary text-28"},Ne=e("div",{class:"text-818488 text-14 truncate"},"\u9879\u76EE\u603B\u6570",-1),Ie={class:"subtotal"},Pe=e("img",{src:ye,class:"subtotalIcon mr-8",alt:""},null,-1),Ue={class:"overflow-hidden"},$e={class:"text-primary text-28"},He=e("div",{class:"text-818488 text-14 truncate"},"\u65B0\u589E\u8BA2\u5355",-1),Je={class:"subtotal"},Ge=e("img",{src:be,class:"subtotalIcon mr-8",alt:""},null,-1),qe={class:"overflow-hidden"},Ke={class:"text-primary text-28"},Qe=e("div",{class:"text-818488 text-14 truncate"},"\u670D\u52A1\u4E2D\u8BA2\u5355",-1),We={class:"subtotal"},Xe=e("img",{src:xe,class:"subtotalIcon mr-8",alt:""},null,-1),Ze={class:"overflow-hidden"},et={class:"text-primary text-28"},tt=e("div",{class:"text-818488 text-14 truncate"},"\u5DF2\u786E\u8BA4\u8BA2\u5355",-1),ot={class:"subtotal justify-between"},st={class:"flex items-center"},at=e("img",{src:pe,class:"subtotalIcon mr-8",alt:""},null,-1),lt={class:"text-FE6935 text-28"},nt=e("div",{class:"text-818488 text-14"},"\u9884\u8BA1\u670D\u52A1\u8D39(\u5143)",-1),rt={class:"flex justify-between items-center"},it={class:"flex justify-between items-center"},dt=e("a",{class:"text-primary text-14"},"\u66F4\u591A",-1),ct=ie({name:"companyHome"}),Vt=Object.assign(ct,{setup(d){const j=de(),h=ce.userStore.userBaseInfo,_=m({start:y().startOf("month").format("YYYY-MM-DD"),end:y().endOf("month").format("YYYY-MM-DD")}),g=m(1),v=m(),R=a=>{switch(a){case 1:_.value={start:y().startOf("month").format("YYYY-MM-DD"),end:y().endOf("month").format("YYYY-MM-DD")},v.value=void 0,E();break;case 2:_.value={start:y().add(-1,"month").startOf("month").format("YYYY-MM-DD"),end:y().add(-1,"month").endOf("month").format("YYYY-MM-DD")},v.value=void 0,E();break}},w=a=>{g.value=3,_.value={start:y(a).startOf("month").format("YYYY-MM-DD"),end:y(a).endOf("month").format("YYYY-MM-DD")},E()},i=m(),C=()=>F(this,null,function*(){const a=yield ge(_.value);i.value=a.data}),N=m(),I=m(),Y=m("ordersToBeConfirmed");let M;const P=m(),W=(a,l)=>{M||(M=S(P.value));const r={color:[new f(0,0,0,1,[{offset:0,color:"#257EF2"},{offset:1,color:"#254FF2"}]),new f(0,0,0,1,[{offset:0,color:"#FEC735"},{offset:1,color:"#FE6935"}])],tooltip:{trigger:"axis",axisPointer:{type:"shadow"}},legend:{},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",data:l.map(b=>b.label)},yAxis:{type:"value"},series:[{name:a==="1"?"\u8BA2\u5355\u603B\u6570":"\u603B\u8D39\u7528",type:"bar",data:l.map(b=>b.val1)},{name:"\u5DF2\u7ED3\u7B97",type:"bar",data:l.map(b=>b.val2)}]};M.setOption(r)},k=m("1"),X=a=>{U(a)},U=a=>F(this,null,function*(){let l;a==="1"?l=yield we(_.value):l=yield Ce(_.value),W(k.value,l.data)});let O;const $=m(),Z=a=>{O||(O=S($.value));const l={title:{text:"\u5404\u5DE5\u4F5C\u7C7B\u578B\u8BA2\u5355\u60C5\u51B5",textStyle:{fontSize:16,color:"#303133"}},color:[new f(0,0,0,1,[{offset:0,color:"#257EF2"},{offset:1,color:"#254FF2"}]),new f(0,0,0,1,[{offset:0,color:"#FEC735"},{offset:1,color:"#FE6935"}]),new f(0,0,0,1,[{offset:0,color:"#00CB8B"},{offset:1,color:"#00B4E3"}])],angleAxis:{clockwise:!1,axisLine:{show:!1},axisLabel:{show:!1},splitLine:{show:!1},axisTick:{show:!1},min:0,startAngle:0},tooltip:{trigger:"item",formatter:function(r){return r.marker+r.seriesName+" "+r.data}},legend:{orient:"vertical",data:a.map(r=>r.key),right:0,bottom:0},radiusAxis:{type:"category",data:["1","2","3"],z:10,axisLine:{show:!1},axisTick:{show:!1},axisLabel:{show:!1}},polar:{},series:a.map(r=>({type:"bar",data:[0,0,r.value],coordinateSystem:"polar",name:r.key,roundCap:!0,stack:"a"}))};O.setOption(l)},ee=()=>F(this,null,function*(){const a=yield Ye(_.value);Z(a.data)});let T;const H=m(),te=a=>{T||(T=S(H.value));const l={title:{text:"\u5404\u8F66\u8F86\u7C7B\u578B\u8BA2\u5355\u60C5\u51B5",textStyle:{fontSize:16,color:"#303133"}},color:[new f(0,0,0,1,[{offset:0,color:"#257EF2"},{offset:1,color:"#254FF2"}]),new f(0,0,0,1,[{offset:0,color:"#00CB8B"},{offset:1,color:"#00B4E3"}]),new f(0,0,0,1,[{offset:0,color:"#96A9C4"},{offset:1,color:"#5D7092"}]),new f(0,0,0,1,[{offset:0,color:"#FEC735"},{offset:1,color:"#FE6935"}]),new f(0,0,0,1,[{offset:0,color:"#F581B4"},{offset:1,color:"#FF1D82"}]),new f(0,0,0,1,[{offset:0,color:"#6FE0FF"},{offset:1,color:"#0FBBFF"}])],tooltip:{trigger:"item"},legend:{orient:"vertical",right:0,bottom:0},series:[{type:"pie",radius:["50%","70%"],data:a.map(r=>({name:r.key,value:r.value}))}]};T.setOption(l)},oe=()=>F(this,null,function*(){const a=yield Be(_.value);te(a.data)}),E=()=>{C(),U(k.value),ee(),oe()},se=()=>{window.addEventListener("resize",()=>{M.resize(),O.resize(),T.resize()})};return me(()=>{E(),se()}),(a,l)=>{const r=c("el-avatar"),b=c("el-tag"),z=c("el-radio-button"),ae=c("ArrowDownBold"),le=c("el-icon"),ne=c("el-date-picker"),re=c("el-radio-group"),B=c("el-card"),x=c("el-col"),J=c("el-row"),V=c("el-tab-pane"),G=c("el-tabs");return fe(),_e("div",Fe,[t(B,{shadow:"never",class:"mb-16"},{default:s(()=>{var o,n;return[e("div",De,[e("div",Me,[t(r,{size:56,icon:"User",class:"mr-16"}),e("div",null,[e("div",ke,[e("span",Oe,"\u4F60\u597D\uFF0C"+p((o=L(h))==null?void 0:o.realName),1),t(b,null,{default:s(()=>{var u;return[A(p((u=L(h))==null?void 0:u.roleName),1)]}),_:1})]),e("div",null,[e("span",Te,p((n=L(h))==null?void 0:n.companyName),1)])])]),t(re,{modelValue:g.value,"onUpdate:modelValue":l[1]||(l[1]=u=>g.value=u),size:"small",class:"monthRadio",onChange:R},{default:s(()=>[t(z,{label:1},{default:s(()=>[Ee]),_:1}),t(z,{label:2},{default:s(()=>[Ve]),_:1}),t(z,{label:3},{default:s(()=>[e("span",Le,[e("span",je,p(v.value?v.value:"\u81EA\u5B9A\u4E49"),1),t(le,null,{default:s(()=>[t(ae)]),_:1})]),t(ne,{modelValue:v.value,"onUpdate:modelValue":l[0]||(l[0]=u=>v.value=u),class:"customMonth",type:"month","value-format":"YYYY-MM",editable:!1,clearable:!1,size:"small",onChange:w},null,8,["modelValue"])]),_:1})]),_:1},8,["modelValue"])])]}),_:1}),t(J,{gutter:16},{default:s(()=>[t(x,{sm:8,lg:4},{default:s(()=>{var o,n;return[e("div",Re,[ze,e("div",Se,[e("div",Ae,p((n=(o=i.value)==null?void 0:o.projectCount)!=null?n:"-"),1),Ne])])]}),_:1}),t(x,{sm:8,lg:4},{default:s(()=>{var o,n;return[e("div",Ie,[Pe,e("div",Ue,[e("div",$e,p((n=(o=i.value)==null?void 0:o.newOrderCount)!=null?n:"-"),1),He])])]}),_:1}),t(x,{sm:8,lg:4},{default:s(()=>{var o,n;return[e("div",Je,[Ge,e("div",qe,[e("div",Ke,p((n=(o=i.value)==null?void 0:o.servicingCount)!=null?n:"-"),1),Qe])])]}),_:1}),t(x,{sm:8,lg:4},{default:s(()=>{var o,n;return[e("div",We,[Xe,e("div",Ze,[e("div",et,p((n=(o=i.value)==null?void 0:o.confirmedCount)!=null?n:"-"),1),tt])])]}),_:1}),t(x,{sm:16,lg:8},{default:s(()=>{var o,n;return[e("div",ot,[e("div",st,[at,e("div",null,[e("div",lt,p((n=(o=i.value)==null?void 0:o.estimatedCost)!=null?n:"-"),1),nt])])])]}),_:1})]),_:1}),t(B,{shadow:"never",class:"tab-card mb-16"},{header:s(()=>[e("div",rt,[t(G,{modelValue:Y.value,"onUpdate:modelValue":l[2]||(l[2]=o=>Y.value=o),class:"flex-1"},{default:s(()=>{var o,n,u,q;return[t(V,{label:`\u5F85\u786E\u8BA4\u8BA2\u5355\uFF08${(n=(o=N.value)==null?void 0:o.total)!=null?n:0}\uFF09`,name:"ordersToBeConfirmed"},null,8,["label"]),t(V,{label:`\u5F85\u786E\u8BA4\u7ED3\u7B97\u5355\uFF08${(q=(u=I.value)==null?void 0:u.total)!=null?q:0}\uFF09`,name:"statementToBeConfirmed"},null,8,["label"])]}),_:1},8,["modelValue"]),e("a",{class:"text-primary text-14",onClick:l[3]||(l[3]=o=>L(j).push({name:Y.value}))},"\u66F4\u591A")])]),default:s(()=>[K(t(he,{ref_key:"orderListRef",ref:N,state:"ordersToBeConfirmed"},null,512),[[Q,Y.value==="ordersToBeConfirmed"]]),K(t(ve,{ref_key:"statementListRef",ref:I,state:"statementToBeConfirmed"},null,512),[[Q,Y.value==="statementToBeConfirmed"]])]),_:1}),t(B,{shadow:"never",class:"tab-card mb-16"},{header:s(()=>[e("div",it,[t(G,{modelValue:k.value,"onUpdate:modelValue":l[4]||(l[4]=o=>k.value=o),class:"flex-1",onTabChange:X},{default:s(()=>[t(V,{label:"\u5404\u9879\u76EE\u8BA2\u5355\u7EDF\u8BA1",name:"1"}),t(V,{label:"\u5404\u9879\u76EE\u8D39\u7528\u7EDF\u8BA1",name:"2"})]),_:1},8,["modelValue"]),dt])]),default:s(()=>[e("div",{ref_key:"chart1Ref",ref:P,class:"chart"},null,512)]),_:1}),t(J,{gutter:16},{default:s(()=>[t(x,{span:12},{default:s(()=>[t(B,{shadow:"never"},{default:s(()=>[e("div",{ref_key:"chart2Ref",ref:$,class:"chart"},null,512)]),_:1})]),_:1}),t(x,{span:12},{default:s(()=>[t(B,{shadow:"never"},{default:s(()=>[e("div",{ref_key:"chart3Ref",ref:H,class:"chart"},null,512)]),_:1})]),_:1})]),_:1})])}}});export{Vt as default};