import{_ as v,d as _,w as i,bs as y,r as C,o as g,G as B,C as D,j as N,l as A,aq as F,aN as d}from"./index.js";import{F as b,c as h}from"./form.47628e.js";const w=_({__name:"modal",props:{visible:{type:Boolean,required:!0},companyNo:{type:String,required:!0}},emits:["refresh"],setup(t,{emit:c}){const l=t,n=i(!1),e=y(l,"visible"),u={expire_date:"",hand_uid:"",resign_date:"",resign_uid:""},a=i({...u});function m(){e.value=!1,a.value={...u}}async function p(){n.value=!0;const r=await h({...a.value,companyNo:l.companyNo});n.value=!1,r.code===0?d.success("\u6DFB\u52A0\u6210\u529F"):d.warning("\u6DFB\u52A0\u5931\u8D25"),e.value=!1,c("refresh")}return(r,o)=>{const f=C("ElDialog");return g(),B(f,{modelValue:A(e),"onUpdate:modelValue":o[1]||(o[1]=s=>F(e)?e.value=s:null),title:"\u6DFB\u52A0\u79BB\u804C\u4EA4\u63A5","close-on-click-modal":!1,onClose:m,center:""},{default:D(()=>[N(b,{data:a.value,"onUpdate:data":o[0]||(o[0]=s=>a.value=s),companyNo:t.companyNo,onSubmit:p,modal:!0},null,8,["data","companyNo"])]),_:1},8,["modelValue"])}}});var k=v(w,[["__file","C:/Users/Administrator/Desktop/projects/purchase-vue3/src/views/interest/handover/modal.vue"]]);export{k as default};
