2 lines
5.2 KiB
Java
2 lines
5.2 KiB
Java
import x from"./OnlineForm-XYVwvG5y-Bwf4FJdQ.js";import{d as B,f as p,w as L,e as V,n as O,ah as f,ar as v,as as y,k as h,aF as I,ag as P,G as R}from"./vue-vendor-C7Zq48Yl.js";import{q as _,f as E}from"./index-BI6CMai0.js";import{g as b}from"./useExtendComponent-D3N4jqMD-BdcrIiWO.js";import G from"./TaskOpinionList-eOcI0in3-CS7Sq7fd.js";import{h as H}from"./main.index-Cs5ETdXF.js";import"./index-Di-j2gt4.js";import"./BasicForm-BJnSRkIE.js";import"./antd-vue-vendor-BPnV8VqP.js";import"./componentMap-BBZeqR-K.js";import"./useFormItem-BdW6EoZe.js";import"./index-Du0A3ksf.js";import"./BasicModal-0sAdFEk_.js";import"./ModalHeader-keHdAHWH.js";import"./useTimeout-DDl4l82I.js";import"./vxe-table-vendor-B88kchpX.js";import"./index-DeEq83Ov.js";import"./useWindowSizeFn-PRZSD86C.js";import"./index-pxs5MULf.js";import"./index-BgYCgfME.js";import"./index-f8O7TghW.js";import"./useIntersectionObserver-BMxdTqP3.js";import"./download-UE0L9Rfp.js";import"./base64Conver-24EVOS6V.js";import"./index-CIBZG4nR.js";import"./index-BhQEwnQQ.js";import"./useCountdown-DqnNWBp6.js";import"./useFormItemSingle-BbRhswfn.js";import"./JSelectUser-B71zikzw.js";import"./props-DAezUTeZ.js";import"./JSelectBiz-CnEaVMUF.js";import"./JAddInput-D6qcyZjQ.js";import"./areaDataUtil-CbYCy3Ig.js";import"./index-CNkz_PUv.js";import"./index-CUdllngZ.js";import"./bem-EhXRi4nW.js";import"./props-D4vdsy3J.js";import"./useContextMenu-Cwx1lIOK.js";import"./depart.api-DeMNV8zW.js";import"./TreeIcon-DE4jdeZV.js";import"./JSelectDept-DRDVeruW.js";import"./JPopup-Bva6u6tk.js";import"./usePopBiz-CG0vVpgI.js";import"./useMethods-DVip17X8.js";import"./index-Dg4HCEvo.js";import"./JEllipsis-DqRFTSm0.js";import"./JUpload-Cz9HN61B.js";import"./index-MGIrEF-A.js";import"./index-MREkPhsT.js";import"./useForm-BZtHZyx2.js";import"./JAreaLinkage-BeRUFHSB.js";import"./JCodeEditor-CLVZA7Uj.js";import"./htmlmixed-NhwyF9-q.js";import"./vue-CgbRSACy.js";/* empty css */import"./EasyCronInput-7xfJ3nBh.js";import"./useCustomHook-B35kFqDB-CgF4pAeZ.js";import"./constant-DnbpmwZg-Ddbq-fz2.js";import"./index-CTZQXB0y.js";import"./user.api-C1eRtqao.js";import"./customExpression-C9jki4vL.js";import"./index-BgJbdjPf.js";import"./BasicTable-DfLkrEeh.js";import"./injectionKey-DPVn4AgL.js";import"./useListPage-BWia52we.js";import"./LinkTableListPiece-DrNSark7-C1dHz4Dy.js";import"./DictColors-Cn4yPqfS.js";import"./OnlineSelectCascade-BWTVAfOS-Cb16XdEY.js";import"./JModalTip-VeUmOvUx-C10ppy-S.js";var g=(t,a,o)=>new Promise((d,m)=>{var c=e=>{try{i(o.next(e))}catch(n){m(n)}},s=e=>{try{i(o.throw(e))}catch(n){m(n)}},i=e=>e.done?d(e.value):Promise.resolve(e.value).then(c,s);i((o=o.apply(t,a)).next())});const M=B({name:"ProcessOnlineForm",inheritAttrs:!1,components:{TaskOpinionList:G,OnlineForm:x},props:{dataId:{type:String,default:""},tableName:{type:String,default:""},taskId:{type:String,default:""},taskOriginalId:{type:String,default:""},procInsId:{type:String,default:""},processTabType:{type:String,default:""},disabled:{type:Boolean,default:!1}},emits:["success","validate"],setup(t,{emit:a}){const o=p(),d=p(""),m=p(1),c=p(!1),s=p(""),i=p(!1);L(()=>t.tableName,r=>{r&&n()},{immediate:!0});const e=V(()=>!_().useNewTaskModal);function n(){return g(this,null,function*(){i.value=!0;const r=`/online/cgform/api/getFormItemBytbname/${t.tableName}`,N={taskId:t.taskId};try{let l=yield E.get({url:r,params:N});d.value=l.head.id,m.value=Number(l.head.formTemplate||1),c.value=l.head.isTree==="Y",s.value=l.head.treeParentIdField||"",yield O(()=>g(null,null,function*(){(yield b(o)).createRootProperties(l)}))}catch(l){}})}function k(){return g(this,null,function*(){let r=yield b(o);i.value=!1,r.show(!0,{id:t.dataId})})}const u=p(!1);function T(){return g(this,null,function*(){u.value=!0,o.value.handleSubmit()})}function S(r=null){u.value=!1,a("success",r)}function F(){o.value.handleValidate()}function C(r=null){a("validate",r)}function w(){u.value=!1}return{onlineFormCompRef:o,formId:d,formTemplate:m,isTreeForm:c,pidFieldName:s,renderSuccess:k,handleSuccess:S,handleClose:w,handleSubmit:T,handleValidate:F,validateBack:C,buttonLoading:u,spinLoading:i,showSubmitButton:e}}}),Y={class:"cust-onl-form"},j={key:0,style:{width:"100%","text-align":"center","margin-top":"5px"}};function q(t,a,o,d,m,c){const s=f("a-button"),i=f("TaskOpinionList"),e=f("online-form"),n=f("a-spin");return y(),v("div",Y,[h(n,{spinning:t.spinLoading},{default:I(()=>[h(e,{ref:"onlineFormCompRef",id:t.formId,disabled:t.disabled,"form-template":t.formTemplate,isTree:t.isTreeForm,pidField:t.pidFieldName,taskId:t.taskId,onRendered:t.renderSuccess,onSuccess:t.handleSuccess,onValidate:t.validateBack,onClose:t.handleClose},{bottom:I(()=>[!t.disabled&&!t.spinLoading&&t.showSubmitButton?(y(),v("div",j,[h(s,{preIcon:"ant-design:check",style:{width:"126px"},type:"primary",onClick:t.handleSubmit,loading:t.buttonLoading},{default:I(()=>[...a[0]||(a[0]=[R(" 提 交 ",-1)])]),_:1},8,["onClick","loading"])])):P("",!0),h(i,{class:"task-opinion",taskId:t.taskOriginalId,procInsId:t.procInsId,processTabType:t.processTabType},null,8,["taskId","procInsId","processTabType"])]),_:1},8,["id","disabled","form-template","isTree","pidField","taskId","onRendered","onSuccess","onValidate","onClose"])]),_:1},8,["spinning"])])}const ro=H(M,[["render",q],["__scopeId","data-v-0c6a105e"]]);export{ro as default};
|