kz-ui-base 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +5 -0
- package/kztool/css/10.96cad523.css +1 -0
- package/kztool/css/11.e4c864cd.css +1 -0
- package/kztool/css/12.647fccce.css +1 -0
- package/kztool/css/13.65952a1f.css +1 -0
- package/kztool/css/14.dd36c45f.css +1 -0
- package/kztool/css/15.832c7deb.css +1 -0
- package/kztool/css/16.8b271d59.css +1 -0
- package/kztool/css/17.0e84559e.css +1 -0
- package/kztool/css/18.832c7deb.css +1 -0
- package/kztool/css/19.6a3d2dce.css +1 -0
- package/kztool/css/2.f1342bd9.css +1 -0
- package/kztool/css/20.bb41fc34.css +1 -0
- package/kztool/css/21.ed73c08f.css +1 -0
- package/kztool/css/22.e894eb6f.css +1 -0
- package/kztool/css/23.57aa83b4.css +1 -0
- package/kztool/css/25.5f134180.css +1 -0
- package/kztool/css/26.832c7deb.css +1 -0
- package/kztool/css/4.a42922b4.css +1 -0
- package/kztool/css/6.2fd4b699.css +1 -0
- package/kztool/css/7.9be14673.css +21 -0
- package/kztool/css/9.9d93e54d.css +22 -0
- package/kztool/demo.html +10 -0
- package/kztool/img/401.089007e7.gif +0 -0
- package/kztool/img/404.a57b6f31.png +0 -0
- package/kztool/img/404.cb2515ac.svg +1 -0
- package/kztool/img/404_cloud.0f4bc32b.png +0 -0
- package/kztool/img/bug.f34b1328.svg +1 -0
- package/kztool/img/build.afff0ba4.svg +1 -0
- package/kztool/img/button.43a072f1.svg +1 -0
- package/kztool/img/cascader.af4b06f5.svg +1 -0
- package/kztool/img/chart.15fe45db.svg +1 -0
- package/kztool/img/checkbox.33950d05.svg +1 -0
- package/kztool/img/client.8669e2c6.svg +1 -0
- package/kztool/img/clipboard.a754c187.svg +1 -0
- package/kztool/img/code.21a8c1ce.svg +1 -0
- package/kztool/img/color.d6e1d0d9.svg +1 -0
- package/kztool/img/component.a69885f8.svg +1 -0
- package/kztool/img/dark.412ca67e.svg +39 -0
- package/kztool/img/dashboard.28a2a850.svg +1 -0
- package/kztool/img/date-range.21c0ab78.svg +1 -0
- package/kztool/img/date.43878da9.svg +1 -0
- package/kztool/img/dict.e54d50d6.svg +1 -0
- package/kztool/img/documentation.250402ca.svg +1 -0
- package/kztool/img/download.5153dc2b.svg +1 -0
- package/kztool/img/drag.4a19e202.svg +1 -0
- package/kztool/img/druid.09b411e5.svg +1 -0
- package/kztool/img/edit.82ad92eb.svg +1 -0
- package/kztool/img/education.8a144773.svg +1 -0
- package/kztool/img/email.e4742db4.svg +1 -0
- package/kztool/img/example.894f4689.svg +1 -0
- package/kztool/img/excel.25efb1e4.svg +1 -0
- package/kztool/img/exit-fullscreen.c0a0b5af.svg +1 -0
- package/kztool/img/eye-open.26bf09f4.svg +1 -0
- package/kztool/img/eye.e4fe315c.svg +1 -0
- package/kztool/img/file-config.e9cf97b5.png +0 -0
- package/kztool/img/file-doc.2e32d62d.png +0 -0
- package/kztool/img/file-exe.ba756588.png +0 -0
- package/kztool/img/file-ini.b1d3af9d.png +0 -0
- package/kztool/img/file-jpg.20c594b1.png +0 -0
- package/kztool/img/file-mpg.4a3b6b53.png +0 -0
- package/kztool/img/file-none.529195fd.png +0 -0
- package/kztool/img/file-pdf.36c3acbd.png +0 -0
- package/kztool/img/file-png.961aaab6.png +0 -0
- package/kztool/img/file-ppt.b13aca2d.png +0 -0
- package/kztool/img/file-rar.d940b06e.png +0 -0
- package/kztool/img/file-txt.fba6847c.png +0 -0
- package/kztool/img/file-wav.6c6a98a5.png +0 -0
- package/kztool/img/file-xls.0ba7ceb7.png +0 -0
- package/kztool/img/form.f3ed6fee.svg +1 -0
- package/kztool/img/fullscreen.9ce971c6.svg +1 -0
- package/kztool/img/github.a1e0a262.svg +1 -0
- package/kztool/img/guide.fe0b5508.svg +1 -0
- package/kztool/img/icon-ext.ba81b24c.png +0 -0
- package/kztool/img/icon.3ab19eb2.svg +1 -0
- package/kztool/img/icon.551539f8.png +0 -0
- package/kztool/img/input.fd627960.svg +1 -0
- package/kztool/img/international.256537bf.svg +1 -0
- package/kztool/img/job.b6da1ffe.svg +1 -0
- package/kztool/img/kz_authority.3278f033.svg +1 -0
- package/kztool/img/kz_build.d01b7fab.svg +1 -0
- package/kztool/img/kz_code.181e9399.svg +1 -0
- package/kztool/img/kz_config.8ed433a4.svg +1 -0
- package/kztool/img/kz_creatTime.b36ed35c.svg +1 -0
- package/kztool/img/kz_dept.5e64451a.svg +1 -0
- package/kztool/img/kz_dept_profile.5d4e147f.svg +1 -0
- package/kztool/img/kz_dict.2ab95ca5.svg +1 -0
- package/kztool/img/kz_edit.7d07a3ee.svg +1 -0
- package/kztool/img/kz_enlarge.af9fd797.svg +1 -0
- package/kztool/img/kz_enterprise.d341ab44.svg +1 -0
- package/kztool/img/kz_fold.17a83166.svg +2 -0
- package/kztool/img/kz_job.d4e52276.svg +1 -0
- package/kztool/img/kz_layout.9bab2381.svg +1 -0
- package/kztool/img/kz_log.685b9ce0.svg +1 -0
- package/kztool/img/kz_log_loginInfo.68ba7786.svg +1 -0
- package/kztool/img/kz_log_operation.fdc2ddf9.svg +1 -0
- package/kztool/img/kz_master-slave.83dad46f.svg +2 -0
- package/kztool/img/kz_menu.35eddf40.svg +1 -0
- package/kztool/img/kz_menu_analyse.4b4d8f9b.svg +22 -0
- package/kztool/img/kz_message.b8712b45.svg +1 -0
- package/kztool/img/kz_monitor.8b10fbe6.svg +1 -0
- package/kztool/img/kz_nacos.c51b9d4a.svg +1 -0
- package/kztool/img/kz_narrow.2a646b99.svg +1 -0
- package/kztool/img/kz_notice.34428b82.svg +2 -0
- package/kztool/img/kz_online.754b59da.svg +1 -0
- package/kztool/img/kz_open.c0247e97.svg +2 -0
- package/kztool/img/kz_organization.c4c24b8b.svg +1 -0
- package/kztool/img/kz_post.a3b24529.svg +1 -0
- package/kztool/img/kz_post_profile.729ed1fd.svg +1 -0
- package/kztool/img/kz_productCenter.94cb1bf1.svg +1 -0
- package/kztool/img/kz_rabbit.c1e30068.svg +1 -0
- package/kztool/img/kz_refresh.e4335ee7.svg +2 -0
- package/kztool/img/kz_renovation.cec7bdbb.svg +1 -0
- package/kztool/img/kz_role.337dafc2.svg +1 -0
- package/kztool/img/kz_roleGroup.d40cf86e.svg +1 -0
- package/kztool/img/kz_search.91e19919.svg +1 -0
- package/kztool/img/kz_sentinel.65a96c32.svg +1 -0
- package/kztool/img/kz_server.1aeaae9a.svg +1 -0
- package/kztool/img/kz_setting.b121026e.svg +1 -0
- package/kztool/img/kz_sex.2dfbc39c.svg +1 -0
- package/kztool/img/kz_source.78acc35f.svg +2 -0
- package/kztool/img/kz_strategy.960f4e2b.svg +2 -0
- package/kztool/img/kz_swagger.72b031ef.svg +1 -0
- package/kztool/img/kz_system.a0a83a20.svg +1 -0
- package/kztool/img/kz_tenant.bb89322f.svg +1 -0
- package/kztool/img/kz_tool.bc04a7cd.svg +1 -0
- package/kztool/img/kz_user.8ade980b.svg +1 -0
- package/kztool/img/language.a84ceaa6.svg +1 -0
- package/kztool/img/light.4183aad0.svg +39 -0
- package/kztool/img/link.9c719b73.svg +1 -0
- package/kztool/img/list.76dedeca.svg +1 -0
- package/kztool/img/loading-0.a72011cc.gif +0 -0
- package/kztool/img/lock.8634238d.svg +1 -0
- package/kztool/img/log.7798bf59.svg +1 -0
- package/kztool/img/login-background.c5b184b7.jpg +0 -0
- package/kztool/img/logininfor.182c8103.svg +1 -0
- package/kztool/img/logo.8ae3d6ee.jpg +0 -0
- package/kztool/img/logo.eeed0dd2.png +0 -0
- package/kztool/img/mes-ad.af0324d3.svg +21 -0
- package/kztool/img/mes-ic.7d10c9df.svg +16 -0
- package/kztool/img/mes-mfg-order.d03a00ac.svg +22 -0
- package/kztool/img/mes-tm.e3818cf7.svg +15 -0
- package/kztool/img/message.1fbaa155.svg +1 -0
- package/kztool/img/money.954fffc7.svg +1 -0
- package/kztool/img/monitor.7eeb6217.svg +2 -0
- package/kztool/img/nacos.147e9bf5.svg +1 -0
- package/kztool/img/nested.c948fb38.svg +1 -0
- package/kztool/img/number.7e0faaa5.svg +1 -0
- package/kztool/img/online.fb93d2e7.svg +1 -0
- package/kztool/img/password.9173da92.svg +1 -0
- package/kztool/img/pdf.7e6ae0e3.svg +1 -0
- package/kztool/img/people.665094ec.svg +1 -0
- package/kztool/img/peoples.73b2be61.svg +1 -0
- package/kztool/img/phone.4ab5e783.svg +1 -0
- package/kztool/img/post.4f1521cb.svg +1 -0
- package/kztool/img/profile.8ae3d6ee.jpg +0 -0
- package/kztool/img/qq.8968a17d.svg +1 -0
- package/kztool/img/question.6dd93e77.svg +1 -0
- package/kztool/img/radio.1db061a7.svg +1 -0
- package/kztool/img/rate.d8284c44.svg +1 -0
- package/kztool/img/row.88cc2b15.svg +1 -0
- package/kztool/img/search.8b49baae.svg +1 -0
- package/kztool/img/select.be2885c0.svg +1 -0
- package/kztool/img/sentinel.51b1eedb.svg +1 -0
- package/kztool/img/server.e9df1296.svg +1 -0
- package/kztool/img/shop-call.31143fe6.svg +14 -0
- package/kztool/img/shopping.232bbd1d.svg +1 -0
- package/kztool/img/size.c77e5b9c.svg +1 -0
- package/kztool/img/skill.9842762c.svg +1 -0
- package/kztool/img/slider.dca17dd6.svg +1 -0
- package/kztool/img/star.91c10562.svg +1 -0
- package/kztool/img/stock-query.e3aea312.svg +14 -0
- package/kztool/img/stock-report.03ca7ff1.svg +14 -0
- package/kztool/img/stock-take.6bd8c87e.svg +14 -0
- package/kztool/img/swagger.78429129.svg +1 -0
- package/kztool/img/switch.67ff45e5.svg +1 -0
- package/kztool/img/system.8f062138.svg +2 -0
- package/kztool/img/tab.02b3a5b8.svg +1 -0
- package/kztool/img/table.fe7671a5.svg +1 -0
- package/kztool/img/textarea.6a19873e.svg +1 -0
- package/kztool/img/theme.a8c15249.svg +1 -0
- package/kztool/img/time-range.4a869bcb.svg +1 -0
- package/kztool/img/time.809df2f6.svg +1 -0
- package/kztool/img/tool.ce0f6d38.svg +1 -0
- package/kztool/img/tree-table.76f687b5.svg +1 -0
- package/kztool/img/tree.59ecebc1.svg +1 -0
- package/kztool/img/upload.84d5b598.svg +1 -0
- package/kztool/img/user.9f469d0b.svg +1 -0
- package/kztool/img/validCode.9e7b7784.svg +1 -0
- package/kztool/img/wechat.28725df0.svg +1 -0
- package/kztool/img/xy-cancel.c5f3d1db.svg +1 -0
- package/kztool/img/xy-choice.b2e8c9cf.svg +1 -0
- package/kztool/img/xy-choice2.453db322.svg +31 -0
- package/kztool/img/zip.839d61e0.svg +1 -0
- package/kztool/kztool.common.0.js +17212 -0
- package/kztool/kztool.common.1.js +11 -0
- package/kztool/kztool.common.10.js +2775 -0
- package/kztool/kztool.common.11.js +1920 -0
- package/kztool/kztool.common.12.js +641 -0
- package/kztool/kztool.common.13.js +1363 -0
- package/kztool/kztool.common.14.js +987 -0
- package/kztool/kztool.common.15.js +2477 -0
- package/kztool/kztool.common.16.js +222 -0
- package/kztool/kztool.common.17.js +140 -0
- package/kztool/kztool.common.18.js +1053 -0
- package/kztool/kztool.common.19.js +319 -0
- package/kztool/kztool.common.2.js +2893 -0
- package/kztool/kztool.common.20.js +131 -0
- package/kztool/kztool.common.21.js +396 -0
- package/kztool/kztool.common.22.js +377 -0
- package/kztool/kztool.common.23.js +677 -0
- package/kztool/kztool.common.24.js +1007 -0
- package/kztool/kztool.common.25.js +246 -0
- package/kztool/kztool.common.26.js +138 -0
- package/kztool/kztool.common.27.js +505 -0
- package/kztool/kztool.common.28.js +62 -0
- package/kztool/kztool.common.29.js +65 -0
- package/kztool/kztool.common.3.js +3868 -0
- package/kztool/kztool.common.4.js +1387 -0
- package/kztool/kztool.common.5.js +10 -0
- package/kztool/kztool.common.6.js +32006 -0
- package/kztool/kztool.common.7.js +28976 -0
- package/kztool/kztool.common.9.js +63288 -0
- package/kztool/kztool.common.js +137547 -0
- package/kztool/kztool.css +7 -0
- package/kztool/kztool.umd.0.js +17212 -0
- package/kztool/kztool.umd.1.js +11 -0
- package/kztool/kztool.umd.10.js +2775 -0
- package/kztool/kztool.umd.11.js +1920 -0
- package/kztool/kztool.umd.12.js +641 -0
- package/kztool/kztool.umd.13.js +1363 -0
- package/kztool/kztool.umd.14.js +987 -0
- package/kztool/kztool.umd.15.js +2477 -0
- package/kztool/kztool.umd.16.js +222 -0
- package/kztool/kztool.umd.17.js +140 -0
- package/kztool/kztool.umd.18.js +1053 -0
- package/kztool/kztool.umd.19.js +319 -0
- package/kztool/kztool.umd.2.js +2893 -0
- package/kztool/kztool.umd.20.js +131 -0
- package/kztool/kztool.umd.21.js +396 -0
- package/kztool/kztool.umd.22.js +377 -0
- package/kztool/kztool.umd.23.js +677 -0
- package/kztool/kztool.umd.24.js +1007 -0
- package/kztool/kztool.umd.25.js +246 -0
- package/kztool/kztool.umd.26.js +138 -0
- package/kztool/kztool.umd.27.js +505 -0
- package/kztool/kztool.umd.28.js +62 -0
- package/kztool/kztool.umd.29.js +65 -0
- package/kztool/kztool.umd.3.js +3868 -0
- package/kztool/kztool.umd.4.js +1387 -0
- package/kztool/kztool.umd.5.js +10 -0
- package/kztool/kztool.umd.6.js +32006 -0
- package/kztool/kztool.umd.7.js +28976 -0
- package/kztool/kztool.umd.9.js +63288 -0
- package/kztool/kztool.umd.js +137557 -0
- package/kztool/kztool.umd.min.0.js +9 -0
- package/kztool/kztool.umd.min.1.js +1 -0
- package/kztool/kztool.umd.min.10.js +1 -0
- package/kztool/kztool.umd.min.11.js +1 -0
- package/kztool/kztool.umd.min.12.js +1 -0
- package/kztool/kztool.umd.min.13.js +1 -0
- package/kztool/kztool.umd.min.14.js +1 -0
- package/kztool/kztool.umd.min.15.js +1 -0
- package/kztool/kztool.umd.min.16.js +1 -0
- package/kztool/kztool.umd.min.17.js +1 -0
- package/kztool/kztool.umd.min.18.js +1 -0
- package/kztool/kztool.umd.min.19.js +1 -0
- package/kztool/kztool.umd.min.2.js +1 -0
- package/kztool/kztool.umd.min.20.js +1 -0
- package/kztool/kztool.umd.min.21.js +1 -0
- package/kztool/kztool.umd.min.22.js +1 -0
- package/kztool/kztool.umd.min.23.js +1 -0
- package/kztool/kztool.umd.min.24.js +1 -0
- package/kztool/kztool.umd.min.25.js +1 -0
- package/kztool/kztool.umd.min.26.js +1 -0
- package/kztool/kztool.umd.min.27.js +1 -0
- package/kztool/kztool.umd.min.28.js +1 -0
- package/kztool/kztool.umd.min.29.js +1 -0
- package/kztool/kztool.umd.min.3.js +8 -0
- package/kztool/kztool.umd.min.4.js +1 -0
- package/kztool/kztool.umd.min.5.js +1 -0
- package/kztool/kztool.umd.min.6.js +1 -0
- package/kztool/kztool.umd.min.7.js +24 -0
- package/kztool/kztool.umd.min.9.js +24 -0
- package/kztool/kztool.umd.min.js +349 -0
- package/list-bese-page/doublelistBasePageTs.vue +996 -0
- package/list-bese-page/listBasePageTs.vue +2170 -0
- package/package.json +12 -0
|
@@ -0,0 +1,996 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="app-container">
|
|
3
|
+
<slot></slot>
|
|
4
|
+
<el-row :gutter="24">
|
|
5
|
+
<!--树数据-->
|
|
6
|
+
<el-col v-if="treeSetting.visable" :span="4" :xs="24">
|
|
7
|
+
<div class="wrapper-container wrapper-container-supplement">
|
|
8
|
+
<div class="head-container">
|
|
9
|
+
<el-input
|
|
10
|
+
v-model="deptName"
|
|
11
|
+
:placeholder="treeSetting.title"
|
|
12
|
+
clearable
|
|
13
|
+
size="small"
|
|
14
|
+
prefix-icon="el-icon-search"
|
|
15
|
+
style="margin-bottom: 20px"
|
|
16
|
+
/>
|
|
17
|
+
</div>
|
|
18
|
+
<div class="head-container">
|
|
19
|
+
<el-tree
|
|
20
|
+
:data="deptPostOptions"
|
|
21
|
+
:props="defaultProps"
|
|
22
|
+
:expand-on-click-node="false"
|
|
23
|
+
:filter-node-method="filterNode"
|
|
24
|
+
ref="tree"
|
|
25
|
+
default-expand-all
|
|
26
|
+
@node-click="handleNodeClick"
|
|
27
|
+
/>
|
|
28
|
+
</div>
|
|
29
|
+
</div>
|
|
30
|
+
</el-col>
|
|
31
|
+
<!--用户数据-->
|
|
32
|
+
<el-col :span="treeSetting.visable ? 20 : 24" :xs="24">
|
|
33
|
+
<div class="wrapper-container" v-show="isShowSearch">
|
|
34
|
+
<el-form
|
|
35
|
+
:model="listQueryParams"
|
|
36
|
+
ref="queryForm"
|
|
37
|
+
:inline="true"
|
|
38
|
+
label-width="100px"
|
|
39
|
+
>
|
|
40
|
+
<component
|
|
41
|
+
v-for="(searchRule, index) in searchRules"
|
|
42
|
+
:key="index"
|
|
43
|
+
v-if="
|
|
44
|
+
searchRule.visible == undefined || searchRule.visible != false
|
|
45
|
+
"
|
|
46
|
+
:is="
|
|
47
|
+
searchRule.displayType != null
|
|
48
|
+
? 'KZ_' + searchRule.displayType
|
|
49
|
+
: 'KZ_TextBox'
|
|
50
|
+
"
|
|
51
|
+
:columns="searchRules"
|
|
52
|
+
:column="searchRule"
|
|
53
|
+
:entity="searchRule"
|
|
54
|
+
:setting.sync="searchRule.setting"
|
|
55
|
+
:value="searchRule.value"
|
|
56
|
+
@keyup.enter.native="handleQuery"
|
|
57
|
+
>
|
|
58
|
+
</component>
|
|
59
|
+
<el-form-item>
|
|
60
|
+
<el-button
|
|
61
|
+
type="primary"
|
|
62
|
+
icon="el-icon-search"
|
|
63
|
+
size="mini"
|
|
64
|
+
@click="handleQuery"
|
|
65
|
+
>搜索</el-button
|
|
66
|
+
>
|
|
67
|
+
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
|
|
68
|
+
>重置</el-button
|
|
69
|
+
>
|
|
70
|
+
</el-form-item>
|
|
71
|
+
</el-form>
|
|
72
|
+
</div>
|
|
73
|
+
|
|
74
|
+
<div class="wrapper-container">
|
|
75
|
+
<el-row :gutter="10" class="mb8">
|
|
76
|
+
<template v-for="opMenu in opMenus">
|
|
77
|
+
<el-col :key="opMenu.name" :span="1.5" v-if="opMenu.visable">
|
|
78
|
+
<el-button
|
|
79
|
+
:type="opMenu.cssType || 'primary'"
|
|
80
|
+
plain
|
|
81
|
+
:icon="opMenu.icon"
|
|
82
|
+
:disabled="opMenu.disabled"
|
|
83
|
+
size="mini"
|
|
84
|
+
@click="onOpMenuClick({ opMenu: opMenu })"
|
|
85
|
+
v-hasPermi="[
|
|
86
|
+
opMenu.permission,
|
|
87
|
+
`${moduleName}:${serviceName}:${opMenu.permission}`,
|
|
88
|
+
]"
|
|
89
|
+
>
|
|
90
|
+
{{ opMenu.text }}
|
|
91
|
+
</el-button>
|
|
92
|
+
</el-col>
|
|
93
|
+
</template>
|
|
94
|
+
<template v-for="(opMenu, index) in customOpMenus">
|
|
95
|
+
<el-col :key="index" :span="1.5" v-if="opMenu.visable">
|
|
96
|
+
<el-button
|
|
97
|
+
:type="opMenu.cssType || 'primary'"
|
|
98
|
+
plain
|
|
99
|
+
:icon="opMenu.icon"
|
|
100
|
+
:disabled="opMenu.disabled"
|
|
101
|
+
size="mini"
|
|
102
|
+
@click="onCustomOpMenuClick({ opMenu: opMenu })"
|
|
103
|
+
v-hasPermi="[
|
|
104
|
+
opMenu.permission,
|
|
105
|
+
`${moduleName}:${serviceName}:${opMenu.permission}`,
|
|
106
|
+
]"
|
|
107
|
+
>
|
|
108
|
+
{{ opMenu.text }}
|
|
109
|
+
</el-button>
|
|
110
|
+
</el-col>
|
|
111
|
+
</template>
|
|
112
|
+
|
|
113
|
+
<right-toolbar
|
|
114
|
+
:showSearch.sync="isShowSearch"
|
|
115
|
+
:sortVisible="false"
|
|
116
|
+
@queryTable="getList"
|
|
117
|
+
:columns="listColumns"
|
|
118
|
+
/>
|
|
119
|
+
</el-row>
|
|
120
|
+
|
|
121
|
+
<el-table
|
|
122
|
+
ref="multipleTable"
|
|
123
|
+
:height="tableHeight"
|
|
124
|
+
v-loading="loading"
|
|
125
|
+
:border="true"
|
|
126
|
+
:data="listData"
|
|
127
|
+
highlight-current-row
|
|
128
|
+
@current-change="rowclick"
|
|
129
|
+
@row-click="clickRow"
|
|
130
|
+
@selection-change="onSelectionChange"
|
|
131
|
+
>
|
|
132
|
+
<el-table-column
|
|
133
|
+
v-if="isMultiple"
|
|
134
|
+
type="selection"
|
|
135
|
+
width="50"
|
|
136
|
+
align="center"
|
|
137
|
+
/>
|
|
138
|
+
<el-table-column
|
|
139
|
+
v-if="listSetting.isShowIndexColumn != false"
|
|
140
|
+
type="index"
|
|
141
|
+
label="序号"
|
|
142
|
+
width="50"
|
|
143
|
+
align="center"
|
|
144
|
+
>
|
|
145
|
+
<template scope="scope">
|
|
146
|
+
<span>{{
|
|
147
|
+
(listQueryParams.pageNum - 1) * listQueryParams.pageSize +
|
|
148
|
+
scope.$index +
|
|
149
|
+
1
|
|
150
|
+
}}</span>
|
|
151
|
+
</template>
|
|
152
|
+
</el-table-column>
|
|
153
|
+
<template v-for="(column, index) in listColumns">
|
|
154
|
+
<el-table-column
|
|
155
|
+
:show-overflow-tooltip="true"
|
|
156
|
+
:key="index"
|
|
157
|
+
:label="column.text"
|
|
158
|
+
align="center"
|
|
159
|
+
:prop="column.property"
|
|
160
|
+
v-if="column.visible != false"
|
|
161
|
+
:min-width="column.width || 100"
|
|
162
|
+
>
|
|
163
|
+
<template slot-scope="scope">
|
|
164
|
+
<div v-if="column.displayType == 'Upload'">
|
|
165
|
+
{{ getFileNickName(scope.row[scope.column.property]) }}
|
|
166
|
+
</div>
|
|
167
|
+
<div v-else-if="column.displayType == 'DatePicker'">
|
|
168
|
+
{{
|
|
169
|
+
dateFormat(
|
|
170
|
+
scope.row,
|
|
171
|
+
column,
|
|
172
|
+
scope.row[column.property],
|
|
173
|
+
scope.row[column.property]
|
|
174
|
+
)
|
|
175
|
+
}}
|
|
176
|
+
</div>
|
|
177
|
+
<div
|
|
178
|
+
v-else-if="
|
|
179
|
+
column.setting &&
|
|
180
|
+
(column.setting.type || column.setting.dictType)
|
|
181
|
+
"
|
|
182
|
+
>
|
|
183
|
+
{{
|
|
184
|
+
tableDisplayFormat(
|
|
185
|
+
scope.row,
|
|
186
|
+
column,
|
|
187
|
+
scope.row[column.property]
|
|
188
|
+
)
|
|
189
|
+
}}
|
|
190
|
+
</div>
|
|
191
|
+
<div v-else-if="column.htmlFormat">
|
|
192
|
+
<span
|
|
193
|
+
v-html="
|
|
194
|
+
evalFunction(
|
|
195
|
+
column.htmlFormat,
|
|
196
|
+
scope.row,
|
|
197
|
+
column,
|
|
198
|
+
scope.row[column.property]
|
|
199
|
+
)
|
|
200
|
+
"
|
|
201
|
+
></span>
|
|
202
|
+
</div>
|
|
203
|
+
<div v-else-if="!!column.htmlFormat">
|
|
204
|
+
<span
|
|
205
|
+
v-html="
|
|
206
|
+
evalFunction(
|
|
207
|
+
column.htmlFormat,
|
|
208
|
+
scope.row,
|
|
209
|
+
column,
|
|
210
|
+
scope.row[column.property]
|
|
211
|
+
)
|
|
212
|
+
"
|
|
213
|
+
></span>
|
|
214
|
+
</div>
|
|
215
|
+
<div v-else-if="column.format">
|
|
216
|
+
{{
|
|
217
|
+
evalFunction(
|
|
218
|
+
column.format,
|
|
219
|
+
scope.row,
|
|
220
|
+
column,
|
|
221
|
+
scope.row[column.property]
|
|
222
|
+
)
|
|
223
|
+
}}
|
|
224
|
+
</div>
|
|
225
|
+
<div v-else-if="column.click">
|
|
226
|
+
<el-link
|
|
227
|
+
type="primary"
|
|
228
|
+
@click="
|
|
229
|
+
evalFunction(
|
|
230
|
+
column.click,
|
|
231
|
+
scope.row,
|
|
232
|
+
column,
|
|
233
|
+
scope.row[column.property]
|
|
234
|
+
)
|
|
235
|
+
"
|
|
236
|
+
>
|
|
237
|
+
<span v-if="column.clickFormat">
|
|
238
|
+
{{
|
|
239
|
+
evalFunction(
|
|
240
|
+
column.clickFormat,
|
|
241
|
+
scope.row,
|
|
242
|
+
column,
|
|
243
|
+
scope.row[column.property]
|
|
244
|
+
)
|
|
245
|
+
}}
|
|
246
|
+
</span>
|
|
247
|
+
<span v-else>{{ scope.row[scope.column.property] }}</span>
|
|
248
|
+
</el-link>
|
|
249
|
+
</div>
|
|
250
|
+
<div v-else>
|
|
251
|
+
{{ scope.row[scope.column.property] }}
|
|
252
|
+
</div>
|
|
253
|
+
</template>
|
|
254
|
+
</el-table-column>
|
|
255
|
+
</template>
|
|
256
|
+
|
|
257
|
+
<el-table-column
|
|
258
|
+
label="操作"
|
|
259
|
+
align="center"
|
|
260
|
+
min-width="160"
|
|
261
|
+
class-name="small-padding fixed-width"
|
|
262
|
+
v-if="listSetting.isShowOpColumn"
|
|
263
|
+
>
|
|
264
|
+
<template slot-scope="scope">
|
|
265
|
+
<el-button
|
|
266
|
+
v-for="(opMenu, index) in listCustomOpMenus"
|
|
267
|
+
:key="index"
|
|
268
|
+
size="mini"
|
|
269
|
+
type="text"
|
|
270
|
+
:icon="opMenu.icon"
|
|
271
|
+
@click="
|
|
272
|
+
onListCustomOpMenuClick({ opMenu: opMenu, data: scope.row })
|
|
273
|
+
"
|
|
274
|
+
v-hasPermi="[
|
|
275
|
+
opMenu.permission,
|
|
276
|
+
`${moduleName}:${serviceName}:${opMenu.permission}`,
|
|
277
|
+
]"
|
|
278
|
+
>
|
|
279
|
+
{{ opMenu.text }}
|
|
280
|
+
</el-button>
|
|
281
|
+
</template>
|
|
282
|
+
</el-table-column>
|
|
283
|
+
</el-table>
|
|
284
|
+
|
|
285
|
+
<pagination
|
|
286
|
+
:total="listQueryParams.total"
|
|
287
|
+
:page.sync="listQueryParams.pageNum"
|
|
288
|
+
:limit.sync="listQueryParams.pageSize"
|
|
289
|
+
@pagination="getList"
|
|
290
|
+
/>
|
|
291
|
+
|
|
292
|
+
<template v-for="(item, dex) in tableSetting">
|
|
293
|
+
<div
|
|
294
|
+
v-if="searchShow"
|
|
295
|
+
class="wrapper-container doubleWrapper"
|
|
296
|
+
:key="dex + 'wra'"
|
|
297
|
+
>
|
|
298
|
+
<el-form
|
|
299
|
+
:model="listQueryParams"
|
|
300
|
+
:ref="'queryForm' + dex"
|
|
301
|
+
:inline="true"
|
|
302
|
+
label-width="100px"
|
|
303
|
+
>
|
|
304
|
+
<component
|
|
305
|
+
v-for="(searchRule, y) in item.searchRules"
|
|
306
|
+
:key="y + 'rules'"
|
|
307
|
+
:is="
|
|
308
|
+
searchRule.displayType != null
|
|
309
|
+
? 'KZ_' + searchRule.displayType
|
|
310
|
+
: 'KZ_TextBox'
|
|
311
|
+
"
|
|
312
|
+
:column="{ text: searchRule.text, property: 'value' }"
|
|
313
|
+
:entity="searchRule"
|
|
314
|
+
:setting.sync="searchRule.setting"
|
|
315
|
+
:value="searchRule.value"
|
|
316
|
+
>
|
|
317
|
+
</component>
|
|
318
|
+
<el-form-item>
|
|
319
|
+
<el-button
|
|
320
|
+
type="primary"
|
|
321
|
+
icon="el-icon-search"
|
|
322
|
+
size="mini"
|
|
323
|
+
@click="doubleHandleQuery(dex)"
|
|
324
|
+
>搜索</el-button
|
|
325
|
+
>
|
|
326
|
+
<el-button
|
|
327
|
+
icon="el-icon-refresh"
|
|
328
|
+
size="mini"
|
|
329
|
+
@click="doubleResetQuery(dex)"
|
|
330
|
+
>重置</el-button
|
|
331
|
+
>
|
|
332
|
+
</el-form-item>
|
|
333
|
+
</el-form>
|
|
334
|
+
</div>
|
|
335
|
+
<template v-for="(opMenu, ix) in tableSetting[dex].customOpMenus">
|
|
336
|
+
<el-col
|
|
337
|
+
class="doublemenu"
|
|
338
|
+
:span="1.5"
|
|
339
|
+
v-if="bottomShow && opMenu.visable"
|
|
340
|
+
:key="ix + 'menu'"
|
|
341
|
+
>
|
|
342
|
+
<el-button
|
|
343
|
+
:type="opMenu.cssType || 'primary'"
|
|
344
|
+
plain
|
|
345
|
+
:icon="opMenu.icon"
|
|
346
|
+
:disabled="opMenu.disabled"
|
|
347
|
+
size="mini"
|
|
348
|
+
@click="doubleOnCustomOpMenuClick({ opMenu: opMenu }, ix)"
|
|
349
|
+
v-hasPermi="[
|
|
350
|
+
opMenu.permission,
|
|
351
|
+
`${moduleName}:${serviceName}:${opMenu.permission}`,
|
|
352
|
+
]"
|
|
353
|
+
>
|
|
354
|
+
{{ opMenu.text }}
|
|
355
|
+
</el-button>
|
|
356
|
+
</el-col>
|
|
357
|
+
</template>
|
|
358
|
+
<el-table
|
|
359
|
+
:height="tableHeight"
|
|
360
|
+
:border="true"
|
|
361
|
+
:key="dex"
|
|
362
|
+
v-loading="loading"
|
|
363
|
+
:data="multipleListData[dex]"
|
|
364
|
+
@selection-change="doubleSelectionChange"
|
|
365
|
+
>
|
|
366
|
+
<el-table-column
|
|
367
|
+
v-if="SelectionChangeShow"
|
|
368
|
+
type="selection"
|
|
369
|
+
width="50"
|
|
370
|
+
align="center"
|
|
371
|
+
/>
|
|
372
|
+
<el-table-column
|
|
373
|
+
v-if="tableSetting[dex].isShowIndexColumn != false"
|
|
374
|
+
type="index"
|
|
375
|
+
label="序号"
|
|
376
|
+
width="50"
|
|
377
|
+
align="center"
|
|
378
|
+
>
|
|
379
|
+
<template scope="scope">
|
|
380
|
+
<span>{{
|
|
381
|
+
(multiplelistQueryParams[dex].pageNum - 1) *
|
|
382
|
+
multiplelistQueryParams[dex].pageSize +
|
|
383
|
+
scope.$index +
|
|
384
|
+
1
|
|
385
|
+
}}</span>
|
|
386
|
+
</template>
|
|
387
|
+
</el-table-column>
|
|
388
|
+
<template v-for="(column, index) in item.listColumns">
|
|
389
|
+
<el-table-column
|
|
390
|
+
:key="index + 'column'"
|
|
391
|
+
:label="column.text"
|
|
392
|
+
align="center"
|
|
393
|
+
:prop="column.property"
|
|
394
|
+
v-if="column.visible != false"
|
|
395
|
+
:min-width="column.width || 100"
|
|
396
|
+
>
|
|
397
|
+
<template slot-scope="scope">
|
|
398
|
+
<div v-if="column.displayType == 'Upload'">
|
|
399
|
+
{{ getFileNickName(scope.row[scope.column.property]) }}
|
|
400
|
+
</div>
|
|
401
|
+
<div v-else-if="column.displayType == 'DatePicker'">
|
|
402
|
+
{{
|
|
403
|
+
dateFormat(
|
|
404
|
+
scope.row,
|
|
405
|
+
column,
|
|
406
|
+
scope.row[column.property],
|
|
407
|
+
scope.row[column.property]
|
|
408
|
+
)
|
|
409
|
+
}}
|
|
410
|
+
</div>
|
|
411
|
+
<div
|
|
412
|
+
v-else-if="
|
|
413
|
+
column.setting &&
|
|
414
|
+
(column.setting.type || column.setting.dictType)
|
|
415
|
+
"
|
|
416
|
+
>
|
|
417
|
+
{{
|
|
418
|
+
doubleTableDisplayFormat(
|
|
419
|
+
scope.row,
|
|
420
|
+
column,
|
|
421
|
+
scope.row[column.property],
|
|
422
|
+
dex
|
|
423
|
+
)
|
|
424
|
+
}}
|
|
425
|
+
</div>
|
|
426
|
+
<div v-else-if="column.htmlFormat">
|
|
427
|
+
<span
|
|
428
|
+
v-html="
|
|
429
|
+
evalFunction(
|
|
430
|
+
column.htmlFormat,
|
|
431
|
+
scope.row,
|
|
432
|
+
column,
|
|
433
|
+
scope.row[column.property]
|
|
434
|
+
)
|
|
435
|
+
"
|
|
436
|
+
></span>
|
|
437
|
+
</div>
|
|
438
|
+
<div v-else-if="!!column.htmlFormat">
|
|
439
|
+
<span
|
|
440
|
+
v-html="
|
|
441
|
+
evalFunction(
|
|
442
|
+
column.htmlFormat,
|
|
443
|
+
scope.row,
|
|
444
|
+
column,
|
|
445
|
+
scope.row[column.property]
|
|
446
|
+
)
|
|
447
|
+
"
|
|
448
|
+
></span>
|
|
449
|
+
</div>
|
|
450
|
+
<div v-else-if="column.format">
|
|
451
|
+
{{
|
|
452
|
+
evalFunction(
|
|
453
|
+
column.format,
|
|
454
|
+
scope.row,
|
|
455
|
+
column,
|
|
456
|
+
scope.row[column.property]
|
|
457
|
+
)
|
|
458
|
+
}}
|
|
459
|
+
</div>
|
|
460
|
+
<div v-else-if="column.click">
|
|
461
|
+
<el-link
|
|
462
|
+
type="primary"
|
|
463
|
+
@click="
|
|
464
|
+
evalFunction(
|
|
465
|
+
column.click,
|
|
466
|
+
scope.row,
|
|
467
|
+
column,
|
|
468
|
+
scope.row[column.property]
|
|
469
|
+
)
|
|
470
|
+
"
|
|
471
|
+
>
|
|
472
|
+
<span v-if="column.clickFormat">
|
|
473
|
+
{{
|
|
474
|
+
evalFunction(
|
|
475
|
+
column.clickFormat,
|
|
476
|
+
scope.row,
|
|
477
|
+
column,
|
|
478
|
+
scope.row[column.property]
|
|
479
|
+
)
|
|
480
|
+
}}
|
|
481
|
+
</span>
|
|
482
|
+
<span v-else>{{
|
|
483
|
+
scope.row[scope.column.property]
|
|
484
|
+
}}</span>
|
|
485
|
+
</el-link>
|
|
486
|
+
</div>
|
|
487
|
+
<div v-else>
|
|
488
|
+
{{ scope.row[scope.column.property] }}
|
|
489
|
+
</div>
|
|
490
|
+
</template>
|
|
491
|
+
</el-table-column>
|
|
492
|
+
</template>
|
|
493
|
+
|
|
494
|
+
<el-table-column
|
|
495
|
+
label="操作"
|
|
496
|
+
align="center"
|
|
497
|
+
min-width="160"
|
|
498
|
+
class-name="small-padding fixed-width"
|
|
499
|
+
v-if="tableSetting[dex].isShowOpColumn"
|
|
500
|
+
>
|
|
501
|
+
<template slot-scope="scope">
|
|
502
|
+
<el-button
|
|
503
|
+
v-for="(opMenu, ix) in item.listCustomOpMenus"
|
|
504
|
+
:key="ix + 'opMenu'"
|
|
505
|
+
size="mini"
|
|
506
|
+
type="text"
|
|
507
|
+
:icon="opMenu.icon"
|
|
508
|
+
@click="
|
|
509
|
+
onListCustomOpMenuClick({
|
|
510
|
+
opMenu: opMenu,
|
|
511
|
+
data: scope.row,
|
|
512
|
+
index: scope.$index,
|
|
513
|
+
})
|
|
514
|
+
"
|
|
515
|
+
v-hasPermi="[
|
|
516
|
+
opMenu.permission,
|
|
517
|
+
`${moduleName}:${serviceName}:${opMenu.permission}`,
|
|
518
|
+
]"
|
|
519
|
+
>
|
|
520
|
+
{{ opMenu.text }}
|
|
521
|
+
</el-button>
|
|
522
|
+
</template>
|
|
523
|
+
</el-table-column>
|
|
524
|
+
</el-table>
|
|
525
|
+
<pagination
|
|
526
|
+
:key="dex + 'pagin'"
|
|
527
|
+
v-show="multiplelistQueryParams[dex].total > 0"
|
|
528
|
+
:total="multiplelistQueryParams[dex].total"
|
|
529
|
+
:page.sync="multiplelistQueryParams[dex].pageNum"
|
|
530
|
+
:limit.sync="multiplelistQueryParams[dex].pageSize"
|
|
531
|
+
@pagination="
|
|
532
|
+
doubleGetList(
|
|
533
|
+
dex,
|
|
534
|
+
undefined,
|
|
535
|
+
searchShow ? 'doubleList' : 'doubleListSearch'
|
|
536
|
+
)
|
|
537
|
+
"
|
|
538
|
+
/>
|
|
539
|
+
</template>
|
|
540
|
+
</div>
|
|
541
|
+
</el-col>
|
|
542
|
+
</el-row>
|
|
543
|
+
|
|
544
|
+
<!-- 添加或修改参数配置对话框 -->
|
|
545
|
+
<component
|
|
546
|
+
ref="editDialog"
|
|
547
|
+
:title="title"
|
|
548
|
+
:moduleName="moduleName"
|
|
549
|
+
:serviceName="serviceName"
|
|
550
|
+
:entity.sync="currentEntity"
|
|
551
|
+
:setting.sync="editSetting"
|
|
552
|
+
:columns.sync="editColumns"
|
|
553
|
+
:editForm="editSetting.listSetting.listColumns.editForm"
|
|
554
|
+
:rules.sync="editRules"
|
|
555
|
+
:customOpMenus.sync="editCustomOpMenus"
|
|
556
|
+
:areaSetting="areaSetting"
|
|
557
|
+
v-on:onCustomOpMenuClick="onEditCustomOpMenuClick"
|
|
558
|
+
v-on:onSaveClick="onEditSaveClick"
|
|
559
|
+
v-on:onCancelClick="onEditCancelClick"
|
|
560
|
+
v-on:change="onChangeEvent"
|
|
561
|
+
v-if="editSetting.isShow"
|
|
562
|
+
width="600px"
|
|
563
|
+
append-to-body
|
|
564
|
+
v-dialogDrag
|
|
565
|
+
v-dialogDragHeight
|
|
566
|
+
:is="editDialogComponent"
|
|
567
|
+
>
|
|
568
|
+
</component>
|
|
569
|
+
|
|
570
|
+
<!-- 用户导入对话框 -->
|
|
571
|
+
<UploadDialog
|
|
572
|
+
ref="uploadDialog"
|
|
573
|
+
:moduleName="moduleName"
|
|
574
|
+
:serviceName="serviceName"
|
|
575
|
+
:setting.sync="uploadSetting"
|
|
576
|
+
:visible.sync="uploadSetting.isShow"
|
|
577
|
+
width="400px"
|
|
578
|
+
append-to-body
|
|
579
|
+
v-dialogDrag
|
|
580
|
+
v-dialogDragHeight
|
|
581
|
+
>
|
|
582
|
+
</UploadDialog>
|
|
583
|
+
|
|
584
|
+
<!-- 打印界面对话框 -->
|
|
585
|
+
<printDialog
|
|
586
|
+
ref="printDialog"
|
|
587
|
+
:moduleName="moduleName"
|
|
588
|
+
:serviceName="serviceName"
|
|
589
|
+
:templateType="templateType"
|
|
590
|
+
:setting.sync="printSetting"
|
|
591
|
+
:visible.sync="printSetting.isShow"
|
|
592
|
+
width="70%"
|
|
593
|
+
append-to-body
|
|
594
|
+
v-dialogDrag
|
|
595
|
+
v-dialogDragHeight
|
|
596
|
+
>
|
|
597
|
+
</printDialog>
|
|
598
|
+
</div>
|
|
599
|
+
</template>
|
|
600
|
+
|
|
601
|
+
<script>
|
|
602
|
+
import { Component } from "vue-property-decorator";
|
|
603
|
+
import {
|
|
604
|
+
listEntity,
|
|
605
|
+
selectInterfaceSetting,
|
|
606
|
+
initTableField,
|
|
607
|
+
} from "@api/common/common";
|
|
608
|
+
import {ListBasePage} from "list-bese-page";
|
|
609
|
+
@Component
|
|
610
|
+
export default class doubleBasePageTs extends ListBasePage {
|
|
611
|
+
//表格高度
|
|
612
|
+
tableHeight = "700";
|
|
613
|
+
//独立搜索
|
|
614
|
+
searchShow = false;
|
|
615
|
+
//多表格独立自定义按钮
|
|
616
|
+
bottomShow = false;
|
|
617
|
+
//多表格全选按钮
|
|
618
|
+
SelectionChangeShow = false;
|
|
619
|
+
|
|
620
|
+
//多个表格
|
|
621
|
+
tableSetting = [
|
|
622
|
+
{
|
|
623
|
+
//获取列表数据的api方法名
|
|
624
|
+
getListAction: "list",
|
|
625
|
+
//微服务模块名称
|
|
626
|
+
moduleName: undefined,
|
|
627
|
+
//实体名称-服务名称
|
|
628
|
+
serviceName: undefined,
|
|
629
|
+
//当前表格主键字段
|
|
630
|
+
pkField: "id",
|
|
631
|
+
//子表外健字段
|
|
632
|
+
fkField: undefined,
|
|
633
|
+
//子表外健绑定主表外键字段
|
|
634
|
+
parentFkField: undefined,
|
|
635
|
+
//表格是否自动加载数据
|
|
636
|
+
isAutoLoad: true,
|
|
637
|
+
//是否显示操作栏
|
|
638
|
+
isShowOpColumn: false,
|
|
639
|
+
//是否显示行号
|
|
640
|
+
isShowIndexColumn: true,
|
|
641
|
+
// 列表列信息
|
|
642
|
+
listColumns: [
|
|
643
|
+
//{ key: 0, text: `用户编码`, property: "userNo", type: "string", visible: true },
|
|
644
|
+
//{ key: 1, text: `用户账号`, property: "userAccount", visible: true },
|
|
645
|
+
],
|
|
646
|
+
//列表自定义操作菜单设定 - 若无自定义按钮,不需要重写
|
|
647
|
+
listCustomOpMenus: [
|
|
648
|
+
//{ visable: true, text: "按钮1", icon: "el-icon-edit", permission: "", name: "custom1", isShowText: false }
|
|
649
|
+
],
|
|
650
|
+
|
|
651
|
+
//搜索项
|
|
652
|
+
searchRules: { rules: [] },
|
|
653
|
+
//自定义操作菜单设定 - 若无自定义按钮,不需要重写
|
|
654
|
+
customOpMenus: [
|
|
655
|
+
{
|
|
656
|
+
visable: true,
|
|
657
|
+
text: "按钮1",
|
|
658
|
+
icon: "el-icon-plus",
|
|
659
|
+
permission: "",
|
|
660
|
+
name: "custom1",
|
|
661
|
+
isShowText: false,
|
|
662
|
+
cssType: "success",
|
|
663
|
+
},
|
|
664
|
+
],
|
|
665
|
+
},
|
|
666
|
+
];
|
|
667
|
+
//表格分页
|
|
668
|
+
multiplelistQueryParams = [];
|
|
669
|
+
//表格数据
|
|
670
|
+
multipleListData = [[{}, {}]];
|
|
671
|
+
//表格选中数据
|
|
672
|
+
multipleCurrentEntity = [];
|
|
673
|
+
rowNew = {};
|
|
674
|
+
created() {
|
|
675
|
+
this.initItemTableField();
|
|
676
|
+
|
|
677
|
+
//获取树数据
|
|
678
|
+
if (this.treeSetting.visable) {
|
|
679
|
+
this.getTreeSelect();
|
|
680
|
+
}
|
|
681
|
+
for (const key in this.tableSetting) {
|
|
682
|
+
this.multiplelistQueryParams.push({
|
|
683
|
+
pageNum: 1,
|
|
684
|
+
pageSize: 10,
|
|
685
|
+
totalPages: 1,
|
|
686
|
+
total: 0,
|
|
687
|
+
orderBy: "id",
|
|
688
|
+
});
|
|
689
|
+
}
|
|
690
|
+
if (this.isAutoLoad) {
|
|
691
|
+
console.log(this.isAutoLoad);
|
|
692
|
+
if (this.moduleName && this.serviceName) this.getList();
|
|
693
|
+
}
|
|
694
|
+
//是否开启各自搜索
|
|
695
|
+
if (this.searchShow) {
|
|
696
|
+
this.doubleList();
|
|
697
|
+
}
|
|
698
|
+
this.editSetting.pkField = this.pkField;
|
|
699
|
+
this.listSetting.pkField = this.pkField;
|
|
700
|
+
}
|
|
701
|
+
mounted() {
|
|
702
|
+
this.$nextTick(function () {
|
|
703
|
+
this.tableHeight =
|
|
704
|
+
window.innerHeight / 2 -
|
|
705
|
+
this.$refs.multipleTable.$el.getBoundingClientRect().top;
|
|
706
|
+
|
|
707
|
+
// 监听窗口大小变化
|
|
708
|
+
|
|
709
|
+
var that = this;
|
|
710
|
+
|
|
711
|
+
window.onresize = function () {
|
|
712
|
+
that.tableHeight =
|
|
713
|
+
window.innerHeight / 2 -
|
|
714
|
+
that.$refs.multipleTable.$el.getBoundingClientRect().top;
|
|
715
|
+
};
|
|
716
|
+
});
|
|
717
|
+
}
|
|
718
|
+
/** 表格列显示格式化方法 */
|
|
719
|
+
doubleTableDisplayFormat(row, column, cellValue, index) {
|
|
720
|
+
return this.super(ListBasePage, "tableDisplayFormat", [
|
|
721
|
+
row,
|
|
722
|
+
column,
|
|
723
|
+
cellValue,
|
|
724
|
+
this.tableSetting[index].listColumns,
|
|
725
|
+
]);
|
|
726
|
+
}
|
|
727
|
+
//带各自搜索的首次请求
|
|
728
|
+
doubleList() {
|
|
729
|
+
this.multipleListData = [];
|
|
730
|
+
for (const key in this.tableSetting) {
|
|
731
|
+
this.multipleListData.push(null);
|
|
732
|
+
this.doubleGetList(key, undefined, "doubleList");
|
|
733
|
+
}
|
|
734
|
+
}
|
|
735
|
+
/** 获取查询条件 */
|
|
736
|
+
getSearchParams(pagerInfo, searchRules, index, type) {
|
|
737
|
+
if (!pagerInfo)
|
|
738
|
+
if (!pagerInfo) {
|
|
739
|
+
pagerInfo = this.listQueryParams;
|
|
740
|
+
if (index != undefined) {
|
|
741
|
+
pagerInfo = this.multiplelistQueryParams[index];
|
|
742
|
+
}
|
|
743
|
+
}
|
|
744
|
+
// 是多表格搜索
|
|
745
|
+
|
|
746
|
+
if (type == "tableSetting") {
|
|
747
|
+
var searchParams = { rules: [] };
|
|
748
|
+
for (var key in pagerInfo) {
|
|
749
|
+
searchParams[key] = pagerInfo[key];
|
|
750
|
+
}
|
|
751
|
+
if (!searchRules) searchRules = this.tableSetting[index].searchRules;
|
|
752
|
+
if (searchRules) {
|
|
753
|
+
for (var item of searchRules) {
|
|
754
|
+
// searchParams[item.property] = item.value;
|
|
755
|
+
searchParams.rules.push({
|
|
756
|
+
op: item.op,
|
|
757
|
+
property: item["property"],
|
|
758
|
+
value: item["value"],
|
|
759
|
+
});
|
|
760
|
+
}
|
|
761
|
+
}
|
|
762
|
+
return searchParams;
|
|
763
|
+
}
|
|
764
|
+
if (!searchRules) searchRules = this.searchRules;
|
|
765
|
+
var searchParams = { rules: [] };
|
|
766
|
+
|
|
767
|
+
for (var key in pagerInfo) {
|
|
768
|
+
searchParams[key] = pagerInfo[key];
|
|
769
|
+
}
|
|
770
|
+
if (this.searchRules) {
|
|
771
|
+
for (var item of searchRules) {
|
|
772
|
+
// searchParams[item.property] = item.value;
|
|
773
|
+
if (item[item.property] || item[item.property] == 0) {
|
|
774
|
+
searchParams.rules.push({
|
|
775
|
+
op: item.op,
|
|
776
|
+
property: item["property"],
|
|
777
|
+
value: item[item.property],
|
|
778
|
+
});
|
|
779
|
+
}
|
|
780
|
+
}
|
|
781
|
+
}
|
|
782
|
+
return searchParams;
|
|
783
|
+
}
|
|
784
|
+
/** 查询用户列表 */
|
|
785
|
+
getList() {
|
|
786
|
+
//多表格查询
|
|
787
|
+
this.loading = true;
|
|
788
|
+
listEntity(
|
|
789
|
+
this.moduleName,
|
|
790
|
+
this.serviceName,
|
|
791
|
+
{ op: "AND", ...this.getSearchParams() },
|
|
792
|
+
this.listSetting.getListAction
|
|
793
|
+
)
|
|
794
|
+
.then((response) => {
|
|
795
|
+
this.listData = response.rows;
|
|
796
|
+
this.listQueryParams.total = Number(response.total);
|
|
797
|
+
this.loading = false;
|
|
798
|
+
//节流
|
|
799
|
+
this.$nextTick(() => {
|
|
800
|
+
this.resetQueryClick = true;
|
|
801
|
+
this.loading = false;
|
|
802
|
+
});
|
|
803
|
+
})
|
|
804
|
+
.catch(() => {
|
|
805
|
+
this.loading = false;
|
|
806
|
+
});
|
|
807
|
+
}
|
|
808
|
+
|
|
809
|
+
//多列表查询
|
|
810
|
+
doubleGetList(index, row, type) {
|
|
811
|
+
var item = this.tableSetting[index];
|
|
812
|
+
this.loading = true;
|
|
813
|
+
if (!type) if (!row) row = this.currentEntity;
|
|
814
|
+
// if (!row) return;
|
|
815
|
+
if (row) {
|
|
816
|
+
if (row[item.parentFkField]) {
|
|
817
|
+
this.loading = true;
|
|
818
|
+
this.multiplelistQueryParams[index][item.fkField] =
|
|
819
|
+
row[item.parentFkField];
|
|
820
|
+
|
|
821
|
+
listEntity(
|
|
822
|
+
item.moduleName,
|
|
823
|
+
item.serviceName,
|
|
824
|
+
{
|
|
825
|
+
op: "AND",
|
|
826
|
+
...this.getSearchParams(
|
|
827
|
+
undefined,
|
|
828
|
+
undefined,
|
|
829
|
+
index,
|
|
830
|
+
"tableSetting"
|
|
831
|
+
),
|
|
832
|
+
},
|
|
833
|
+
item.getListAction
|
|
834
|
+
)
|
|
835
|
+
.then((response) => {
|
|
836
|
+
this.multipleListData[index] = response.rows;
|
|
837
|
+
this.multiplelistQueryParams[index].total = Number(response.total);
|
|
838
|
+
this.loading = false;
|
|
839
|
+
this.$forceUpdate();
|
|
840
|
+
})
|
|
841
|
+
.catch(() => {
|
|
842
|
+
this.loading = false;
|
|
843
|
+
});
|
|
844
|
+
}
|
|
845
|
+
if (!row[item.parentFkField]) {
|
|
846
|
+
this.multipleListData = [];
|
|
847
|
+
this.multiplelistQueryParams[index].total = 0;
|
|
848
|
+
}
|
|
849
|
+
}
|
|
850
|
+
if (!row) {
|
|
851
|
+
this.multipleListData = [];
|
|
852
|
+
let getSearchParam = {};
|
|
853
|
+
if (type) {
|
|
854
|
+
getSearchParam = this.getSearchParams(undefined, undefined, index);
|
|
855
|
+
}
|
|
856
|
+
if (!type || type == "doubleListSearch") {
|
|
857
|
+
getSearchParam = this.getSearchParams(
|
|
858
|
+
undefined,
|
|
859
|
+
undefined,
|
|
860
|
+
index,
|
|
861
|
+
"tableSetting"
|
|
862
|
+
);
|
|
863
|
+
}
|
|
864
|
+
listEntity(
|
|
865
|
+
this.tableSetting[index].moduleName,
|
|
866
|
+
this.tableSetting[index].serviceName,
|
|
867
|
+
{ op: "AND", ...getSearchParam },
|
|
868
|
+
this.tableSetting[index].getListAction
|
|
869
|
+
)
|
|
870
|
+
.then((response) => {
|
|
871
|
+
this.multipleListData.push(response.rows);
|
|
872
|
+
this.multiplelistQueryParams[index].total = Number(response.total);
|
|
873
|
+
this.$forceUpdate();
|
|
874
|
+
this.loading = false;
|
|
875
|
+
})
|
|
876
|
+
.catch(() => {
|
|
877
|
+
this.loading = false;
|
|
878
|
+
});
|
|
879
|
+
}
|
|
880
|
+
}
|
|
881
|
+
//点击表格单行
|
|
882
|
+
rowclick(row, column) {
|
|
883
|
+
// 点击行多选
|
|
884
|
+
//节流
|
|
885
|
+
if (!this.resetQueryClick) {
|
|
886
|
+
return;
|
|
887
|
+
}
|
|
888
|
+
this.rowNew = row;
|
|
889
|
+
this.tableSetting.forEach((item, key) => {
|
|
890
|
+
this.doubleGetList(key, row);
|
|
891
|
+
});
|
|
892
|
+
}
|
|
893
|
+
//多选框选中数据
|
|
894
|
+
doubleSelectionChange(value) {
|
|
895
|
+
this.multipleCurrentEntity = value;
|
|
896
|
+
}
|
|
897
|
+
/** 搜索按钮操作 */
|
|
898
|
+
handleQuery() {
|
|
899
|
+
this.listQueryParams.pageNum = 1;
|
|
900
|
+
if (!this.searchShow) {
|
|
901
|
+
this.multipleListData = [];
|
|
902
|
+
}
|
|
903
|
+
//节流
|
|
904
|
+
this.resetQueryClick = false;
|
|
905
|
+
this.getList();
|
|
906
|
+
this.$forceUpdate();
|
|
907
|
+
}
|
|
908
|
+
/** 重置按钮操作 */
|
|
909
|
+
resetQuery() {
|
|
910
|
+
for (var searchRule of this.searchRules) {
|
|
911
|
+
this.$set(searchRule, searchRule.property, undefined);
|
|
912
|
+
}
|
|
913
|
+
|
|
914
|
+
this.resetQueryClick = false;
|
|
915
|
+
this.resetForm("queryForm");
|
|
916
|
+
this.handleQuery();
|
|
917
|
+
}
|
|
918
|
+
//多表格搜索按钮
|
|
919
|
+
doubleHandleQuery(index) {
|
|
920
|
+
this.multiplelistQueryParams[index].pageNum = 1;
|
|
921
|
+
this.doubleGetList(index, undefined, "doubleListSearch");
|
|
922
|
+
}
|
|
923
|
+
doubleResetQuery(index) {
|
|
924
|
+
for (var searchRule of this.tableSetting[index].searchRules) {
|
|
925
|
+
this.$set(searchRule, "value", undefined);
|
|
926
|
+
}
|
|
927
|
+
|
|
928
|
+
this.resetForm("queryForm" + index, index);
|
|
929
|
+
this.doubleHandleQuery(index);
|
|
930
|
+
}
|
|
931
|
+
initItemTableField() {
|
|
932
|
+
var entityName =
|
|
933
|
+
this.serviceName.charAt(0).toUpperCase() + this.serviceName.slice(1);
|
|
934
|
+
selectInterfaceSetting({
|
|
935
|
+
moduleName: this.moduleName,
|
|
936
|
+
entityName: entityName,
|
|
937
|
+
}).then((response) => {
|
|
938
|
+
if (response.data.length == 1) {
|
|
939
|
+
if (response.data[0].entityItemName) {
|
|
940
|
+
selectInterfaceSetting({
|
|
941
|
+
name: response.data[0].entityItemName,
|
|
942
|
+
}).then((response) => {
|
|
943
|
+
if (response.data.length == 1) {
|
|
944
|
+
//设置明细表模块和服务
|
|
945
|
+
this.tableSetting[0].moduleName = response.data[0].moduleName;
|
|
946
|
+
this.tableSetting[0].serviceName = response.data[0].entityName;
|
|
947
|
+
//初始化子表字段
|
|
948
|
+
initTableField({ interfaceSettingId: response.data[0].id }).then(
|
|
949
|
+
(response) => {
|
|
950
|
+
console.log("初始化明细列表字段");
|
|
951
|
+
for (var d of response.data) {
|
|
952
|
+
let a = {
|
|
953
|
+
setting: "",
|
|
954
|
+
width: "",
|
|
955
|
+
text: "",
|
|
956
|
+
property: "",
|
|
957
|
+
visible: "",
|
|
958
|
+
};
|
|
959
|
+
if (d.setting) {
|
|
960
|
+
a.setting = JSON.parse(d.setting);
|
|
961
|
+
}
|
|
962
|
+
if (d.width) {
|
|
963
|
+
a.width = d.width;
|
|
964
|
+
}
|
|
965
|
+
a.text = d.displayText;
|
|
966
|
+
a.property = d.field;
|
|
967
|
+
a.visible = d.isShow;
|
|
968
|
+
this.tableSetting[0].listColumns.push(a);
|
|
969
|
+
}
|
|
970
|
+
}
|
|
971
|
+
);
|
|
972
|
+
console.log(this.tableSetting[0].listColumns);
|
|
973
|
+
} else {
|
|
974
|
+
this.msgError("数据错误!");
|
|
975
|
+
}
|
|
976
|
+
});
|
|
977
|
+
}
|
|
978
|
+
}
|
|
979
|
+
});
|
|
980
|
+
}
|
|
981
|
+
}
|
|
982
|
+
</script>
|
|
983
|
+
|
|
984
|
+
<style scoped>
|
|
985
|
+
.wrapper-container-supplement {
|
|
986
|
+
min-height: 415px;
|
|
987
|
+
}
|
|
988
|
+
.doubleWrapper {
|
|
989
|
+
padding: 0;
|
|
990
|
+
margin-bottom: 0;
|
|
991
|
+
}
|
|
992
|
+
.doublemenu {
|
|
993
|
+
margin-bottom: 10px;
|
|
994
|
+
padding-left: 0px !important;
|
|
995
|
+
}
|
|
996
|
+
</style>
|