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 lines
6.4KB

  1. import{d as J,B as K,y as Q,b as X,r as y,o as ee,c as o,e as d,G as P,i as a,h as t,g as m,j as b,t as k,f as u,n as B,k as p,F as Y,u as v,Z as x,q as te}from"./index.e8b71da7.js";import{E as ae}from"./index.492a43bb.js";import{l as le,g as ne}from"./evaluationPlan.79fa9aca.js";const oe={class:"flex"},se={class:"flex justify-between"},re={key:0,class:"flex items-center"},ie={key:1},de=["onClick"],ue=["onClick"],me=["onClick"],pe=["onClick"],ce=["onClick"];const _e=J({name:"evaluationPlan"}),ke=Object.assign(_e,{setup(fe){const{proxy:T}=te(),{operationTypeOptions:q}=K.dictStore.globalDicts||{},c=Q(),s=X({name:void 0,times:void 0}),D={1:"\u9879\u76EE",2:"\u5E94\u7528"},j=[{label:"\u5E8F\u53F7",type:"index",width:"60"},{label:"\u8BA1\u5212\u540D\u79F0",key:"name",prop:"name",minWidth:200,showOverflowTooltip:!0},{label:"\u81EA\u8BC4\u65F6\u95F4",key:"seltTime",slot:"seltTime",width:200},{label:"\u8BC4\u4EF7\u5BF9\u8C61",key:"target",prop:"target",render:n=>x("span",n.target.split(",").map(l=>D[l]).join("\uFF0C")),width:100},{label:"\u521B\u5EFA\u65F6\u95F4",key:"createOn",prop:"createOn",width:"180"},{label:"\u5BA1\u6838\u72B6\u6001",key:"auditStatusName",slot:"auditStatusName",width:100},{label:"\u64CD\u4F5C",slot:"action",fixed:"right",width:190}],M=[{label:"\u5E8F\u53F7",type:"index",width:"60"},{label:"\u8BA1\u5212\u540D\u79F0",key:"name",prop:"name",minWidth:200,showOverflowTooltip:!0},{label:"\u8BC4\u4EF7\u5BF9\u8C61",key:"target",prop:"target",render:n=>{var l;return x("span",(l=n.target)==null?void 0:l.split(",").map(i=>D[i]).join("\uFF0C"))},width:100},{label:"\u63D0\u4EA4\u5BA1\u6838\u65F6\u95F4",key:"createOn",prop:"createOn"},{label:"\u5BA1\u6838\u64CD\u4F5C",key:"operationType",prop:"operationType",render:n=>x("span",q[n.operationType]||"-")},{label:"\u5BA1\u6838\u72B6\u6001",slot:"auditStatusName",prop:"auditStatusName"},{label:"\u64CD\u4F5C",slot:"action",fixed:"right",width:190}],N=y(0),h=y([]),E=n=>{s.regionCode=n.regionLevel===3?n.regionCode:void 0,_.value.pageParams.pageNumber=1,f()},_=y(),r=y("1"),f=async(n=_.value.pageParams)=>{var i,w;h.value=[];const l=await le(r.value,{...n,...s,start:((i=s.times)==null?void 0:i[0])||void 0,end:((w=s.times)==null?void 0:w[1])||void 0,times:void 0,auditType:2});h.value=l.data.records,N.value=l.data.total},G=()=>{_.value.pageParams.pageNumber=1,f()},V=()=>{_.value.pageParams.pageNumber=1,s.name=void 0,s.times=void 0,f()},W=()=>{c.push({name:"addPlan",query:{regionId:s.regionId}})},ge=n=>{T.$messageBox.confirm(`\u662F\u5426\u5220\u9664${n.name}?`,"\u63D0\u793A\uFF01",{type:"warning"}).then(async()=>{await ne(n.id),T.$message.success("\u5220\u9664\u6210\u529F\uFF01"),f()})},z=n=>{r.value=n,V()};return ee(()=>{}),(n,l)=>{const i=o("el-col"),w=o("el-input"),C=o("el-form-item"),F=o("el-date-picker"),S=o("el-button"),$=o("el-row"),L=o("el-form"),I=o("el-card"),O=o("el-tab-pane"),R=o("el-tabs"),U=o("Warning"),Z=o("el-icon"),A=o("el-tooltip"),H=o("table-list");return d(),P($,null,{default:a(()=>[t(i,{style:{"padding-right":"16px"},span:4},{default:a(()=>[t(ae,{onGetTree:E})]),_:1}),t(i,{span:20},{default:a(()=>[t(I,{class:"w-full search"},{default:a(()=>[t(L,{model:s,size:"small","label-suffix":":"},{default:a(()=>[t($,{gutter:16},{default:a(()=>[t(i,{span:8},{default:a(()=>[t(C,{label:"\u8BA1\u5212\u540D\u79F0"},{default:a(()=>[t(w,{modelValue:s.name,"onUpdate:modelValue":l[0]||(l[0]=e=>s.name=e),placeholder:"\u8BF7\u8F93\u5165"},null,8,["modelValue"])]),_:1})]),_:1}),t(i,{span:9},{default:a(()=>[t(C,{label:"\u521B\u5EFA\u65F6\u95F4"},{default:a(()=>[t(F,{modelValue:s.times,"onUpdate:modelValue":l[1]||(l[1]=e=>s.times=e),type:"daterange",editable:!1,format:"YYYY-MM-DD","value-format":"YYYY-MM-DD","range-separator":"-","start-placeholder":"\u5F00\u59CB\u65F6\u95F4","end-placeholder":"\u7ED3\u675F\u65F6\u95F4"},null,8,["modelValue"])]),_:1})]),_:1}),t(i,{span:7},{default:a(()=>[t(C,{class:"btn"},{default:a(()=>[m("div",oe,[t(S,{type:"primary",onClick:G},{default:a(()=>l[3]||(l[3]=[b("\u67E5\u8BE2")])),_:1}),t(S,{onClick:V},{default:a(()=>l[4]||(l[4]=[b("\u91CD\u7F6E")])),_:1})])]),_:1})]),_:1})]),_:1})]),_:1},8,["model"])]),_:1}),t(I,{class:"w-full mt-8 tab-card"},{header:a(()=>[m("div",se,[t(R,{modelValue:r.value,"onUpdate:modelValue":l[2]||(l[2]=e=>r.value=e),onTabChange:z},{default:a(()=>[t(O,{label:"\u8BA1\u5212\u5217\u8868",name:"1"}),t(O,{label:"\u5BA1\u6838\u5217\u8868",name:"2"})]),_:1},8,["modelValue"]),m("div",null,[t(S,{type:"primary",size:"small",icon:"plus",onClick:W},{default:a(()=>l[5]||(l[5]=[b("\u65B0\u5EFA\u8BA1\u5212")])),_:1})])])]),default:a(()=>[t(H,{ref_key:"tableListRef",ref:_,column:r.value==="1"?j:M,data:h.value,total:N.value,onGetTableData:f},{seltTime:a(({scope:e})=>[b(" \u9879\u76EE\u7EC8\u9A8C"+k(e.row.startSelfDays)+"\u5929\u540E\u5F00\u59CB\u81EA\u8BC4\uFF0C\u5E76\u4E14\u5728"+k(e.row.completeSelfDays)+"\u5929\u5B8C\u6210\u81EA\u8BC4 ",1)]),auditStatusName:a(({scope:e})=>[e.row.auditStatus?(d(),u("div",re,[m("span",{class:B(`dot mr-4 ${e.row.auditStatus===1?"bg-warning":e.row.auditStatus===2?"bg-success":"bg-danger"}`)},null,2),m("span",{class:B(`${e.row.auditStatus===1?"text-warning":e.row.auditStatus===2?"text-success":"text-danger"}`)},k(e.row.auditStatusName),3),e.row.auditStatus===3?(d(),P(A,{key:0,content:e.row.auditMessage,placement:"bottom",effect:"light"},{default:a(()=>[t(Z,{class:"ml-4"},{default:a(()=>[t(U)]),_:1})]),_:2},1032,["content"])):p("",!0)])):(d(),u("span",ie,"-"))]),action:a(({scope:e})=>[r.value==="1"?(d(),u(Y,{key:0},[e.row.auditStatus===2||e.row.auditStatus===3?(d(),u("a",{key:0,onClick:g=>v(c).push({name:"addPlan",query:{id:r.value==="1"?e.row.id:e.row.appraisalId,auditId:r.value==="2"?e.row.id:""}})},k(e.row.auditStatus===2?"\u7F16\u8F91":"\u91CD\u65B0\u63D0\u4EA4"),9,de)):p("",!0),e.row.auditStatus===2?(d(),u("a",{key:1,onClick:g=>v(c).push({name:"projectGroup",query:{appraisalId:e.row.id}})},"\u9879\u76EE\u5206\u7EC4",8,ue)):p("",!0),r.value==="1"?(d(),u("a",{key:2,onClick:g=>v(c).push({name:"planDetail",query:{id:e.row.id}})},"\u8BE6\u60C5",8,me)):p("",!0)],64)):(d(),u(Y,{key:1},[e.row.auditStatus===3?(d(),u("a",{key:0,onClick:g=>v(c).push({name:"addPlan",query:{id:r.value==="1"?e.row.id:e.row.appraisalId,auditId:r.value==="2"?e.row.id:""}})},"\u91CD\u65B0\u63D0\u4EA4",8,pe)):p("",!0),m("a",{onClick:g=>n.$router.push({name:"planDetail",query:{id:e.row.appraisalId,auditId:e.row.id}})},"\u8BE6\u60C5",8,ce)],64)),p("",!0)]),_:1},8,["column","data","total"])]),_:1})]),_:1})]),_:1})}}});export{ke as default};