1 |
- import{d as b,bK as I,r as v,e as x,o as U,q,w as r,g as w,ay as B,f as E,m as F,a as t,B as j,b1 as D,__tla as H}from"./index-73e02845.js";import{b as K,a as P,U as S,H as $,__tla as k}from"./upload-8f3e317f.js";import{u as z,__tla as A}from"./useMessage-1490ad82.js";import{U as i,__tla as C}from"./useUpload-a526e316.js";import{_ as G}from"./_plugin-vue_export-helper-1b428a4d.js";let _,J=Promise.all([(()=>{try{return H}catch{}})(),(()=>{try{return k}catch{}})(),(()=>{try{return A}catch{}})(),(()=>{try{return C}catch{}})()]).then(async()=>{let l;l={class:"el-upload__tip",style:{"margin-left":"5px"}},_=G(b({__name:"UploadFile",props:{type:{}},emits:["uploaded"],setup(c,{emit:p}){const e=z(),n=c,u=I("accountId"),o=v([]),d=p,s=x({type:i.Image,title:"",introduction:"",accountId:u}),m=n.type===i.Image?K:P,f=a=>{if(a.code!==0)return e.alertError("\u4E0A\u4F20\u51FA\u9519\uFF1A"+a.msg),!1;o.value=[],s.title="",s.introduction="",e.notifySuccess("\u4E0A\u4F20\u6210\u529F"),d("uploaded")},y=a=>e.error("\u4E0A\u4F20\u5931\u8D25: "+a.message);return(a,L)=>{const h=j,g=D;return U(),q(g,{action:t(S),headers:t($),multiple:"",limit:1,"file-list":t(o),data:t(s),"on-error":y,"before-upload":t(m),"on-success":f},{tip:r(()=>[w("span",l,[B(a.$slots,"default",{},void 0,!0)])]),default:r(()=>[E(h,{type:"primary",plain:""},{default:r(()=>[F(" \u70B9\u51FB\u4E0A\u4F20 ")]),_:1})]),_:3},8,["action","headers","file-list","data","before-upload"])}}}),[["__scopeId","data-v-c21a7348"]])});export{J as __tla,_ as default};
|