2 lines
6.2 KiB
JavaScript
2 lines
6.2 KiB
JavaScript
import{I as J,y as K,w as Q,D as X,C as Y,L as ee,Z as oe,M as te,N as ae}from"./element-plus.4ff6f47d.js";import{_ as le}from"./index.vue_vue_type_script_setup_true_lang.7dabd2cb.js";import{f as ne,a as ie}from"./index.aaca920c.js";import{u as ue}from"./usePaging.f6660143.js";import{u as se}from"./useDictOptions.c83e2497.js";import{_ as re,a as pe,b as P,c as de}from"./edit.vue_vue_type_script_setup_true_name_projectEdit_lang.b36f85ba.js";import{d as N,a0 as $,s as L,r as g,ai as ce,o as l,c as h,V as e,M as t,O as _,u as s,L as p,S as R,a as S,W as me,a8 as _e,k as fe,T as d,n as D,U as ve}from"./@vue.ab566ce7.js";import"./lodash.8ea2174a.js";import he from"./detail.73d3310e.js";import"./@vueuse.8fcae4c2.js";import"./@element-plus.8497a500.js";import"./lodash-es.49f4af13.js";import"./dayjs.fc5568d8.js";import"./axios.5b893b79.js";import"./async-validator.fb49d0f5.js";import"./@ctrl.82a509e0.js";import"./escape-html.e5dfadb9.js";import"./normalize-wheel-es.8aeb3683.js";import"./vue-router.87ebc608.js";import"./pinia.b6700c26.js";import"./vue-demi.ebc8116b.js";import"./css-color-function.4cbccc26.js";import"./color.033abf8c.js";import"./clone.a6258514.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./debug.7eedf28f.js";import"./ms.a9ae1d6d.js";import"./nprogress.93182424.js";import"./vue-clipboard3.6a55d49e.js";import"./clipboard.2986c82d.js";import"./echarts.b30ab882.js";import"./tslib.60310f1a.js";import"./zrender.3760070d.js";import"./highlight.js.4ebdf9a4.js";import"./@highlightjs.62ff6725.js";import"./index.vue_vue_type_style_index_0_lang.0c71951f.js";import"./common.3ce42f04.js";import"./index.ff7c6188.js";import"./project_document_set.11dcf684.js";import"./index.vue_vue_type_script_setup_true_lang.c07aa9ab.js";import"./project.86812b1a.js";import"./custom.01004c04.js";const we=d("\u67E5\u8BE2"),Fe=d("\u91CD\u7F6E"),ke=d(" \u65B0\u589E "),Ce=d(" \u5220\u9664 "),be={class:"mt-4"},Ee={key:0},ye={key:1},ge=d(" \u7F16\u8F91 "),De=d(" \u5220\u9664 "),je=d(" \u8BE6\u60C5 "),xe={class:"flex justify-end mt-4"},Be=N({name:"projectLists"}),Eo=N({...Be,setup(Ve){$([]);const b=L(),w=L(),F=g(!1),E=g(!1),m=$({code:"",name:""}),y=g([]),T=n=>{y.value=n.map(({id:o})=>o)},{dictData:j}=se(""),{pager:f,getLists:k,resetParams:I,resetPage:U}=ue({fetchFun:pe,params:m}),A=async()=>{var n;F.value=!0,await D(),(n=w.value)==null||n.open("add")},M=async n=>{var r,u;console.log(n.id);let o=await P({id:n.id});F.value=!0,await D(),(r=w.value)==null||r.open("edit"),(u=w.value)==null||u.setFormData(o)},x=async n=>{await ne.confirm("\u786E\u5B9A\u8981\u5220\u9664\uFF1F"),await de({id:n}),k()},q=async n=>{var r,u;let o=await P({id:n.id});E.value=!0,await D(),(r=b.value)==null||r.open(),(u=b.value)==null||u.setFormData(o)};return k(),(n,o)=>{const r=J,u=K,c=Q,O=X,B=Y,W=ie,i=ee,Z=oe,z=te,G=le,v=ce("perms"),H=ae;return l(),h("div",null,[e(B,{class:"!border-none mb-4",shadow:"never"},{default:t(()=>[e(O,{class:"mb-[-16px]",model:m,inline:""},{default:t(()=>[e(u,{label:"\u6587\u6863\u7F16\u7801",prop:"code"},{default:t(()=>[e(r,{class:"w-[280px]",modelValue:m.code,"onUpdate:modelValue":o[0]||(o[0]=a=>m.code=a),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u6587\u6863\u7F16\u7801"},null,8,["modelValue"])]),_:1}),e(u,{label:"\u6587\u6863\u540D\u79F0",prop:"name"},{default:t(()=>[e(r,{class:"w-[280px]",modelValue:m.name,"onUpdate:modelValue":o[1]||(o[1]=a=>m.name=a),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u6587\u6863\u540D\u79F0"},null,8,["modelValue"])]),_:1}),e(u,null,{default:t(()=>[e(c,{type:"primary",onClick:s(U)},{default:t(()=>[we]),_:1},8,["onClick"]),e(c,{onClick:s(I)},{default:t(()=>[Fe]),_:1},8,["onClick"])]),_:1})]),_:1},8,["model"])]),_:1}),_((l(),p(B,{class:"!border-none",shadow:"never"},{default:t(()=>[_((l(),p(c,{type:"primary",onClick:A},{icon:t(()=>[e(W,{name:"el-icon-Plus"})]),default:t(()=>[ke]),_:1})),[[v,["project.project_document/add"]]]),_((l(),p(c,{disabled:!y.value.length,onClick:o[2]||(o[2]=a=>x(y.value))},{default:t(()=>[Ce]),_:1},8,["disabled"])),[[v,["project.project_document/delete"]]]),S("div",be,[e(z,{data:s(f).lists,onSelectionChange:T},{default:t(()=>[e(i,{type:"selection",width:"55"}),e(i,{label:"\u5E8F\u53F7",type:"index",width:"55"}),e(i,{label:"ID",prop:"id","show-overflow-tooltip":""}),e(i,{label:"\u9879\u76EE\u540D\u79F0",prop:"project_name","show-overflow-tooltip":""}),e(i,{label:"\u9879\u76EE\u7F16\u7801",prop:"project_code","show-overflow-tooltip":""}),e(i,{label:"\u6587\u6863\u5927\u7C7B",prop:"large_category","show-overflow-tooltip":""}),e(i,{label:"\u6587\u6863\u4E2D\u7C7B",prop:"middle_category","show-overflow-tooltip":""}),e(i,{label:"\u6587\u6863\u7F16\u53F7",prop:"code","show-overflow-tooltip":""}),e(i,{label:"\u6587\u6863\u540D\u79F0",prop:"name","show-overflow-tooltip":""}),e(i,{label:"\u7248\u672C\u53F7",prop:"version","show-overflow-tooltip":""}),e(i,{label:"\u9644\u4EF6",prop:"annex","show-overflow-tooltip":""},{default:t(({row:a})=>[a.annex&&a.annex.length>0?(l(),h("div",Ee,[(l(!0),h(me,null,_e(a.annex,(C,V)=>(l(),h("div",{key:V},[e(Z,{href:C,target:"_blank"},{default:t(()=>[d("\u6587\u4EF6"+ve(V+1)+"\u67E5\u770B",1)]),_:2},1032,["href"])]))),128))])):(l(),h("div",ye," \u6682\u65E0\u6587\u4EF6 "))]),_:1}),e(i,{label:"\u64CD\u4F5C",width:"150",fixed:"right"},{default:t(({row:a})=>[_((l(),p(c,{type:"primary",link:"",onClick:C=>M(a)},{default:t(()=>[ge]),_:2},1032,["onClick"])),[[v,["project.project_document/edit"]]]),_((l(),p(c,{type:"danger",link:"",onClick:C=>x(a.id)},{default:t(()=>[De]),_:2},1032,["onClick"])),[[v,["project.project_document/delete"]]]),_((l(),p(c,{link:"",onClick:C=>q(a)},{default:t(()=>[je]),_:2},1032,["onClick"])),[[v,["project.project_document/detail"]]])]),_:1})]),_:1},8,["data"])]),S("div",xe,[e(G,{modelValue:s(f),"onUpdate:modelValue":o[3]||(o[3]=a=>fe(f)?f.value=a:null),onChange:s(k)},null,8,["modelValue","onChange"])])]),_:1})),[[H,s(f).loading]]),F.value?(l(),p(re,{key:0,ref_key:"editRef",ref:w,"dict-data":s(j),onSuccess:s(k),onClose:o[4]||(o[4]=a=>F.value=!1)},null,8,["dict-data","onSuccess"])):R("",!0),E.value?(l(),p(he,{key:1,ref_key:"detailRef",ref:b,"dict-data":s(j),onClose:o[5]||(o[5]=a=>E.value=!1)},null,8,["dict-data"])):R("",!0)])}}});export{Eo as default};
|