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