var M=Object.defineProperty;var _=Object.getOwnPropertySymbols;var U=Object.prototype.hasOwnProperty,q=Object.prototype.propertyIsEnumerable;var j=(e,r,t)=>r in e?M(e,r,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[r]=t,B=(e,r)=>{for(var t in r||(r={}))U.call(r,t)&&j(e,t,r[t]);if(_)for(var t of _(r))q.call(r,t)&&j(e,t,r[t]);return e};var b=(e,r,t)=>new Promise((f,p)=>{var F=o=>{try{a(t.next(o))}catch(i){p(i)}},c=o=>{try{a(t.throw(o))}catch(i){p(i)}},a=o=>o.done?f(o.value):Promise.resolve(o.value).then(F,c);a((t=t.apply(e,r)).next())});import"./index-BN26Feep.js";import{U as l,a2 as v,a3 as $,k as u,af as k,ad as L,V as H,d as N,e as P,f as y,r as E}from"./vue-vendor-CxLCUzY4.js";import{_ as G,h as T,F as w}from"./index-Cy4uayzW.js";import{a as W,j as z}from"./data-BRhMNtcN.js";import Q from"./JeecgOrderCustomerForm-Byp2MwSR.js";import{u as X,B as Y}from"./useForm-DfoT2G6J.js";import"./componentMap-0iK4HQBq.js";import"./antd-vue-vendor-CahNzUUa.js";import"./useFormItem-IOFWTdED.js";import"./index-zKZnG1QC.js";import"./BasicModal-sKcs_9Ir.js";import"./ModalHeader-ByCVDoqO.js";import"./useTimeout-gJpgadD6.js";import"./vxe-table-vendor-Cdi8WfTx.js";import"./index-Bdn0r8CG.js";import"./useWindowSizeFn-DDyhhqyw.js";import"./index-CYoRlduV.js";import"./index-DYB8Ashr.js";import"./index-CrdW4fN1.js";import"./useIntersectionObserver-FVRzwlSd.js";import"./download-Bn4f3tzD.js";import"./base64Conver-24EVOS6V.js";import"./index-D6H6KsT6.js";import"./index-CLxBW_h0.js";import"./useCountdown-2P9HvnfJ.js";import"./useFormItemSingle-BEyrYQqf.js";import"./JSelectUser-B98pRPrS.js";import"./props-CtlWAg-s.js";import"./JSelectBiz-vYDBA0SK.js";import"./JAddInput-DP4caUmw.js";import"./areaDataUtil-Dk3xkGfK.js";import"./china-area-data-vendor-ByvEpbzN.js";import"./index-tDBMxW9-.js";import"./index-CNQBnF3P.js";import"./bem-IZKqD41e.js";import"./props-CG-jAkbI.js";import"./useContextMenu-Q6J5bB_u.js";import"./depart.api-B8q8MC-j.js";import"./JImageUpload-C5OCTlCG.js";import"./JDictSelectTag-CalJXNVe.js";import"./JSelectDept-D-TUaHvK.js";import"./JPopup-CVHkQZFq.js";import"./JEllipsis-TuDc52fh.js";import"./JUpload-DSWoDwh2.js";import"./index-B4vNk56t.js";import"./index-Dc7Jr5-j.js";import"./index-Dm1rPBfc.js";import"./JAreaLinkage-CTMEfTuh.js";import"./JCodeEditor-U9QIstNN.js";import"./htmlmixed-DoVLO6sG.js";import"./vue-DY75b9GC.js";/* empty css             */import"./EasyCronInput-CZdChTcP.js";const Z=N({name:"JeecgOrderMainForm",components:{BasicForm:Y,JeecgOrderCustomerForm:Q},props:{formData:w.object.def({}),formBpm:w.bool.def(!0)},setup(e){const[r,{setFieldsValue:t,setProps:f,getFieldsValue:p,updateSchema:F}]=X({labelWidth:150,schemas:W(e.formData),showActionButtonGroup:!1,baseColProps:{span:8}}),c=P(()=>e.formData.disabled!==!1),a=y(),o=y(),i=y(!1);let d={};const h="/test/jeecgOrderMain/queryById";function S(){return b(this,null,function*(){let n={id:e.formData.dataId};const s=yield T.get({url:h,params:n});d=B({},s),yield t(d),yield f({disabled:c.value}),yield a.value.initFormData(e.formData.dataId),yield V(e.formData.dataId),i.value=!0})}function R(){return b(this,null,function*(){let n=p(),s=Object.assign({},d,n);yield saveOrUpdate(s,!0)})}S();const I=y("jeecgOrderCustomerForm");function J(){}const O=E({loading:!1,dataSource:[],columns:K(z,"order:")});function V(n){return b(this,null,function*(){const s="/test/jeecgOrderMain/queryOrderTicketListByMainId";let C={id:n};O.dataSource=[];const g=yield T.get({url:s,params:C});g&&g.length>0&&(O.dataSource=[...g])})}function K(n,s){let C=e.formData.permissionList;return n.filter(D=>{let m=C.find(A=>A.action===s+D.key);return m?(m instanceof Array&&(m=m[0]),m.type=="2"&&!m.isAuth?(D.disabled=!0,!0):!(m.type=="1"&&!m.isAuth)):!0})}return{registerForm:r,formDisabled:c,submitForm:R,jeecgOrderCustomerFormRef:a,activeKey:I,handleChangeTabs:J,table2:O,jeecgOrderTicketRef:o,ok:i}}}),x={class:"jeecg-flow-demo"};function ee(e,r,t,f,p,F){const c=l("BasicForm"),a=l("JeecgOrderCustomerForm"),o=l("a-tab-pane"),i=l("JVxeTable"),d=l("a-tabs");return v(),$("div",x,[u(c,{onRegister:e.registerForm},null,8,["onRegister"]),u(d,{activeKey:e.activeKey,"onUpdate:activeKey":r[0]||(r[0]=h=>e.activeKey=h),onChange:e.handleChangeTabs},{default:k(()=>[u(o,{tab:"客户信息",key:"jeecgOrderCustomerForm",forceRender:!0},{default:k(()=>[u(a,{ref:"jeecgOrderCustomerFormRef",formData:e.formData},null,8,["formData"])]),_:1}),u(o,{tab:"机票信息",key:"jeecgOrderTicket",forceRender:!0},{default:k(()=>[e.ok?(v(),L(i,{key:0,ref:"jeecgOrderTicketRef",stripe:"",rowSelection:"",keepSource:"",maxHeight:300,loading:e.table2.loading,columns:e.table2.columns,dataSource:e.table2.dataSource},null,8,["loading","columns","dataSource"])):H("",!0)]),_:1})]),_:1},8,["activeKey","onChange"])])}const tt=G(Z,[["render",ee]]);export{tt as default};
