import{a9 as B,a5 as F,r as N,av as S,aw as J,F as L,K as U,W as P}from"./index.17037962789732.js";import"./index.170379627897337.js";import"./index.170379627897315.js";import"./index.170379627897318.js";import"./index.170379627897319.js";import{a as T,_ as q}from"./index.vue_vue_type_script_setup_true_lang.1703796278973.js";import"./index.170379627897327.js";import"./index.170379627897316.js";import"./index.170379627897317.js";import{b as D}from"./product.17037962789737.js";import{d as O,k as R,v as $,m as z,o as s,c as u,a as e,b as l,t as i,z as A,u as t,x as E,F as K,h as M,A as W,B as f}from"./vue.1703796278973.js";const G={style:{"margin-top":"10px"}},ne=O({__name:"index",props:{data:{type:Object,default:void 0},type:String},emits:["close","save"],setup(v,{emit:d}){const r=v,_=R([]),o=$({product:void 0,upload:[],file:{fileType:"xlsx",autoDeploy:!1}});z(()=>r.data,()=>{D({paging:!1,terms:[{column:"state",value:"1",type:"and"},{column:"accessProvider",value:r==null?void 0:r.type}],sorts:[{name:"createTime",order:"desc"}]}).then(c=>{c.status===200&&(_.value=c.result)})},{immediate:!0,deep:!0});const y=()=>{d("close")},b=()=>{d("close"),d("save")};return(c,n)=>{const x=B,V=F,p=N,m=S,g=T,j=q,k=J,C=L,w=U,h=P;return s(),u(h,{maskClosable:!1,width:"800px",visible:!0,title:"导入",onCancel:y},{footer:e(()=>[l(w,{type:"primary",onClick:b},{default:e(()=>[i("关闭")]),_:1})]),default:e(()=>[A("div",G,[l(C,{layout:"vertical"},{default:e(()=>[l(k,null,{default:e(()=>[l(m,{span:"24"},{default:e(()=>[l(p,{label:"产品",required:""},{default:e(()=>[l(V,{showSearch:"",value:t(o).product,"onUpdate:value":n[0]||(n[0]=a=>t(o).product=a),placeholder:"请选择产品"},{default:e(()=>[(s(!0),E(K,null,M(t(_),a=>(s(),u(x,{value:a.id,key:a.id,label:a.name},{default:e(()=>[i(W(a.name),1)]),_:2},1032,["value","label"]))),128))]),_:1},8,["value"])]),_:1})]),_:1}),l(m,{span:"24"},{default:e(()=>[t(o).product?(s(),u(p,{key:0,label:"文件格式"},{default:e(()=>[l(g,{modelValue:t(o).file,"onUpdate:modelValue":n[1]||(n[1]=a=>t(o).file=a)},null,8,["modelValue"])]),_:1})):f("",!0)]),_:1}),l(m,{span:"12"},{default:e(()=>[t(o).product?(s(),u(p,{key:0,label:"文件上传"},{default:e(()=>[l(j,{product:t(o).product,modelValue:t(o).upload,"onUpdate:modelValue":n[2]||(n[2]=a=>t(o).upload=a),file:t(o).file},null,8,["product","modelValue","file"])]),_:1})):f("",!0)]),_:1})]),_:1})]),_:1})])]),_:1})}}});export{ne as _};
