Files
qhmes/web-dist/js/LinkTableListModal-DDOMeOT_.js
2026-06-16 18:19:57 +08:00

3 lines
11 KiB
Java

const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["js/BasicTable-C6eG0bgK.js","js/BasicTable.vue_vue_type_style_index_0_lang-B9DxrWas.js","js/vue-vendor-DNhG1Cve.js","js/BasicForm-ClUSoD_-.js","js/helper-DcLcf4v6.js","js/index-X7Y8jykP.js","js/emoji-mart-vue-fast-R0uJEDq-.js","assets/index-GuhSw_Yp.css","js/index-BzChaRPg.js","assets/index-DTCEk8S9.css","js/useAppInject-DPZGPcR3.js","js/BasicForm.vue_vue_type_style_index_0_lang-B29PWQy0.js","js/index-DO7ZhK45.js","js/index-ByCwbQDV.js","js/index-Upeu4GGa.js","js/index-C4wWpZeQ.js","js/useTimeout-D5AmIBZw.js","js/index-M9QP6cvf.js","js/Skeleton-CimgOdM7.js","js/useScrollTo-0FPEw5-K.js","js/useIntersectionObserver-BGOgyKyu.js","assets/index-zj-Vfn3Q.css","assets/BasicForm-BKgjVE-6.css","js/index-saD4h7VJ.js","js/useBreakpoint-DXhPW7nV.js","js/useEventListener-BRXjwk7A.js","js/breakpointEnum-BhAg6bcX.js","js/uniqBy--vsL0WVB.js","js/index-BDvqZ5j4.js","js/BasicModal-xH56XuRZ.js","js/ModalHeader-Sr8KwhJJ.js","assets/ModalHeader-CLCbovMP.css","js/useWindowSizeFn-C-0M9_Ul.js","js/index-CuWaQdlK.js","assets/BasicModal-ByeTDAzn.css","assets/index-CUOTvden.css","js/useForm-D61zovon.js","js/injectionKey-DPVn4AgL.js","js/index-DSsDi_fL.js","js/Group-UHkub2tu.js","js/Checkbox-Dbxs4we4.js","js/index-BuONesFs.js","js/FormOutlined-Y84itqS0.js","js/useTableContext-CncNVXgp.js","js/index-DTjkSGYl.js","js/eagerComputed-BTlOruLW.js","js/fromPairs-Dx9PT-t0.js","js/useMaxLevel-DE205ncc.js","js/index-CfNJyBRj.js","js/dropdown-jkliuVyN.js","js/index-DfHu-LAS.js","js/Group-DBzJABA_.js","js/RadioButton-DRBix2Fq.js","js/index-C7ckZv9Z.js","js/DirectoryTree-nk_YTTIy.js","js/FolderOpenOutlined-SzIPA7z0.js","js/index-Cl-8Hzo4.js","js/scrollTo-D49dA-9c.js","js/operationUnit-vCu2co3e.js","js/index-C69VKHba.js","js/index-DklMb9Qc.js","js/UpOutlined-B1UMbtrP.js","js/index-DsixALRt.js","js/dayjs-jnKD3YGS.js","js/index-aCD42OrZ.js","js/quarterOfYear-BU2sPnff.js","js/index-J2mOtM3w.js","js/dayjs-ALi1pEeb.js","js/clickOutside-DHfwTU6R.js","js/onMountedOrActivated-DhSdLlqP.js","js/throttle-De_jAmBh.js","js/uuid-CODpppBC.js","js/sortable.esm-DJNoJSdJ.js","js/RedoOutlined-Cq2g4Slp.js","js/index-CeNCCWzL.js","assets/BasicTable-Wa_ugCm0.css","js/TableAction-BiXnWkvt.js","js/TableAction.vue_vue_type_style_index_0_lang-BIWZ0bGo.js","js/index-fAAIzD3j.js","assets/index-B20OC4Sz.css","assets/TableAction-D0qHjuZb.css"])))=>i.map(i=>d[i]);
var v=(t,a,d)=>new Promise((w,y)=>{var C=l=>{try{p(d.next(l))}catch(c){y(c)}},u=l=>{try{p(d.throw(l))}catch(c){y(c)}},p=l=>l.done?w(l.value):Promise.resolve(l.value).then(C,u);p((d=d.apply(t,a)).next())});import{p as F,s as se,_ as V,d as $,au as pe,bY as me}from"./index-X7Y8jykP.js";import{B as de}from"./index-BDvqZ5j4.js";import{u as ue}from"./useListPage-CK9oQ-1O.js";import{u as ce}from"./useTableColumns-DkARxJ3d.js";import{u as fe}from"./JLinkTableCard-CiSXnD9S.js";import{a as ge}from"./useModal-DaJ3Bflg.js";import{e as ye,r as g,h as E,c as be,t as Te,K as S,y as O,z as T,A as r,f as h,Q as B,G as Q,C as L,E as D}from"./vue-vendor-DNhG1Cve.js";import"./emoji-mart-vue-fast-R0uJEDq-.js";import"./BasicModal-xH56XuRZ.js";import"./ModalHeader-Sr8KwhJJ.js";import"./useTimeout-D5AmIBZw.js";import"./index-BzChaRPg.js";import"./useWindowSizeFn-C-0M9_Ul.js";import"./index-ByCwbQDV.js";import"./index-Upeu4GGa.js";import"./index-C4wWpZeQ.js";import"./index-M9QP6cvf.js";import"./Skeleton-CimgOdM7.js";import"./useScrollTo-0FPEw5-K.js";import"./useIntersectionObserver-BGOgyKyu.js";import"./useAppInject-DPZGPcR3.js";import"./index-CuWaQdlK.js";import"./index-DO7ZhK45.js";import"./BasicTable.vue_vue_type_style_index_0_lang-B9DxrWas.js";import"./BasicForm-ClUSoD_-.js";import"./helper-DcLcf4v6.js";import"./BasicForm.vue_vue_type_style_index_0_lang-B29PWQy0.js";import"./index-saD4h7VJ.js";import"./useBreakpoint-DXhPW7nV.js";import"./useEventListener-BRXjwk7A.js";import"./breakpointEnum-BhAg6bcX.js";import"./uniqBy--vsL0WVB.js";import"./useForm-D61zovon.js";import"./injectionKey-DPVn4AgL.js";import"./index-DSsDi_fL.js";import"./Group-UHkub2tu.js";import"./Checkbox-Dbxs4we4.js";import"./index-BuONesFs.js";import"./FormOutlined-Y84itqS0.js";import"./useTableContext-CncNVXgp.js";import"./index-DTjkSGYl.js";import"./eagerComputed-BTlOruLW.js";import"./fromPairs-Dx9PT-t0.js";import"./useMaxLevel-DE205ncc.js";import"./index-CfNJyBRj.js";import"./dropdown-jkliuVyN.js";import"./index-DfHu-LAS.js";import"./Group-DBzJABA_.js";import"./RadioButton-DRBix2Fq.js";import"./index-C7ckZv9Z.js";import"./DirectoryTree-nk_YTTIy.js";import"./FolderOpenOutlined-SzIPA7z0.js";import"./index-Cl-8Hzo4.js";import"./scrollTo-D49dA-9c.js";import"./operationUnit-vCu2co3e.js";import"./index-C69VKHba.js";import"./index-DklMb9Qc.js";import"./UpOutlined-B1UMbtrP.js";import"./index-DsixALRt.js";import"./dayjs-jnKD3YGS.js";import"./index-aCD42OrZ.js";import"./quarterOfYear-BU2sPnff.js";import"./index-J2mOtM3w.js";import"./dayjs-ALi1pEeb.js";import"./clickOutside-DHfwTU6R.js";import"./onMountedOrActivated-DhSdLlqP.js";import"./throttle-De_jAmBh.js";import"./uuid-CODpppBC.js";import"./sortable.esm-DJNoJSdJ.js";import"./RedoOutlined-Cq2g4Slp.js";import"./index-CeNCCWzL.js";import"./TableAction.vue_vue_type_style_index_0_lang-BIWZ0bGo.js";import"./index-fAAIzD3j.js";import"./TableImg.vue_vue_type_style_index_0_lang-65ZOQtFn.js";import"./index-DfX9t4DO.js";import"./isNumeric-DjvBa-1E.js";import"./useTable-DbHE4FHE.js";import"./useMethods-D3efiSSd.js";import"./useApprovalSelection-D4wlWO_T.js";import"./JDictSelectUtil-DwVTEDM5.js";import"./index-Cq6YxX27.js";import"./Area-CONPDlNK.js";import"./pcaUtils-DD1r5iUJ.js";import"./LinkTableListPiece-DoOFTrC_.js";import"./DictColors-Cn4yPqfS.js";import"./placeholderImage-CRpUMlaT.js";import"./MinusCircleFilled-BLRBKPEV.js";const he=ye({name:"LinkTableListModal",props:{id:{type:String,default:""},multi:{type:Boolean,default:!1},addAuth:{type:Boolean,default:!0}},components:{BasicModal:de,BasicTable:F(()=>V(()=>import("./BasicTable-C6eG0bgK.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75])),{loading:!0,delay:1e3}),TableAction:F(()=>V(()=>import("./TableAction-BiXnWkvt.js"),__vite__mapDeps([76,77,5,6,2,7,78,48,49,79,43,13,14,8,9,15,16,17,18,19,20,21,23,80])),{loading:!0,delay:1e3})},emits:["success","register"],setup(t,{emit:a}){const{createMessage:d}=se(),w=g(null),{popModalFixedWidth:y,resetBodyStyle:C,popBodyStyle:u}=fe(),p=g(""),l=g(800),[c,{closeModal:b}]=ge(e=>{p.value="",A.value=e.selectedRowKeys,M.value=e.selectedRows,setTimeout(()=>v(null,null,function*(){yield te({current:1}),yield k(),C()}),100)});function o(){b()}const m=be(()=>{const e=A.value;return!(e&&e.length>0)}),_=g(!1);function q(){_.value=!0;let e=Te(M.value);e&&e.length>0&&(a("success",e),b()),setTimeout(()=>{_.value=!1},200)}function x(e){const i="/online/cgform/api/getData/"+t.id;return $.get({url:i,params:e})}function z(e){return e.column="id",new Promise((i,f)=>v(null,null,function*(){const s=yield x(e);i(s)}))}const N={isPopList:!0,reloadTable(){},isTree(){return!1}},H=g({}),{columns:P,downloadRowFile:K,getImgView:U,getPcaText:W,getFormatDate:j,handleColumnResult:J,hrefComponent:G,viewOnlineCellImage:Y}=ce(N,H);function X(){const e="/online/cgform/api/getColumns/"+t.id;return new Promise((i,f)=>{$.get({url:e},{isTransformResponse:!1}).then(s=>{s.success?i(s.result):(d.warning(s.message),f())})})}const I=g("");E(()=>t.id,()=>v(null,null,function*(){let e=yield X();J(e),I.value=e.description}),{immediate:!0});const{tableContext:Z}=ue({designScope:"process-design",pagination:!0,tableProps:{title:"",api:z,clickToRowSelect:!0,columns:P,showTableSetting:!1,immediate:!1,canResize:!1,showActionColumn:!1,actionColumn:{dataIndex:"action",slots:{customRender:"action"}},useSearchForm:!1,beforeFetch:e=>re(e)}}),[ee,{reload:k,setPagination:te},{rowSelection:R,selectedRowKeys:A,selectedRows:M}]=Z;E(()=>t.multi,e=>{e==!0?R.type="checkbox":R.type="radio"},{immediate:!0});function oe(e){return[{label:"编辑",onClick:ie.bind(null,e)}]}function ie(e){}function ae(){k()}const ne=["int","double","Date","Datetime","BigDecimal"];function re(e){let i=p.value;if(!i)return e.superQueryMatchType="or",e.superQueryParams="",e;let f=P.value,s=[];if(f&&f.length>0)for(let n of f)n.dbType&&(n.dbType=="string"?s.push({field:n.dataIndex,type:n.dbType.toLowerCase(),rule:"like",val:i}):n.dbType=="Date"?i.length==10&&s.push({field:n.dataIndex,type:n.dbType.toLowerCase(),rule:"eq",val:i}):n.dbType=="Datetime"?i.length==19&&s.push({field:n.dataIndex,type:n.dbType.toLowerCase(),rule:"eq",val:i}):ne.indexOf(n.dbType)&&s.push({field:n.dataIndex,type:n.dbType.toLowerCase(),rule:"eq",val:i}));return e.superQueryMatchType="or",e.superQueryParams=encodeURI(JSON.stringify(s)),e}function le(e){let i=[e,...M.value];a("success",i),b()}return{registerModal:c,modalWidth:l,handleCancel:o,submitDisabled:m,submitLoading:_,handleSubmit:q,registerTable:ee,getTableAction:oe,searchText:p,onSearch:ae,downloadRowFile:K,getImgView:U,getPcaText:W,getFormatDate:j,hrefComponent:G,viewOnlineCellImage:Y,rowSelection:R,modalTitle:I,reload:k,popModalFixedWidth:y,popBodyStyle:u,handleDataSave:le,tableRef:w}}}),we={key:0,style:{"font-size":"12px","font-style":"italic"}},Ce={key:0,style:{"font-size":"12px","font-style":"italic"}},ve=["src","onClick"],Se=["innerHTML"],_e=["title"];function ke(t,a,d,w,y,C){const u=S("a-button"),p=me,l=S("TableAction"),c=S("BasicTable"),b=S("BasicModal");return T(),O(b,{onRegister:t.registerModal,width:t.popModalFixedWidth,dialogStyle:{top:"70px"},bodyStyle:t.popBodyStyle,title:t.modalTitle,wrapClassName:"jeecg-online-pop-list-modal"},{footer:r(()=>[h(u,{key:"back",onClick:t.handleCancel},{default:r(()=>[...a[1]||(a[1]=[D("关闭",-1)])]),_:1},8,["onClick"]),h(u,{disabled:t.submitDisabled,key:"submit",type:"primary",onClick:t.handleSubmit,loading:t.submitLoading},{default:r(()=>[...a[2]||(a[2]=[D("确定",-1)])]),_:1},8,["disabled","onClick","loading"])]),default:r(()=>[h(c,{ref:"tableRef",onRegister:t.registerTable,rowSelection:t.rowSelection},{tableTitle:r(()=>[h(p,{value:t.searchText,"onUpdate:value":a[0]||(a[0]=o=>t.searchText=o),onSearch:t.onSearch,placeholder:"请输入关键词,按回车搜索",style:{width:"240px"}},null,8,["value","onSearch"])]),action:r(({record:o})=>[h(l,{actions:t.getTableAction(o)},null,8,["actions"])]),fileSlot:r(({text:o})=>[o?(T(),O(u,{key:1,ghost:!0,type:"primary",preIcon:"ant-design:download",size:"small",onClick:m=>t.downloadRowFile(o)},{default:r(()=>[...a[3]||(a[3]=[D(" 下载 ",-1)])]),_:1},8,["onClick"])):(T(),L("span",we,"无文件"))]),imgSlot:r(({text:o})=>[o?(T(),L("img",{key:1,src:t.getImgView(o),alt:"图片不存在",class:"online-cell-image",onClick:m=>t.viewOnlineCellImage(o)},null,8,ve)):(T(),L("span",Ce,"无图片"))]),htmlSlot:r(({text:o})=>[B("div",{innerHTML:o},null,8,Se)]),pcaSlot:r(({text:o,column:m})=>[B("div",{title:t.getPcaText(o,m)},Q(t.getPcaText(o,m)),9,_e)]),dateSlot:r(({text:o,column:m})=>[B("span",null,Q(t.getFormatDate(o,m)),1)]),_:1},8,["onRegister","rowSelection"])]),_:1},8,["onRegister","width","bodyStyle","title"])}const ro=pe(he,[["render",ke]]);export{ro as default};