index.48d19b3d.js 7.0 KB

1
  1. import{L as ee}from"./left-pano.9b176b4c.js";/* empty css */import{d as S,K as x,r as I,g3 as A,c as R,o,e as a,u as e,h as d,j as $,f as C,L as y,cl as N,F as _,m as c,l as H,t as V,T as L,c_ as K,g4 as te,_ as D,eJ as M,b as W,au as oe,V as Y,Q as b,g5 as B,O as le,cA as ne,g6 as se,fX as ae,a as E,R as J,fH as re,eH as Q,fB as X,eh as ie,bS as ue,S as q,J as ce}from"./index.932f1548.js";import{U as de}from"./UpOutlined.ead005a4.js";import{D as pe}from"./DownOutlined.e8d377cc.js";import{a as me,T as fe}from"./TabPane.0bc0f3b9.js";import"./index.f159ba9e.js";import"./Menu.b368adf3.js";import"./isMobile.39a6fa85.js";const ve={class:"items"},_e={class:"img-item-content"},ye=S({__name:"modal-floder-view",props:{root:null},emits:["preview"],setup(n,{emit:p}){var m;const l=n,t=k=>{var v;return!((v=k.children)!=null&&v.length)},w=x(()=>{var k;return((k=l.root.children)==null?void 0:k.every(v=>t(v)))&&!l.root.flat}),s=x(()=>w.value?l.root.children.find(k=>!t(k)):null),r=k=>{p("preview",[k,l.root])},f=I((m=s.value)==null?void 0:m.id),i=x(()=>l.root.flat?A(l.root):l.root.floders),u=x(()=>l.root.flat?[]:l.root.children),g=x(()=>i.value.length),F=I(!1),P=6,j=x(()=>F.value?g.value:Math.min(P,g.value)),U=x(()=>g.value>P);return(k,v)=>{const O=R("ui-group-option"),Z=R("ui-group"),z=R("ModalFloderView",!0);return o(),a(_,null,[e(i).length?(o(),d(Z,{key:0},{default:$(()=>[C(O,null,{default:$(()=>[y("span",{onClick:v[0]||(v[0]=h=>e(U)&&(F.value=!F.value)),class:N({["fun-ctrl"]:e(U)})},[e(U)?(o(),a(_,{key:0},[F.value?(o(),d(e(de),{key:0})):(o(),d(e(pe),{key:1}))],64)):c("",!0),H(" "+V(n.root.title),1)],2)]),_:1}),C(O,null,{default:$(()=>[y("div",ve,[(o(!0),a(_,null,L(e(j),(h,T)=>(o(),a("div",{class:"img-item",key:e(i)[T].filesId,style:K({"--rawLen":P})},[y("div",_e,[y("div",null,[C(te,{focus:"",media:{url:e(i)[T].filesUrl},onClick:Ve=>r(e(i)[T])},null,8,["media","onClick"])])])],4))),128))])]),_:1})]),_:1})):c("",!0),e(w)?(o(!0),a(_,{key:2},L(e(u),h=>(o(),a(_,{key:h.id},[t(h)?(o(),d(z,{key:0,root:h,onPreview:v[3]||(v[3]=T=>p("preview",T))},null,8,["root"])):c("",!0)],64))),128)):(o(),d(e(fe),{key:1,activeKey:f.value,"onUpdate:activeKey":v[2]||(v[2]=h=>f.value=h),class:"f-tabs"},{default:$(()=>[(o(!0),a(_,null,L(n.root.children,h=>(o(),a(_,null,[e(A)(h).length?(o(),d(e(me),{tab:h.title,key:h.id},{default:$(()=>[C(z,{root:h,onPreview:v[1]||(v[1]=T=>p("preview",T))},null,8,["root"])]),_:2},1032,["tab"])):c("",!0)],64))),256))]),_:1},8,["activeKey"]))],64)}}});const we=D(ye,[["__scopeId","data-v-d2ef7825"]]),ge=["onClick"],ke={class:"modal-root-content"},he=S({__name:"floder-view",props:{root:null,index:null},emits:["preview"],setup(n,{emit:p}){const l=n,t=l.index||1,w={[M.image]:"pic",[M.video]:"a-film",[M.other]:"nav-edit",[M.audio]:"nav-edit",[M.xfile]:"nav-edit"},s=x(()=>l.root.flat?A(l.root):l.root.floders),r=x(()=>l.root.flat||l.root.modal?[]:l.root.children),f=I(!l.root.modal);return W(()=>{f.value&&console.log(oe(l.root))}),(i,u)=>{var P,j,U;const g=R("ui-icon"),F=R("FloderView",!0);return o(),a(_,null,[e(A)(n.root).length!==0?(o(),a("div",{key:0,class:N([{root:e(t)===1},"tree"])},[y("div",{class:N(["solid header",{["root-header"]:e(t)===1}]),style:K({"--index":e(t)}),onClick:u[0]||(u[0]=m=>f.value=!f.value)},[y("span",null,V(n.root.title),1),e(s).length||((P=n.root.children)==null?void 0:P.length)?(o(),d(g,{key:0,type:`pull-${f.value?"up":"down"}`,class:"icon",ctrl:""},null,8,["type"])):c("",!0)],6),!n.root.modal&&f.value&&(e(s).length||((j=e(r))==null?void 0:j.length))?(o(),a("div",{key:0,class:N(["items",{["root-items"]:e(t)===1}])},[e(s).length?(o(!0),a(_,{key:0},L(e(s),m=>(o(),a("div",{style:K({"--index":e(t)}),key:m.filesId,class:"fun-ctrl solid item",onClick:k=>i.$emit("preview",[m,n.root])},[m.metaType?(o(),d(g,{key:0,type:w[m.metaType]},null,8,["type"])):c("",!0),y("p",null,V(m.filesTitle),1)],12,ge))),128)):c("",!0),(U=e(r))!=null&&U.length?(o(!0),a(_,{key:1},L(e(r),m=>(o(),d(F,{onPreview:u[1]||(u[1]=k=>p("preview",k)),root:m,index:e(t)+1},null,8,["root","index"]))),256)):c("",!0)],2)):c("",!0)],2)):c("",!0),n.root.modal?(o(),d(e(Y),{key:1,width:"1200px",title:n.root.title,onCancel:u[3]||(u[3]=m=>f.value=!1),open:f.value,footer:null},{default:$(()=>[y("div",ke,[C(we,{root:n.root,onPreview:u[2]||(u[2]=m=>p("preview",m))},null,8,["root"])])]),_:1},8,["title","open"])):c("",!0)],64)}}});const be=D(he,[["__scopeId","data-v-bcc2b81c"]]),xe={key:0,class:"info"},$e=S({__name:"info",props:{title:null,data:null,labelMap:null},setup(n){return(p,l)=>n.data?(o(),a("div",xe,[y("h2",null,V(n.title),1),y("div",null,[(o(!0),a(_,null,L(n.labelMap,(t,w)=>(o(),a("p",null,[y("span",null,V(typeof t=="string"?t:t[0])+":",1),H(" "+V(typeof t=="string"?n.data[w]:t[1](n.data[w])),1)]))),256))])])):c("",!0)}});const G=D($e,[["__scopeId","data-v-40afad00"]]),Ce=S({__name:"index",props:{open:{type:Boolean}},emits:["update:open"],setup(n){const p={...b.case.cols,homicideCase:[b.case.cols.homicideCase,t=>t===null?"":t?b.case.yv:b.case.nv],criminalCase:[b.case.cols.criminalCase,t=>(console.error(t),t===null?"":t?b.case.yv:b.case.nv)],caseRegion:[b.case.cols.caseRegion,t=>t.join("-")],caseAddress:b.case.cols.caseAddress,latAndLong:[b.case.cols.latAndLong,t=>t?t.split(",").reverse().join(","):""]},l={...b.case.tmCols,times:[b.case.tmCols.times,t=>t.join("-")]};return(t,w)=>(o(),d(e(Y),{width:"1200px",title:e(le),onCancel:w[0]||(w[0]=s=>t.$emit("update:open",!1)),open:n.open,footer:null},{default:$(()=>{var s;return[e(B)?(o(),d(G,{key:0,title:t.$t("case.name"),data:e(B),"label-map":e(p)},null,8,["title","data","label-map"])):c("",!0),(s=e(B))!=null&&s.tmProject?(o(),d(G,{key:1,title:t.$t("case.tmName"),data:e(B).tmProject,"label-map":e(l)},null,8,["title","data","label-map"])):c("",!0)]}),_:1},8,["title","open"]))}}),Te={class:"types"},Ie=S({__name:"index",setup(n){W(()=>{E.currentRoute.value.name===J.fireInfo&&re.ga!=="true"&&E.replace({name:J.summaryShow})});const p=I(!1),l=I(-1),t=I([]),w=async([s,r])=>{if(Q(s.filesUrl)===M.other){const i=s.filesUrl.includes("blob");s.filesTypeId===100?X(s.filesUrl,s.filesTitle+".doc"):(await X(ie(s.filesUrl+(i?"":"?time="+Date.now()))),ue.success(q.t("sys.download")+q.t("resCode.0")))}else{const u=(r.flat?A(r):r.floders).map(g=>({type:Q(g.filesUrl),id:g.filesId,url:g.filesUrl}));l.value=u.findIndex(g=>g.id===s.filesId),t.value=u}};return ne(()=>ce.push(I(!1))),(s,r)=>{const f=R("ui-icon");return o(),a(_,null,[C(e(ee),null,{default:$(()=>[y("div",Te,[y("h2",{onClick:r[0]||(r[0]=i=>p.value=!0)},[H(V(s.$t("case.summary"))+" ",1),C(f,{type:`pull-${p.value?"up":"down"}`,class:"icon",ctrl:""},null,8,["type"])])]),(o(!0),a(_,null,L(e(se),i=>(o(),d(be,{key:i.id,root:i,onPreview:r[1]||(r[1]=u=>w(u))},null,8,["root"]))),128))]),_:1}),~l.value?(o(),d(e(ae),{key:0,items:t.value,current:l.value,onClose:r[2]||(r[2]=i=>l.value=-1)},null,8,["items","current"])):c("",!0),C(Ce,{open:p.value,"onUpdate:open":r[3]||(r[3]=i=>p.value=i)},null,8,["open"])],64)}}});const Be=D(Ie,[["__scopeId","data-v-dcbf24bf"]]);export{Be as default};