var N=Object.defineProperty,A=Object.defineProperties;var E=Object.getOwnPropertyDescriptors;var b=Object.getOwnPropertySymbols;var K=Object.prototype.hasOwnProperty,L=Object.prototype.propertyIsEnumerable;var h=(e,t,o)=>t in e?N(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o,C=(e,t)=>{for(var o in t||(t={}))K.call(t,o)&&h(e,o,t[o]);if(b)for(var o of b(t))L.call(t,o)&&h(e,o,t[o]);return e},w=(e,t)=>A(e,E(t));var s=(e,t,o)=>new Promise((g,l)=>{var a=r=>{try{c(o.next(r))}catch(p){l(p)}},y=r=>{try{c(o.throw(r))}catch(p){l(p)}},c=r=>r.done?g(r.value):Promise.resolve(r.value).then(a,y);c((o=o.apply(e,t)).next())});import{d as P,U as O,a2 as M,a3 as D,k as d,af as f,u as n,G as x,ad as G,V as Q}from"./vue-vendor-CxLCUzY4.js";import"./index-LwlFn7Y4.js";import"./index-D2AmS0aU.js";import{p as $,k as S}from"./tenant.api-CpQl223K.js";import{p as q,d as z}from"./tenant.data-jovtG_GO.js";import H from"./TenantPackMenuModal-BuAmXefp.js";import{a9 as T,ab as J,u as W}from"./index-B_2CoVdl.js";import{useListPage as X}from"./useListPage-BEtybUiF.js";import{M as Y}from"./antd-vue-vendor-CDWW6V_M.js";import{Q as Z}from"./componentMap-CzCGDP7x.js";import tt from"./BasicTable-Clbg3fHx.js";import"./BasicModal-D3g2CFhF.js";import"./ModalHeader-C-C0dUi_.js";import"./useTimeout-CB9F1PLu.js";import"./vxe-table-vendor-B5h3MVdD.js";import"./index-DAURrYyA.js";import"./useWindowSizeFn-C3WExEpc.js";import"./index-Dz2zbQB_.js";import"./index-exs4VcBw.js";import"./index-ByLO0zSl.js";import"./useIntersectionObserver-FVRzwlSd.js";import"./renderUtils-Cbe4E0PZ.js";import"./index-CkL00Q0a.js";import"./validator-jM63P_3m.js";import"./user.api-BLHI3_6c.js";import"./index-ARbUvvsq.js";import"./useForm-CcjrODHR.js";import"./JAreaLinkage-CSgDAlrn.js";import"./areaDataUtil-DFHnz1wu.js";import"./china-area-data-vendor-D0sJ9kfX.js";import"./JSelectUser-BQIJUcBR.js";import"./props-BCVPj-bG.js";import"./JSelectBiz-CJyWq5s2.js";import"./JSelectDept-wKz_Qtmc.js";import"./index-BKs2x_To.js";import"./bem-C6eT35UB.js";import"./props-BLY2qIO5.js";import"./useContextMenu-CSt5a1-F.js";import"./JCodeEditor-esTLnfS3.js";import"./useFormItem-CWa0w7fA.js";import"./htmlmixed-DRe7JlAp.js";import"./vue-B0b3nX1K.js";/* empty css             */import"./JAddInput-YFlAniYT.js";import"./depart.api-0qTriT9h.js";import"./JPopup-BJBYqoWe.js";import"./EasyCronInput-DclSHT47.js";import"./JEllipsis-Cn7GCKHR.js";import"./JDictSelectTag-CxpDdimB.js";import"./download-2tYEzlDW.js";import"./base64Conver-24EVOS6V.js";import"./index-Cgt544dC.js";import"./index-BZ9ST2iq.js";import"./useCountdown-ImUE7YaG.js";import"./useFormItemSingle-DM34aWgK.js";import"./JUpload-DzM-D4DX.js";import"./index-khU3p_On.js";import"./index-DPEnuI0R.js";import"./index-Cnb8BkwG.js";import"./injectionKey-DPVn4AgL.js";const ot=P({name:"tenant-default-pack"}),co=P(w(C({},ot),{setup(e){const{createMessage:t}=W(),[o,{openModal:g}]=T(),[l,{openModal:a}]=T(),y=J(),{prefixCls:c,tableContext:r}=X({designScope:"tenant-template",tableProps:{api:$,columns:z,formConfig:{schemas:q},beforeFetch:i=>Object.assign(i,{packType:"default"})}}),[p,{reload:R},{rowSelection:v,selectedRowKeys:m,selectedRows:et}]=r;function B(i){return[{label:"编辑",onClick:V.bind(null,i)},{label:"删除",popConfirm:{title:"是否确认删除租户产品包",confirm:U.bind(null,i.id)}}]}function F(){a(!0,{isUpdate:!1,packType:"default",showFooter:!0})}function U(i){return s(this,null,function*(){yield S({ids:i},k)})}function V(i){a(!0,{isUpdate:!0,record:i,packType:"default",showFooter:!0})}function rt(){return s(this,null,function*(){if(n(m).length>1){t.warn("请选择一个");return}a(!0,{tenantId:n(m.value.join(","))})})}function k(){(m.value=[])&&R()}function j(){return s(this,null,function*(){Y.confirm({title:"删除租户产品包",content:"是否删除租户产品包",okText:"确认",cancelText:"取消",onOk:()=>s(this,null,function*(){yield S({ids:m.value.join(",")},k)})})})}return(i,u)=>{const _=O("a-button");return M(),D("div",null,[d(n(tt),{onRegister:n(p),rowSelection:n(v)},{tableTitle:f(()=>[d(_,{preIcon:"ant-design:user-add-outlined",type:"primary",onClick:F},{default:f(()=>u[0]||(u[0]=[x("新增")])),_:1}),n(m).length>0?(M(),G(_,{key:0,preIcon:"ant-design:delete-outlined",type:"primary",onClick:j,style:{"margin-right":"5px"}},{default:f(()=>u[1]||(u[1]=[x("批量删除 ")])),_:1})):Q("",!0)]),action:f(({record:I})=>[d(n(Z),{actions:B(I)},null,8,["actions"])]),_:1},8,["onRegister","rowSelection"]),d(H,{onRegister:n(l),onSuccess:k},null,8,["onRegister"])])}}}));export{co as default};
