2 lines
6.6 KiB
Java
2 lines
6.6 KiB
Java
var k=(e,p,o)=>new Promise((l,s)=>{var u=t=>{try{i(o.next(t))}catch(a){s(a)}},r=t=>{try{i(o.throw(t))}catch(a){s(a)}},i=t=>t.done?l(t.value):Promise.resolve(t.value).then(u,r);i((o=o.apply(e,p)).next())});import{B as G}from"./index-BDvqZ5j4.js";import K from"./OnlineForm-EKDpzQwF.js";import{u as Q}from"./useAutoModal-C9ZiBxOc.js";import{C as U}from"./CommentPanel-Dk7IUKj3.js";import{a as q}from"./constant-DfcHKztj.js";import{e as J,h as X,r as y,y as f,z as c,A as m,B as N,K as b,f as C,C as Y,H as O,F as Z,D as _,E as x,G as B,Q as F}from"./vue-vendor-DNhG1Cve.js";import{au as ee}from"./index-X7Y8jykP.js";import{O as te}from"./index-CuWaQdlK.js";import{A as oe}from"./index-DO7ZhK45.js";import"./BasicModal-xH56XuRZ.js";import"./ModalHeader-Sr8KwhJJ.js";import"./useTimeout-D5AmIBZw.js";import"./emoji-mart-vue-fast-R0uJEDq-.js";import"./index-BzChaRPg.js";import"./useWindowSizeFn-C-0M9_Ul.js";import"./index-ByCwbQDV.js";import"./index-Upeu4GGa.js";import"./index-C4wWpZeQ.js";import"./index-M9QP6cvf.js";import"./Skeleton-CimgOdM7.js";import"./useScrollTo-0FPEw5-K.js";import"./useIntersectionObserver-BGOgyKyu.js";import"./useAppInject-DPZGPcR3.js";import"./BasicForm-ClUSoD_-.js";import"./helper-DcLcf4v6.js";import"./BasicForm.vue_vue_type_style_index_0_lang-B29PWQy0.js";import"./index-saD4h7VJ.js";import"./useBreakpoint-DXhPW7nV.js";import"./useEventListener-BRXjwk7A.js";import"./breakpointEnum-BhAg6bcX.js";import"./uniqBy--vsL0WVB.js";import"./useForm-D61zovon.js";import"./useExtendComponent-DsD-dPUC.js";import"./JUpload.vue_vue_type_style_index_0_lang-B_SS088g.js";import"./JUploadModal.vue_vue_type_script_setup_true_lang-CSwYeVkH.js";import"./useModal-DaJ3Bflg.js";import"./LinkTableSelect-Bxfjs2Wv.js";import"./useLinkTable-DuzCQq29.js";import"./JDictSelectUtil-DwVTEDM5.js";import"./index-Cq6YxX27.js";import"./placeholderImage-CRpUMlaT.js";import"./EditOutlined-drlR34lz.js";import"./LinkTableCard-BUdn9nTb.js";import"./MinusCircleFilled-BLRBKPEV.js";import"./OnlineSelectCascade-BuXb37Ka.js";import"./useAutoForm-Dtkm06h9.js";import"./user.api-M95RuX7p.js";import"./customExpression-DKKqya45.js";import"./quarterOfYear-BU2sPnff.js";import"./useEnhance-DSMGDhnx.js";import"./OnlineSubForm-Dzb1OYao.js";/* empty css */import"./OnlinePopModal-PPYKdfpV.js";import"./OnlinePopForm-DsBK5td-.js";import"./FormOutlined-Y84itqS0.js";import"./PrinterOutlined-C4QwxYYW.js";/* empty css */import"./JModalTip-BKHwxwTZ.js";/* empty css */import"./useCustomHook-DGM29EbD.js";/* empty css */import"./UserSelectModal-BFDUCW9t.js";import"./SelectedUserItem-RRb_QZKg.js";import"./index-B4gPlWQt.js";import"./eagerComputed-BTlOruLW.js";import"./index-DSsDi_fL.js";import"./Group-UHkub2tu.js";import"./Checkbox-Dbxs4we4.js";import"./index-BuONesFs.js";import"./index-DfHu-LAS.js";import"./Group-DBzJABA_.js";import"./RadioButton-DRBix2Fq.js";import"./index-Wl3jtD-0.js";import"./index-C7ckZv9Z.js";import"./DirectoryTree-nk_YTTIy.js";import"./FolderOpenOutlined-SzIPA7z0.js";import"./index-Cl-8Hzo4.js";import"./useMaxLevel-DE205ncc.js";import"./UploadOutlined-D3m-zwOG.js";import"./index-CeNCCWzL.js";/* empty css */import"./MessageOutlined-BnylU_gE.js";const ne=J({name:"OnlineAutoModal",props:{id:{type:String,default:""},source:{type:String,default:""},buttonSwitch:Object,cgBIBtnMap:Object,confirmBtnCfg:{type:Object,default:()=>({enabled:!0,buttonName:"确定",buttonIcon:""})},cancelBtnCfg:{type:Object,default:()=>({enabled:!0,buttonName:"关闭",buttonIcon:""})}},components:{BasicModal:G,OnlineForm:K,CommentPanel:U},emits:["success","register","formConfig"],setup(e,{emit:p}){const o=y(),l=y(0);function s(){o.value&&o.value.reload()}const{title:u,modalWidth:r,registerModal:i,closeModal:t,cgButtonList:a,handleCgButtonClick:g,disableSubmit:h,handleSubmit:n,submitLoading:I,handleCancel:M,handleFormConfig:T,onlineFormCompRef:w,formTemplate:R,isTreeForm:v,pidFieldName:A,renderSuccess:$,formRendered:E,tableName:L,tableId:j,formDataId:P,enableComment:D,onCloseEvent:S,themeTemplate:V}=Q(!1,{emit:p},s);function H(d){p("success",d),t(),S()}X(()=>e.id,W,{immediate:!0});function W(){return k(this,null,function*(){if(E.value=!1,!e.id)return;const d={};e.source===q&&(d.tabletype=3),yield T(e.id,d)})}return{title:u,onlineFormCompRef:w,renderSuccess:$,registerModal:i,handleSubmit:n,handleSuccess:H,handleCancel:M,modalWidth:r,formTemplate:R,disableSubmit:h,cgButtonList:a,handleCgButtonClick:g,isTreeForm:v,pidFieldName:A,submitLoading:I,tableName:L,tableId:j,formDataId:P,enableComment:D,commentPanelRef:o,onCloseEvent:S,themeTemplate:V,handleCommentOpen:(d,z)=>{l.value=z},commentSpan:l}}});function me(e,p,o,l,s,u){const r=b("a-button"),i=oe,t=te,a=b("online-form"),g=b("comment-panel"),h=b("BasicModal");return c(),f(h,N({title:e.title,onCancel:e.onCloseEvent,enableComment:e.enableComment,width:e.modalWidth},e.$attrs,{maxHeight:600,onRegister:e.registerModal,wrapClassName:"jeecg-online-modal",onOk:e.handleSubmit,onCommentOpen:e.handleCommentOpen}),{footer:m(()=>[C(t,null,{default:m(()=>[C(i,{span:24-e.commentSpan},{default:m(()=>[(c(!0),Y(Z,null,_(e.cgButtonList,n=>(c(),f(r,{key:n.id,type:"primary",onClick:I=>e.handleCgButtonClick(n.optType,n.buttonCode),preIcon:n.buttonIcon?"ant-design:"+n.buttonIcon:""},{default:m(()=>[x(B(n.buttonName),1)]),_:2},1032,["onClick","preIcon"]))),128)),!e.disableSubmit&&e.confirmBtnCfg.enabled?(c(),f(r,{key:"submit",type:"primary",preIcon:e.confirmBtnCfg.buttonIcon,loading:e.submitLoading,onClick:e.handleSubmit},{default:m(()=>[F("span",null,B(e.confirmBtnCfg.buttonName),1)]),_:1},8,["preIcon","loading","onClick"])):O("",!0),e.cancelBtnCfg.enabled?(c(),f(r,{key:"back",onClick:e.handleCancel},{default:m(()=>[F("span",null,B(e.cancelBtnCfg.buttonName),1)]),_:1},8,["onClick"])):O("",!0)]),_:1},8,["span"])]),_:1})]),comment:m(()=>[C(g,{ref:"commentPanelRef",tableId:e.tableId,tableName:e.tableName,dataId:e.formDataId},null,8,["tableId","tableName","dataId"])]),default:m(()=>[C(a,N(e.$attrs,{ref:"onlineFormCompRef",id:e.id,disabled:e.disableSubmit,"form-template":e.formTemplate,isTree:e.isTreeForm,pidField:e.pidFieldName,themeTemplate:e.themeTemplate,cgBIBtnMap:e.cgBIBtnMap,buttonSwitch:e.buttonSwitch,onRendered:e.renderSuccess,onSuccess:e.handleSuccess}),null,16,["id","disabled","form-template","isTree","pidField","themeTemplate","cgBIBtnMap","buttonSwitch","onRendered","onSuccess"])]),_:1},16,["title","onCancel","enableComment","width","onRegister","onOk","onCommentOpen"])}const jt=ee(ne,[["render",me]]);export{jt as default};
|