index.7c91ff4d.js 3.3 KB

1
  1. import{_ as V,d as R,E as o,aI as O,A,a7 as I,x as g,aA as q,o as x,c as M,y as t,K as l,b as c,O as S,N as h,u as d,a as y,aK as T,L as U,W as D}from"./index.743f0c80.js";import j from"./capital-modal.55dca938.js";import{B as z}from"./basic-descriptions.e56bd542.js";import{b as H}from"./index.5ec0a88b.js";import{d as K}from"./index.8212cab4.js";import{O as L}from"./inv-open.a0819b58.js";import{I as W}from"./index.5fbf2896.js";import G from"./red-dialog.9121f4b2.js";import"./configs.80dd5359.js";import"./tootip.48acd346.js";import"./status.868e86c0.js";import"./invoice.7fa18a6d.js";import"./index.398a38e6.js";const J=c("h1",{"text-xl":"","font-bold":"","mb-2":""},"\u521B\u5EFA\u9000\u7968\u7533\u8BF7",-1),P={flex:"","justify-end":"","w-full":"","mb-2":""},Q=D("\u9009\u62E9"),X=D(" n "),Y=c("div",{"mt-5":""},null,-1),Z={flex:"","w-full":"","justify-end":""},$=D("\u4FDD\u5B58"),ee=R({__name:"index",setup(te){const p=o(""),F=o(""),k=o(null),b=o(null),f=o(null),_=o(null),w=O(),{push:B}=A(),v=o(!1),a=I({invNo:"",return_reason:"",remark:""}),C={invNo:[{required:!0,trigger:"change",message:"\u8BF7\u9009\u62E9\u4E00\u5F20\u53D1\u7968"}],return_reason:[{required:!0,trigger:"change",message:"\u8BF7\u8F93\u5165\u9000\u8D27\u539F\u56E0"}],remark:[{required:!0,trigger:"change",message:"\u8BF7\u8F93\u5165\u5907\u6CE8"}]};async function E({invNo:s,inv_number:e,open_date:r}){v.value=!0,p.value=e,F.value=r;const{code:u,message:i,data:m}=await K({invNo:s});w({code:u,message:i,handler:function(){f.value=m,a.invNo=m.invNo,_.value.validateField("logNo")}}),v.value=!1}function N(){_.value.validate(async s=>{if(!s)return;const{code:e,message:r}=await H(a);w({code:e,message:r,handler:()=>B("/InvoiceSales/returnTicket")})})}return(s,e)=>{const r=g("el-button"),u=g("el-form-item"),i=g("el-input"),m=q("loading");return x(),M(U,null,[J,t(d(T),{rules:C,model:a,ref_key:"formRef",ref:_,size:"small","label-width":"100px"},{default:l(()=>[t(u,{label:"\u53D1\u7968",prop:"invNo"},{default:l(()=>[c("div",P,[t(r,{size:"small",type:"primary",onClick:e[0]||(e[0]=()=>k.value.onDisplay())},{default:l(()=>[Q]),_:1})]),f.value?S((x(),h(d(z),{key:0,"w-full":"",data:f.value,"col-number":2,columns:d(L)},null,8,["data","columns"])),[[m,v.value]]):y("v-if",!0)]),_:1}),X,p.value?(x(),h(d(W),{key:0,"mt-5":"","inv-number":p.value,type:"sale"},null,8,["inv-number"])):y("v-if",!0),Y,t(u,{label:"\u9000\u7968\u539F\u56E0",prop:"return_reason","w-480px":""},{default:l(()=>[t(i,{type:"textarea",rows:6,maxlength:"2000",max:"","w-300px":"",modelValue:a.return_reason,"onUpdate:modelValue":e[1]||(e[1]=n=>a.return_reason=n),"show-word-limit":""},null,8,["modelValue"])]),_:1}),t(u,{label:"\u5907\u6CE8",prop:"remark","w-480px":""},{default:l(()=>[t(i,{type:"textarea",rows:6,maxlength:"2000",modelValue:a.remark,"onUpdate:modelValue":e[2]||(e[2]=n=>a.remark=n),placeholder:"\u8BF7\u8F93\u5165\u53D1\u7968\u5907\u6CE8","show-word-limit":""},null,8,["modelValue"])]),_:1}),c("div",Z,[t(r,{type:"primary",onClick:N},{default:l(()=>[$]),_:1})])]),_:1},8,["model"]),t(j,{ref_key:"capitalModalRef",ref:k,onOnAddOrder:e[3]||(e[3]=n=>E(n))},null,512),t(G,{ref_key:"redDialog",ref:b},null,512)],64)}}});var _e=V(ee,[["__file","D:/work/accout-vue3-ui/src/views/InvoiceSales/returnTicket/components/create-return-ticket/index.vue"]]);export{_e as default};