engineering/public/admin/assets/index.abac5506.js
2024-03-04 15:04:21 +08:00

2 lines
8.5 KiB
JavaScript

import{I as eo,y as to,G as lo,H as io,w as ao,D as no,C as uo,L as so,M as ro,N as po}from"./element-plus.258bf9e7.js";import{_ as co}from"./index.vue_vue_type_script_setup_true_lang.60e89e82.js";import{f as mo,a as _o}from"./index.ec401e3b.js";import{u as vo}from"./usePaging.f6660143.js";import{u as fo}from"./useDictOptions.c644f395.js";import{d as wo,a as $,e as go}from"./InvoicingRequests.ffa42549.js";import"./lodash.1d82ee7c.js";import{a as bo}from"./contract.4f8a540d.js";import{b as Fo}from"./custom.13e75d58.js";import{_ as ho}from"./edit.vue_vue_type_script_setup_true_name_projectEdit_lang.8c339049.js";import Co from"./detail.0c813a6d.js";import{d as U,a0 as A,s as P,r as g,ai as Eo,o as n,c as k,V as o,M as i,O as v,u as r,L as s,S,W as N,a8 as T,a as j,k as yo,T as m,n as B}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.50cbfcc9.js";import"./tslib.60310f1a.js";import"./zrender.a255a587.js";import"./highlight.js.4ebdf9a4.js";import"./@highlightjs.62ff6725.js";import"./index.vue_vue_type_script_setup_true_lang.291052e3.js";import"./index.vue_vue_type_script_setup_true_lang.e1e5e943.js";import"./index.9492d03b.js";import"./index.vue_vue_type_script_setup_true_lang.5a5f706a.js";import"./project.bccf4059.js";import"./projecttype.f974a874.js";const Do=m("\u67E5\u8BE2"),ko=m("\u91CD\u7F6E"),Bo=m(" \u65B0\u589E "),Vo=m(" \u5220\u9664 "),Ro={class:"mt-4"},Io=m(" \u7F16\u8F91 "),xo=m(" \u5220\u9664 "),qo=m(" \u8BE6\u60C5 "),Lo={class:"flex justify-end mt-4"},$o=U({name:"projectLists"}),Re=U({...$o,setup(Ao){A([]);const E=P(),b=P(),F=g(!1),y=g(!1),V=g([]),R=g([]),p=A({invoicing_company_name:"",contract_id:"",customer_id:""}),D=g([]),M=a=>{D.value=a.map(({id:t})=>t)},{dictData:I}=fo("pay_period,invoice_type"),{pager:f,getLists:h,resetParams:O,resetPage:G}=vo({fetchFun:wo,params:p}),H=async()=>{var a;F.value=!0,await B(),(a=b.value)==null||a.open("add")},W=async a=>{var c,u;let t=await $({id:a.id});F.value=!0,await B(),(c=b.value)==null||c.open("edit"),(u=b.value)==null||u.setFormData(t)},x=async a=>{await mo.confirm("\u786E\u5B9A\u8981\u5220\u9664\uFF1F"),await go({id:a}),h()},z=async a=>{var c,u;let t=await $({id:a.id});y.value=!0,await B(),(c=E.value)==null||c.open(),(u=E.value)==null||u.setFormData(t)},J=()=>{bo().then(a=>{V.value=a.lists})},K=()=>{Fo().then(a=>{R.value=a.lists})};return J(),K(),h(),(a,t)=>{const c=eo,u=to,C=lo,q=io,d=ao,Q=no,L=uo,X=_o,e=so,Y=ro,Z=co,w=Eo("perms"),oo=po;return n(),k("div",null,[o(L,{class:"!border-none mb-4",shadow:"never"},{default:i(()=>[o(Q,{class:"mb-[-16px]",model:p,inline:""},{default:i(()=>[o(u,{label:"\u5F00\u7968\u516C\u53F8\u540D\u79F0",prop:"invoicing_company_name"},{default:i(()=>[o(c,{class:"w-[280px]",modelValue:p.invoicing_company_name,"onUpdate:modelValue":t[0]||(t[0]=l=>p.invoicing_company_name=l),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u5F00\u7968\u516C\u53F8\u540D\u79F0"},null,8,["modelValue"])]),_:1}),o(u,{label:"\u5BA2\u6237",prop:"customer_id"},{default:i(()=>[o(q,{class:"w-[280px]",modelValue:p.customer_id,"onUpdate:modelValue":t[1]||(t[1]=l=>p.customer_id=l),clearable:"",placeholder:"\u8BF7\u9009\u62E9\u5BA2\u6237"},{default:i(()=>[o(C,{label:"\u5168\u90E8",value:""}),(n(!0),k(N,null,T(R.value,(l,_)=>(n(),s(C,{key:_,label:l.name,value:l.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),o(u,{label:"\u5408\u540C",prop:"contract_id"},{default:i(()=>[o(q,{class:"w-[280px]",modelValue:p.contract_id,"onUpdate:modelValue":t[2]||(t[2]=l=>p.contract_id=l),clearable:"",placeholder:"\u8BF7\u9009\u62E9\u5408\u540C"},{default:i(()=>[o(C,{label:"\u5168\u90E8",value:""}),(n(!0),k(N,null,T(V.value,(l,_)=>(n(),s(C,{key:_,label:l.contract_name,value:l.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),o(u,null,{default:i(()=>[o(d,{type:"primary",onClick:r(G)},{default:i(()=>[Do]),_:1},8,["onClick"]),o(d,{onClick:r(O)},{default:i(()=>[ko]),_:1},8,["onClick"])]),_:1})]),_:1},8,["model"])]),_:1}),v((n(),s(L,{class:"!border-none",shadow:"never"},{default:i(()=>[v((n(),s(d,{type:"primary",onClick:H},{icon:i(()=>[o(X,{name:"el-icon-Plus"})]),default:i(()=>[Bo]),_:1})),[[w,["InvoicingRequests.InvoicingRequests/add"]]]),v((n(),s(d,{disabled:!D.value.length,onClick:t[3]||(t[3]=l=>x(D.value))},{default:i(()=>[Vo]),_:1},8,["disabled"])),[[w,["InvoicingRequests.InvoicingRequests/delete"]]]),j("div",Ro,[o(Y,{data:r(f).lists,onSelectionChange:M},{default:i(()=>[o(e,{type:"selection",width:"55"}),o(e,{label:"\u5E8F\u53F7",type:"index",width:"55"}),o(e,{label:"ID",prop:"customer_name","show-overflow-tooltip":""}),o(e,{label:"\u5355\u53F7",prop:"customer_name","show-overflow-tooltip":""}),o(e,{label:"\u5165\u5E93\u6D41\u6C34\u7F16\u53F7",prop:"customer_name","show-overflow-tooltip":""}),o(e,{label:"\u9879\u76EE\u7F16\u7801",prop:"project_name","show-overflow-tooltip":""}),o(e,{label:"\u9879\u76EE\u540D\u79F0",prop:"project_code","show-overflow-tooltip":""}),o(e,{label:"\u5355\u636E\u7C7B\u578B",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u4F9B\u5E94\u65B9\u5F0F",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u51FA\u5E93\u65E5\u671F",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u4ED3\u5E93",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u4ED3\u5E93\u7F16\u7801",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u4F9B\u5E94\u5546",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u4F9B\u5E94\u5546\u7F16\u7801",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u6750\u6599\u7C7B\u522B",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u6750\u6599\u4E2D\u7C7B",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u6750\u6599\u5C0F\u7C7B",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u6750\u6599\u540D\u79F0",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u6750\u6599\u7F16\u7801",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u89C4\u683C\u578B\u53F7",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u54C1\u724C",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u7279\u6B8A\u5C5E\u6027",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u5355\u4F4D",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u51FA\u5E93\u6570\u91CF",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u6210\u672C\u5355\u4EF7",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u6210\u672C\u91D1\u989D",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u662F\u5426\u5360\u7528",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u5DF2\u9000\u8D27\u6570\u91CF",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u672A\u9000\u8D27\u6570\u91CF",prop:"invoicing_date","show-overflow-tooltip":""}),o(e,{label:"\u64CD\u4F5C",width:"160",fixed:"right"},{default:i(({row:l})=>[v((n(),s(d,{type:"primary",link:"",onClick:_=>W(l)},{default:i(()=>[Io]),_:2},1032,["onClick"])),[[w,["InvoicingRequests.InvoicingRequests/edit"]]]),v((n(),s(d,{type:"danger",link:"",onClick:_=>x(l.id)},{default:i(()=>[xo]),_:2},1032,["onClick"])),[[w,["InvoicingRequests.InvoicingRequests/delete"]]]),v((n(),s(d,{link:"",onClick:_=>z(l)},{default:i(()=>[qo]),_:2},1032,["onClick"])),[[w,["InvoicingRequests.InvoicingRequests/detail"]]])]),_:1})]),_:1},8,["data"])]),j("div",Lo,[o(Z,{modelValue:r(f),"onUpdate:modelValue":t[4]||(t[4]=l=>yo(f)?f.value=l:null),onChange:r(h)},null,8,["modelValue","onChange"])])]),_:1})),[[oo,r(f).loading]]),F.value?(n(),s(ho,{key:0,ref_key:"editRef",ref:b,"dict-data":r(I),onSuccess:r(h),onClose:t[5]||(t[5]=l=>F.value=!1)},null,8,["dict-data","onSuccess"])):S("",!0),y.value?(n(),s(Co,{key:1,ref_key:"detailRef",ref:E,"dict-data":r(I),onClose:t[6]||(t[6]=l=>y.value=!1)},null,8,["dict-data"])):S("",!0)])}}});export{Re as default};