import{_ as w,d as V,Z as d,ah as b,x as D,a0 as F,r as u,o as _,G as f,D as a,l as e,m as n,a as A,M as h,aQ as q}from"./index.js";import{I as U}from"./index.63cd11b6.js";const I=V({__name:"approval-pending",props:{returnType:{type:String,required:!0}},emits:["approval"],setup(c,{emit:g}){const v=c,t=d({return_img:"",status:"",remark:""}),s=d({return_img:[{required:!1,trigger:"change",message:"\u8BF7\u4E0A\u4F20\u9000\u6B3E\u56DE\u6267"}],status:[{required:!0,trigger:"change",message:"\u9009\u62E9\u5BA1\u6838\u72B6\u6001"}],remark:[{required:!0,trigger:"change",message:"\u8BF7\u8F93\u5165\u5907\u6CE8"}]}),k=b(()=>v.returnType!=="2"),p=D(null),x=()=>{p.value.validate(m=>m&&g("approval",n(t)))};return F(()=>{s.remark[0].required=String(t.status)!=="1"}),(m,r)=>{const i=u("el-option"),y=u("el-select"),l=u("el-form-item"),B=u("el-input"),C=u("el-row"),E=u("el-button");return _(),f(n(q),{ref_key:"formRef",ref:p,"label-width":"100px",size:"small",model:t,rules:s},{default:a(()=>[e(l,{label:"\u5BA1\u6279\u72B6\u6001",prop:"status"},{default:a(()=>[e(y,{"w-400px":"",modelValue:t.status,"onUpdate:modelValue":r[0]||(r[0]=o=>t.status=o)},{default:a(()=>[e(i,{label:"\u901A\u8FC7",value:"1"}),e(i,{label:"\u4E0D\u901A\u8FC7",value:"2"})]),_:1},8,["modelValue"])]),_:1}),e(l,{label:"\u5907\u6CE8",prop:"remark","w-500px":""},{default:a(()=>[e(B,{type:"textarea",modelValue:t.remark,"onUpdate:modelValue":r[1]||(r[1]=o=>t.remark=o)},null,8,["modelValue"])]),_:1}),e(C,null,{default:a(()=>[n(k)?(_(),f(l,{key:0,label:"\u9000\u6B3E\u56DE\u6267",prop:"return_img"},{default:a(()=>[e(n(U),{multiple:"",onChange:r[2]||(r[2]=o=>t.return_img=o)})]),_:1})):A("v-if",!0)]),_:1}),e(l,{"w-full":"",flex:"","justify-end":""},{default:a(()=>[e(E,{type:"primary",onClick:x},{default:a(()=>[h("\u4FDD\u5B58")]),_:1})]),_:1})]),_:1},8,["model","rules"])}}});var R=w(I,[["__file","C:/Users/89793/Desktop/projects/settle-vue3/src/views/InvoiceSales/refund/components/approval-pending.vue"]]);export{R as default};
