var c=(w,s,m)=>new Promise((f,p)=>{var d=o=>{try{l(m.next(o))}catch(i){p(i)}},C=o=>{try{l(m.throw(o))}catch(i){p(i)}},l=o=>o.done?f(o.value):Promise.resolve(o.value).then(d,C);l((m=m.apply(w,s)).next())});import{d as F,c as N,e as U,w as D,U as u,a2 as h,a3 as O,k as r,af as n,u as a,G as g,ad as P,V as $}from"./vue-vendor-CxLCUzY4.js";import"./index-BN5Ac_IG.js";import j from"./JeecgOrderCustomerModal-DlIi0QwL.js";import{useListPage as A}from"./useListPage-i3Wl0_Fg.js";import"./index-CF_FJn6P.js";import{c as G,a as H,d as J,b as Q}from"./erplist.api-PZf4FuwF.js";import{a9 as q,i as S,u as W}from"./index-CYriLmQo.js";import{Q as X}from"./componentMap-7D1QIeNI.js";import Y from"./BasicTable-DAfCfXmD.js";import"./antd-vue-vendor-CDWW6V_M.js";import"./index-BkgeZpOO.js";import"./useForm-8o5KRzWo.js";import"./index-CxQILSKV.js";import"./index-BRTtls-l.js";import"./index-DOuVMe-q.js";import"./index-ByLO0zSl.js";import"./useTimeout-DC8132dd.js";import"./vxe-table-vendor-B5h3MVdD.js";import"./useIntersectionObserver-FVRzwlSd.js";import"./BasicModal-BBgVjypv.js";import"./ModalHeader-jGKMr-DQ.js";import"./useWindowSizeFn-BxrEMPtP.js";import"./JAreaLinkage-DFTeDmm8.js";import"./areaDataUtil-DFHnz1wu.js";import"./china-area-data-vendor-D0sJ9kfX.js";import"./JSelectUser-nVFm3ao2.js";import"./props-DoGpHXAD.js";import"./JSelectBiz-BW6f3e--.js";import"./JSelectDept-DorRVguN.js";import"./index-BTAl55Kt.js";import"./bem-2ra1afoV.js";import"./props-BLY2qIO5.js";import"./useContextMenu-DYyhcDf7.js";import"./JCodeEditor-_KZ8XnNK.js";import"./useFormItem-CWa0w7fA.js";import"./htmlmixed-DRe7JlAp.js";import"./vue-B0b3nX1K.js";/* empty css             */import"./JAddInput-CXT54-j9.js";import"./index-BTSd5ebC.js";import"./depart.api-C9T5xfw6.js";import"./JPopup-KP1kIsae.js";import"./EasyCronInput-XK54XB3r.js";import"./JEllipsis-287cEHxd.js";import"./JDictSelectTag-Jqy9TBcS.js";import"./download-CkbK5et1.js";import"./base64Conver-24EVOS6V.js";import"./index-QMJkXEyl.js";import"./index-Bb_NRLur.js";import"./useCountdown-C3-PRPLY.js";import"./useFormItemSingle-DM34aWgK.js";import"./JUpload-pyrTRFCz.js";import"./index-Bx9Mnn3N.js";import"./index-B1-pj6uh.js";import"./index-isxCPgHp.js";import"./injectionKey-DPVn4AgL.js";import"./renderUtils-CGtepdOw.js";const ro=F({__name:"JeecgOrderCustomerList",setup(w){const s=N("orderId",U(()=>"")),m=W(),[f,{openModal:p}]=q(),d={},{prefixCls:C,tableContext:l}=A({tableProps:{api:R,tableSetting:{cacheKey:"customer"},columns:G,canResize:!1,useSearchForm:!1,actionColumn:{width:180},pagination:{current:1,pageSize:5,pageSizeOptions:["5","10","20"]}}}),[o,{reload:i,setSelectedRowKeys:k},{rowSelection:I,selectedRowKeys:_}]=l;D(s,()=>{d.orderId=a(s),i(),k([])});function R(t){return c(this,null,function*(){let{orderId:e}=t;return e==null||S(e)?[]:yield H(t)})}function v(){if(S(a(s))){m.createMessage.warning("请选择一个订单信息");return}p(!0,{isUpdate:!1,showFooter:!0})}function x(t){return c(this,null,function*(){p(!0,{record:t,isUpdate:!0,showFooter:!0})})}function M(t){return c(this,null,function*(){yield J({id:t.id},i)})}function B(){return c(this,null,function*(){yield Q({ids:_.value},()=>{_.value=[],i()})})}function K(){i()}function L(t){return[{label:"编辑",onClick:x.bind(null,t)},{label:"删除",popConfirm:{title:"是否确认删除",confirm:M.bind(null,t)}}]}return(t,e)=>{const b=u("a-button"),y=u("Icon"),T=u("a-menu-item"),V=u("a-menu"),z=u("a-dropdown");return h(),O("div",null,[r(a(Y),{onRegister:a(o),rowSelection:a(I),searchInfo:d},{tableTitle:n(()=>[r(b,{type:"primary",preIcon:"ant-design:plus-outlined",onClick:v},{default:n(()=>e[0]||(e[0]=[g(" 新增")])),_:1}),a(_).length>0?(h(),P(z,{key:0},{overlay:n(()=>[r(V,null,{default:n(()=>[r(T,{key:"1",onClick:B},{default:n(()=>[r(y,{icon:"ant-design:delete-outlined"}),e[1]||(e[1]=g(" 删除 "))]),_:1})]),_:1})]),default:n(()=>[r(b,null,{default:n(()=>[e[2]||(e[2]=g("批量操作 ")),r(y,{icon:"mdi:chevron-down"})]),_:1})]),_:1})):$("",!0)]),action:n(({record:E})=>[r(a(X),{actions:L(E)},null,8,["actions"])]),_:1},8,["onRegister","rowSelection"]),r(j,{onRegister:a(f),onSuccess:K},null,8,["onRegister"])])}}});export{ro as default};
