engineering/public/admin/assets/index.ae2149a1.js
2024-02-27 10:28:16 +08:00

2 lines
6.5 KiB
JavaScript

import{J as H,y as K,w as Q,D as W,C as X,L as Z,M as ee,N as te}from"./element-plus.517d4382.js";import{_ as oe}from"./index.vue_vue_type_script_setup_true_lang.5ae95555.js";import{f as ae,a as le}from"./index.8b1962e9.js";import{u as ne}from"./usePaging.f6660143.js";import{u as ie}from"./useDictOptions.b5854a9e.js";import{_ as re,a as ue,b as x,c as pe}from"./edit.vue_vue_type_script_setup_true_name_projectEdit_lang.f8c9d443.js";import"./lodash.1d82ee7c.js";import se from"./detail.79a82a49.js";import{d as L,a0 as $,s as A,r as w,ai as de,o as r,c as me,V as e,M as a,O as _,u as p,L as s,S as Y,a as P,k as ce,T as c,n as D}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"./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"./echarts.b30ab882.js";import"./tslib.60310f1a.js";import"./zrender.3760070d.js";import"./highlight.js.4ebdf9a4.js";import"./@highlightjs.62ff6725.js";import"./index.vue_vue_type_style_index_0_lang.c7aef442.js";import"./common.9d529cba.js";import"./index.b17dae19.js";import"./index.vue_vue_type_script_setup_true_lang.b3047aa5.js";import"./index.vue_vue_type_script_setup_true_lang.e1e5e943.js";import"./contract.2d0c2079.js";import"./index.vue_vue_type_script_setup_true_lang.ed719f67.js";import"./project.a81dff6c.js";import"./projecttype.80aa89f5.js";import"./department.b8dec04d.js";import"./organization.5e75830a.js";import"./custom.99349afc.js";const _e=c("\u67E5\u8BE2"),fe=c("\u91CD\u7F6E"),ve=c(" \u65B0\u589E "),Ee=c(" \u5220\u9664 "),Ce={class:"mt-4"},he=c(" \u7F16\u8F91 "),we=c(" \u5220\u9664 "),Fe=c(" \u8BE6\u60C5 "),ye={class:"flex justify-end mt-4"},be=L({name:"projectLists"}),yt=L({...be,setup(ke){$([]);const F=A(),C=A(),h=w(!1),y=w(!1),b=w([]),M=o=>{d.start_date=o[0],d.delivery_date=o[1]},d=$({project_approval_date:"",start_date:"",delivery_date:""}),R=()=>{Object.assign(d,{project_approval_date:"",start_date:"",delivery_date:""}),b.value="",v()},k=w([]),T=o=>{k.value=o.map(({id:t})=>t)},{dictData:g}=ie("invoice_type"),{pager:f,getLists:v,resetParams:De,resetPage:N}=ne({fetchFun:ue,params:d}),S=async()=>{var o;h.value=!0,await D(),(o=C.value)==null||o.open("add")},U=async o=>{var u,i;console.log(o.id);let t=await x({id:o.id});h.value=!0,await D(),(u=C.value)==null||u.open("edit"),(i=C.value)==null||i.setFormData(t)},j=async o=>{await ae.confirm("\u786E\u5B9A\u8981\u5220\u9664\uFF1F"),await pe({id:o}),v()},O=async o=>{var u,i;let t=await x({id:o.id});y.value=!0,await D(),(u=F.value)==null||u.open(),(i=F.value)==null||i.setFormData(t)};return v(),(o,t)=>{const u=H,i=K,m=Q,q=W,B=X,I=le,n=Z,J=ee,z=oe,E=de("perms"),G=te;return r(),me("div",null,[e(B,{class:"!border-none mb-4",shadow:"never"},{default:a(()=>[e(q,{class:"mb-[-16px]",model:d,inline:""},{default:a(()=>[e(i,{label:"\u7ACB\u9879\u65E5\u671F",prop:"project_approval_date"},{default:a(()=>[e(u,{class:"flex-1 !flex",modelValue:d.project_approval_date,"onUpdate:modelValue":t[0]||(t[0]=l=>d.project_approval_date=l),clearable:"",type:"date","value-format":"YYYY-MM-DD ",placeholder:"\u9009\u62E9\u7B7E\u8BA2\u65E5\u671F"},null,8,["modelValue"])]),_:1}),e(i,{label:"\u9879\u76EE\u65F6\u95F4\u8303\u56F4"},{default:a(()=>[e(u,{modelValue:b.value,"onUpdate:modelValue":t[1]||(t[1]=l=>b.value=l),type:"daterange","start-placeholder":"\u9879\u76EE\u5F00\u59CB\u65E5\u671F","end-placeholder":"\u9879\u76EE\u4EA4\u4ED8\u65E5\u671F","default-time":o.defaultTime,"value-format":"YYYY-MM-DD ",onChange:M},null,8,["modelValue","default-time"])]),_:1}),e(i,null,{default:a(()=>[e(m,{type:"primary",onClick:p(N)},{default:a(()=>[_e]),_:1},8,["onClick"]),e(m,{onClick:R},{default:a(()=>[fe]),_:1})]),_:1})]),_:1},8,["model"])]),_:1}),_((r(),s(B,{class:"!border-none",shadow:"never"},{default:a(()=>[_((r(),s(m,{type:"primary",onClick:S},{icon:a(()=>[e(I,{name:"el-icon-Plus"})]),default:a(()=>[ve]),_:1})),[[E,["project.project_manager_appointment/add"]]]),_((r(),s(m,{disabled:!k.value.length,onClick:t[2]||(t[2]=l=>j(k.value))},{default:a(()=>[Ee]),_:1},8,["disabled"])),[[E,["project.project_manager_appointment/delete"]]]),P("div",Ce,[e(J,{data:p(f).lists,onSelectionChange:T},{default:a(()=>[e(n,{type:"selection",width:"55"}),e(n,{label:"\u5E8F\u53F7",type:"index",width:"55"}),e(n,{label:"\u9879\u76EE\u540D\u79F0",prop:"project_name","show-overflow-tooltip":""}),e(n,{label:"\u5BA2\u6237\u540D\u79F0",prop:"custom_name","show-overflow-tooltip":""}),e(n,{label:"\u5408\u540C\u7F16\u53F7",prop:"contract_code","show-overflow-tooltip":""}),e(n,{label:"\u9879\u76EE\u7C7B\u578B",prop:"project_type_name","show-overflow-tooltip":""}),e(n,{label:"\u9879\u76EE\u91D1\u989D",prop:"amount","show-overflow-tooltip":""}),e(n,{label:"\u7ACB\u9879\u65E5\u671F",prop:"project_approval_date","show-overflow-tooltip":""}),e(n,{label:"\u9879\u76EE\u5F00\u59CB\u65E5\u671F",prop:"start_date","show-overflow-tooltip":""}),e(n,{label:"\u9879\u76EE\u4EA4\u4ED8\u65E5\u671F",prop:"delivery_date","show-overflow-tooltip":""}),e(n,{label:"\u64CD\u4F5C",width:"150",fixed:"right"},{default:a(({row:l})=>[_((r(),s(m,{type:"primary",link:"",onClick:V=>U(l)},{default:a(()=>[he]),_:2},1032,["onClick"])),[[E,["project.project_manager_appointment/edit"]]]),_((r(),s(m,{type:"danger",link:"",onClick:V=>j(l.id)},{default:a(()=>[we]),_:2},1032,["onClick"])),[[E,["project.project_manager_appointment/delete"]]]),_((r(),s(m,{link:"",onClick:V=>O(l)},{default:a(()=>[Fe]),_:2},1032,["onClick"])),[[E,["project.project_manager_appointment/detail"]]])]),_:1})]),_:1},8,["data"])]),P("div",ye,[e(z,{modelValue:p(f),"onUpdate:modelValue":t[3]||(t[3]=l=>ce(f)?f.value=l:null),onChange:p(v)},null,8,["modelValue","onChange"])])]),_:1})),[[G,p(f).loading]]),h.value?(r(),s(re,{key:0,ref_key:"editRef",ref:C,"dict-data":p(g),onSuccess:p(v),onClose:t[4]||(t[4]=l=>h.value=!1)},null,8,["dict-data","onSuccess"])):Y("",!0),y.value?(r(),s(se,{key:1,ref_key:"detailRef",ref:F,"dict-data":p(g),onClose:t[5]||(t[5]=l=>y.value=!1)},null,8,["dict-data"])):Y("",!0)])}}});export{yt as default};