sale-client 4.2.118 → 4.2.120
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/package.json
CHANGED
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
methods: {
|
|
73
73
|
handleTabListClick (index, el) {
|
|
74
74
|
this.$parent.show = el.header
|
|
75
|
-
if (el.comp._scope && el.comp._scope.tab) {
|
|
75
|
+
if (el.comp && el.comp._scope && el.comp._scope.tab && el.comp._scope.tab.comp && el.comp._scope.tab.comp.name) {
|
|
76
76
|
this.$dispatch('tab-changed', el.comp._scope.tab.comp.name)
|
|
77
77
|
}
|
|
78
78
|
if (!el.disabled) this.active = index
|
|
@@ -8,104 +8,13 @@
|
|
|
8
8
|
@cancel-re="cancelRe"
|
|
9
9
|
@search-main="search"></user-base-info-new></div>
|
|
10
10
|
<saletabbut v-if="row" v-ref:list style="height:72%;margin-top: 1%;overflow-y: scroll">
|
|
11
|
-
<saletab header="
|
|
12
|
-
<
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
<charge-query-user :row="row" v-if="show == '收费查询'" @deal-msg="dealMsg"></charge-query-user>
|
|
19
|
-
</saletab>
|
|
20
|
-
<saletab header="收费查询" v-if="newWebHand && permission('收费查询')">
|
|
21
|
-
<charge-query-user :row="row" v-if="show == '收费查询'" @deal-msg="dealMsg"></charge-query-user>
|
|
22
|
-
</saletab>
|
|
23
|
-
<saletab header="累购查询" v-if="permission('累购查询')">
|
|
24
|
-
<Repurchase :row="row" v-if="show == '累购查询'" @deal-msg="dealMsg"></Repurchase>
|
|
25
|
-
</saletab>
|
|
26
|
-
<saletab header="下账查询" v-if="!newWebHand && row.f_meter_type.includes('物联网表')&&permission('自动下账查询')">
|
|
27
|
-
<automatic-purse :row="row" @deal-msg="dealMsg"></automatic-purse>
|
|
28
|
-
</saletab>
|
|
29
|
-
<saletab header="下账查询" v-if="newWebHand && row.f_meter_type.includes('物联网表')&&permission('自动下账查询')">
|
|
30
|
-
<web-automatic-purse :row="row" @deal-msg="dealMsg"></web-automatic-purse>
|
|
31
|
-
</saletab>
|
|
32
|
-
<saletab header="抄表记录" v-if="row.f_meter_type.includes('卡表')&&permission('抄表记录')">
|
|
33
|
-
<card-hand-record :row="row" v-if="show == '抄表记录'" @deal-msg="dealMsg"></card-hand-record>
|
|
34
|
-
</saletab>
|
|
35
|
-
<saletab header="抄表记录" v-if="!newWebHand && !row.f_meter_type.includes('卡表')&&permission('抄表记录')">
|
|
36
|
-
<hand-query-user :row="row" v-if="show == '抄表记录'" @deal-msg="dealMsg"></hand-query-user>
|
|
37
|
-
</saletab>
|
|
38
|
-
<saletab header="抄表记录" v-if="newWebHand && !row.f_meter_type.includes('卡表')&&permission('抄表记录')">
|
|
39
|
-
<web-hand-query-user :row="row" v-if="show == '抄表记录'" @deal-msg="dealMsg"></web-hand-query-user>
|
|
40
|
-
</saletab>
|
|
41
|
-
<saletab header="补卡查询" v-if="row.f_meter_type.includes('卡表')&&permission('补卡查询')">
|
|
42
|
-
<fill-card-query-user :row="row" v-if="show == '补卡查询'" @deal-msg="dealMsg"></fill-card-query-user>
|
|
43
|
-
</saletab>
|
|
44
|
-
<saletab header="补气查询" v-if="permission('补气查询')">
|
|
45
|
-
<fill-gas-query-user :row="row" v-if="show == '补气查询'" @deal-msg="dealMsg"></fill-gas-query-user>
|
|
46
|
-
</saletab>
|
|
47
|
-
<saletab header="换表查询" v-if="permission('换表查询')">
|
|
48
|
-
<change-meter-query-user :row="row" v-if="show == '换表查询'" @deal-msg="dealMsg"></change-meter-query-user>
|
|
49
|
-
</saletab>
|
|
50
|
-
<saletab header="其他收费" v-if="permission('其他收费')">
|
|
51
|
-
<other-charge-query-user :row="row" v-if="show == '其他收费'" @deal-msg="dealMsg"></other-charge-query-user>
|
|
52
|
-
</saletab>
|
|
53
|
-
<saletab header="保险收费记录" v-if="permission('保险收费记录')">
|
|
54
|
-
<insurance-charges-record :row="row" @deal-msg="dealMsg"></insurance-charges-record>
|
|
55
|
-
</saletab>
|
|
56
|
-
<saletab header="垃圾费收费记录" v-if="permission('垃圾费收费记录')">
|
|
57
|
-
<garbage-record-list :row="row" @deal-msg="dealMsg"></garbage-record-list>
|
|
58
|
-
</saletab>
|
|
59
|
-
<saletab header="过户查询" v-if="permission('过户查询')">
|
|
60
|
-
<transfer-query-user :row="row" v-if="show == '过户查询'" @deal-msg="dealMsg"></transfer-query-user>
|
|
61
|
-
</saletab>
|
|
62
|
-
<saletab header="价格调整" v-if="permission('价格调整')">
|
|
63
|
-
<price-change-query-user :row="row" v-if="show == '价格调整'" @deal-msg="dealMsg"></price-change-query-user>
|
|
64
|
-
</saletab>
|
|
65
|
-
<saletab header="附件查看" v-if="permission('附件查看')">
|
|
66
|
-
<upload-file-history :row="row" v-if="show == '附件查看'" @deal-msg="dealMsg"></upload-file-history>
|
|
67
|
-
</saletab>
|
|
68
|
-
<saletab header="变更记录" v-if="permission('变更记录')">
|
|
69
|
-
<change-record :row="row" v-if="show == '变更记录'" @deal-msg="dealMsg"></change-record>
|
|
70
|
-
</saletab>
|
|
71
|
-
<saletab header="指令查看" v-if="row.f_meter_type.includes('物联网表')&&permission('指令查看')">
|
|
72
|
-
<query-instruct :row="row" v-if="show == '指令查看'" @deal-msg="dealMsg"></query-instruct>
|
|
73
|
-
</saletab>
|
|
74
|
-
<saletab header="历史指令查看" v-if="row.f_meter_type.includes('物联网表')&&permission('历史指令查看')">
|
|
75
|
-
<query-history-instruct :row="row" v-if="show == '历史指令查看'" @deal-msg="dealMsg"></query-history-instruct>
|
|
76
|
-
</saletab>
|
|
77
|
-
<saletab header="异常报警" v-if="row.f_meter_type.includes('物联网表')&&permission('异常报警')">
|
|
78
|
-
<watch-warning :row="row" v-if="show == '异常报警'" @deal-msg="dealMsg"></watch-warning>
|
|
79
|
-
</saletab>
|
|
80
|
-
<saletab header="表具采集" v-if="row.f_meter_type.includes('物联网表')&&permission('表具采集')">
|
|
81
|
-
<watch-collection :row="row" v-if="show == '表具采集'" @deal-msg="dealMsg"></watch-collection>
|
|
82
|
-
</saletab>
|
|
83
|
-
<saletab header="调价补差" v-if="permission('调价补差')">
|
|
84
|
-
<price-adjustment-query-user :row="row" v-if="show == '调价补差'" @deal-msg="dealMsg"></price-adjustment-query-user>
|
|
85
|
-
</saletab>
|
|
86
|
-
<saletab header="设备查询" v-if="permission('设备查询')">
|
|
87
|
-
<deveice-record :row="row" v-if="show == '设备查询'" @deal-msg="dealMsg"></deveice-record>
|
|
88
|
-
</saletab>
|
|
89
|
-
<saletab header="流量计参数查看" v-if="permission('流量计参数查看')">
|
|
90
|
-
<meter-param :row="row" v-if="show == '流量计参数查看'" @deal-msg="dealMsg"></meter-param>
|
|
91
|
-
</saletab>
|
|
92
|
-
<saletab header="表使用量图表" v-if="permission('流量计参数查看')">
|
|
93
|
-
<table-usage-chart :row="row" v-if="show == '表使用量图表'" @deal-msg="dealMsg"></table-usage-chart>
|
|
94
|
-
</saletab>
|
|
95
|
-
<saletab header="用户设备查询" v-if="permission('用户设备查看')">
|
|
96
|
-
<user-device-query :row="row" v-if="show == '用户设备查询'" @deal-msg="dealMsg"></user-device-query>
|
|
97
|
-
</saletab>
|
|
98
|
-
<saletab header="合同查看" v-if="permission('合同查看')">
|
|
99
|
-
<contract-signing-list :row="row" v-if="show == '合同查看'" @deal-msg="dealMsg"></contract-signing-list>
|
|
100
|
-
</saletab>
|
|
101
|
-
<saletab header="用户重点记录" v-if="permission('用户重点记录')">
|
|
102
|
-
<user-key-record :row="row" @deal-msg="dealMsg"></user-key-record>
|
|
103
|
-
</saletab>
|
|
104
|
-
<saletab header="维修记录" v-if="permission('维修记录')">
|
|
105
|
-
<repair-list :row="row" @deal-msg="dealMsg"></repair-list>
|
|
106
|
-
</saletab>
|
|
107
|
-
<saletab header="安检记录" v-if="permission('安检记录')">
|
|
108
|
-
<security-check-info :row="row" @deal-msg="dealMsg"></security-check-info>
|
|
11
|
+
<saletab v-for="tab in tabConfigs" :header="tab.header" :key="$index">
|
|
12
|
+
<component
|
|
13
|
+
:is="tab.component"
|
|
14
|
+
:row="row"
|
|
15
|
+
v-if="!tab.needShowCheck || show == tab.header"
|
|
16
|
+
@deal-msg="dealMsg">
|
|
17
|
+
</component>
|
|
109
18
|
</saletab>
|
|
110
19
|
<!-- <saletab header="装表记录" v-if="permission('装表记录')">-->
|
|
111
20
|
<!-- <metering-records :row="row" @deal-msg="dealMsg"></metering-records>-->
|
|
@@ -142,13 +51,13 @@
|
|
|
142
51
|
import UserDeviceQuery from './ic_detail/UserDeviceQuery'
|
|
143
52
|
import contractSigningList from './ic_detail/contractSigningList'
|
|
144
53
|
import UserKeyRecord from './ic_detail/UserKeyRecord'
|
|
145
|
-
import RepairList from
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
54
|
+
import RepairList from './ic_detail/RepairList'
|
|
55
|
+
import SecurityCheckInfo from './ic_detail/SecuritycheckInfo'
|
|
56
|
+
// import MeteringRecords from './ic_detail/MeteringRecords'
|
|
57
|
+
// import SupervisoryControl from './apply_detail/Supervisory/SupervisoryControl'
|
|
58
|
+
// import ApplyChargeSearch from './apply_detail/applyCharge/ApplyChargeSearch'
|
|
59
|
+
// 导入物联网相关查询
|
|
60
|
+
import QueryInstruct from './iot_detail/QueryInstruct'
|
|
152
61
|
import QueryHistoryInstruct from './iot_detail/QueryHistoryInstruct'
|
|
153
62
|
import WatchCollection from './iot_detail/WatchCollection'
|
|
154
63
|
import WatchWarning from './iot_detail/WatchWarning'
|
|
@@ -198,6 +107,345 @@ export default {
|
|
|
198
107
|
// SupervisoryControl,
|
|
199
108
|
// ApplyChargeSearch
|
|
200
109
|
},
|
|
110
|
+
computed: {
|
|
111
|
+
// 标签配置数组
|
|
112
|
+
tabConfigs () {
|
|
113
|
+
if (!this.row) {
|
|
114
|
+
return []
|
|
115
|
+
}
|
|
116
|
+
const configs = []
|
|
117
|
+
// 流水查询
|
|
118
|
+
if (this.permission('流水查询')) {
|
|
119
|
+
configs.push({
|
|
120
|
+
header: '流水查询',
|
|
121
|
+
permission: '流水查询',
|
|
122
|
+
component: 'record-query-user',
|
|
123
|
+
condition: () => true,
|
|
124
|
+
needShowCheck: false // 流水查询不需要 show 检查
|
|
125
|
+
})
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
// 机表流水查询
|
|
129
|
+
if (this.permission('机表流水查询') && this.row.f_meter_type && this.row.f_meter_type.includes('机表')) {
|
|
130
|
+
configs.push({
|
|
131
|
+
header: '机表流水查询',
|
|
132
|
+
permission: '机表流水查询',
|
|
133
|
+
component: 'machine-record-query',
|
|
134
|
+
condition: () => this.row.f_meter_type && this.row.f_meter_type.includes('机表'),
|
|
135
|
+
needShowCheck: true
|
|
136
|
+
})
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
// 收费查询(根据 newWebHand 选择组件,但这里组件相同)
|
|
140
|
+
if (this.permission('收费查询')) {
|
|
141
|
+
configs.push({
|
|
142
|
+
header: '收费查询',
|
|
143
|
+
permission: '收费查询',
|
|
144
|
+
component: 'charge-query-user',
|
|
145
|
+
condition: () => true,
|
|
146
|
+
needShowCheck: true
|
|
147
|
+
})
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
// 累购查询
|
|
151
|
+
if (this.permission('累购查询')) {
|
|
152
|
+
configs.push({
|
|
153
|
+
header: '累购查询',
|
|
154
|
+
permission: '累购查询',
|
|
155
|
+
component: 'repurchase',
|
|
156
|
+
condition: () => true,
|
|
157
|
+
needShowCheck: true
|
|
158
|
+
})
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
// 下账查询(根据 newWebHand 选择不同组件)
|
|
162
|
+
if (this.row.f_meter_type && this.row.f_meter_type.includes('物联网表') && this.permission('自动下账查询')) {
|
|
163
|
+
configs.push({
|
|
164
|
+
header: '下账查询',
|
|
165
|
+
permission: '自动下账查询',
|
|
166
|
+
component: this.newWebHand ? 'web-automatic-purse' : 'automatic-purse',
|
|
167
|
+
condition: () => this.row.f_meter_type && this.row.f_meter_type.includes('物联网表'),
|
|
168
|
+
needShowCheck: false // 下账查询不需要 show 检查
|
|
169
|
+
})
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
// 抄表记录(根据 meter_type 和 newWebHand 选择不同组件)
|
|
173
|
+
if (this.permission('抄表记录')) {
|
|
174
|
+
if (this.row.f_meter_type && this.row.f_meter_type.includes('卡表')) {
|
|
175
|
+
configs.push({
|
|
176
|
+
header: '抄表记录',
|
|
177
|
+
permission: '抄表记录',
|
|
178
|
+
component: 'card-hand-record',
|
|
179
|
+
condition: () => this.row.f_meter_type && this.row.f_meter_type.includes('卡表'),
|
|
180
|
+
needShowCheck: true
|
|
181
|
+
})
|
|
182
|
+
} else {
|
|
183
|
+
configs.push({
|
|
184
|
+
header: '抄表记录',
|
|
185
|
+
permission: '抄表记录',
|
|
186
|
+
component: this.newWebHand ? 'web-hand-query-user' : 'hand-query-user',
|
|
187
|
+
condition: () => !this.row.f_meter_type || !this.row.f_meter_type.includes('卡表'),
|
|
188
|
+
needShowCheck: true
|
|
189
|
+
})
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
// 补卡查询
|
|
194
|
+
if (this.row.f_meter_type && this.row.f_meter_type.includes('卡表') && this.permission('补卡查询')) {
|
|
195
|
+
configs.push({
|
|
196
|
+
header: '补卡查询',
|
|
197
|
+
permission: '补卡查询',
|
|
198
|
+
component: 'fill-card-query-user',
|
|
199
|
+
condition: () => this.row.f_meter_type && this.row.f_meter_type.includes('卡表'),
|
|
200
|
+
needShowCheck: true
|
|
201
|
+
})
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
// 补气查询
|
|
205
|
+
if (this.permission('补气查询')) {
|
|
206
|
+
configs.push({
|
|
207
|
+
header: '补气查询',
|
|
208
|
+
permission: '补气查询',
|
|
209
|
+
component: 'fill-gas-query-user',
|
|
210
|
+
condition: () => true,
|
|
211
|
+
needShowCheck: true
|
|
212
|
+
})
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
// 换表查询
|
|
216
|
+
if (this.permission('换表查询')) {
|
|
217
|
+
configs.push({
|
|
218
|
+
header: '换表查询',
|
|
219
|
+
permission: '换表查询',
|
|
220
|
+
component: 'change-meter-query-user',
|
|
221
|
+
condition: () => true,
|
|
222
|
+
needShowCheck: true
|
|
223
|
+
})
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
// 其他收费
|
|
227
|
+
if (this.permission('其他收费')) {
|
|
228
|
+
configs.push({
|
|
229
|
+
header: '其他收费',
|
|
230
|
+
permission: '其他收费',
|
|
231
|
+
component: 'other-charge-query-user',
|
|
232
|
+
condition: () => true,
|
|
233
|
+
needShowCheck: true
|
|
234
|
+
})
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
// 保险收费记录
|
|
238
|
+
if (this.permission('保险收费记录')) {
|
|
239
|
+
configs.push({
|
|
240
|
+
header: '保险收费记录',
|
|
241
|
+
permission: '保险收费记录',
|
|
242
|
+
component: 'insurance-charges-record',
|
|
243
|
+
condition: () => true,
|
|
244
|
+
needShowCheck: false
|
|
245
|
+
})
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
// 垃圾费收费记录
|
|
249
|
+
if (this.permission('垃圾费收费记录')) {
|
|
250
|
+
configs.push({
|
|
251
|
+
header: '垃圾费收费记录',
|
|
252
|
+
permission: '垃圾费收费记录',
|
|
253
|
+
component: 'garbage-record-list',
|
|
254
|
+
condition: () => true,
|
|
255
|
+
needShowCheck: false
|
|
256
|
+
})
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
// 过户查询
|
|
260
|
+
if (this.permission('过户查询')) {
|
|
261
|
+
configs.push({
|
|
262
|
+
header: '过户查询',
|
|
263
|
+
permission: '过户查询',
|
|
264
|
+
component: 'transfer-query-user',
|
|
265
|
+
condition: () => true,
|
|
266
|
+
needShowCheck: true
|
|
267
|
+
})
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
// 价格调整
|
|
271
|
+
if (this.permission('价格调整')) {
|
|
272
|
+
configs.push({
|
|
273
|
+
header: '价格调整',
|
|
274
|
+
permission: '价格调整',
|
|
275
|
+
component: 'price-change-query-user',
|
|
276
|
+
condition: () => true,
|
|
277
|
+
needShowCheck: true
|
|
278
|
+
})
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
// 附件查看
|
|
282
|
+
if (this.permission('附件查看')) {
|
|
283
|
+
configs.push({
|
|
284
|
+
header: '附件查看',
|
|
285
|
+
permission: '附件查看',
|
|
286
|
+
component: 'upload-file-history',
|
|
287
|
+
condition: () => true,
|
|
288
|
+
needShowCheck: true
|
|
289
|
+
})
|
|
290
|
+
}
|
|
291
|
+
|
|
292
|
+
// 变更记录
|
|
293
|
+
if (this.permission('变更记录')) {
|
|
294
|
+
configs.push({
|
|
295
|
+
header: '变更记录',
|
|
296
|
+
permission: '变更记录',
|
|
297
|
+
component: 'change-record',
|
|
298
|
+
condition: () => true,
|
|
299
|
+
needShowCheck: true
|
|
300
|
+
})
|
|
301
|
+
}
|
|
302
|
+
|
|
303
|
+
// 指令查看
|
|
304
|
+
if (this.row.f_meter_type && this.row.f_meter_type.includes('物联网表') && this.permission('指令查看')) {
|
|
305
|
+
configs.push({
|
|
306
|
+
header: '指令查看',
|
|
307
|
+
permission: '指令查看',
|
|
308
|
+
component: 'query-instruct',
|
|
309
|
+
condition: () => this.row.f_meter_type && this.row.f_meter_type.includes('物联网表'),
|
|
310
|
+
needShowCheck: true
|
|
311
|
+
})
|
|
312
|
+
}
|
|
313
|
+
|
|
314
|
+
// 历史指令查看
|
|
315
|
+
if (this.row.f_meter_type && this.row.f_meter_type.includes('物联网表') && this.permission('历史指令查看')) {
|
|
316
|
+
configs.push({
|
|
317
|
+
header: '历史指令查看',
|
|
318
|
+
permission: '历史指令查看',
|
|
319
|
+
component: 'query-history-instruct',
|
|
320
|
+
condition: () => this.row.f_meter_type && this.row.f_meter_type.includes('物联网表'),
|
|
321
|
+
needShowCheck: true
|
|
322
|
+
})
|
|
323
|
+
}
|
|
324
|
+
|
|
325
|
+
// 异常报警
|
|
326
|
+
if (this.row.f_meter_type && this.row.f_meter_type.includes('物联网表') && this.permission('异常报警')) {
|
|
327
|
+
configs.push({
|
|
328
|
+
header: '异常报警',
|
|
329
|
+
permission: '异常报警',
|
|
330
|
+
component: 'watch-warning',
|
|
331
|
+
condition: () => this.row.f_meter_type && this.row.f_meter_type.includes('物联网表'),
|
|
332
|
+
needShowCheck: true
|
|
333
|
+
})
|
|
334
|
+
}
|
|
335
|
+
|
|
336
|
+
// 表具采集
|
|
337
|
+
if (this.row.f_meter_type && this.row.f_meter_type.includes('物联网表') && this.permission('表具采集')) {
|
|
338
|
+
configs.push({
|
|
339
|
+
header: '表具采集',
|
|
340
|
+
permission: '表具采集',
|
|
341
|
+
component: 'watch-collection',
|
|
342
|
+
condition: () => this.row.f_meter_type && this.row.f_meter_type.includes('物联网表'),
|
|
343
|
+
needShowCheck: true
|
|
344
|
+
})
|
|
345
|
+
}
|
|
346
|
+
|
|
347
|
+
// 调价补差
|
|
348
|
+
if (this.permission('调价补差')) {
|
|
349
|
+
configs.push({
|
|
350
|
+
header: '调价补差',
|
|
351
|
+
permission: '调价补差',
|
|
352
|
+
component: 'price-adjustment-query-user',
|
|
353
|
+
condition: () => true,
|
|
354
|
+
needShowCheck: true
|
|
355
|
+
})
|
|
356
|
+
}
|
|
357
|
+
|
|
358
|
+
// 设备查询
|
|
359
|
+
if (this.permission('设备查询')) {
|
|
360
|
+
configs.push({
|
|
361
|
+
header: '设备查询',
|
|
362
|
+
permission: '设备查询',
|
|
363
|
+
component: 'deveice-record',
|
|
364
|
+
condition: () => true,
|
|
365
|
+
needShowCheck: true
|
|
366
|
+
})
|
|
367
|
+
}
|
|
368
|
+
|
|
369
|
+
// 流量计参数查看
|
|
370
|
+
if (this.permission('流量计参数查看')) {
|
|
371
|
+
configs.push({
|
|
372
|
+
header: '流量计参数查看',
|
|
373
|
+
permission: '流量计参数查看',
|
|
374
|
+
component: 'meter-param',
|
|
375
|
+
condition: () => true,
|
|
376
|
+
needShowCheck: true
|
|
377
|
+
})
|
|
378
|
+
}
|
|
379
|
+
|
|
380
|
+
// 表使用量图表
|
|
381
|
+
if (this.permission('流量计参数查看')) {
|
|
382
|
+
configs.push({
|
|
383
|
+
header: '表使用量图表',
|
|
384
|
+
permission: '流量计参数查看',
|
|
385
|
+
component: 'table-usage-chart',
|
|
386
|
+
condition: () => true,
|
|
387
|
+
needShowCheck: true
|
|
388
|
+
})
|
|
389
|
+
}
|
|
390
|
+
|
|
391
|
+
// 用户设备查询
|
|
392
|
+
if (this.permission('用户设备查看')) {
|
|
393
|
+
configs.push({
|
|
394
|
+
header: '用户设备查询',
|
|
395
|
+
permission: '用户设备查看',
|
|
396
|
+
component: 'user-device-query',
|
|
397
|
+
condition: () => true,
|
|
398
|
+
needShowCheck: true
|
|
399
|
+
})
|
|
400
|
+
}
|
|
401
|
+
|
|
402
|
+
// 合同查看
|
|
403
|
+
if (this.permission('合同查看')) {
|
|
404
|
+
configs.push({
|
|
405
|
+
header: '合同查看',
|
|
406
|
+
permission: '合同查看',
|
|
407
|
+
component: 'contract-signing-list',
|
|
408
|
+
condition: () => true,
|
|
409
|
+
needShowCheck: true
|
|
410
|
+
})
|
|
411
|
+
}
|
|
412
|
+
|
|
413
|
+
// 用户重点记录
|
|
414
|
+
if (this.permission('用户重点记录')) {
|
|
415
|
+
configs.push({
|
|
416
|
+
header: '用户重点记录',
|
|
417
|
+
permission: '用户重点记录',
|
|
418
|
+
component: 'user-key-record',
|
|
419
|
+
condition: () => true,
|
|
420
|
+
needShowCheck: false
|
|
421
|
+
})
|
|
422
|
+
}
|
|
423
|
+
|
|
424
|
+
// 维修记录
|
|
425
|
+
if (this.permission('维修记录')) {
|
|
426
|
+
configs.push({
|
|
427
|
+
header: '维修记录',
|
|
428
|
+
permission: '维修记录',
|
|
429
|
+
component: 'repair-list',
|
|
430
|
+
condition: () => true,
|
|
431
|
+
needShowCheck: false
|
|
432
|
+
})
|
|
433
|
+
}
|
|
434
|
+
|
|
435
|
+
// 安检记录
|
|
436
|
+
if (this.permission('安检记录')) {
|
|
437
|
+
configs.push({
|
|
438
|
+
header: '安检记录',
|
|
439
|
+
permission: '安检记录',
|
|
440
|
+
component: 'security-check-info',
|
|
441
|
+
condition: () => true,
|
|
442
|
+
needShowCheck: false
|
|
443
|
+
})
|
|
444
|
+
}
|
|
445
|
+
|
|
446
|
+
return configs
|
|
447
|
+
}
|
|
448
|
+
},
|
|
201
449
|
data () {
|
|
202
450
|
return {
|
|
203
451
|
row: null,
|
|
@@ -206,18 +454,13 @@ export default {
|
|
|
206
454
|
show: ''
|
|
207
455
|
}
|
|
208
456
|
},
|
|
209
|
-
ready () {
|
|
210
|
-
this.search()
|
|
457
|
+
async ready () {
|
|
458
|
+
await this.search()
|
|
211
459
|
console.log(this.$login)
|
|
212
460
|
},
|
|
213
461
|
methods: {
|
|
214
462
|
permission (name) {
|
|
215
|
-
|
|
216
|
-
if (!this.$login.r.find(value => value == name)) {
|
|
217
|
-
return false
|
|
218
|
-
}
|
|
219
|
-
}
|
|
220
|
-
return true
|
|
463
|
+
return this.$login.r.includes(name)
|
|
221
464
|
},
|
|
222
465
|
async search () {
|
|
223
466
|
let http = new HttpResetClass()
|
|
@@ -235,6 +478,10 @@ export default {
|
|
|
235
478
|
}, {resolveMsg: null, rejectMsg: '获取基本信息出错'})
|
|
236
479
|
this.row = getBaseInfo.data
|
|
237
480
|
this.row.parentname = this.parentname || ''
|
|
481
|
+
// 数据加载完成后,初始化第一个可见标签
|
|
482
|
+
this.$nextTick(() => {
|
|
483
|
+
this.initFirstVisibleTab()
|
|
484
|
+
})
|
|
238
485
|
},
|
|
239
486
|
|
|
240
487
|
cancel (val) {
|
|
@@ -248,6 +495,35 @@ export default {
|
|
|
248
495
|
|
|
249
496
|
butOper (val) {
|
|
250
497
|
this.name = val
|
|
498
|
+
},
|
|
499
|
+
|
|
500
|
+
dealMsg (msg) {
|
|
501
|
+
// 处理消息
|
|
502
|
+
},
|
|
503
|
+
|
|
504
|
+
// 获取组件渲染配置
|
|
505
|
+
getComponentConfig (tab) {
|
|
506
|
+
// 返回组件名和是否需要 show 检查
|
|
507
|
+
return {
|
|
508
|
+
name: tab.component,
|
|
509
|
+
needShow: tab.needShowCheck
|
|
510
|
+
}
|
|
511
|
+
},
|
|
512
|
+
|
|
513
|
+
// 初始化第一个可见的标签
|
|
514
|
+
initFirstVisibleTab () {
|
|
515
|
+
// 确保 row 数据存在,因为很多标签的显示依赖于 row
|
|
516
|
+
if (!this.row) {
|
|
517
|
+
return
|
|
518
|
+
}
|
|
519
|
+
// 如果已经有值且不为空,说明已经初始化过了,不需要再次初始化
|
|
520
|
+
if (this.show) {
|
|
521
|
+
return
|
|
522
|
+
}
|
|
523
|
+
// 使用 tabConfigs 找到第一个可见的标签
|
|
524
|
+
if (this.tabConfigs && this.tabConfigs.length > 0) {
|
|
525
|
+
this.show = this.tabConfigs[0].header
|
|
526
|
+
}
|
|
251
527
|
}
|
|
252
528
|
},
|
|
253
529
|
watch: {
|