import{h as _}from"./axios--FnjuHWf.js";import{d as m,r as i,b as f,c as v,e,f as o,g as y,a as u,h as b}from"./index-eJPIzJhh.js";const g={style:{"background-color":"#d2d2fa",height:"100vh",display:"grid","place-items":"center"}},w={style:{"background-color":"#fff",width:"70%",height:"70%","border-radius":"10px",padding:"20px",overflow:"auto"}},V=e("div",{style:{display:"flex","justify-content":"space-between","align-items":"center"}},[e("div",{style:{"font-size":"20px","font-weight":"bold"}},"合并-微信数据库"),e("div",{style:{display:"flex","justify-content":"space-between","align-items":"center"}})],-1),x={style:{"margin-top":"20px"}},k=e("label",null,"数据库路径: ",-1),C=e("br",null,null,-1),P=e("label",null,"微信数据库路径: ",-1),B=e("br",null,null,-1),j=m({__name:"MergeView",setup(E){const n=i(""),s=i(""),a=i(""),c=async()=>{try{a.value=await _.post("/api/merge",{dbPath:n.value,outPath:s.value})}catch(d){return a.value=`Error fetching data: 
`+d,console.error("Error fetching data:",d),[]}};return(d,t)=>{const r=u("el-input"),p=u("el-button"),h=u("el-divider");return f(),v("div",g,[e("div",w,[V,e("div",x,[k,o(r,{placeholder:"数据库路径（文件夹，并且确保文件夹下的db文件已经解密）：",modelValue:n.value,"onUpdate:modelValue":t[0]||(t[0]=l=>n.value=l),style:{width:"80%"}},null,8,["modelValue"]),C,P,o(r,{placeholder:"输出文件夹",modelValue:s.value,"onUpdate:modelValue":t[1]||(t[1]=l=>s.value=l),style:{width:"80%"}},null,8,["modelValue"]),B,o(p,{style:{"margin-top":"10px",width:"50%"},type:"success",onClick:c},{default:y(()=>[b("合并")]),_:1}),o(h),o(r,{type:"textarea",rows:10,readonly:"",placeholder:"合并后数据库路径",modelValue:a.value,"onUpdate:modelValue":t[2]||(t[2]=l=>a.value=l),style:{width:"100%"}},null,8,["modelValue"])])])])}}});export{j as default};
