← Back
Editing: index236.js
import{A as e,R as l,j as a,e as s,v as t,c as i,ag as d,al as o}from"./utils-lib.js?v=1765440387";import{c,s as m,g as r,q as n,v as u,y as v,x as p,e as f,z as _,B as h,F as g,a$ as x,b8 as b,A as w,H as y,I as V,aw as j,p as C,T as I,ad as k,D as U,a5 as z,G as D,P as A,aB as F}from"./base-lib.js?v=1765440387";import{a2 as H}from"./store.js?v=1765440387";import"./__commonjsHelpers__.js?v=1765440387";import"./files.js?v=1765440387";import"./validator.js?v=1765440387";import"./index94.js?v=1765440387";import"./column.js?v=1765440387";import"./store2.js?v=1765440387";import"./index91.js?v=1765440387";const B={class:"flex flex-col h-[40rem]"},L={class:"item-card"},N={class:"item"},P={class:"title"},$=["src"],q={class:"con"},G={class:"item-card"},M={class:"item"},O={class:"con"},R={class:"item"},T={class:"con overflow-ellipsis flex-1 break-all"},E={class:"item"},J={class:"con"},K={class:"item-card"},Q={class:"item"},S={class:"con"},W={class:"item"},X={class:"con"},Y={class:"item"},Z={class:"con"},ee={class:"item-card !border-b-0"},le={class:"item"},ae={class:"con"},se={class:"item"},te={class:"con"},ie=s(c({__name:"base",setup(s){const t=H(),{fileItem:i}=m(t),d=r(()=>"".concat(i.value.path,"/").concat(i.value.name).replace(/\/\//g,"/"));return(s,t)=>{const o=a;return n(),u("div",B,[v("div",L,[v("div",N,[v("div",P,[v("img",{class:"w-[5rem] h-[5rem]",src:"/static/images/file_icon/".concat(p(i).is_dir?"folder_win10":"file",".png"),alt:""},null,8,$)]),v("div",q,[f(o,{width:"38rem",modelValue:p(i).name,"onUpdate:modelValue":t[0]||(t[0]=e=>p(i).name=e),disabled:""},null,8,["modelValue"])])])]),v("div",G,[v("div",M,[t[2]||(t[2]=v("div",{class:"title"},"类型:",-1)),v("div",O,_(p(i).st_type||"未知文件"),1)]),v("div",R,[t[3]||(t[3]=v("div",{class:"title"},"文件路径:",-1)),v("div",T,[h(_(p(d))+" ",1),v("i",{class:"svgtofont-icon-copy cursor-pointer hover:text-primary text-[1.4rem] ml-[4px] align-middle",onClick:t[1]||(t[1]=l=>p(e)({value:"".concat(p(i).path,"/").concat(p(i).name)}))})])]),v("div",E,[t[4]||(t[4]=v("div",{class:"title"},"大小:",-1)),v("div",J,_(p(i).st_size),1)])]),v("div",K,[v("div",Q,[t[5]||(t[5]=v("div",{class:"title"},"权限:",-1)),v("div",S,_(p(i).mode),1)]),v("div",W,[t[6]||(t[6]=v("div",{class:"title"},"所属组:",-1)),v("div",X,_(p(i).group),1)]),v("div",Y,[t[7]||(t[7]=v("div",{class:"title"},"所属用户:",-1)),v("div",Z,_(p(i).user),1)])]),v("div",ee,[v("div",le,[t[8]||(t[8]=v("div",{class:"title"},"访问时间:",-1)),v("div",ae,_(p(l)(p(i).st_atime)),1)]),v("div",se,[t[9]||(t[9]=v("div",{class:"title"},"修改时间:",-1)),v("div",te,_(p(l)(p(i).st_mtime)),1)])])])}}}),[["__scopeId","data-v-a6a1e032"]]),de={class:"h-[40rem] pt-[.5rem] overflow-hidden"},oe={class:"h-[36.5rem] overflow-y-auto"},ce={class:"title"},me={class:"con"},re=s(c({__name:"detail",setup(e){const l=H(),{fileItem:a,attrList:s}=m(l);return(e,l)=>(n(),u("div",de,[l[0]||(l[0]=v("div",{class:"item th"},[v("div",{class:"title"},"属性"),v("div",{class:"con"},"值")],-1)),v("div",oe,[(n(!0),u(g,null,x(p(s),e=>(n(),u("div",{key:e.title,class:"item"},[v("div",ce,_(e.title),1),v("div",me,_(e.value),1)]))),128))])]))}}),[["__scopeId","data-v-3fe95b32"]]),ne={class:"h-[40rem] pt-[.5rem] overflow-hidden"},ue={class:"h-[36.5rem] overflow-y-auto"},ve={class:"w-[14rem]"},pe={class:"w-[8.5rem]"},fe={class:"con"},_e={class:"w-[9rem] text-right"},he=s(c({__name:"history",setup(e){const a=H(),{fileItem:s}=m(a),{showHistory:d,recoverHistory:o}=a;return(e,a)=>{const d=i,c=j;return n(),u("div",ne,[a[1]||(a[1]=b('<div class="item th" data-v-d6a939e5><div class="w-[14rem]" data-v-d6a939e5>修改时间</div><div class="w-[8.5rem]" data-v-d6a939e5>文件大小</div><div class="con" data-v-d6a939e5>MD5</div><div class="w-[9rem] text-right" data-v-d6a939e5>操作</div></div>',1)),v("div",ue,[(n(!0),u(g,null,x(p(s).history,e=>(n(),u("div",{key:e.md5,class:"item"},[v("div",ve,_(p(l)(e.st_mtime)),1),v("div",pe,_("".concat(p(t)(e.st_size))),1),v("div",fe,_(e.md5),1),v("div",_e,[f(d,{onClick:l=>p(o)(e)},{default:w(()=>[...a[0]||(a[0]=[h("恢复",-1)])]),_:1},8,["onClick"])])]))),128)),y(f(c,{description:"暂无历史版本"},null,512),[[V,0===p(s).history.length]])])])}}}),[["__scopeId","data-v-d6a939e5"]]),ge={class:"h-[40rem] overflow-hidden"},xe={class:"flex justify-around"},be={class:"p-4px"},we={class:"p-4px"},ye={class:"p-4px"},Ve={class:"flex items-center pl-[3rem]"},je=s(c({__name:"auth",setup(e){const l=H(),{checkList:s}=m(l),{ownerOptions:t,checkNumber:i,changeUser:o,setFileAuths:c,reversePermission:r,getFileAuths:_}=l;return C(()=>{_()}),(e,l)=>{const m=I,_=k,g=a,x=d,b=U;return n(),u("div",ge,[v("div",xe,[v("fieldset",be,[l[9]||(l[9]=v("legend",null,"所有者",-1)),f(_,{class:"flex flex-col",style:{gap:"4px"},modelValue:p(s).owner,"onUpdate:modelValue":l[0]||(l[0]=e=>p(s).owner=e),onChange:p(r)},{default:w(()=>[f(m,{class:"ml-[1rem]",label:"r"},{default:w(()=>[...l[6]||(l[6]=[h("读取",-1)])]),_:1}),f(m,{class:"ml-[1rem]",label:"w"},{default:w(()=>[...l[7]||(l[7]=[h("写入",-1)])]),_:1}),f(m,{class:"ml-[1rem]",label:"x"},{default:w(()=>[...l[8]||(l[8]=[h("执行",-1)])]),_:1})]),_:1},8,["modelValue","onChange"])]),v("fieldset",we,[l[13]||(l[13]=v("legend",null,"用户组",-1)),f(_,{class:"flex flex-col",style:{gap:"4px"},modelValue:p(s).group,"onUpdate:modelValue":l[1]||(l[1]=e=>p(s).group=e),onChange:p(r)},{default:w(()=>[f(m,{class:"ml-[1rem]",label:"r"},{default:w(()=>[...l[10]||(l[10]=[h("读取",-1)])]),_:1}),f(m,{class:"ml-[1rem]",label:"w"},{default:w(()=>[...l[11]||(l[11]=[h("写入",-1)])]),_:1}),f(m,{class:"ml-[1rem]",label:"x"},{default:w(()=>[...l[12]||(l[12]=[h("执行",-1)])]),_:1})]),_:1},8,["modelValue","onChange"])]),v("fieldset",ye,[l[17]||(l[17]=v("legend",null,"公共",-1)),f(_,{class:"flex flex-col",modelValue:p(s).public,"onUpdate:modelValue":l[2]||(l[2]=e=>p(s).public=e),style:{gap:"4px"},onChange:p(r)},{default:w(()=>[f(m,{class:"ml-[1rem]",label:"r"},{default:w(()=>[...l[14]||(l[14]=[h("读取",-1)])]),_:1}),f(m,{class:"ml-[1rem]",label:"w"},{default:w(()=>[...l[15]||(l[15]=[h("写入",-1)])]),_:1}),f(m,{class:"ml-[1rem]",label:"x"},{default:w(()=>[...l[16]||(l[16]=[h("执行",-1)])]),_:1})]),_:1},8,["modelValue","onChange"])])]),v("div",Ve,[f(g,{width:"6rem",modelValue:p(s).auth,"onUpdate:modelValue":l[3]||(l[3]=e=>p(s).auth=e),onInput:p(i),class:"!w-6rem",type:"number",min:"0",max:"777",oninput:"if(value){value=value.replace(/[^\\d]/g,'')} if(value<=0){value=0} if(value>777){value=777}"},null,8,["modelValue","onInput"]),l[20]||(l[20]=v("div",{class:"mx-[1rem]"},"权限,所有者",-1)),f(x,{modelValue:p(s).user,"onUpdate:modelValue":l[4]||(l[4]=e=>p(s).user=e),options:p(t),class:"!w-[10rem]",onChange:p(o)},null,8,["modelValue","options","onChange"]),f(m,{class:"ml-[1rem]",modelValue:p(s).isDir,"onUpdate:modelValue":l[5]||(l[5]=e=>p(s).isDir=e)},{default:w(()=>[...l[18]||(l[18]=[h("应用到子目录",-1)])]),_:1},8,["modelValue"]),f(b,{type:"primary",class:"!ml-[2rem]",onClick:p(c)},{default:w(()=>[...l[19]||(l[19]=[h("应用",-1)])]),_:1},8,["onClick"])])])}}}),[["__scopeId","data-v-a6fb501f"]]),Ce={class:"p-2rem"},Ie=c({__name:"index",props:{compData:{default:()=>({fileItem:{},tab:"routine"})}},setup(e){const l=H(),{activeName:a,load:s}=m(l),{getFileItem:t,$reset:i}=l;return C(()=>{t()}),z(()=>{i()}),(e,l)=>{const t=F,i=o,d=D("bt-loading");return y((n(),u("div",Ce,[f(i,{modelValue:p(a),"onUpdate:modelValue":l[0]||(l[0]=e=>A(a)?a.value=e:null),type:"card"},{default:w(()=>[f(t,{label:"常规",name:"routine",lazy:""},{default:w(()=>[f(ie)]),_:1}),f(t,{label:"详细信息",name:"detail",lazy:""},{default:w(()=>[f(re)]),_:1}),f(t,{label:"历史版本",name:"history",lazy:""},{default:w(()=>[f(he)]),_:1}),f(t,{label:"权限",name:"auth",lazy:""},{default:w(()=>[f(je)]),_:1})]),_:1},8,["modelValue"])])),[[d,p(s)],[d,"正在获取文件信息,请稍候...","title"]])}}});export{Ie as default};
Save File
Cancel