style:列表增加数组渲染方法,搜索功能显示搜索条件的完善
Showing
7 changed files
with
61 additions
and
33 deletions
... | @@ -13,12 +13,12 @@ | ... | @@ -13,12 +13,12 @@ |
13 | </template> | 13 | </template> |
14 | 14 | ||
15 | <script> | 15 | <script> |
16 | import { mapGetters } from 'vuex' | 16 | import { mapGetters } from 'vuex' |
17 | import Logo from './Logo' | 17 | import Logo from './Logo' |
18 | import SidebarItem from './SidebarItem' | 18 | import SidebarItem from './SidebarItem' |
19 | import variables from '@/styles/variables.scss' | 19 | import variables from '@/styles/variables.scss' |
20 | import { asyncRoutes } from '@/router' | 20 | import { asyncRoutes } from '@/router' |
21 | export default { | 21 | export default { |
22 | components: { SidebarItem, Logo }, | 22 | components: { SidebarItem, Logo }, |
23 | computed: { | 23 | computed: { |
24 | ...mapGetters(['permission_routes', 'sidebar']), | 24 | ...mapGetters(['permission_routes', 'sidebar']), |
... | @@ -37,5 +37,5 @@ export default { | ... | @@ -37,5 +37,5 @@ export default { |
37 | return asyncRoutes | 37 | return asyncRoutes |
38 | } | 38 | } |
39 | } | 39 | } |
40 | } | 40 | } |
41 | </script> | 41 | </script> | ... | ... |
1 | /* | 1 | /* |
2 | * @Description: | 2 | * @Description: |
3 | * @Autor: renchao | 3 | * @Autor: renchao |
4 | * @LastEditTime: 2023-08-28 15:31:31 | 4 | * @LastEditTime: 2023-09-25 10:56:39 |
5 | */ | 5 | */ |
6 | import store from '@/store' | 6 | import store from '@/store' |
7 | // table 内部过滤器 由于过滤器只能在模板中使用 所以 就有了 jsx内部方法过滤器 | 7 | // table 内部过滤器 由于过滤器只能在模板中使用 所以 就有了 jsx内部方法过滤器 |
... | @@ -110,4 +110,11 @@ export default class filter { | ... | @@ -110,4 +110,11 @@ export default class filter { |
110 | 110 | ||
111 | return text; | 111 | return text; |
112 | } | 112 | } |
113 | joinItem (val) { | ||
114 | if (Array.isArray(val) && val.length > 0) { | ||
115 | return val.join() | ||
116 | } else { | ||
117 | return val | ||
118 | } | ||
119 | } | ||
113 | } | 120 | } | ... | ... |
1 | /* | 1 | /* |
2 | * @Description: | 2 | * @Description: |
3 | * @Autor: renchao | 3 | * @Autor: renchao |
4 | * @LastEditTime: 2023-05-17 10:42:40 | 4 | * @LastEditTime: 2023-09-25 09:31:27 |
5 | */ | 5 | */ |
6 | export default { | 6 | export default { |
7 | data () { | 7 | data () { |
... | @@ -12,7 +12,6 @@ export default { | ... | @@ -12,7 +12,6 @@ export default { |
12 | } | 12 | } |
13 | }, | 13 | }, |
14 | methods: { | 14 | methods: { |
15 | // 点击高级查询弹出查询弹框 | ||
16 | /** | 15 | /** |
17 | * @description: 点击高级查询弹出查询弹框 | 16 | * @description: 点击高级查询弹出查询弹框 |
18 | * @author: renchao | 17 | * @author: renchao |
... | @@ -21,7 +20,6 @@ export default { | ... | @@ -21,7 +20,6 @@ export default { |
21 | this.isSearch = true | 20 | this.isSearch = true |
22 | 21 | ||
23 | }, | 22 | }, |
24 | // 查询事件 | ||
25 | /** | 23 | /** |
26 | * @description: 查询事件 | 24 | * @description: 查询事件 |
27 | * @param {*} bs | 25 | * @param {*} bs |
... | @@ -36,7 +34,6 @@ export default { | ... | @@ -36,7 +34,6 @@ export default { |
36 | } | 34 | } |
37 | }) | 35 | }) |
38 | }, | 36 | }, |
39 | // 清空单个表单 | ||
40 | /** | 37 | /** |
41 | * @description: 清空单个表单 | 38 | * @description: 清空单个表单 |
42 | * @param {*} el | 39 | * @param {*} el |
... | @@ -62,7 +59,6 @@ export default { | ... | @@ -62,7 +59,6 @@ export default { |
62 | } | 59 | } |
63 | this.searchForm[el] = '' | 60 | this.searchForm[el] = '' |
64 | }, | 61 | }, |
65 | // 删除单个查询条件 | ||
66 | /** | 62 | /** |
67 | * @description: 删除单个查询条件 | 63 | * @description: 删除单个查询条件 |
68 | * @param {*} item | 64 | * @param {*} item |
... | @@ -92,7 +88,8 @@ export default { | ... | @@ -92,7 +88,8 @@ export default { |
92 | iterationData () { | 88 | iterationData () { |
93 | let obj = { | 89 | let obj = { |
94 | ywlymc: '业务来源', qllxmc: '权利类型', djlxmc: '登记类型', ywh: '业务号', sqywmc: '申请业务名称', | 90 | ywlymc: '业务来源', qllxmc: '权利类型', djlxmc: '登记类型', ywh: '业务号', sqywmc: '申请业务名称', |
95 | qlrmc: '权利人', ywrmc: '义务人', slsj: '受理时间' | 91 | bdcdyh: '不动产单元号', |
92 | sqrmc: '申请人', sqrzjhm: '申请人证件号', zl: '坐落' | ||
96 | } | 93 | } |
97 | this.searchList = Object.entries({ ...this.searchForm, ...this.otherForm }).map((item) => { | 94 | this.searchList = Object.entries({ ...this.searchForm, ...this.otherForm }).map((item) => { |
98 | const [name, value] = item | 95 | const [name, value] = item |
... | @@ -109,7 +106,6 @@ export default { | ... | @@ -109,7 +106,6 @@ export default { |
109 | this.iterationData() | 106 | this.iterationData() |
110 | this.queryClick() | 107 | this.queryClick() |
111 | }, | 108 | }, |
112 | // 清空查询条件 | ||
113 | /** | 109 | /** |
114 | * @description: 清空查询条件 | 110 | * @description: 清空查询条件 |
115 | * @author: renchao | 111 | * @author: renchao |
... | @@ -120,7 +116,11 @@ export default { | ... | @@ -120,7 +116,11 @@ export default { |
120 | ywly: "", | 116 | ywly: "", |
121 | qllx: "", | 117 | qllx: "", |
122 | djlx: "", | 118 | djlx: "", |
123 | ywh: "" | 119 | ywh: "", |
120 | bdcdyh: "", | ||
121 | sqrmc: "", | ||
122 | sqrzjhm: "", | ||
123 | zl: "" | ||
124 | } | 124 | } |
125 | this.otherForm = {} | 125 | this.otherForm = {} |
126 | this.searchList = [] | 126 | this.searchList = [] | ... | ... |
1 | <!-- | 1 | <!-- |
2 | * @Description: | 2 | * @Description: |
3 | * @Autor: renchao | 3 | * @Autor: renchao |
4 | * @LastEditTime: 2023-09-21 14:49:29 | 4 | * @LastEditTime: 2023-09-25 10:33:39 |
5 | --> | 5 | --> |
6 | <template> | 6 | <template> |
7 | <div class="from-clues"> | 7 | <div class="from-clues"> |
... | @@ -221,14 +221,18 @@ | ... | @@ -221,14 +221,18 @@ |
221 | }; | 221 | }; |
222 | }, | 222 | }, |
223 | methods: { | 223 | methods: { |
224 | // 列表渲染接口 | ||
225 | /** | 224 | /** |
226 | * @description: 列表渲染接口 | 225 | * @description: 列表渲染接口 |
227 | * @author: renchao | 226 | * @author: renchao |
228 | */ | 227 | */ |
229 | queryClick () { | 228 | queryClick () { |
230 | this.$startLoading(); | 229 | this.$startLoading(); |
231 | this.searchForm.ywh = this.queryForm.ywh; | 230 | const { ywh, bdcdyh, sqrmc, sqrzjhm, zl } = this.queryForm; |
231 | this.searchForm.ywh = ywh; | ||
232 | this.searchForm.bdcdyh = bdcdyh; | ||
233 | this.searchForm.sqrmc = sqrmc; | ||
234 | this.searchForm.sqrzjhm = sqrzjhm; | ||
235 | this.searchForm.zl = zl; | ||
232 | this.iterationData(); | 236 | this.iterationData(); |
233 | searchTaskToDo({ | 237 | searchTaskToDo({ |
234 | ...this.queryForm, | 238 | ...this.queryForm, | ... | ... |
1 | /* | 1 | /* |
2 | * @Description: | 2 | * @Description: |
3 | * @Autor: renchao | 3 | * @Autor: renchao |
4 | * @LastEditTime: 2023-09-20 17:17:22 | 4 | * @LastEditTime: 2023-09-25 10:58:15 |
5 | */ | 5 | */ |
6 | import filter from '@/utils/filter.js' | 6 | import filter from '@/utils/filter.js' |
7 | let vm = null | 7 | let vm = null |
... | @@ -62,7 +62,11 @@ class data extends filter { | ... | @@ -62,7 +62,11 @@ class data extends filter { |
62 | align: 'center', | 62 | align: 'center', |
63 | minWidth: '100', | 63 | minWidth: '100', |
64 | render: (h, scope) => { | 64 | render: (h, scope) => { |
65 | return <el-link type="primary" onClick={() => { vm.ywhClick(scope.row) }}>{scope.row.ywh}</el-link> | 65 | return ( |
66 | <el-tooltip effect="dark" content={this.joinItem(scope.row.ywh)} placement="top" popper-class="tooltip-width "> | ||
67 | <el-link type="primary" onClick={() => { vm.ywhClick(scope.row) }}>{this.joinItem(scope.row.ywh)}</el-link> | ||
68 | </el-tooltip> | ||
69 | ); | ||
66 | } | 70 | } |
67 | }, | 71 | }, |
68 | { | 72 | { |
... | @@ -81,8 +85,8 @@ class data extends filter { | ... | @@ -81,8 +85,8 @@ class data extends filter { |
81 | render: (h, scope) => { | 85 | render: (h, scope) => { |
82 | return ( | 86 | return ( |
83 | <div> | 87 | <div> |
84 | <el-tooltip effect="dark" content={scope.row.qlrmc} placement="top" popper-class="tooltip-width "> | 88 | <el-tooltip effect="dark" content={this.joinItem(scope.row.qlrmc)} placement="top" popper-class="tooltip-width "> |
85 | <span class="ellipsis-table"> {scope.row.qlrmc}</span> | 89 | <span class="ellipsis-table"> {this.joinItem(scope.row.qlrmc)}</span> |
86 | </el-tooltip> | 90 | </el-tooltip> |
87 | </div> | 91 | </div> |
88 | ) | 92 | ) |
... | @@ -94,8 +98,8 @@ class data extends filter { | ... | @@ -94,8 +98,8 @@ class data extends filter { |
94 | render: (h, scope) => { | 98 | render: (h, scope) => { |
95 | return ( | 99 | return ( |
96 | <div> | 100 | <div> |
97 | <el-tooltip effect="dark" content={scope.row.ywrmc} placement="top" popper-class="tooltip-width "> | 101 | <el-tooltip effect="dark" content={this.joinItem(scope.row.ywrmc)} placement="top" popper-class="tooltip-width "> |
98 | <span class="ellipsis-table"> {scope.row.ywrmc}</span> | 102 | <span class="ellipsis-table"> {this.joinItem(scope.row.ywrmc)}</span> |
99 | </el-tooltip> | 103 | </el-tooltip> |
100 | </div> | 104 | </div> |
101 | ) | 105 | ) | ... | ... |
1 | <!-- | 1 | <!-- |
2 | * @Description: | 2 | * @Description: |
3 | * @Autor: renchao | 3 | * @Autor: renchao |
4 | * @LastEditTime: 2023-09-21 14:24:21 | 4 | * @LastEditTime: 2023-09-25 10:01:40 |
5 | --> | 5 | --> |
6 | <template> | 6 | <template> |
7 | <div class="from-clues"> | 7 | <div class="from-clues"> |
... | @@ -197,12 +197,20 @@ | ... | @@ -197,12 +197,20 @@ |
197 | qllx: "", | 197 | qllx: "", |
198 | djlx: "", | 198 | djlx: "", |
199 | ywh: "", | 199 | ywh: "", |
200 | bdcdyh: "", | ||
201 | sqrmc: "", | ||
202 | sqrzjhm: "", | ||
203 | zl: "" | ||
200 | }, | 204 | }, |
201 | searchForm: { | 205 | searchForm: { |
202 | ywlymc: "", | 206 | ywlymc: "", |
203 | qllxmc: "", | 207 | qllxmc: "", |
204 | djlxmc: "", | 208 | djlxmc: "", |
205 | ywh: "", | 209 | ywh: "", |
210 | bdcdyh: "", | ||
211 | sqrmc: "", | ||
212 | sqrzjhm: "", | ||
213 | zl: "" | ||
206 | }, | 214 | }, |
207 | tableData: { | 215 | tableData: { |
208 | total: 0, | 216 | total: 0, |
... | @@ -223,7 +231,12 @@ | ... | @@ -223,7 +231,12 @@ |
223 | */ | 231 | */ |
224 | queryClick () { | 232 | queryClick () { |
225 | this.$startLoading(); | 233 | this.$startLoading(); |
226 | this.searchForm.ywh = this.queryForm.ywh; | 234 | const { ywh, bdcdyh, sqrmc, sqrzjhm, zl } = this.queryForm; |
235 | this.searchForm.ywh = ywh; | ||
236 | this.searchForm.bdcdyh = bdcdyh; | ||
237 | this.searchForm.sqrmc = sqrmc; | ||
238 | this.searchForm.sqrzjhm = sqrzjhm; | ||
239 | this.searchForm.zl = zl; | ||
227 | this.iterationData(); | 240 | this.iterationData(); |
228 | searchTaskDone({ | 241 | searchTaskDone({ |
229 | ...this.queryForm, | 242 | ...this.queryForm, | ... | ... |
1 | /* | 1 | /* |
2 | * @Description: | 2 | * @Description: |
3 | * @Autor: renchao | 3 | * @Autor: renchao |
4 | * @LastEditTime: 2023-09-18 11:07:59 | 4 | * @LastEditTime: 2023-09-25 10:59:16 |
5 | */ | 5 | */ |
6 | import filter from '@/utils/filter.js' | 6 | import filter from '@/utils/filter.js' |
7 | let vm = null | 7 | let vm = null |
... | @@ -56,7 +56,7 @@ class data extends filter { | ... | @@ -56,7 +56,7 @@ class data extends filter { |
56 | label: "业务号", | 56 | label: "业务号", |
57 | width: '100', | 57 | width: '100', |
58 | render: (h, scope) => { | 58 | render: (h, scope) => { |
59 | return <el-link type="primary" onClick={() => { vm.ywhClick(scope.row) }}>{scope.row.ywh}</el-link> | 59 | return <el-link type="primary" onClick={() => { vm.ywhClick(scope.row) }}>{this.joinItem(scope.row.ywh)}</el-link> |
60 | } | 60 | } |
61 | }, | 61 | }, |
62 | { | 62 | { |
... | @@ -70,8 +70,8 @@ class data extends filter { | ... | @@ -70,8 +70,8 @@ class data extends filter { |
70 | render: (h, scope) => { | 70 | render: (h, scope) => { |
71 | return ( | 71 | return ( |
72 | <div> | 72 | <div> |
73 | <el-tooltip effect="dark" content={scope.row.qlrmc} placement="top" popper-class="tooltip-width "> | 73 | <el-tooltip effect="dark" content={this.joinItem(scope.row.qlrmc)} placement="top" popper-class="tooltip-width "> |
74 | <span class="ellipsis-table"> {scope.row.qlrmc}</span> | 74 | <span class="ellipsis-table"> {this.joinItem(scope.row.qlrmc)}</span> |
75 | </el-tooltip> | 75 | </el-tooltip> |
76 | </div> | 76 | </div> |
77 | ) | 77 | ) |
... | @@ -83,8 +83,8 @@ class data extends filter { | ... | @@ -83,8 +83,8 @@ class data extends filter { |
83 | render: (h, scope) => { | 83 | render: (h, scope) => { |
84 | return ( | 84 | return ( |
85 | <div> | 85 | <div> |
86 | <el-tooltip effect="dark" content={scope.row.ywrmc} placement="top" popper-class="tooltip-width"> | 86 | <el-tooltip effect="dark" content={this.joinItem(scope.row.ywrmc)} placement="top" popper-class="tooltip-width"> |
87 | <span class="ellipsis-table"> {scope.row.ywrmc}</span> | 87 | <span class="ellipsis-table"> {this.joinItem(scope.row.ywrmc)}</span> |
88 | </el-tooltip> | 88 | </el-tooltip> |
89 | </div> | 89 | </div> |
90 | ) | 90 | ) | ... | ... |
-
Please register or sign in to post a comment