apply-clients 3.5.6-21 → 3.5.6-22
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/build/dev-server.js +5 -5
- package/package.json +1 -1
- package/src/components/android/Process/AppServiceControl.vue +1760 -1760
- package/src/components/product/Function/Service/FunctionServiceControl.vue +497 -497
- package/src/components/product/Install/ContractCharge.vue +210 -210
- package/src/filiale/dingcheng/android/AppInstallationDetails.vue +477 -477
- package/src/filiale/dingcheng/pc/InstallationDetails.vue +607 -607
- package/src/filiale/fugou/android/AppAddMaterialScience.vue +444 -444
- package/src/filiale/fugou/android/AppAddReplacement.vue +512 -512
- package/src/filiale/fugou/android/AppDevicesManagement.vue +516 -516
- package/src/filiale/fugou/android/AppInstallationDetails.vue +541 -541
- package/src/filiale/fugou/android/AppZhihuanManagement.vue +242 -242
- package/src/filiale/fugou/pc/AddReplacement.vue +511 -511
- package/src/filiale/fugou/pc/ApplyChargeList.vue +554 -554
- package/src/filiale/fugou/pc/Applybatchdispatch.vue +754 -754
- package/src/filiale/fugou/pc/InstallationDetails.vue +646 -646
- package/src/filiale/fugou/pc/ServiceControl.vue +1741 -1741
- package/src/filiale/fugou/pc/addMaterialScience.vue +481 -481
- package/src/filiale/fugou/pc.js +19 -19
- package/src/filiale/gongyi/pc/addressAndUserinfoManagement.vue +187 -187
- package/src/filiale/gongyi/pc/chargeManagement.vue +765 -765
- package/src/filiale/gongyi/pc.js +25 -25
- package/src/filiale/hongda/pc/addMaterialScience.vue +723 -723
- package/src/filiale/jinhuang/android/AppAddMaterialScience.vue +635 -635
- package/src/filiale/jinhuang/android/AppServiceControl.vue +1842 -1842
- package/src/filiale/jinhuang/android.js +7 -7
- package/src/filiale/jinhuang/pc/Applybatchdispatch.vue +770 -770
- package/src/filiale/jinhuang/pc/ContractList.vue +222 -222
- package/src/filiale/jinhuang/pc/ExplorationSelect.vue +511 -511
- package/src/filiale/jinhuang/pc/ServiceControl.vue +2016 -2016
- package/src/filiale/jinhuang/pc/SupervisoryList.vue +478 -478
- package/src/filiale/jinhuang/pc/addMaterialScience.vue +638 -638
- package/src/filiale/jinhuang/pc.js +13 -13
- package/src/filiale/qianneng/pc/Applybatchdispatch.vue +786 -786
- package/src/filiale/qianneng/pc/ServiceControl.vue +1387 -1387
- package/src/filiale/ruihua/pc/ServiceControl.vue +1973 -1973
- package/src/filiale/shexian/android/AppServiceControl.vue +1786 -1786
- package/src/filiale/shexian/android/AppSign.vue +152 -152
- package/src/filiale/yangchunboneng/android/AppChargeManagement.vue +527 -527
- package/src/filiale/yangchunboneng/android/AppContractCharge.vue +222 -222
- package/src/filiale/yangchunboneng/android/AppInstallationMaterial.vue +1144 -1144
- package/src/filiale/yangchunboneng/android/AppOtherChargeList.vue +281 -281
- package/src/filiale/yangchunboneng/android/AppServiceControl.vue +1883 -1883
- package/src/filiale/yangchunboneng/android.js +22 -22
- package/src/filiale/yangchunboneng/pc/ApplyUpload.vue +392 -392
- package/src/filiale/yangchunboneng/pc/ExplorationSelect.vue +622 -622
- package/src/filiale/yangchunboneng/pc/InstallInfoSelect.vue +400 -400
- package/src/filiale/yangchunboneng/pc/ServiceControl.vue +2118 -2118
- package/src/filiale/yangchunboneng/pc/SupervisoryControl.vue +141 -141
- package/src/filiale/yangchunboneng/pc/SupervisoryList.vue +652 -644
- package/src/filiale/yangchunboneng/pc/buildOrderList.vue +421 -421
- package/src/filiale/yangchunboneng/pc/chargeManagement.vue +1060 -1060
- package/src/filiale/yangchunboneng/pc/printBuildOrder.vue +175 -175
- package/src/filiale/yangchunboneng/pc.js +29 -29
- package/src/main.js +3 -3
|
@@ -1,1387 +1,1387 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="" v-if="showview">
|
|
3
|
-
<show-back-reason :selectdata="show_data"></show-back-reason>
|
|
4
|
-
<service-view v-ref:serviceview :data="show_data"></service-view>
|
|
5
|
-
</div>
|
|
6
|
-
</template>
|
|
7
|
-
<script>
|
|
8
|
-
import Vue from 'vue'
|
|
9
|
-
import {HttpResetClass} from 'vue-client'
|
|
10
|
-
import {isEmpty} from "../../../components/Util";
|
|
11
|
-
|
|
12
|
-
// Date格式化
|
|
13
|
-
Date.prototype.Format = function (fmt) {
|
|
14
|
-
var o = {
|
|
15
|
-
"M+": this.getMonth() + 1, //月份
|
|
16
|
-
"d+": this.getDate(), //日
|
|
17
|
-
"H+": this.getHours(), //小时
|
|
18
|
-
"m+": this.getMinutes(), //分
|
|
19
|
-
"s+": this.getSeconds(), //秒
|
|
20
|
-
"q+": Math.floor((this.getMonth() + 3) / 3), //季度
|
|
21
|
-
"S": this.getMilliseconds() //毫秒
|
|
22
|
-
};
|
|
23
|
-
if (/(y+)/.test(fmt)) fmt = fmt.replace(RegExp.$1, (this.getFullYear() + "").substr(4 - RegExp.$1.length));
|
|
24
|
-
for (var k in o)
|
|
25
|
-
if (new RegExp("(" + k + ")").test(fmt)) fmt = fmt.replace(RegExp.$1, (RegExp.$1.length == 1) ? (o[k]) : (("00" + o[k]).substr(("" + o[k]).length)));
|
|
26
|
-
return fmt;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
export default {
|
|
30
|
-
title: '报建流程业务控制层',
|
|
31
|
-
props: ['selectdata'],
|
|
32
|
-
data () {
|
|
33
|
-
return {
|
|
34
|
-
data: null, // 数据库数据,json配置文件数据的数据集合
|
|
35
|
-
json_datas: null, // Json配置文件集合
|
|
36
|
-
showview: false, // 控制显示service-view组件
|
|
37
|
-
show_data: null, // 给view层显示的数据
|
|
38
|
-
config: {},
|
|
39
|
-
Pricetype:''
|
|
40
|
-
}
|
|
41
|
-
},
|
|
42
|
-
ready () {
|
|
43
|
-
this.refurbish()
|
|
44
|
-
},
|
|
45
|
-
methods: {
|
|
46
|
-
//将千分位金额转换为数字
|
|
47
|
-
parseCurrency(str) {
|
|
48
|
-
if(typeof str == 'string'){
|
|
49
|
-
return parseFloat(str.replace(/,/g, ''))
|
|
50
|
-
}
|
|
51
|
-
// 用正则表达式移除千分位分隔符,并转换为数字
|
|
52
|
-
return str
|
|
53
|
-
},
|
|
54
|
-
//将金额转换为千分位
|
|
55
|
-
formatCurrency(number, decimalPlaces) {
|
|
56
|
-
var num = parseFloat(number);
|
|
57
|
-
if (!isNaN(num)) {
|
|
58
|
-
num = num.toFixed(decimalPlaces || 0); // 将金额保留指定位数,四舍五入
|
|
59
|
-
num = num.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ","); // 按照千分位进行分隔
|
|
60
|
-
return num;
|
|
61
|
-
} else {
|
|
62
|
-
return ''; // 如果输入框中的值不是数字,则返回空字符串
|
|
63
|
-
}
|
|
64
|
-
},
|
|
65
|
-
// 组件初始化操作
|
|
66
|
-
async refurbish() {
|
|
67
|
-
this.json_datas = this.$workflow_vue
|
|
68
|
-
let sum = 0
|
|
69
|
-
let jsonData = {}
|
|
70
|
-
if (!this.json_datas || !this.json_datas.activitys || this.json_datas.activitys.length === 0) {
|
|
71
|
-
this.$showMessage("网络故障,请刷新页面")
|
|
72
|
-
return
|
|
73
|
-
}
|
|
74
|
-
this.json_datas.activitys.forEach(item => {
|
|
75
|
-
if (this.selectdata.defname === item.title) {
|
|
76
|
-
jsonData = item // 拿到当前节点的json配置信息
|
|
77
|
-
sum++ // 节点名一样的个数
|
|
78
|
-
}
|
|
79
|
-
return this.selectdata.defname === item.title // 拿到当前节点的json配置信息
|
|
80
|
-
})
|
|
81
|
-
|
|
82
|
-
if (sum === 0) {
|
|
83
|
-
this.$showMessage(`没有在JSON配置文件中找到活动名为:(${this.selectdata.defname})的节点配置`)
|
|
84
|
-
return
|
|
85
|
-
}
|
|
86
|
-
if (sum > 1) {
|
|
87
|
-
this.$showMessage(`在JSON配置文件中找到活动名为:(${this.selectdata.defname})的节点配置:${sum}个`)
|
|
88
|
-
return
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
this.selectdata = Object.assign({}, this.selectdata, jsonData)
|
|
92
|
-
|
|
93
|
-
// fields 字段填充值
|
|
94
|
-
for (const item of this.selectdata.fields) {
|
|
95
|
-
if (!item.value) {
|
|
96
|
-
item.value = null
|
|
97
|
-
}
|
|
98
|
-
// 如果配置类型为select,优先从参数列表获取options
|
|
99
|
-
if (item.type === 'select' || item.type === 'checkbox') {
|
|
100
|
-
if (item.param) {
|
|
101
|
-
let temp = this.$appdata.getParam(item.label)
|
|
102
|
-
|
|
103
|
-
if (temp && temp.length > 0) {
|
|
104
|
-
item.options = temp
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
if (item.paramLabel) {
|
|
108
|
-
temp = this.$appdata.getParam(item.paramLabel)
|
|
109
|
-
if (temp && temp.length > 0) {
|
|
110
|
-
item.options = temp
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
if (item.ready) {
|
|
116
|
-
console.log(item.ready)
|
|
117
|
-
item.options = await this[item.ready]()
|
|
118
|
-
|
|
119
|
-
}
|
|
120
|
-
if (!isEmpty(item.role)){
|
|
121
|
-
console.log('获取对应角色的人员信息',item.role)
|
|
122
|
-
item.options = await this.getDesignerPeople(item.role)
|
|
123
|
-
}
|
|
124
|
-
if (item.multiple && !isEmpty(this.selectdata[item.field])){
|
|
125
|
-
this.selectdata[item.field] = JSON.parse(this.selectdata[item.field])
|
|
126
|
-
}
|
|
127
|
-
}
|
|
128
|
-
if (!item.value && (item.default || item.default === 0) && item.type !== 'datepicker') {
|
|
129
|
-
if (item.eval) {
|
|
130
|
-
item.value = eval(item.default)
|
|
131
|
-
} else {
|
|
132
|
-
item.value = item.default
|
|
133
|
-
}
|
|
134
|
-
}
|
|
135
|
-
|
|
136
|
-
if (this.selectdata[item.field]) {
|
|
137
|
-
// 将json字符串格式化赋值给value
|
|
138
|
-
if (String(this.selectdata[item.field]).startsWith("{")) {
|
|
139
|
-
item.value = JSON.parse(this.selectdata[item.field])
|
|
140
|
-
} else {
|
|
141
|
-
item.value = this.selectdata[item.field]
|
|
142
|
-
}
|
|
143
|
-
}
|
|
144
|
-
if (this.selectdata[item.field] === 0) {
|
|
145
|
-
item.value = 0
|
|
146
|
-
}
|
|
147
|
-
|
|
148
|
-
// datepicker
|
|
149
|
-
if (item.type === 'datepicker' && !item.value && item.default) {
|
|
150
|
-
item.value = new Date().Format(`${item.format ? item.format : 'yyyy-MM-dd HH:mm:ss'}`)
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
if (item.type === 'checkbox') {
|
|
154
|
-
if (this.selectdata[item.field]) {
|
|
155
|
-
item.value = JSON.parse(this.selectdata[item.field])
|
|
156
|
-
} else {
|
|
157
|
-
item.value = []
|
|
158
|
-
}
|
|
159
|
-
}
|
|
160
|
-
//金额千分位
|
|
161
|
-
if (item.percentiles) {
|
|
162
|
-
let amount = item.value
|
|
163
|
-
if (amount > 0) {
|
|
164
|
-
let amounts = this.formatCurrency(amount, 2)
|
|
165
|
-
console.log('金额千分位', amounts)
|
|
166
|
-
item.value = amounts
|
|
167
|
-
console.log('金额千分位1', item.value)
|
|
168
|
-
}
|
|
169
|
-
}
|
|
170
|
-
this.selectdata[item.field] = item.value
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
// 控制组件
|
|
174
|
-
if (this.selectdata.components) {
|
|
175
|
-
this.selectdata.components.forEach(item => {
|
|
176
|
-
if (!item.mark) {
|
|
177
|
-
item.mark = 0
|
|
178
|
-
}
|
|
179
|
-
})
|
|
180
|
-
}
|
|
181
|
-
// 初始化onetomany
|
|
182
|
-
if (this.selectdata.onetomany) {
|
|
183
|
-
for (const item of this.selectdata.onetomany) {
|
|
184
|
-
let res = null
|
|
185
|
-
if (item.queryEvent) {
|
|
186
|
-
res = this[item.queryEvent]()
|
|
187
|
-
} else {
|
|
188
|
-
let data = {
|
|
189
|
-
tablename: item.tables[0],
|
|
190
|
-
condition: `f_process_id='${this.selectdata.f_process_id}'`
|
|
191
|
-
}
|
|
192
|
-
res = await this.$resetpost(
|
|
193
|
-
'rs/sql/apply_singleTable',
|
|
194
|
-
{data: data},
|
|
195
|
-
{resolveMsg: null, rejectMsg: 'onetomany查询失败'}
|
|
196
|
-
)
|
|
197
|
-
}
|
|
198
|
-
|
|
199
|
-
item.rows = res.data
|
|
200
|
-
|
|
201
|
-
// 初始化onetomany中的fields
|
|
202
|
-
for (const field of item.fields) {
|
|
203
|
-
if (!field.value) {
|
|
204
|
-
if (field.value !== 0) {
|
|
205
|
-
field.value = null
|
|
206
|
-
}
|
|
207
|
-
}
|
|
208
|
-
|
|
209
|
-
if (field.default || field.default === 0) {
|
|
210
|
-
field.value = field.default
|
|
211
|
-
}
|
|
212
|
-
|
|
213
|
-
// datepicker
|
|
214
|
-
if (field.type === 'datepicker' && !field.value && field.default) {
|
|
215
|
-
field.value = new Date().Format(`${field.format ? field.format : 'yyyy-MM-dd HH:mm:ss'}`)
|
|
216
|
-
}
|
|
217
|
-
|
|
218
|
-
if (field.type === 'select') {
|
|
219
|
-
|
|
220
|
-
let temp = this.$appdata.getParam(field.label)
|
|
221
|
-
|
|
222
|
-
if (temp && temp.length > 0) {
|
|
223
|
-
field.options = temp
|
|
224
|
-
}
|
|
225
|
-
|
|
226
|
-
if (field.paramLabel) {
|
|
227
|
-
temp = this.$appdata.getParam(field.paramLabel)
|
|
228
|
-
if (temp && temp.length > 0) {
|
|
229
|
-
item.options = temp
|
|
230
|
-
}
|
|
231
|
-
}
|
|
232
|
-
}
|
|
233
|
-
}
|
|
234
|
-
}
|
|
235
|
-
}
|
|
236
|
-
// 初始化 buttons_fields
|
|
237
|
-
for (const item of this.selectdata.buttons) {
|
|
238
|
-
if (item.button_name === '下发') {
|
|
239
|
-
|
|
240
|
-
let data = {
|
|
241
|
-
source: item.source,
|
|
242
|
-
userid: this.$login.f.id
|
|
243
|
-
}
|
|
244
|
-
if (item.sourceMethod) {
|
|
245
|
-
data.source = this[item.sourceMethod]()
|
|
246
|
-
}
|
|
247
|
-
if (!data.source) {
|
|
248
|
-
this.$showMessage("请配置获取人员表达式")
|
|
249
|
-
return
|
|
250
|
-
}
|
|
251
|
-
|
|
252
|
-
let res = await this.$resetpost(
|
|
253
|
-
'rs/search',
|
|
254
|
-
{data: data},
|
|
255
|
-
{resolveMsg: null, rejectMsg: '下发人员查询失败!!!'}
|
|
256
|
-
)
|
|
257
|
-
|
|
258
|
-
let options = res.data.map(source => {
|
|
259
|
-
return {
|
|
260
|
-
"label": source.name,
|
|
261
|
-
"value": source.id
|
|
262
|
-
}
|
|
263
|
-
}).sort((a,b)=>a.label.localeCompare(b.label, 'zh-Hans-CN'))
|
|
264
|
-
if (item.button_fields.length !== 1) {
|
|
265
|
-
this.$showMessage("下发有且只能有一个字段!!!")
|
|
266
|
-
return
|
|
267
|
-
}
|
|
268
|
-
item.button_fields[0].options = options
|
|
269
|
-
}
|
|
270
|
-
if (item.button_fields) {
|
|
271
|
-
item.button_fields.forEach(x => {
|
|
272
|
-
// 如果配置类型为select,优先从参数列表获取options
|
|
273
|
-
if (x.type === 'select') {
|
|
274
|
-
|
|
275
|
-
if (x.param) {
|
|
276
|
-
let temp = this.$appdata.getParam(x.label)
|
|
277
|
-
|
|
278
|
-
if (temp && temp.length > 0) {
|
|
279
|
-
x.options = temp
|
|
280
|
-
}
|
|
281
|
-
|
|
282
|
-
if (x.paramLabel) {
|
|
283
|
-
temp = this.$appdata.getParam(x.paramLabel)
|
|
284
|
-
if (temp && temp.length > 0) {
|
|
285
|
-
x.options = temp
|
|
286
|
-
}
|
|
287
|
-
}
|
|
288
|
-
}
|
|
289
|
-
|
|
290
|
-
}
|
|
291
|
-
})
|
|
292
|
-
}
|
|
293
|
-
}
|
|
294
|
-
// 消除双向绑定,避免子组件(显示层)数据更改,父组件(控制层)也更改
|
|
295
|
-
let temp = JSON.parse(JSON.stringify(this.selectdata))
|
|
296
|
-
console.log('打印下temp',temp)
|
|
297
|
-
this.show_data = temp
|
|
298
|
-
for (const item of this.show_data.fields) {
|
|
299
|
-
if(item.label=='气价名称' && !isEmpty(this.show_data.f_price_name)){
|
|
300
|
-
if(item.label==='气价名称'){
|
|
301
|
-
item.value=this.show_data.f_price_name
|
|
302
|
-
}
|
|
303
|
-
}
|
|
304
|
-
if (this.show_data.f_apply_source === '线下发起' && (item.label === '预约地址' || item.label === '预约单号')) {
|
|
305
|
-
item.hidden = true
|
|
306
|
-
}
|
|
307
|
-
}
|
|
308
|
-
if (this.show_data.f_apply_type == '居民团体用户报建' ){
|
|
309
|
-
if (this.show_data.f_apply_nature == '整体小区'){
|
|
310
|
-
this.showLabels('楼房总户数')
|
|
311
|
-
this.showLabels('楼房总栋数')
|
|
312
|
-
this.showLabels('别墅总户数')
|
|
313
|
-
this.hideLabels('总户数')
|
|
314
|
-
}
|
|
315
|
-
if (this.show_data.f_apply_nature == '整体村庄'){
|
|
316
|
-
this.showLabels('总户数')
|
|
317
|
-
this.hideLabels('楼房总户数')
|
|
318
|
-
this.hideLabels('楼房总栋数')
|
|
319
|
-
this.hideLabels('别墅总户数')
|
|
320
|
-
}
|
|
321
|
-
}
|
|
322
|
-
if (this.show_data.defname == '市场部审核' || this.show_data.defname == '财务审核'){
|
|
323
|
-
let f_due_money = this.parseCurrency(this.show_data.f_due_money)
|
|
324
|
-
let f_cumulative_payment_money = this.parseCurrency(this.show_data.f_due_money)
|
|
325
|
-
let f_surplus_money = this.parseCurrency(this.show_data.f_surplus_money)
|
|
326
|
-
if (Number(f_due_money) > Number(f_cumulative_payment_money) || Number(f_surplus_money) > 0) {
|
|
327
|
-
this.$showAlert('费用未结清!!!', 'warning', 3000)
|
|
328
|
-
}
|
|
329
|
-
}
|
|
330
|
-
this.$nextTick(() => {
|
|
331
|
-
this.showview = true
|
|
332
|
-
})
|
|
333
|
-
},
|
|
334
|
-
// 金额转大写
|
|
335
|
-
smalltoBIG(n) {
|
|
336
|
-
let fraction = ['角', '分'];
|
|
337
|
-
let digit = ['零', '壹', '贰', '叁', '肆', '伍', '陆', '柒', '捌', '玖'];
|
|
338
|
-
let unit = [['元', '万', '亿'], ['', '拾', '佰', '仟']];
|
|
339
|
-
let head = n < 0 ? '欠' : '';
|
|
340
|
-
n = Math.abs(n);
|
|
341
|
-
|
|
342
|
-
let s = '';
|
|
343
|
-
|
|
344
|
-
for (var i = 0; i < fraction.length; i++) {
|
|
345
|
-
s += (digit[Math.floor(n * 10 * Math.pow(10, i)) % 10] + fraction[i]).replace(/零./, '');
|
|
346
|
-
}
|
|
347
|
-
s = s || '整';
|
|
348
|
-
n = Math.floor(n);
|
|
349
|
-
|
|
350
|
-
for (var i = 0; i < unit[0].length && n > 0; i++) {
|
|
351
|
-
let p = '';
|
|
352
|
-
for (var j = 0; j < unit[1].length && n > 0; j++) {
|
|
353
|
-
p = digit[n % 10] + unit[1][j] + p;
|
|
354
|
-
n = Math.floor(n / 10);
|
|
355
|
-
}
|
|
356
|
-
s = p.replace(/(零.)*零$/, '').replace(/^$/, '零') + unit[0][i] + s;
|
|
357
|
-
}
|
|
358
|
-
return head + s.replace(/(零.)*零元/, '元').replace(/(零.)+/g, '零').replace(/^整$/, '零元整')
|
|
359
|
-
},
|
|
360
|
-
// 获取对应label的值
|
|
361
|
-
getLableValue(label) {
|
|
362
|
-
for (const item of this.show_data.fields) {
|
|
363
|
-
if (item.label === label && item.type !== 'number') {
|
|
364
|
-
return item.value || ''
|
|
365
|
-
}
|
|
366
|
-
if (item.label === label && item.type === 'number') {
|
|
367
|
-
return item.value || 0
|
|
368
|
-
}
|
|
369
|
-
}
|
|
370
|
-
},
|
|
371
|
-
// 获取对应label中options的值
|
|
372
|
-
getLableOptions(label) {
|
|
373
|
-
for (const item of this.show_data.fields) {
|
|
374
|
-
if (item.label === label) {
|
|
375
|
-
return item.options
|
|
376
|
-
}
|
|
377
|
-
}
|
|
378
|
-
},
|
|
379
|
-
// 给对应label放置value值
|
|
380
|
-
setLabelValue(label, value) {
|
|
381
|
-
for (const item of this.show_data.fields) {
|
|
382
|
-
if (item.label === label) {
|
|
383
|
-
item.value = value
|
|
384
|
-
this.show_data[item.field] = value
|
|
385
|
-
}
|
|
386
|
-
}
|
|
387
|
-
},
|
|
388
|
-
// 给对应label的options放置value值
|
|
389
|
-
setLabelOptions(label, options) {
|
|
390
|
-
for (const item of this.show_data.fields) {
|
|
391
|
-
if (item.label === label) {
|
|
392
|
-
item.options = options
|
|
393
|
-
}
|
|
394
|
-
}
|
|
395
|
-
},
|
|
396
|
-
// 显示包含labels的文本
|
|
397
|
-
showLabels(...labels) {
|
|
398
|
-
for (const item of this.show_data.fields) {
|
|
399
|
-
if (labels.includes(item.label)) {
|
|
400
|
-
item.hidden = false
|
|
401
|
-
}
|
|
402
|
-
}
|
|
403
|
-
},
|
|
404
|
-
// 隐藏包含labels的文本
|
|
405
|
-
hideLabels(...labels) {
|
|
406
|
-
for (const item of this.show_data.fields) {
|
|
407
|
-
if (labels.includes(item.label)) {
|
|
408
|
-
item.hidden = true
|
|
409
|
-
}
|
|
410
|
-
}
|
|
411
|
-
},
|
|
412
|
-
// 给对应labels的值设置为必填
|
|
413
|
-
requiredLabels(...labels) {
|
|
414
|
-
for (const item of this.show_data.fields) {
|
|
415
|
-
if (labels.includes(item.label)) {
|
|
416
|
-
item.required = true
|
|
417
|
-
}
|
|
418
|
-
}
|
|
419
|
-
},
|
|
420
|
-
// 给对应labels的值设置为不必填
|
|
421
|
-
electiveLabels(...labels) {
|
|
422
|
-
for (const item of this.show_data.fields) {
|
|
423
|
-
if (labels.includes(item.label)) {
|
|
424
|
-
item.required = false
|
|
425
|
-
}
|
|
426
|
-
}
|
|
427
|
-
},
|
|
428
|
-
// 给对应labels的值设置为只读和禁用
|
|
429
|
-
readonlyLabels(...labels) {
|
|
430
|
-
for (const item of this.show_data.fields) {
|
|
431
|
-
if (labels.includes(item.label)) {
|
|
432
|
-
item.readonly = true
|
|
433
|
-
item.disabled = true
|
|
434
|
-
}
|
|
435
|
-
}
|
|
436
|
-
},
|
|
437
|
-
// 给对应labels的值设置为不只读和不禁用
|
|
438
|
-
readwriteLabels(...labels) {
|
|
439
|
-
for (const item of this.show_data.fields) {
|
|
440
|
-
if (labels.includes(item.label)) {
|
|
441
|
-
item.readonly = false
|
|
442
|
-
item.disabled = false
|
|
443
|
-
}
|
|
444
|
-
}
|
|
445
|
-
},
|
|
446
|
-
// 给对应labels的值设置为禁用
|
|
447
|
-
disabledButtons(...buttons) {
|
|
448
|
-
for (const item of this.show_data.buttons) {
|
|
449
|
-
if (buttons.includes(item.button_name)) {
|
|
450
|
-
item.disabled = true
|
|
451
|
-
}
|
|
452
|
-
}
|
|
453
|
-
},
|
|
454
|
-
// 给对应labels的值设置为不禁用
|
|
455
|
-
enableButtons(...buttons) {
|
|
456
|
-
for (const item of this.show_data.buttons) {
|
|
457
|
-
if (buttons.includes(item.button_name)) {
|
|
458
|
-
item.disabled = false
|
|
459
|
-
}
|
|
460
|
-
}
|
|
461
|
-
},
|
|
462
|
-
// 显示对应按钮
|
|
463
|
-
showButtons(...buttons) {
|
|
464
|
-
for (const item of this.show_data.buttons) {
|
|
465
|
-
if (buttons.includes(item.button_name)) {
|
|
466
|
-
item.hidden = false
|
|
467
|
-
}
|
|
468
|
-
}
|
|
469
|
-
},
|
|
470
|
-
// 隐藏对应按钮
|
|
471
|
-
hideButtons(...buttons) {
|
|
472
|
-
for (const item of this.show_data.buttons) {
|
|
473
|
-
if (buttons.includes(item.button_name)) {
|
|
474
|
-
item.hidden = true
|
|
475
|
-
}
|
|
476
|
-
}
|
|
477
|
-
},
|
|
478
|
-
// 检查t_apply对应字段的值是否重复
|
|
479
|
-
async checkDuplicate(index) {
|
|
480
|
-
let http = new HttpResetClass()
|
|
481
|
-
let data = {
|
|
482
|
-
tablename: 't_apply',
|
|
483
|
-
condition: `${this.show_data.fields[index].field} = '${this.show_data.fields[index].value}'`
|
|
484
|
-
}
|
|
485
|
-
let res = await http.load('POST', 'rs/sql/apply_singleTable', {data: data}, {
|
|
486
|
-
resolveMsg: null,
|
|
487
|
-
rejectMsg: `${this.show_data.fields[index].label}查询失败`
|
|
488
|
-
})
|
|
489
|
-
if (res.data.length > 0) {
|
|
490
|
-
this.show_data.fields[index].value = null
|
|
491
|
-
this.$showAlert(`${this.show_data.fields[index].label}已存在!!!`, 'warning', 3000)
|
|
492
|
-
}
|
|
493
|
-
},
|
|
494
|
-
// 获取片区
|
|
495
|
-
async getSliceArea () {
|
|
496
|
-
let data = {
|
|
497
|
-
source: 'this.getParentByType($organization$).getAllChildrens().where(row.getType() == $zone$)',
|
|
498
|
-
userid: this.$login.f.id
|
|
499
|
-
}
|
|
500
|
-
|
|
501
|
-
let http = new HttpResetClass()
|
|
502
|
-
let res = await http.load(
|
|
503
|
-
'POST',
|
|
504
|
-
`rs/search`,
|
|
505
|
-
{data: data},
|
|
506
|
-
{resolveMsg: null, rejectMsg: '片区查询失败!!!'}
|
|
507
|
-
)
|
|
508
|
-
|
|
509
|
-
return res.data.map(item => {
|
|
510
|
-
return {
|
|
511
|
-
label: item.name,
|
|
512
|
-
value: item.name
|
|
513
|
-
}
|
|
514
|
-
})
|
|
515
|
-
},
|
|
516
|
-
// 获取区县
|
|
517
|
-
async getPcd () {
|
|
518
|
-
let data = {
|
|
519
|
-
tablename: 't_pcd',
|
|
520
|
-
condition: `f_filialeid = '${this.$login.f.orgid}'`
|
|
521
|
-
}
|
|
522
|
-
let http = new HttpResetClass()
|
|
523
|
-
let res = await http.load(
|
|
524
|
-
'POST',
|
|
525
|
-
`rs/sql/apply_singleTable`,
|
|
526
|
-
{data: data},
|
|
527
|
-
{resolveMsg: null, rejectMsg: '区县查询失败!!!'}
|
|
528
|
-
)
|
|
529
|
-
|
|
530
|
-
return res.data.map(item => {
|
|
531
|
-
return {
|
|
532
|
-
label: item.f_pcd,
|
|
533
|
-
value: item.f_pcd
|
|
534
|
-
}
|
|
535
|
-
})
|
|
536
|
-
},
|
|
537
|
-
// 获取小区
|
|
538
|
-
async getArea () {
|
|
539
|
-
let data = {
|
|
540
|
-
tablename: 't_area',
|
|
541
|
-
condition: `f_filialeid = '${this.$login.f.orgid}'`
|
|
542
|
-
}
|
|
543
|
-
let http = new HttpResetClass()
|
|
544
|
-
let res = await http.load(
|
|
545
|
-
'POST',
|
|
546
|
-
`rs/sql/apply_singleTable`,
|
|
547
|
-
{data: data},
|
|
548
|
-
{resolveMsg: null, rejectMsg: '小区查询失败!!!'}
|
|
549
|
-
)
|
|
550
|
-
|
|
551
|
-
return res.data.map(item => {
|
|
552
|
-
return {
|
|
553
|
-
label: item.f_residential_area,
|
|
554
|
-
value: item.f_residential_area
|
|
555
|
-
}
|
|
556
|
-
})
|
|
557
|
-
},
|
|
558
|
-
// 缴费前置
|
|
559
|
-
chargeBefore () {
|
|
560
|
-
if (Number(this.show_data.f_due_money) > Number(this.show_data.f_cumulative_payment_money) || Number(this.show_data.f_surplus_money) > 0) {
|
|
561
|
-
this.$showAlert('费用未结清!!!', 'warning', 3000)
|
|
562
|
-
throw null
|
|
563
|
-
}
|
|
564
|
-
},
|
|
565
|
-
// 附件上传必传
|
|
566
|
-
async uploadBefore () {
|
|
567
|
-
let condition = `f_blobid= '${this.selectdata.f_process_id}' `
|
|
568
|
-
let http = new HttpResetClass()
|
|
569
|
-
let data = {
|
|
570
|
-
tablename: 't_files',
|
|
571
|
-
condition: condition + ` order by f_uploaddate desc `
|
|
572
|
-
}
|
|
573
|
-
let res = await http.load('POST', 'rs/sql/apply_singleTable', {data: data}, {
|
|
574
|
-
warnMsg: null,
|
|
575
|
-
resolveMsg: null
|
|
576
|
-
})
|
|
577
|
-
if (res.data.length = 0) {
|
|
578
|
-
this.$showAlert('请上传附件!!!', 'warning', 3000)
|
|
579
|
-
throw null
|
|
580
|
-
}
|
|
581
|
-
},
|
|
582
|
-
// 施工前置 加表具后状态是待开通 提交后是正常 所以这里的判断条件需改正 (and uf.f_meter_classify is null and f_meternumber is null)
|
|
583
|
-
async constructionBefore () {
|
|
584
|
-
let http = new HttpResetClass()
|
|
585
|
-
let data = {
|
|
586
|
-
condition: `ui.f_process_id = '${this.show_data.f_process_id}' and uf.f_meter_classify is null and f_meternumber is null`
|
|
587
|
-
}
|
|
588
|
-
let res = await http.load(
|
|
589
|
-
'POST',
|
|
590
|
-
'rs/sql/countApplyUserinfo',
|
|
591
|
-
{data: data},
|
|
592
|
-
{
|
|
593
|
-
resolveMsg: null,
|
|
594
|
-
rejectMsg: '安装明细查询失败!!!'
|
|
595
|
-
})
|
|
596
|
-
if (res.data[0].num > 0) {
|
|
597
|
-
this.$showAlert(`还有${res.data[0].num}户未安装,无法提交`, 'warning', 3000)
|
|
598
|
-
throw `还有${res.data[0].num}户未安装,无法提交`
|
|
599
|
-
}
|
|
600
|
-
},
|
|
601
|
-
// 获取对应气价id的数组
|
|
602
|
-
async getPrice (f_price_id) {
|
|
603
|
-
console.log('=======================')
|
|
604
|
-
console.log(f_price_id)
|
|
605
|
-
let data = {
|
|
606
|
-
condition: `sp.f_filialeid = '${this.$login.f.orgid}'`
|
|
607
|
-
}
|
|
608
|
-
if (!isEmpty(f_price_id)) {
|
|
609
|
-
data.condition = `sp.f_filialeid = '${this.$login.f.orgid}' and sp.f_price_id = ${f_price_id}`
|
|
610
|
-
}
|
|
611
|
-
let http = new HttpResetClass()
|
|
612
|
-
let res = await http.load(
|
|
613
|
-
'POST',
|
|
614
|
-
`rs/sql/applyGetPrice`,
|
|
615
|
-
{data: data},
|
|
616
|
-
{resolveMsg: null, rejectMsg: '气价查询失败!!!'}
|
|
617
|
-
)
|
|
618
|
-
|
|
619
|
-
let a= res.data.map(item => {
|
|
620
|
-
return {
|
|
621
|
-
label: item.f_price_name,
|
|
622
|
-
value: item
|
|
623
|
-
}
|
|
624
|
-
})
|
|
625
|
-
this.selectdata.fields.forEach(field => {
|
|
626
|
-
if (field.label === '气价名称') {
|
|
627
|
-
field.options = a}
|
|
628
|
-
})
|
|
629
|
-
return a
|
|
630
|
-
},
|
|
631
|
-
// 地址操作
|
|
632
|
-
addressInitialization () {
|
|
633
|
-
this.$getConfig(this, 'UserAddress')
|
|
634
|
-
|
|
635
|
-
},
|
|
636
|
-
// 街道发生改变,获取对应街道下的小区
|
|
637
|
-
async streetChange () {
|
|
638
|
-
if (isEmpty(this.show_data.f_street)) {
|
|
639
|
-
return
|
|
640
|
-
}
|
|
641
|
-
|
|
642
|
-
let data = {
|
|
643
|
-
tablename: 't_area',
|
|
644
|
-
condition: `f_filialeid = '${this.$login.f.orgid}' and f_street = '${this.show_data.f_street}'`
|
|
645
|
-
}
|
|
646
|
-
let http = new HttpResetClass()
|
|
647
|
-
let res = await http.load(
|
|
648
|
-
'POST',
|
|
649
|
-
`rs/sql/apply_singleTable`,
|
|
650
|
-
{data: data},
|
|
651
|
-
{resolveMsg: null, rejectMsg: '小区查询失败!!!'}
|
|
652
|
-
)
|
|
653
|
-
|
|
654
|
-
this.setLabelOptions('小区', res.data.map(item => {
|
|
655
|
-
return {
|
|
656
|
-
label: item.f_residential_area,
|
|
657
|
-
value: item.f_residential_area
|
|
658
|
-
}
|
|
659
|
-
}))
|
|
660
|
-
},
|
|
661
|
-
async searchbuilding () {
|
|
662
|
-
if (isEmpty(this.show_data.f_residential_area)) {
|
|
663
|
-
return
|
|
664
|
-
}
|
|
665
|
-
let data = {
|
|
666
|
-
tablename: 't_building',
|
|
667
|
-
condition: `f_filialeid = '${this.$login.f.orgid}' and f_residential_area like '%${this.show_data.f_residential_area}%'`
|
|
668
|
-
}
|
|
669
|
-
let http = new HttpResetClass()
|
|
670
|
-
let res = await http.load(
|
|
671
|
-
'POST',
|
|
672
|
-
`rs/sql/apply_singleTable`,
|
|
673
|
-
{data: data},
|
|
674
|
-
{resolveMsg: null, rejectMsg: '楼号查询失败!!!'}
|
|
675
|
-
)
|
|
676
|
-
|
|
677
|
-
if (res.data.length === 0) {
|
|
678
|
-
return
|
|
679
|
-
}
|
|
680
|
-
|
|
681
|
-
this.setLabelOptions('楼号/组', res.data.map(item => {
|
|
682
|
-
return {
|
|
683
|
-
label: item.f_building,
|
|
684
|
-
value: item.f_building
|
|
685
|
-
}
|
|
686
|
-
}))
|
|
687
|
-
},
|
|
688
|
-
// 地址类型发生改变,获取对应的街道/乡镇
|
|
689
|
-
async pcdChange () {
|
|
690
|
-
if (isEmpty(this.show_data.f_pcd)) {
|
|
691
|
-
return
|
|
692
|
-
}
|
|
693
|
-
|
|
694
|
-
let data = {
|
|
695
|
-
tablename: 't_street',
|
|
696
|
-
condition: `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}'`
|
|
697
|
-
}
|
|
698
|
-
|
|
699
|
-
let http = new HttpResetClass()
|
|
700
|
-
let res = await http.load(
|
|
701
|
-
'POST',
|
|
702
|
-
`rs/sql/apply_singleTable`,
|
|
703
|
-
{data: data},
|
|
704
|
-
{resolveMsg: null, rejectMsg: '街道/乡镇查询失败!!!'}
|
|
705
|
-
)
|
|
706
|
-
|
|
707
|
-
this.setLabelOptions('街道/乡镇', res.data.map(item => {
|
|
708
|
-
return {
|
|
709
|
-
label: item.f_street,
|
|
710
|
-
value: item.f_street
|
|
711
|
-
}
|
|
712
|
-
}))
|
|
713
|
-
},
|
|
714
|
-
// 获取当前分公司下拥有role角色的人员
|
|
715
|
-
async getDesignerPeople (role) {
|
|
716
|
-
let data = {
|
|
717
|
-
source: 'this.getParentByType($organization$).getChildByName($'+role+"$).getChildren()",
|
|
718
|
-
userid: this.$login.f.id
|
|
719
|
-
}
|
|
720
|
-
|
|
721
|
-
let http = new HttpResetClass()
|
|
722
|
-
let res = await http.load(
|
|
723
|
-
'POST',
|
|
724
|
-
`rs/search`,
|
|
725
|
-
{data: data},
|
|
726
|
-
{resolveMsg: null, rejectMsg: '人员查询失败!!!'}
|
|
727
|
-
)
|
|
728
|
-
|
|
729
|
-
return res.data.map(item => {
|
|
730
|
-
return {
|
|
731
|
-
label: item.name,
|
|
732
|
-
value: item.name
|
|
733
|
-
}
|
|
734
|
-
})
|
|
735
|
-
},
|
|
736
|
-
// 终止报建 reason--终止原因
|
|
737
|
-
async surveyStopApply (reason) {
|
|
738
|
-
console.log('终止报建!!!!!')
|
|
739
|
-
|
|
740
|
-
this.show_data.f_stop_reason = reason
|
|
741
|
-
|
|
742
|
-
let data = {
|
|
743
|
-
data: this.show_data,
|
|
744
|
-
user: this.$login.f
|
|
745
|
-
}
|
|
746
|
-
|
|
747
|
-
let res = await this.$resetpost(
|
|
748
|
-
`rs/logic/surveyStopApply`,
|
|
749
|
-
{data: data},
|
|
750
|
-
{resolveMsg: null, rejectMsg: '终止报建失败!!!'}
|
|
751
|
-
)
|
|
752
|
-
|
|
753
|
-
this.$dispatch('loadPage')
|
|
754
|
-
|
|
755
|
-
throw '终止报建!!!'
|
|
756
|
-
},
|
|
757
|
-
|
|
758
|
-
PrefixInteger(num, n) {
|
|
759
|
-
return (Array(n).join(0) + num).slice(-n);
|
|
760
|
-
}
|
|
761
|
-
},
|
|
762
|
-
events: {
|
|
763
|
-
'priceType'(index){
|
|
764
|
-
this.Pricetype = this.getLableValue('所属类型')
|
|
765
|
-
console.log('打印方法值',this.getPrice(this.show_data.f_price_id))
|
|
766
|
-
for (const item of this.show_data.fields) {
|
|
767
|
-
if (this.show_data.f_sprice_type !=null && this.show_data.f_sprice_type !='') {
|
|
768
|
-
if(item.label==='气价名称'){
|
|
769
|
-
this.getPrice().then(value =>{
|
|
770
|
-
item.options=value
|
|
771
|
-
})
|
|
772
|
-
console.log('最终',item.options)
|
|
773
|
-
}
|
|
774
|
-
}
|
|
775
|
-
}
|
|
776
|
-
},
|
|
777
|
-
'complyInstallation' (index) {
|
|
778
|
-
if (this.show_data.f_apply_type == '居民团体用户报建' ){
|
|
779
|
-
if (this.show_data.f_apply_nature == '整体小区'){
|
|
780
|
-
this.showLabels('楼房总户数')
|
|
781
|
-
this.showLabels('楼房总栋数')
|
|
782
|
-
this.showLabels('别墅总户数')
|
|
783
|
-
this.hideLabels('总户数')
|
|
784
|
-
}
|
|
785
|
-
if (this.show_data.f_apply_nature == '整体村庄'){
|
|
786
|
-
this.showLabels('总户数')
|
|
787
|
-
this.hideLabels('楼房总户数')
|
|
788
|
-
this.hideLabels('楼房总栋数')
|
|
789
|
-
this.hideLabels('别墅总户数')
|
|
790
|
-
}
|
|
791
|
-
}
|
|
792
|
-
},
|
|
793
|
-
async 'igniteDispatchReadyEvent' () {
|
|
794
|
-
let data = {
|
|
795
|
-
tablename: 'activityins',
|
|
796
|
-
condition: `processid = '${this.show_data.f_process_id}' and defname = '工程施工' and state = '结束'`
|
|
797
|
-
}
|
|
798
|
-
let http = new HttpResetClass()
|
|
799
|
-
let res = await http.load(
|
|
800
|
-
'POST',
|
|
801
|
-
`rs/sql/apply_singleTable`,
|
|
802
|
-
{data: data},
|
|
803
|
-
{resolveMsg: null, rejectMsg: '查询失败!!!'}
|
|
804
|
-
)
|
|
805
|
-
if (res.data.length <= 0) {
|
|
806
|
-
console.log('+++++++++++++++++++++++++++++')
|
|
807
|
-
console.log('没有施工,不能退回')
|
|
808
|
-
this.hideButtons('退回')
|
|
809
|
-
}
|
|
810
|
-
},
|
|
811
|
-
'buildReadyEvent' () {
|
|
812
|
-
},
|
|
813
|
-
// 选择材料
|
|
814
|
-
async materialNameChenge (index, fieldIndex) {
|
|
815
|
-
let material = this.show_data.onetomany[index].fields[fieldIndex].value
|
|
816
|
-
|
|
817
|
-
this.show_data.onetomany[index].fields.forEach(item => {
|
|
818
|
-
if (material[item.field]) {
|
|
819
|
-
item.value = material[item.field]
|
|
820
|
-
}
|
|
821
|
-
})
|
|
822
|
-
},
|
|
823
|
-
// 打开模态框获取材料
|
|
824
|
-
async 'getMaterialName' (index) {
|
|
825
|
-
let data = {
|
|
826
|
-
condition: `1=1`
|
|
827
|
-
}
|
|
828
|
-
let http = new HttpResetClass()
|
|
829
|
-
let res = await http.load(
|
|
830
|
-
'POST',
|
|
831
|
-
`rs/sql/getStockMaterial`,
|
|
832
|
-
{data: data},
|
|
833
|
-
{resolveMsg: null, rejectMsg: '材料查询失败!!!'}
|
|
834
|
-
)
|
|
835
|
-
|
|
836
|
-
this.show_data.onetomany[index].fields.forEach(field => {
|
|
837
|
-
if (field.label === '选择材料') {
|
|
838
|
-
field.options = res.data.map(item => {
|
|
839
|
-
return {
|
|
840
|
-
'label': `${item.f_material_name}--${item.f_material_style}--${item.f_material_unit}`,
|
|
841
|
-
'value': item
|
|
842
|
-
}
|
|
843
|
-
})
|
|
844
|
-
}
|
|
845
|
-
})
|
|
846
|
-
},
|
|
847
|
-
// 搜索小区
|
|
848
|
-
async 'searchArea' (area, index) {
|
|
849
|
-
let data = {
|
|
850
|
-
tablename: 't_area',
|
|
851
|
-
condition: `f_filialeid = '${this.$login.f.orgid}' and f_street = '${this.show_data.f_street}' and f_residential_area like '%${area}%'`
|
|
852
|
-
}
|
|
853
|
-
let http = new HttpResetClass()
|
|
854
|
-
let res = await http.load(
|
|
855
|
-
'POST',
|
|
856
|
-
`rs/sql/apply_singleTable`,
|
|
857
|
-
{data: data},
|
|
858
|
-
{resolveMsg: null, rejectMsg: '小区查询失败!!!'}
|
|
859
|
-
)
|
|
860
|
-
|
|
861
|
-
if (res.data.length === 0) {
|
|
862
|
-
return
|
|
863
|
-
}
|
|
864
|
-
|
|
865
|
-
this.setLabelOptions('小区', res.data.map(item => {
|
|
866
|
-
return {
|
|
867
|
-
label: item.f_residential_area,
|
|
868
|
-
value: item.f_residential_area
|
|
869
|
-
}
|
|
870
|
-
}))
|
|
871
|
-
},
|
|
872
|
-
// 搜索小区
|
|
873
|
-
async 'searchAreaCollective' (area, index) {
|
|
874
|
-
let data = {
|
|
875
|
-
tablename: 't_area',
|
|
876
|
-
condition: `f_filialeid = '${this.$login.f.orgid}' and f_residential_area like '%${area}%'`
|
|
877
|
-
}
|
|
878
|
-
let http = new HttpResetClass()
|
|
879
|
-
let res = await http.load(
|
|
880
|
-
'POST',
|
|
881
|
-
`rs/sql/apply_singleTable`,
|
|
882
|
-
{data: data},
|
|
883
|
-
{resolveMsg: null, rejectMsg: '小区查询失败!!!'}
|
|
884
|
-
)
|
|
885
|
-
|
|
886
|
-
if (res.data.length === 0) {
|
|
887
|
-
return
|
|
888
|
-
}
|
|
889
|
-
|
|
890
|
-
this.setLabelOptions('小区', res.data.map(item => {
|
|
891
|
-
return {
|
|
892
|
-
label: item.f_residential_area,
|
|
893
|
-
value: item.f_residential_area
|
|
894
|
-
}
|
|
895
|
-
}))
|
|
896
|
-
},
|
|
897
|
-
// 选择气价
|
|
898
|
-
'priceChange' (index) {
|
|
899
|
-
if (isEmpty(this.show_data.stairPrice)) {
|
|
900
|
-
return
|
|
901
|
-
}
|
|
902
|
-
|
|
903
|
-
let stairPrice = this.getLableValue('气价名称')
|
|
904
|
-
|
|
905
|
-
this.setLabelValue('气价类型', stairPrice.f_price_type)
|
|
906
|
-
this.setLabelValue('用气性质', stairPrice.f_gasproperties)
|
|
907
|
-
this.setLabelValue('价格', stairPrice.f_price)
|
|
908
|
-
this.setLabelValue('客户类型', stairPrice.f_user_type)
|
|
909
|
-
this.show_data.f_price_id = stairPrice.id
|
|
910
|
-
this.show_data.f_price_name = stairPrice.f_price_name
|
|
911
|
-
},
|
|
912
|
-
// 退款金额
|
|
913
|
-
'refundMoneyChange' (index) {
|
|
914
|
-
let f_cumulative_payment_money = this.show_data.f_cumulative_payment_money
|
|
915
|
-
let f_refund_money = this.show_data.fields[index].value
|
|
916
|
-
|
|
917
|
-
if (f_refund_money > f_cumulative_payment_money) {
|
|
918
|
-
this.$showAlert('退款金额不能大于累计缴费金额!!!', 'warning', 3000)
|
|
919
|
-
this.show_data.fields[index].value = null
|
|
920
|
-
}
|
|
921
|
-
},
|
|
922
|
-
// 检查重复
|
|
923
|
-
'checkRepeat' (index) {
|
|
924
|
-
this.checkDuplicate(index)
|
|
925
|
-
},
|
|
926
|
-
// 选择报建项目
|
|
927
|
-
'selectApply' (row) {
|
|
928
|
-
this.setLabelValue('工程名称', row.f_entry_name)
|
|
929
|
-
this.setLabelValue('工程编号', row.f_apply_num)
|
|
930
|
-
this.setLabelValue('报建类型', row.f_apply_type)
|
|
931
|
-
this.setLabelValue('客户名称', row.f_user_name)
|
|
932
|
-
this.setLabelValue('客户电话', row.f_phone)
|
|
933
|
-
this.setLabelValue('证件类型', row.f_credentials)
|
|
934
|
-
this.setLabelValue('证件号码', row.f_idnumber)
|
|
935
|
-
this.setLabelValue('地址', row.f_address)
|
|
936
|
-
this.setLabelValue('累计缴费金额', row.f_cumulative_payment_money)
|
|
937
|
-
|
|
938
|
-
this.show_data.parentApply = JSON.parse(JSON.stringify(row))
|
|
939
|
-
|
|
940
|
-
delete row.id
|
|
941
|
-
delete row.actid
|
|
942
|
-
delete row.defid
|
|
943
|
-
delete row.defname
|
|
944
|
-
delete row.version
|
|
945
|
-
delete row.f_apply_num
|
|
946
|
-
delete row.f_sub_state
|
|
947
|
-
delete row.f_apply_type
|
|
948
|
-
delete row.f_process_id
|
|
949
|
-
|
|
950
|
-
this.show_data = Object.assign({}, this.show_data, row)
|
|
951
|
-
|
|
952
|
-
this.show_data.f_parent_process_id = this.show_data.parentApply.f_process_id
|
|
953
|
-
},
|
|
954
|
-
// 是否终止
|
|
955
|
-
'isStopChange' (index) {
|
|
956
|
-
let f_is_stop = this.show_data.f_is_stop
|
|
957
|
-
|
|
958
|
-
for (const item of this.show_data.fields) {
|
|
959
|
-
if (f_is_stop === '是') {
|
|
960
|
-
if (item.label === '终止原因') {
|
|
961
|
-
item.hidden = false
|
|
962
|
-
item.required = true
|
|
963
|
-
}
|
|
964
|
-
} else {
|
|
965
|
-
if (item.label === '终止原因') {
|
|
966
|
-
item.hidden = true
|
|
967
|
-
item.required = false
|
|
968
|
-
}
|
|
969
|
-
}
|
|
970
|
-
}
|
|
971
|
-
},
|
|
972
|
-
// 终止报建初始化
|
|
973
|
-
async 'stopApplyReadyEvent' () {
|
|
974
|
-
|
|
975
|
-
let f_is_stop = this.getLableValue('是否终止')
|
|
976
|
-
|
|
977
|
-
for (const item of this.show_data.fields) {
|
|
978
|
-
if (f_is_stop === '是') {
|
|
979
|
-
if (item.label === '终止原因') {
|
|
980
|
-
item.hidden = false
|
|
981
|
-
item.required = true
|
|
982
|
-
}
|
|
983
|
-
} else {
|
|
984
|
-
if (item.label === '终止原因') {
|
|
985
|
-
item.hidden = true
|
|
986
|
-
item.required = false
|
|
987
|
-
}
|
|
988
|
-
}
|
|
989
|
-
}
|
|
990
|
-
|
|
991
|
-
if (isEmpty(this.show_data.f_parent_process_id)) {
|
|
992
|
-
return
|
|
993
|
-
}
|
|
994
|
-
let data = {
|
|
995
|
-
condition: `f_process_id = '${this.show_data.f_parent_process_id}'`,
|
|
996
|
-
data: {
|
|
997
|
-
id: this.$login.f.id,
|
|
998
|
-
orgid: this.$login.f.orgid
|
|
999
|
-
}
|
|
1000
|
-
}
|
|
1001
|
-
let res = await this.$resetpost(
|
|
1002
|
-
`rs/sql/supervisory`,
|
|
1003
|
-
{data: data},
|
|
1004
|
-
{resolveMsg: null, rejectMsg: '项目查询失败!!!'}
|
|
1005
|
-
)
|
|
1006
|
-
this.show_data.parentApply = res.data[0]
|
|
1007
|
-
},
|
|
1008
|
-
// 选择客户档案信息
|
|
1009
|
-
'selectUserinfo' (row) {
|
|
1010
|
-
this.setLabelValue('客户编号', row.f_userinfo_code)
|
|
1011
|
-
this.setLabelValue('入户证号', row.f_entry_number)
|
|
1012
|
-
this.setLabelValue('客户名称', row.f_user_name)
|
|
1013
|
-
this.setLabelValue('客户电话', row.f_user_phone)
|
|
1014
|
-
this.setLabelValue('证件类型', row.f_credentials)
|
|
1015
|
-
this.setLabelValue('证件号码', row.f_idnumber)
|
|
1016
|
-
this.setLabelValue('地址', row.f_address)
|
|
1017
|
-
|
|
1018
|
-
this.show_data.f_userinfo_id = row.f_userinfo_id
|
|
1019
|
-
this.show_data.f_userinfo_code = row.f_userinfo_code
|
|
1020
|
-
this.show_data.f_entry_number = row.f_enter_number
|
|
1021
|
-
this.show_data.f_pcd = row.f_pcd
|
|
1022
|
-
this.show_data.f_street = row.f_street
|
|
1023
|
-
this.show_data.f_residential_area = row.f_residential_area
|
|
1024
|
-
this.show_data.f_building = row.f_building
|
|
1025
|
-
this.show_data.f_unit = row.f_unit
|
|
1026
|
-
this.show_data.f_floor = row.f_floor
|
|
1027
|
-
this.show_data.f_room = row.f_room
|
|
1028
|
-
this.show_data.f_room_suffix = row.f_room_suffix
|
|
1029
|
-
},
|
|
1030
|
-
// 通气点火初始化
|
|
1031
|
-
async 'gasReadyEvent' () {
|
|
1032
|
-
// 是否有气价信息
|
|
1033
|
-
if (!isEmpty(this.show_data.f_price_id)) {
|
|
1034
|
-
let priceList = await this.getPrice(this.show_data.f_price_id)
|
|
1035
|
-
this.setLabelValue('气价名称', priceList[0].value)
|
|
1036
|
-
}
|
|
1037
|
-
},
|
|
1038
|
-
// 合同金额失去焦点
|
|
1039
|
-
async 'contractMoneyChange' (index) {
|
|
1040
|
-
let data = {
|
|
1041
|
-
operator: '+',
|
|
1042
|
-
num1: this.show_data.f_contract_money || 0,
|
|
1043
|
-
num2: this.getLableValue('追加金额') || 0
|
|
1044
|
-
}
|
|
1045
|
-
let res = await this.$resetpost(
|
|
1046
|
-
`rs/logic/compute`,
|
|
1047
|
-
{data: data},
|
|
1048
|
-
{resolveMsg: null, rejectMsg: '金额计算失败!!!'}
|
|
1049
|
-
)
|
|
1050
|
-
//转成千分位
|
|
1051
|
-
let money= this.formatCurrency(res.data,2)
|
|
1052
|
-
this.setLabelValue('应交金额', money)
|
|
1053
|
-
//合同金额
|
|
1054
|
-
let contract= this.formatCurrency( this.show_data.f_contract_money,2)
|
|
1055
|
-
this.setLabelValue('合同金额', contract)
|
|
1056
|
-
},
|
|
1057
|
-
// 街道失去焦点
|
|
1058
|
-
async 'streetChange' (index) {
|
|
1059
|
-
if (isEmpty(this.show_data.f_street)) {
|
|
1060
|
-
return
|
|
1061
|
-
}
|
|
1062
|
-
|
|
1063
|
-
this.setLabelValue('小区', null)
|
|
1064
|
-
|
|
1065
|
-
let data = {
|
|
1066
|
-
tablename: 't_area',
|
|
1067
|
-
condition: `f_filialeid = '${this.$login.f.orgid}' and f_street = '${this.show_data.f_street}'`
|
|
1068
|
-
}
|
|
1069
|
-
let http = new HttpResetClass()
|
|
1070
|
-
let res = await http.load(
|
|
1071
|
-
'POST',
|
|
1072
|
-
`rs/sql/apply_singleTable`,
|
|
1073
|
-
{data: data},
|
|
1074
|
-
{resolveMsg: null, rejectMsg: '小区查询失败!!!'}
|
|
1075
|
-
)
|
|
1076
|
-
|
|
1077
|
-
this.setLabelOptions('小区', res.data.map(item => {
|
|
1078
|
-
return {
|
|
1079
|
-
label: item.f_residential_area,
|
|
1080
|
-
value: item.f_residential_area
|
|
1081
|
-
}
|
|
1082
|
-
}))
|
|
1083
|
-
},
|
|
1084
|
-
// 区县失去焦点
|
|
1085
|
-
async 'pcdChange' (index) {
|
|
1086
|
-
if (isEmpty(this.show_data.f_pcd)) {
|
|
1087
|
-
return
|
|
1088
|
-
}
|
|
1089
|
-
|
|
1090
|
-
this.setLabelValue('街道/乡镇', null)
|
|
1091
|
-
this.setLabelValue('小区', null)
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
let data = {
|
|
1096
|
-
tablename: 't_street',
|
|
1097
|
-
condition: `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}'`
|
|
1098
|
-
}
|
|
1099
|
-
let f_address_type = this.getLableValue('地址类型')
|
|
1100
|
-
|
|
1101
|
-
if (f_address_type === '民用市区') {
|
|
1102
|
-
data.condition = `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}' and f_iscity = '市区'`
|
|
1103
|
-
}
|
|
1104
|
-
if (f_address_type === '民用乡镇') {
|
|
1105
|
-
data.condition = `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}' and f_iscity = '乡镇'`
|
|
1106
|
-
}
|
|
1107
|
-
|
|
1108
|
-
let http = new HttpResetClass()
|
|
1109
|
-
let res = await http.load(
|
|
1110
|
-
'POST',
|
|
1111
|
-
`rs/sql/apply_singleTable`,
|
|
1112
|
-
{data: data},
|
|
1113
|
-
{resolveMsg: null, rejectMsg: '街道/乡镇查询失败!!!'}
|
|
1114
|
-
)
|
|
1115
|
-
|
|
1116
|
-
this.setLabelOptions('街道/乡镇', res.data.map(item => {
|
|
1117
|
-
return {
|
|
1118
|
-
label: item.f_street,
|
|
1119
|
-
value: item.f_street
|
|
1120
|
-
}
|
|
1121
|
-
}))
|
|
1122
|
-
},
|
|
1123
|
-
// 搜索楼号
|
|
1124
|
-
async 'searchbuilding' (index) {
|
|
1125
|
-
this.setLabelValue('楼号/组', null)
|
|
1126
|
-
if (isEmpty(this.show_data.f_residential_area)){
|
|
1127
|
-
return
|
|
1128
|
-
}
|
|
1129
|
-
let data = {
|
|
1130
|
-
items:'b.f_building',
|
|
1131
|
-
orderitem: 'b.id',
|
|
1132
|
-
tablename: 't_building b left join t_area a on b.f_residential_area_id = a.id',
|
|
1133
|
-
condition: `b.f_filialeid = '${this.$login.f.orgid}' and b.f_residential_area like '%${this.show_data.f_residential_area}%' and a.f_street = '${this.show_data.f_street}'`
|
|
1134
|
-
}
|
|
1135
|
-
let http = new HttpResetClass()
|
|
1136
|
-
let res = await http.load(
|
|
1137
|
-
'POST',
|
|
1138
|
-
`rs/sql/tel_singleTable_OrderBy`,
|
|
1139
|
-
{data: data},
|
|
1140
|
-
{resolveMsg: null, rejectMsg: '楼号查询失败!!!'}
|
|
1141
|
-
)
|
|
1142
|
-
|
|
1143
|
-
if (res.data.length === 0) {
|
|
1144
|
-
return
|
|
1145
|
-
}
|
|
1146
|
-
|
|
1147
|
-
this.setLabelOptions('楼号/组', res.data.map(item => {
|
|
1148
|
-
return {
|
|
1149
|
-
label: item.f_building,
|
|
1150
|
-
value: item.f_building
|
|
1151
|
-
}
|
|
1152
|
-
}))
|
|
1153
|
-
},
|
|
1154
|
-
// 地址类型失去焦点
|
|
1155
|
-
'addressTypeChange' (index) {
|
|
1156
|
-
},
|
|
1157
|
-
// 居民团体单户报建初始化
|
|
1158
|
-
'apply2ReadyEvent' () {
|
|
1159
|
-
if (this.show_data.f_apply_source === '线下发起') {
|
|
1160
|
-
this.addressInitialization()
|
|
1161
|
-
this.hideLabels('客户编号')
|
|
1162
|
-
this.electiveLabels('客户编号')
|
|
1163
|
-
this.showLabels('片区', '地址类型')
|
|
1164
|
-
this.requiredLabels('片区', '地址类型')
|
|
1165
|
-
}
|
|
1166
|
-
if (this.show_data.f_apply_source === '自动发起') {
|
|
1167
|
-
this.hideLabels('片区', '地址类型')
|
|
1168
|
-
this.electiveLabels('片区', '地址类型',)
|
|
1169
|
-
}
|
|
1170
|
-
},
|
|
1171
|
-
// 申请节点初始化
|
|
1172
|
-
'applyReadyEvent' () {
|
|
1173
|
-
this.addressInitialization()
|
|
1174
|
-
this.pcdChange()
|
|
1175
|
-
this.streetChange()
|
|
1176
|
-
this.searchbuilding()
|
|
1177
|
-
},
|
|
1178
|
-
// ===========================================
|
|
1179
|
-
async 'button'() {
|
|
1180
|
-
if (this.show_data.button.before) {
|
|
1181
|
-
await this[this.show_data.button.before]()
|
|
1182
|
-
}
|
|
1183
|
-
// 点击重置按钮就重置数据
|
|
1184
|
-
if (this.show_data.button.button_name === '重置') {
|
|
1185
|
-
this.$dispatch('breakControl', this.selectdata)
|
|
1186
|
-
return
|
|
1187
|
-
}
|
|
1188
|
-
if ((this.show_data.f_apply_type == '居民用户报建' || this.show_data.f_apply_type == '非居用户报建' || this.show_data.f_apply_type == '其他报建' ) && this.show_data.defname == '报装申请' && this.show_data.f_is_have == '否' && this.show_data.button.button_name == '提交' ){
|
|
1189
|
-
this.show_data.button.button_name = '跳过'
|
|
1190
|
-
}
|
|
1191
|
-
this.show_data.user = this.$login.f
|
|
1192
|
-
this.show_data.start_activity = this.$workflow_vue.start_activity
|
|
1193
|
-
this.show_data.xmlfilename = this.$workflow_vue.workflow_xmlfilename
|
|
1194
|
-
//将千分位金额转成数字
|
|
1195
|
-
for (const item of this.show_data.fields) {
|
|
1196
|
-
if (item.percentiles) {
|
|
1197
|
-
if(item.value.includes(",")){
|
|
1198
|
-
let Money=this.parseCurrency(item.value)
|
|
1199
|
-
this.show_data[item.field]=Money
|
|
1200
|
-
debugger
|
|
1201
|
-
}else{
|
|
1202
|
-
//转为数字
|
|
1203
|
-
let Money= Number(item.value)
|
|
1204
|
-
this.show_data[item.field]=Money
|
|
1205
|
-
debugger
|
|
1206
|
-
}
|
|
1207
|
-
}
|
|
1208
|
-
}
|
|
1209
|
-
let res = await this.$resetpost(
|
|
1210
|
-
`rs/logic/ApplyProductService`,
|
|
1211
|
-
{data: this.show_data},
|
|
1212
|
-
{resolveMsg: null, rejectMsg: '数据保存失败'}
|
|
1213
|
-
)
|
|
1214
|
-
|
|
1215
|
-
if (this.show_data.button.after) {
|
|
1216
|
-
this[this.show_data.button.after]()
|
|
1217
|
-
}
|
|
1218
|
-
this.$dispatch('loadPage')
|
|
1219
|
-
},
|
|
1220
|
-
// 失去焦点出触发事件
|
|
1221
|
-
'onchange' (index) {
|
|
1222
|
-
let http = new HttpResetClass()
|
|
1223
|
-
if (this.show_data.defname === '报装申请' || this.show_data.defname === '信息确认') {
|
|
1224
|
-
|
|
1225
|
-
if (
|
|
1226
|
-
this.show_data.fields[index].label === '区/县' ||
|
|
1227
|
-
this.show_data.fields[index].label === '街道/乡镇' ||
|
|
1228
|
-
this.show_data.fields[index].label === '小区' ||
|
|
1229
|
-
this.show_data.fields[index].label === '楼号/组' ||
|
|
1230
|
-
this.show_data.fields[index].label === '单元/排' ||
|
|
1231
|
-
this.show_data.fields[index].label === '楼层' ||
|
|
1232
|
-
this.show_data.fields[index].label === '门牌号' ||
|
|
1233
|
-
this.show_data.fields[index].label === '地址杂项'
|
|
1234
|
-
) {
|
|
1235
|
-
if (this.show_data.fields[index].label === '单元/排' || this.show_data.fields[index].label === '楼层' || this.show_data.fields[index].label === '门牌号'){
|
|
1236
|
-
if (this.show_data.fields[index].value.length == 1){
|
|
1237
|
-
this.show_data.fields[index].value = '0'+ this.show_data.fields[index].value
|
|
1238
|
-
}
|
|
1239
|
-
}
|
|
1240
|
-
console.log('地址参数',this.config)
|
|
1241
|
-
let f_pcd = this.getLableValue('区/县') || ''
|
|
1242
|
-
let f_street = this.getLableValue('街道/乡镇') || ''
|
|
1243
|
-
let f_residential_area = this.getLableValue('小区') || ''
|
|
1244
|
-
let f_building = this.getLableValue('楼号/组') || ''
|
|
1245
|
-
let f_building_suffix = f_building ? this.config.f_building_suffix : ''
|
|
1246
|
-
//let f_building_suffix = f_building ? '号楼' : ''
|
|
1247
|
-
let f_unit = this.getLableValue('单元/排') || ''
|
|
1248
|
-
let f_unit_suffix = f_unit ? this.config.f_unit_suffix : ''
|
|
1249
|
-
//let f_unit_suffix = f_unit ? '单元' : ''
|
|
1250
|
-
let f_floor = this.getLableValue('楼层') || ''
|
|
1251
|
-
let f_floor_suffix = f_floor ? this.config.f_floor_suffix : ''
|
|
1252
|
-
//let f_floor_suffix = f_floor ? '层' : ''
|
|
1253
|
-
let f_room = this.getLableValue('门牌号') || ''
|
|
1254
|
-
//let f_room_suffix = f_room ? this.config.f_room_suffix : ''
|
|
1255
|
-
//let f_room_suffix = f_room ? '室' : ''
|
|
1256
|
-
let f_room_suffix = this.getLableValue('地址杂项') || ''
|
|
1257
|
-
|
|
1258
|
-
let f_address = f_pcd + f_street + f_residential_area + f_building + f_building_suffix + f_unit + f_unit_suffix + f_floor + f_floor_suffix + f_room + f_room_suffix
|
|
1259
|
-
this.setLabelValue("地址", f_address)
|
|
1260
|
-
}
|
|
1261
|
-
}
|
|
1262
|
-
if (this.show_data.fields[index].label == '入户证号'){
|
|
1263
|
-
let data = {
|
|
1264
|
-
tablename: `t_apply`,
|
|
1265
|
-
condition: `f_entry_number='${this.show_data.fields[index].value}' and f_sub_state in ('正在进行','完工')`
|
|
1266
|
-
}
|
|
1267
|
-
http.load('post','rs/sql/apply_singleTable',{data: data},
|
|
1268
|
-
{resolveMsg: null, rejectMsg: '查询失败'}).then(row=>{
|
|
1269
|
-
if (row.data.length > 0){
|
|
1270
|
-
this.$showMessage('请注意入户证号重复!!!')
|
|
1271
|
-
}
|
|
1272
|
-
})
|
|
1273
|
-
}
|
|
1274
|
-
},
|
|
1275
|
-
selectSearch (val, index) {},
|
|
1276
|
-
'onblur' (index) {},
|
|
1277
|
-
'oninput' (index) {
|
|
1278
|
-
},
|
|
1279
|
-
'initializtionView' () {},
|
|
1280
|
-
async 'onchangeModal' (index, fieldIndex) {
|
|
1281
|
-
},
|
|
1282
|
-
async 'onblurModal' (index, fieldIndex) {
|
|
1283
|
-
|
|
1284
|
-
},
|
|
1285
|
-
async 'oninputModal' (index, fieldIndex) {
|
|
1286
|
-
|
|
1287
|
-
},
|
|
1288
|
-
async 'onetomanydelete' (index, rowIndex) {
|
|
1289
|
-
|
|
1290
|
-
let http = new HttpResetClass()
|
|
1291
|
-
|
|
1292
|
-
let res = await http.load(
|
|
1293
|
-
'DELETE',
|
|
1294
|
-
`rs/entity/${this.show_data.onetomany[index].tables[0]}/${this.show_data.onetomany[index].rows[rowIndex].id}`,
|
|
1295
|
-
null,
|
|
1296
|
-
{resolveMsg: null, rejectMsg: '删除失败!!!'}
|
|
1297
|
-
)
|
|
1298
|
-
|
|
1299
|
-
res = await this.$resetpost(
|
|
1300
|
-
'rs/entity/t_apply',
|
|
1301
|
-
this.show_data
|
|
1302
|
-
)
|
|
1303
|
-
|
|
1304
|
-
this.$dispatch('breakControl', this.show_data)
|
|
1305
|
-
},
|
|
1306
|
-
async 'onetomanyupdate' (index, rowIndex) {
|
|
1307
|
-
let data = this.show_data.onetomany[index].rows[rowIndex]
|
|
1308
|
-
|
|
1309
|
-
this.show_data.onetomany[index].fields.forEach(item => {
|
|
1310
|
-
data[item.field] = item.value
|
|
1311
|
-
})
|
|
1312
|
-
let res = await this.$resetpost(
|
|
1313
|
-
`rs/entity/${this.show_data.onetomany[index].tables[0]}`,
|
|
1314
|
-
data
|
|
1315
|
-
)
|
|
1316
|
-
|
|
1317
|
-
res = await this.$resetpost(
|
|
1318
|
-
'rs/entity/t_apply',
|
|
1319
|
-
this.show_data
|
|
1320
|
-
)
|
|
1321
|
-
|
|
1322
|
-
this.$dispatch('breakControl', this.show_data)
|
|
1323
|
-
},
|
|
1324
|
-
async 'onetomanyadd' (index) {
|
|
1325
|
-
let data = {
|
|
1326
|
-
f_process_id : this.show_data.f_process_id,
|
|
1327
|
-
f_operator_id: this.$login.f.id,
|
|
1328
|
-
f_operator: this.$login.f.name,
|
|
1329
|
-
f_operation_date: new Date().Format('yyyy-MM-dd HH:mm:ss'),
|
|
1330
|
-
f_orgid: this.$login.f.orgid,
|
|
1331
|
-
f_orgname: this.$login.f.orgs
|
|
1332
|
-
}
|
|
1333
|
-
this.show_data.onetomany[index].fields.forEach(item => {
|
|
1334
|
-
data[item.field] = item.value
|
|
1335
|
-
})
|
|
1336
|
-
let res = await this.$resetpost(
|
|
1337
|
-
`rs/entity/${this.show_data.onetomany[index].tables[0]}`,
|
|
1338
|
-
data
|
|
1339
|
-
)
|
|
1340
|
-
|
|
1341
|
-
res = await this.$resetpost(
|
|
1342
|
-
'rs/entity/t_apply',
|
|
1343
|
-
this.show_data
|
|
1344
|
-
)
|
|
1345
|
-
|
|
1346
|
-
this.$dispatch('breakControl', this.show_data)
|
|
1347
|
-
},
|
|
1348
|
-
async 'importEvent' (index, table, configName, filepath) {
|
|
1349
|
-
let data = {
|
|
1350
|
-
selectdata: this.show_data,
|
|
1351
|
-
table: table,
|
|
1352
|
-
filepath: filepath,
|
|
1353
|
-
configName: configName,
|
|
1354
|
-
user: this.$login.f
|
|
1355
|
-
}
|
|
1356
|
-
|
|
1357
|
-
let res = await this.$resetpost(
|
|
1358
|
-
`rs/logic/importEvent`,
|
|
1359
|
-
data
|
|
1360
|
-
)
|
|
1361
|
-
|
|
1362
|
-
this.$dispatch('breakControl', this.show_data)
|
|
1363
|
-
},
|
|
1364
|
-
'onbutchange' (index) {
|
|
1365
|
-
|
|
1366
|
-
},
|
|
1367
|
-
'onbutblur' (index) {
|
|
1368
|
-
|
|
1369
|
-
},
|
|
1370
|
-
'onbutinput' (index) {
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
}
|
|
1374
|
-
},
|
|
1375
|
-
watch: {
|
|
1376
|
-
}
|
|
1377
|
-
}
|
|
1378
|
-
</script>
|
|
1379
|
-
<style scoped>
|
|
1380
|
-
/*清除model中的浮动*/
|
|
1381
|
-
.clearfix:after,.clearfix:before{
|
|
1382
|
-
display: table;
|
|
1383
|
-
}
|
|
1384
|
-
.clearfix:after{
|
|
1385
|
-
clear: both;
|
|
1386
|
-
}
|
|
1387
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div class="" v-if="showview">
|
|
3
|
+
<show-back-reason :selectdata="show_data"></show-back-reason>
|
|
4
|
+
<service-view v-ref:serviceview :data="show_data"></service-view>
|
|
5
|
+
</div>
|
|
6
|
+
</template>
|
|
7
|
+
<script>
|
|
8
|
+
import Vue from 'vue'
|
|
9
|
+
import {HttpResetClass} from 'vue-client'
|
|
10
|
+
import {isEmpty} from "../../../components/Util";
|
|
11
|
+
|
|
12
|
+
// Date格式化
|
|
13
|
+
Date.prototype.Format = function (fmt) {
|
|
14
|
+
var o = {
|
|
15
|
+
"M+": this.getMonth() + 1, //月份
|
|
16
|
+
"d+": this.getDate(), //日
|
|
17
|
+
"H+": this.getHours(), //小时
|
|
18
|
+
"m+": this.getMinutes(), //分
|
|
19
|
+
"s+": this.getSeconds(), //秒
|
|
20
|
+
"q+": Math.floor((this.getMonth() + 3) / 3), //季度
|
|
21
|
+
"S": this.getMilliseconds() //毫秒
|
|
22
|
+
};
|
|
23
|
+
if (/(y+)/.test(fmt)) fmt = fmt.replace(RegExp.$1, (this.getFullYear() + "").substr(4 - RegExp.$1.length));
|
|
24
|
+
for (var k in o)
|
|
25
|
+
if (new RegExp("(" + k + ")").test(fmt)) fmt = fmt.replace(RegExp.$1, (RegExp.$1.length == 1) ? (o[k]) : (("00" + o[k]).substr(("" + o[k]).length)));
|
|
26
|
+
return fmt;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export default {
|
|
30
|
+
title: '报建流程业务控制层',
|
|
31
|
+
props: ['selectdata'],
|
|
32
|
+
data () {
|
|
33
|
+
return {
|
|
34
|
+
data: null, // 数据库数据,json配置文件数据的数据集合
|
|
35
|
+
json_datas: null, // Json配置文件集合
|
|
36
|
+
showview: false, // 控制显示service-view组件
|
|
37
|
+
show_data: null, // 给view层显示的数据
|
|
38
|
+
config: {},
|
|
39
|
+
Pricetype:''
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
ready () {
|
|
43
|
+
this.refurbish()
|
|
44
|
+
},
|
|
45
|
+
methods: {
|
|
46
|
+
//将千分位金额转换为数字
|
|
47
|
+
parseCurrency(str) {
|
|
48
|
+
if(typeof str == 'string'){
|
|
49
|
+
return parseFloat(str.replace(/,/g, ''))
|
|
50
|
+
}
|
|
51
|
+
// 用正则表达式移除千分位分隔符,并转换为数字
|
|
52
|
+
return str
|
|
53
|
+
},
|
|
54
|
+
//将金额转换为千分位
|
|
55
|
+
formatCurrency(number, decimalPlaces) {
|
|
56
|
+
var num = parseFloat(number);
|
|
57
|
+
if (!isNaN(num)) {
|
|
58
|
+
num = num.toFixed(decimalPlaces || 0); // 将金额保留指定位数,四舍五入
|
|
59
|
+
num = num.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ","); // 按照千分位进行分隔
|
|
60
|
+
return num;
|
|
61
|
+
} else {
|
|
62
|
+
return ''; // 如果输入框中的值不是数字,则返回空字符串
|
|
63
|
+
}
|
|
64
|
+
},
|
|
65
|
+
// 组件初始化操作
|
|
66
|
+
async refurbish() {
|
|
67
|
+
this.json_datas = this.$workflow_vue
|
|
68
|
+
let sum = 0
|
|
69
|
+
let jsonData = {}
|
|
70
|
+
if (!this.json_datas || !this.json_datas.activitys || this.json_datas.activitys.length === 0) {
|
|
71
|
+
this.$showMessage("网络故障,请刷新页面")
|
|
72
|
+
return
|
|
73
|
+
}
|
|
74
|
+
this.json_datas.activitys.forEach(item => {
|
|
75
|
+
if (this.selectdata.defname === item.title) {
|
|
76
|
+
jsonData = item // 拿到当前节点的json配置信息
|
|
77
|
+
sum++ // 节点名一样的个数
|
|
78
|
+
}
|
|
79
|
+
return this.selectdata.defname === item.title // 拿到当前节点的json配置信息
|
|
80
|
+
})
|
|
81
|
+
|
|
82
|
+
if (sum === 0) {
|
|
83
|
+
this.$showMessage(`没有在JSON配置文件中找到活动名为:(${this.selectdata.defname})的节点配置`)
|
|
84
|
+
return
|
|
85
|
+
}
|
|
86
|
+
if (sum > 1) {
|
|
87
|
+
this.$showMessage(`在JSON配置文件中找到活动名为:(${this.selectdata.defname})的节点配置:${sum}个`)
|
|
88
|
+
return
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
this.selectdata = Object.assign({}, this.selectdata, jsonData)
|
|
92
|
+
|
|
93
|
+
// fields 字段填充值
|
|
94
|
+
for (const item of this.selectdata.fields) {
|
|
95
|
+
if (!item.value) {
|
|
96
|
+
item.value = null
|
|
97
|
+
}
|
|
98
|
+
// 如果配置类型为select,优先从参数列表获取options
|
|
99
|
+
if (item.type === 'select' || item.type === 'checkbox') {
|
|
100
|
+
if (item.param) {
|
|
101
|
+
let temp = this.$appdata.getParam(item.label)
|
|
102
|
+
|
|
103
|
+
if (temp && temp.length > 0) {
|
|
104
|
+
item.options = temp
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
if (item.paramLabel) {
|
|
108
|
+
temp = this.$appdata.getParam(item.paramLabel)
|
|
109
|
+
if (temp && temp.length > 0) {
|
|
110
|
+
item.options = temp
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
if (item.ready) {
|
|
116
|
+
console.log(item.ready)
|
|
117
|
+
item.options = await this[item.ready]()
|
|
118
|
+
|
|
119
|
+
}
|
|
120
|
+
if (!isEmpty(item.role)){
|
|
121
|
+
console.log('获取对应角色的人员信息',item.role)
|
|
122
|
+
item.options = await this.getDesignerPeople(item.role)
|
|
123
|
+
}
|
|
124
|
+
if (item.multiple && !isEmpty(this.selectdata[item.field])){
|
|
125
|
+
this.selectdata[item.field] = JSON.parse(this.selectdata[item.field])
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
if (!item.value && (item.default || item.default === 0) && item.type !== 'datepicker') {
|
|
129
|
+
if (item.eval) {
|
|
130
|
+
item.value = eval(item.default)
|
|
131
|
+
} else {
|
|
132
|
+
item.value = item.default
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
if (this.selectdata[item.field]) {
|
|
137
|
+
// 将json字符串格式化赋值给value
|
|
138
|
+
if (String(this.selectdata[item.field]).startsWith("{")) {
|
|
139
|
+
item.value = JSON.parse(this.selectdata[item.field])
|
|
140
|
+
} else {
|
|
141
|
+
item.value = this.selectdata[item.field]
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
if (this.selectdata[item.field] === 0) {
|
|
145
|
+
item.value = 0
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
// datepicker
|
|
149
|
+
if (item.type === 'datepicker' && !item.value && item.default) {
|
|
150
|
+
item.value = new Date().Format(`${item.format ? item.format : 'yyyy-MM-dd HH:mm:ss'}`)
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
if (item.type === 'checkbox') {
|
|
154
|
+
if (this.selectdata[item.field]) {
|
|
155
|
+
item.value = JSON.parse(this.selectdata[item.field])
|
|
156
|
+
} else {
|
|
157
|
+
item.value = []
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
//金额千分位
|
|
161
|
+
if (item.percentiles) {
|
|
162
|
+
let amount = item.value
|
|
163
|
+
if (amount > 0) {
|
|
164
|
+
let amounts = this.formatCurrency(amount, 2)
|
|
165
|
+
console.log('金额千分位', amounts)
|
|
166
|
+
item.value = amounts
|
|
167
|
+
console.log('金额千分位1', item.value)
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
this.selectdata[item.field] = item.value
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
// 控制组件
|
|
174
|
+
if (this.selectdata.components) {
|
|
175
|
+
this.selectdata.components.forEach(item => {
|
|
176
|
+
if (!item.mark) {
|
|
177
|
+
item.mark = 0
|
|
178
|
+
}
|
|
179
|
+
})
|
|
180
|
+
}
|
|
181
|
+
// 初始化onetomany
|
|
182
|
+
if (this.selectdata.onetomany) {
|
|
183
|
+
for (const item of this.selectdata.onetomany) {
|
|
184
|
+
let res = null
|
|
185
|
+
if (item.queryEvent) {
|
|
186
|
+
res = this[item.queryEvent]()
|
|
187
|
+
} else {
|
|
188
|
+
let data = {
|
|
189
|
+
tablename: item.tables[0],
|
|
190
|
+
condition: `f_process_id='${this.selectdata.f_process_id}'`
|
|
191
|
+
}
|
|
192
|
+
res = await this.$resetpost(
|
|
193
|
+
'rs/sql/apply_singleTable',
|
|
194
|
+
{data: data},
|
|
195
|
+
{resolveMsg: null, rejectMsg: 'onetomany查询失败'}
|
|
196
|
+
)
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
item.rows = res.data
|
|
200
|
+
|
|
201
|
+
// 初始化onetomany中的fields
|
|
202
|
+
for (const field of item.fields) {
|
|
203
|
+
if (!field.value) {
|
|
204
|
+
if (field.value !== 0) {
|
|
205
|
+
field.value = null
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
if (field.default || field.default === 0) {
|
|
210
|
+
field.value = field.default
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
// datepicker
|
|
214
|
+
if (field.type === 'datepicker' && !field.value && field.default) {
|
|
215
|
+
field.value = new Date().Format(`${field.format ? field.format : 'yyyy-MM-dd HH:mm:ss'}`)
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
if (field.type === 'select') {
|
|
219
|
+
|
|
220
|
+
let temp = this.$appdata.getParam(field.label)
|
|
221
|
+
|
|
222
|
+
if (temp && temp.length > 0) {
|
|
223
|
+
field.options = temp
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
if (field.paramLabel) {
|
|
227
|
+
temp = this.$appdata.getParam(field.paramLabel)
|
|
228
|
+
if (temp && temp.length > 0) {
|
|
229
|
+
item.options = temp
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
// 初始化 buttons_fields
|
|
237
|
+
for (const item of this.selectdata.buttons) {
|
|
238
|
+
if (item.button_name === '下发') {
|
|
239
|
+
|
|
240
|
+
let data = {
|
|
241
|
+
source: item.source,
|
|
242
|
+
userid: this.$login.f.id
|
|
243
|
+
}
|
|
244
|
+
if (item.sourceMethod) {
|
|
245
|
+
data.source = this[item.sourceMethod]()
|
|
246
|
+
}
|
|
247
|
+
if (!data.source) {
|
|
248
|
+
this.$showMessage("请配置获取人员表达式")
|
|
249
|
+
return
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
let res = await this.$resetpost(
|
|
253
|
+
'rs/search',
|
|
254
|
+
{data: data},
|
|
255
|
+
{resolveMsg: null, rejectMsg: '下发人员查询失败!!!'}
|
|
256
|
+
)
|
|
257
|
+
|
|
258
|
+
let options = res.data.map(source => {
|
|
259
|
+
return {
|
|
260
|
+
"label": source.name,
|
|
261
|
+
"value": source.id
|
|
262
|
+
}
|
|
263
|
+
}).sort((a,b)=>a.label.localeCompare(b.label, 'zh-Hans-CN'))
|
|
264
|
+
if (item.button_fields.length !== 1) {
|
|
265
|
+
this.$showMessage("下发有且只能有一个字段!!!")
|
|
266
|
+
return
|
|
267
|
+
}
|
|
268
|
+
item.button_fields[0].options = options
|
|
269
|
+
}
|
|
270
|
+
if (item.button_fields) {
|
|
271
|
+
item.button_fields.forEach(x => {
|
|
272
|
+
// 如果配置类型为select,优先从参数列表获取options
|
|
273
|
+
if (x.type === 'select') {
|
|
274
|
+
|
|
275
|
+
if (x.param) {
|
|
276
|
+
let temp = this.$appdata.getParam(x.label)
|
|
277
|
+
|
|
278
|
+
if (temp && temp.length > 0) {
|
|
279
|
+
x.options = temp
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
if (x.paramLabel) {
|
|
283
|
+
temp = this.$appdata.getParam(x.paramLabel)
|
|
284
|
+
if (temp && temp.length > 0) {
|
|
285
|
+
x.options = temp
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
}
|
|
291
|
+
})
|
|
292
|
+
}
|
|
293
|
+
}
|
|
294
|
+
// 消除双向绑定,避免子组件(显示层)数据更改,父组件(控制层)也更改
|
|
295
|
+
let temp = JSON.parse(JSON.stringify(this.selectdata))
|
|
296
|
+
console.log('打印下temp',temp)
|
|
297
|
+
this.show_data = temp
|
|
298
|
+
for (const item of this.show_data.fields) {
|
|
299
|
+
if(item.label=='气价名称' && !isEmpty(this.show_data.f_price_name)){
|
|
300
|
+
if(item.label==='气价名称'){
|
|
301
|
+
item.value=this.show_data.f_price_name
|
|
302
|
+
}
|
|
303
|
+
}
|
|
304
|
+
if (this.show_data.f_apply_source === '线下发起' && (item.label === '预约地址' || item.label === '预约单号')) {
|
|
305
|
+
item.hidden = true
|
|
306
|
+
}
|
|
307
|
+
}
|
|
308
|
+
if (this.show_data.f_apply_type == '居民团体用户报建' ){
|
|
309
|
+
if (this.show_data.f_apply_nature == '整体小区'){
|
|
310
|
+
this.showLabels('楼房总户数')
|
|
311
|
+
this.showLabels('楼房总栋数')
|
|
312
|
+
this.showLabels('别墅总户数')
|
|
313
|
+
this.hideLabels('总户数')
|
|
314
|
+
}
|
|
315
|
+
if (this.show_data.f_apply_nature == '整体村庄'){
|
|
316
|
+
this.showLabels('总户数')
|
|
317
|
+
this.hideLabels('楼房总户数')
|
|
318
|
+
this.hideLabels('楼房总栋数')
|
|
319
|
+
this.hideLabels('别墅总户数')
|
|
320
|
+
}
|
|
321
|
+
}
|
|
322
|
+
if (this.show_data.defname == '市场部审核' || this.show_data.defname == '财务审核'){
|
|
323
|
+
let f_due_money = this.parseCurrency(this.show_data.f_due_money)
|
|
324
|
+
let f_cumulative_payment_money = this.parseCurrency(this.show_data.f_due_money)
|
|
325
|
+
let f_surplus_money = this.parseCurrency(this.show_data.f_surplus_money)
|
|
326
|
+
if (Number(f_due_money) > Number(f_cumulative_payment_money) || Number(f_surplus_money) > 0) {
|
|
327
|
+
this.$showAlert('费用未结清!!!', 'warning', 3000)
|
|
328
|
+
}
|
|
329
|
+
}
|
|
330
|
+
this.$nextTick(() => {
|
|
331
|
+
this.showview = true
|
|
332
|
+
})
|
|
333
|
+
},
|
|
334
|
+
// 金额转大写
|
|
335
|
+
smalltoBIG(n) {
|
|
336
|
+
let fraction = ['角', '分'];
|
|
337
|
+
let digit = ['零', '壹', '贰', '叁', '肆', '伍', '陆', '柒', '捌', '玖'];
|
|
338
|
+
let unit = [['元', '万', '亿'], ['', '拾', '佰', '仟']];
|
|
339
|
+
let head = n < 0 ? '欠' : '';
|
|
340
|
+
n = Math.abs(n);
|
|
341
|
+
|
|
342
|
+
let s = '';
|
|
343
|
+
|
|
344
|
+
for (var i = 0; i < fraction.length; i++) {
|
|
345
|
+
s += (digit[Math.floor(n * 10 * Math.pow(10, i)) % 10] + fraction[i]).replace(/零./, '');
|
|
346
|
+
}
|
|
347
|
+
s = s || '整';
|
|
348
|
+
n = Math.floor(n);
|
|
349
|
+
|
|
350
|
+
for (var i = 0; i < unit[0].length && n > 0; i++) {
|
|
351
|
+
let p = '';
|
|
352
|
+
for (var j = 0; j < unit[1].length && n > 0; j++) {
|
|
353
|
+
p = digit[n % 10] + unit[1][j] + p;
|
|
354
|
+
n = Math.floor(n / 10);
|
|
355
|
+
}
|
|
356
|
+
s = p.replace(/(零.)*零$/, '').replace(/^$/, '零') + unit[0][i] + s;
|
|
357
|
+
}
|
|
358
|
+
return head + s.replace(/(零.)*零元/, '元').replace(/(零.)+/g, '零').replace(/^整$/, '零元整')
|
|
359
|
+
},
|
|
360
|
+
// 获取对应label的值
|
|
361
|
+
getLableValue(label) {
|
|
362
|
+
for (const item of this.show_data.fields) {
|
|
363
|
+
if (item.label === label && item.type !== 'number') {
|
|
364
|
+
return item.value || ''
|
|
365
|
+
}
|
|
366
|
+
if (item.label === label && item.type === 'number') {
|
|
367
|
+
return item.value || 0
|
|
368
|
+
}
|
|
369
|
+
}
|
|
370
|
+
},
|
|
371
|
+
// 获取对应label中options的值
|
|
372
|
+
getLableOptions(label) {
|
|
373
|
+
for (const item of this.show_data.fields) {
|
|
374
|
+
if (item.label === label) {
|
|
375
|
+
return item.options
|
|
376
|
+
}
|
|
377
|
+
}
|
|
378
|
+
},
|
|
379
|
+
// 给对应label放置value值
|
|
380
|
+
setLabelValue(label, value) {
|
|
381
|
+
for (const item of this.show_data.fields) {
|
|
382
|
+
if (item.label === label) {
|
|
383
|
+
item.value = value
|
|
384
|
+
this.show_data[item.field] = value
|
|
385
|
+
}
|
|
386
|
+
}
|
|
387
|
+
},
|
|
388
|
+
// 给对应label的options放置value值
|
|
389
|
+
setLabelOptions(label, options) {
|
|
390
|
+
for (const item of this.show_data.fields) {
|
|
391
|
+
if (item.label === label) {
|
|
392
|
+
item.options = options
|
|
393
|
+
}
|
|
394
|
+
}
|
|
395
|
+
},
|
|
396
|
+
// 显示包含labels的文本
|
|
397
|
+
showLabels(...labels) {
|
|
398
|
+
for (const item of this.show_data.fields) {
|
|
399
|
+
if (labels.includes(item.label)) {
|
|
400
|
+
item.hidden = false
|
|
401
|
+
}
|
|
402
|
+
}
|
|
403
|
+
},
|
|
404
|
+
// 隐藏包含labels的文本
|
|
405
|
+
hideLabels(...labels) {
|
|
406
|
+
for (const item of this.show_data.fields) {
|
|
407
|
+
if (labels.includes(item.label)) {
|
|
408
|
+
item.hidden = true
|
|
409
|
+
}
|
|
410
|
+
}
|
|
411
|
+
},
|
|
412
|
+
// 给对应labels的值设置为必填
|
|
413
|
+
requiredLabels(...labels) {
|
|
414
|
+
for (const item of this.show_data.fields) {
|
|
415
|
+
if (labels.includes(item.label)) {
|
|
416
|
+
item.required = true
|
|
417
|
+
}
|
|
418
|
+
}
|
|
419
|
+
},
|
|
420
|
+
// 给对应labels的值设置为不必填
|
|
421
|
+
electiveLabels(...labels) {
|
|
422
|
+
for (const item of this.show_data.fields) {
|
|
423
|
+
if (labels.includes(item.label)) {
|
|
424
|
+
item.required = false
|
|
425
|
+
}
|
|
426
|
+
}
|
|
427
|
+
},
|
|
428
|
+
// 给对应labels的值设置为只读和禁用
|
|
429
|
+
readonlyLabels(...labels) {
|
|
430
|
+
for (const item of this.show_data.fields) {
|
|
431
|
+
if (labels.includes(item.label)) {
|
|
432
|
+
item.readonly = true
|
|
433
|
+
item.disabled = true
|
|
434
|
+
}
|
|
435
|
+
}
|
|
436
|
+
},
|
|
437
|
+
// 给对应labels的值设置为不只读和不禁用
|
|
438
|
+
readwriteLabels(...labels) {
|
|
439
|
+
for (const item of this.show_data.fields) {
|
|
440
|
+
if (labels.includes(item.label)) {
|
|
441
|
+
item.readonly = false
|
|
442
|
+
item.disabled = false
|
|
443
|
+
}
|
|
444
|
+
}
|
|
445
|
+
},
|
|
446
|
+
// 给对应labels的值设置为禁用
|
|
447
|
+
disabledButtons(...buttons) {
|
|
448
|
+
for (const item of this.show_data.buttons) {
|
|
449
|
+
if (buttons.includes(item.button_name)) {
|
|
450
|
+
item.disabled = true
|
|
451
|
+
}
|
|
452
|
+
}
|
|
453
|
+
},
|
|
454
|
+
// 给对应labels的值设置为不禁用
|
|
455
|
+
enableButtons(...buttons) {
|
|
456
|
+
for (const item of this.show_data.buttons) {
|
|
457
|
+
if (buttons.includes(item.button_name)) {
|
|
458
|
+
item.disabled = false
|
|
459
|
+
}
|
|
460
|
+
}
|
|
461
|
+
},
|
|
462
|
+
// 显示对应按钮
|
|
463
|
+
showButtons(...buttons) {
|
|
464
|
+
for (const item of this.show_data.buttons) {
|
|
465
|
+
if (buttons.includes(item.button_name)) {
|
|
466
|
+
item.hidden = false
|
|
467
|
+
}
|
|
468
|
+
}
|
|
469
|
+
},
|
|
470
|
+
// 隐藏对应按钮
|
|
471
|
+
hideButtons(...buttons) {
|
|
472
|
+
for (const item of this.show_data.buttons) {
|
|
473
|
+
if (buttons.includes(item.button_name)) {
|
|
474
|
+
item.hidden = true
|
|
475
|
+
}
|
|
476
|
+
}
|
|
477
|
+
},
|
|
478
|
+
// 检查t_apply对应字段的值是否重复
|
|
479
|
+
async checkDuplicate(index) {
|
|
480
|
+
let http = new HttpResetClass()
|
|
481
|
+
let data = {
|
|
482
|
+
tablename: 't_apply',
|
|
483
|
+
condition: `${this.show_data.fields[index].field} = '${this.show_data.fields[index].value}'`
|
|
484
|
+
}
|
|
485
|
+
let res = await http.load('POST', 'rs/sql/apply_singleTable', {data: data}, {
|
|
486
|
+
resolveMsg: null,
|
|
487
|
+
rejectMsg: `${this.show_data.fields[index].label}查询失败`
|
|
488
|
+
})
|
|
489
|
+
if (res.data.length > 0) {
|
|
490
|
+
this.show_data.fields[index].value = null
|
|
491
|
+
this.$showAlert(`${this.show_data.fields[index].label}已存在!!!`, 'warning', 3000)
|
|
492
|
+
}
|
|
493
|
+
},
|
|
494
|
+
// 获取片区
|
|
495
|
+
async getSliceArea () {
|
|
496
|
+
let data = {
|
|
497
|
+
source: 'this.getParentByType($organization$).getAllChildrens().where(row.getType() == $zone$)',
|
|
498
|
+
userid: this.$login.f.id
|
|
499
|
+
}
|
|
500
|
+
|
|
501
|
+
let http = new HttpResetClass()
|
|
502
|
+
let res = await http.load(
|
|
503
|
+
'POST',
|
|
504
|
+
`rs/search`,
|
|
505
|
+
{data: data},
|
|
506
|
+
{resolveMsg: null, rejectMsg: '片区查询失败!!!'}
|
|
507
|
+
)
|
|
508
|
+
|
|
509
|
+
return res.data.map(item => {
|
|
510
|
+
return {
|
|
511
|
+
label: item.name,
|
|
512
|
+
value: item.name
|
|
513
|
+
}
|
|
514
|
+
})
|
|
515
|
+
},
|
|
516
|
+
// 获取区县
|
|
517
|
+
async getPcd () {
|
|
518
|
+
let data = {
|
|
519
|
+
tablename: 't_pcd',
|
|
520
|
+
condition: `f_filialeid = '${this.$login.f.orgid}'`
|
|
521
|
+
}
|
|
522
|
+
let http = new HttpResetClass()
|
|
523
|
+
let res = await http.load(
|
|
524
|
+
'POST',
|
|
525
|
+
`rs/sql/apply_singleTable`,
|
|
526
|
+
{data: data},
|
|
527
|
+
{resolveMsg: null, rejectMsg: '区县查询失败!!!'}
|
|
528
|
+
)
|
|
529
|
+
|
|
530
|
+
return res.data.map(item => {
|
|
531
|
+
return {
|
|
532
|
+
label: item.f_pcd,
|
|
533
|
+
value: item.f_pcd
|
|
534
|
+
}
|
|
535
|
+
})
|
|
536
|
+
},
|
|
537
|
+
// 获取小区
|
|
538
|
+
async getArea () {
|
|
539
|
+
let data = {
|
|
540
|
+
tablename: 't_area',
|
|
541
|
+
condition: `f_filialeid = '${this.$login.f.orgid}'`
|
|
542
|
+
}
|
|
543
|
+
let http = new HttpResetClass()
|
|
544
|
+
let res = await http.load(
|
|
545
|
+
'POST',
|
|
546
|
+
`rs/sql/apply_singleTable`,
|
|
547
|
+
{data: data},
|
|
548
|
+
{resolveMsg: null, rejectMsg: '小区查询失败!!!'}
|
|
549
|
+
)
|
|
550
|
+
|
|
551
|
+
return res.data.map(item => {
|
|
552
|
+
return {
|
|
553
|
+
label: item.f_residential_area,
|
|
554
|
+
value: item.f_residential_area
|
|
555
|
+
}
|
|
556
|
+
})
|
|
557
|
+
},
|
|
558
|
+
// 缴费前置
|
|
559
|
+
chargeBefore () {
|
|
560
|
+
if (Number(this.show_data.f_due_money) > Number(this.show_data.f_cumulative_payment_money) || Number(this.show_data.f_surplus_money) > 0) {
|
|
561
|
+
this.$showAlert('费用未结清!!!', 'warning', 3000)
|
|
562
|
+
throw null
|
|
563
|
+
}
|
|
564
|
+
},
|
|
565
|
+
// 附件上传必传
|
|
566
|
+
async uploadBefore () {
|
|
567
|
+
let condition = `f_blobid= '${this.selectdata.f_process_id}' `
|
|
568
|
+
let http = new HttpResetClass()
|
|
569
|
+
let data = {
|
|
570
|
+
tablename: 't_files',
|
|
571
|
+
condition: condition + ` order by f_uploaddate desc `
|
|
572
|
+
}
|
|
573
|
+
let res = await http.load('POST', 'rs/sql/apply_singleTable', {data: data}, {
|
|
574
|
+
warnMsg: null,
|
|
575
|
+
resolveMsg: null
|
|
576
|
+
})
|
|
577
|
+
if (res.data.length = 0) {
|
|
578
|
+
this.$showAlert('请上传附件!!!', 'warning', 3000)
|
|
579
|
+
throw null
|
|
580
|
+
}
|
|
581
|
+
},
|
|
582
|
+
// 施工前置 加表具后状态是待开通 提交后是正常 所以这里的判断条件需改正 (and uf.f_meter_classify is null and f_meternumber is null)
|
|
583
|
+
async constructionBefore () {
|
|
584
|
+
let http = new HttpResetClass()
|
|
585
|
+
let data = {
|
|
586
|
+
condition: `ui.f_process_id = '${this.show_data.f_process_id}' and uf.f_meter_classify is null and f_meternumber is null`
|
|
587
|
+
}
|
|
588
|
+
let res = await http.load(
|
|
589
|
+
'POST',
|
|
590
|
+
'rs/sql/countApplyUserinfo',
|
|
591
|
+
{data: data},
|
|
592
|
+
{
|
|
593
|
+
resolveMsg: null,
|
|
594
|
+
rejectMsg: '安装明细查询失败!!!'
|
|
595
|
+
})
|
|
596
|
+
if (res.data[0].num > 0) {
|
|
597
|
+
this.$showAlert(`还有${res.data[0].num}户未安装,无法提交`, 'warning', 3000)
|
|
598
|
+
throw `还有${res.data[0].num}户未安装,无法提交`
|
|
599
|
+
}
|
|
600
|
+
},
|
|
601
|
+
// 获取对应气价id的数组
|
|
602
|
+
async getPrice (f_price_id) {
|
|
603
|
+
console.log('=======================')
|
|
604
|
+
console.log(f_price_id)
|
|
605
|
+
let data = {
|
|
606
|
+
condition: `sp.f_filialeid = '${this.$login.f.orgid}'`
|
|
607
|
+
}
|
|
608
|
+
if (!isEmpty(f_price_id)) {
|
|
609
|
+
data.condition = `sp.f_filialeid = '${this.$login.f.orgid}' and sp.f_price_id = ${f_price_id}`
|
|
610
|
+
}
|
|
611
|
+
let http = new HttpResetClass()
|
|
612
|
+
let res = await http.load(
|
|
613
|
+
'POST',
|
|
614
|
+
`rs/sql/applyGetPrice`,
|
|
615
|
+
{data: data},
|
|
616
|
+
{resolveMsg: null, rejectMsg: '气价查询失败!!!'}
|
|
617
|
+
)
|
|
618
|
+
|
|
619
|
+
let a= res.data.map(item => {
|
|
620
|
+
return {
|
|
621
|
+
label: item.f_price_name,
|
|
622
|
+
value: item
|
|
623
|
+
}
|
|
624
|
+
})
|
|
625
|
+
this.selectdata.fields.forEach(field => {
|
|
626
|
+
if (field.label === '气价名称') {
|
|
627
|
+
field.options = a}
|
|
628
|
+
})
|
|
629
|
+
return a
|
|
630
|
+
},
|
|
631
|
+
// 地址操作
|
|
632
|
+
addressInitialization () {
|
|
633
|
+
this.$getConfig(this, 'UserAddress')
|
|
634
|
+
|
|
635
|
+
},
|
|
636
|
+
// 街道发生改变,获取对应街道下的小区
|
|
637
|
+
async streetChange () {
|
|
638
|
+
if (isEmpty(this.show_data.f_street)) {
|
|
639
|
+
return
|
|
640
|
+
}
|
|
641
|
+
|
|
642
|
+
let data = {
|
|
643
|
+
tablename: 't_area',
|
|
644
|
+
condition: `f_filialeid = '${this.$login.f.orgid}' and f_street = '${this.show_data.f_street}'`
|
|
645
|
+
}
|
|
646
|
+
let http = new HttpResetClass()
|
|
647
|
+
let res = await http.load(
|
|
648
|
+
'POST',
|
|
649
|
+
`rs/sql/apply_singleTable`,
|
|
650
|
+
{data: data},
|
|
651
|
+
{resolveMsg: null, rejectMsg: '小区查询失败!!!'}
|
|
652
|
+
)
|
|
653
|
+
|
|
654
|
+
this.setLabelOptions('小区', res.data.map(item => {
|
|
655
|
+
return {
|
|
656
|
+
label: item.f_residential_area,
|
|
657
|
+
value: item.f_residential_area
|
|
658
|
+
}
|
|
659
|
+
}))
|
|
660
|
+
},
|
|
661
|
+
async searchbuilding () {
|
|
662
|
+
if (isEmpty(this.show_data.f_residential_area)) {
|
|
663
|
+
return
|
|
664
|
+
}
|
|
665
|
+
let data = {
|
|
666
|
+
tablename: 't_building',
|
|
667
|
+
condition: `f_filialeid = '${this.$login.f.orgid}' and f_residential_area like '%${this.show_data.f_residential_area}%'`
|
|
668
|
+
}
|
|
669
|
+
let http = new HttpResetClass()
|
|
670
|
+
let res = await http.load(
|
|
671
|
+
'POST',
|
|
672
|
+
`rs/sql/apply_singleTable`,
|
|
673
|
+
{data: data},
|
|
674
|
+
{resolveMsg: null, rejectMsg: '楼号查询失败!!!'}
|
|
675
|
+
)
|
|
676
|
+
|
|
677
|
+
if (res.data.length === 0) {
|
|
678
|
+
return
|
|
679
|
+
}
|
|
680
|
+
|
|
681
|
+
this.setLabelOptions('楼号/组', res.data.map(item => {
|
|
682
|
+
return {
|
|
683
|
+
label: item.f_building,
|
|
684
|
+
value: item.f_building
|
|
685
|
+
}
|
|
686
|
+
}))
|
|
687
|
+
},
|
|
688
|
+
// 地址类型发生改变,获取对应的街道/乡镇
|
|
689
|
+
async pcdChange () {
|
|
690
|
+
if (isEmpty(this.show_data.f_pcd)) {
|
|
691
|
+
return
|
|
692
|
+
}
|
|
693
|
+
|
|
694
|
+
let data = {
|
|
695
|
+
tablename: 't_street',
|
|
696
|
+
condition: `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}'`
|
|
697
|
+
}
|
|
698
|
+
|
|
699
|
+
let http = new HttpResetClass()
|
|
700
|
+
let res = await http.load(
|
|
701
|
+
'POST',
|
|
702
|
+
`rs/sql/apply_singleTable`,
|
|
703
|
+
{data: data},
|
|
704
|
+
{resolveMsg: null, rejectMsg: '街道/乡镇查询失败!!!'}
|
|
705
|
+
)
|
|
706
|
+
|
|
707
|
+
this.setLabelOptions('街道/乡镇', res.data.map(item => {
|
|
708
|
+
return {
|
|
709
|
+
label: item.f_street,
|
|
710
|
+
value: item.f_street
|
|
711
|
+
}
|
|
712
|
+
}))
|
|
713
|
+
},
|
|
714
|
+
// 获取当前分公司下拥有role角色的人员
|
|
715
|
+
async getDesignerPeople (role) {
|
|
716
|
+
let data = {
|
|
717
|
+
source: 'this.getParentByType($organization$).getChildByName($'+role+"$).getChildren()",
|
|
718
|
+
userid: this.$login.f.id
|
|
719
|
+
}
|
|
720
|
+
|
|
721
|
+
let http = new HttpResetClass()
|
|
722
|
+
let res = await http.load(
|
|
723
|
+
'POST',
|
|
724
|
+
`rs/search`,
|
|
725
|
+
{data: data},
|
|
726
|
+
{resolveMsg: null, rejectMsg: '人员查询失败!!!'}
|
|
727
|
+
)
|
|
728
|
+
|
|
729
|
+
return res.data.map(item => {
|
|
730
|
+
return {
|
|
731
|
+
label: item.name,
|
|
732
|
+
value: item.name
|
|
733
|
+
}
|
|
734
|
+
})
|
|
735
|
+
},
|
|
736
|
+
// 终止报建 reason--终止原因
|
|
737
|
+
async surveyStopApply (reason) {
|
|
738
|
+
console.log('终止报建!!!!!')
|
|
739
|
+
|
|
740
|
+
this.show_data.f_stop_reason = reason
|
|
741
|
+
|
|
742
|
+
let data = {
|
|
743
|
+
data: this.show_data,
|
|
744
|
+
user: this.$login.f
|
|
745
|
+
}
|
|
746
|
+
|
|
747
|
+
let res = await this.$resetpost(
|
|
748
|
+
`rs/logic/surveyStopApply`,
|
|
749
|
+
{data: data},
|
|
750
|
+
{resolveMsg: null, rejectMsg: '终止报建失败!!!'}
|
|
751
|
+
)
|
|
752
|
+
|
|
753
|
+
this.$dispatch('loadPage')
|
|
754
|
+
|
|
755
|
+
throw '终止报建!!!'
|
|
756
|
+
},
|
|
757
|
+
|
|
758
|
+
PrefixInteger(num, n) {
|
|
759
|
+
return (Array(n).join(0) + num).slice(-n);
|
|
760
|
+
}
|
|
761
|
+
},
|
|
762
|
+
events: {
|
|
763
|
+
'priceType'(index){
|
|
764
|
+
this.Pricetype = this.getLableValue('所属类型')
|
|
765
|
+
console.log('打印方法值',this.getPrice(this.show_data.f_price_id))
|
|
766
|
+
for (const item of this.show_data.fields) {
|
|
767
|
+
if (this.show_data.f_sprice_type !=null && this.show_data.f_sprice_type !='') {
|
|
768
|
+
if(item.label==='气价名称'){
|
|
769
|
+
this.getPrice().then(value =>{
|
|
770
|
+
item.options=value
|
|
771
|
+
})
|
|
772
|
+
console.log('最终',item.options)
|
|
773
|
+
}
|
|
774
|
+
}
|
|
775
|
+
}
|
|
776
|
+
},
|
|
777
|
+
'complyInstallation' (index) {
|
|
778
|
+
if (this.show_data.f_apply_type == '居民团体用户报建' ){
|
|
779
|
+
if (this.show_data.f_apply_nature == '整体小区'){
|
|
780
|
+
this.showLabels('楼房总户数')
|
|
781
|
+
this.showLabels('楼房总栋数')
|
|
782
|
+
this.showLabels('别墅总户数')
|
|
783
|
+
this.hideLabels('总户数')
|
|
784
|
+
}
|
|
785
|
+
if (this.show_data.f_apply_nature == '整体村庄'){
|
|
786
|
+
this.showLabels('总户数')
|
|
787
|
+
this.hideLabels('楼房总户数')
|
|
788
|
+
this.hideLabels('楼房总栋数')
|
|
789
|
+
this.hideLabels('别墅总户数')
|
|
790
|
+
}
|
|
791
|
+
}
|
|
792
|
+
},
|
|
793
|
+
async 'igniteDispatchReadyEvent' () {
|
|
794
|
+
let data = {
|
|
795
|
+
tablename: 'activityins',
|
|
796
|
+
condition: `processid = '${this.show_data.f_process_id}' and defname = '工程施工' and state = '结束'`
|
|
797
|
+
}
|
|
798
|
+
let http = new HttpResetClass()
|
|
799
|
+
let res = await http.load(
|
|
800
|
+
'POST',
|
|
801
|
+
`rs/sql/apply_singleTable`,
|
|
802
|
+
{data: data},
|
|
803
|
+
{resolveMsg: null, rejectMsg: '查询失败!!!'}
|
|
804
|
+
)
|
|
805
|
+
if (res.data.length <= 0) {
|
|
806
|
+
console.log('+++++++++++++++++++++++++++++')
|
|
807
|
+
console.log('没有施工,不能退回')
|
|
808
|
+
this.hideButtons('退回')
|
|
809
|
+
}
|
|
810
|
+
},
|
|
811
|
+
'buildReadyEvent' () {
|
|
812
|
+
},
|
|
813
|
+
// 选择材料
|
|
814
|
+
async materialNameChenge (index, fieldIndex) {
|
|
815
|
+
let material = this.show_data.onetomany[index].fields[fieldIndex].value
|
|
816
|
+
|
|
817
|
+
this.show_data.onetomany[index].fields.forEach(item => {
|
|
818
|
+
if (material[item.field]) {
|
|
819
|
+
item.value = material[item.field]
|
|
820
|
+
}
|
|
821
|
+
})
|
|
822
|
+
},
|
|
823
|
+
// 打开模态框获取材料
|
|
824
|
+
async 'getMaterialName' (index) {
|
|
825
|
+
let data = {
|
|
826
|
+
condition: `1=1`
|
|
827
|
+
}
|
|
828
|
+
let http = new HttpResetClass()
|
|
829
|
+
let res = await http.load(
|
|
830
|
+
'POST',
|
|
831
|
+
`rs/sql/getStockMaterial`,
|
|
832
|
+
{data: data},
|
|
833
|
+
{resolveMsg: null, rejectMsg: '材料查询失败!!!'}
|
|
834
|
+
)
|
|
835
|
+
|
|
836
|
+
this.show_data.onetomany[index].fields.forEach(field => {
|
|
837
|
+
if (field.label === '选择材料') {
|
|
838
|
+
field.options = res.data.map(item => {
|
|
839
|
+
return {
|
|
840
|
+
'label': `${item.f_material_name}--${item.f_material_style}--${item.f_material_unit}`,
|
|
841
|
+
'value': item
|
|
842
|
+
}
|
|
843
|
+
})
|
|
844
|
+
}
|
|
845
|
+
})
|
|
846
|
+
},
|
|
847
|
+
// 搜索小区
|
|
848
|
+
async 'searchArea' (area, index) {
|
|
849
|
+
let data = {
|
|
850
|
+
tablename: 't_area',
|
|
851
|
+
condition: `f_filialeid = '${this.$login.f.orgid}' and f_street = '${this.show_data.f_street}' and f_residential_area like '%${area}%'`
|
|
852
|
+
}
|
|
853
|
+
let http = new HttpResetClass()
|
|
854
|
+
let res = await http.load(
|
|
855
|
+
'POST',
|
|
856
|
+
`rs/sql/apply_singleTable`,
|
|
857
|
+
{data: data},
|
|
858
|
+
{resolveMsg: null, rejectMsg: '小区查询失败!!!'}
|
|
859
|
+
)
|
|
860
|
+
|
|
861
|
+
if (res.data.length === 0) {
|
|
862
|
+
return
|
|
863
|
+
}
|
|
864
|
+
|
|
865
|
+
this.setLabelOptions('小区', res.data.map(item => {
|
|
866
|
+
return {
|
|
867
|
+
label: item.f_residential_area,
|
|
868
|
+
value: item.f_residential_area
|
|
869
|
+
}
|
|
870
|
+
}))
|
|
871
|
+
},
|
|
872
|
+
// 搜索小区
|
|
873
|
+
async 'searchAreaCollective' (area, index) {
|
|
874
|
+
let data = {
|
|
875
|
+
tablename: 't_area',
|
|
876
|
+
condition: `f_filialeid = '${this.$login.f.orgid}' and f_residential_area like '%${area}%'`
|
|
877
|
+
}
|
|
878
|
+
let http = new HttpResetClass()
|
|
879
|
+
let res = await http.load(
|
|
880
|
+
'POST',
|
|
881
|
+
`rs/sql/apply_singleTable`,
|
|
882
|
+
{data: data},
|
|
883
|
+
{resolveMsg: null, rejectMsg: '小区查询失败!!!'}
|
|
884
|
+
)
|
|
885
|
+
|
|
886
|
+
if (res.data.length === 0) {
|
|
887
|
+
return
|
|
888
|
+
}
|
|
889
|
+
|
|
890
|
+
this.setLabelOptions('小区', res.data.map(item => {
|
|
891
|
+
return {
|
|
892
|
+
label: item.f_residential_area,
|
|
893
|
+
value: item.f_residential_area
|
|
894
|
+
}
|
|
895
|
+
}))
|
|
896
|
+
},
|
|
897
|
+
// 选择气价
|
|
898
|
+
'priceChange' (index) {
|
|
899
|
+
if (isEmpty(this.show_data.stairPrice)) {
|
|
900
|
+
return
|
|
901
|
+
}
|
|
902
|
+
|
|
903
|
+
let stairPrice = this.getLableValue('气价名称')
|
|
904
|
+
|
|
905
|
+
this.setLabelValue('气价类型', stairPrice.f_price_type)
|
|
906
|
+
this.setLabelValue('用气性质', stairPrice.f_gasproperties)
|
|
907
|
+
this.setLabelValue('价格', stairPrice.f_price)
|
|
908
|
+
this.setLabelValue('客户类型', stairPrice.f_user_type)
|
|
909
|
+
this.show_data.f_price_id = stairPrice.id
|
|
910
|
+
this.show_data.f_price_name = stairPrice.f_price_name
|
|
911
|
+
},
|
|
912
|
+
// 退款金额
|
|
913
|
+
'refundMoneyChange' (index) {
|
|
914
|
+
let f_cumulative_payment_money = this.show_data.f_cumulative_payment_money
|
|
915
|
+
let f_refund_money = this.show_data.fields[index].value
|
|
916
|
+
|
|
917
|
+
if (f_refund_money > f_cumulative_payment_money) {
|
|
918
|
+
this.$showAlert('退款金额不能大于累计缴费金额!!!', 'warning', 3000)
|
|
919
|
+
this.show_data.fields[index].value = null
|
|
920
|
+
}
|
|
921
|
+
},
|
|
922
|
+
// 检查重复
|
|
923
|
+
'checkRepeat' (index) {
|
|
924
|
+
this.checkDuplicate(index)
|
|
925
|
+
},
|
|
926
|
+
// 选择报建项目
|
|
927
|
+
'selectApply' (row) {
|
|
928
|
+
this.setLabelValue('工程名称', row.f_entry_name)
|
|
929
|
+
this.setLabelValue('工程编号', row.f_apply_num)
|
|
930
|
+
this.setLabelValue('报建类型', row.f_apply_type)
|
|
931
|
+
this.setLabelValue('客户名称', row.f_user_name)
|
|
932
|
+
this.setLabelValue('客户电话', row.f_phone)
|
|
933
|
+
this.setLabelValue('证件类型', row.f_credentials)
|
|
934
|
+
this.setLabelValue('证件号码', row.f_idnumber)
|
|
935
|
+
this.setLabelValue('地址', row.f_address)
|
|
936
|
+
this.setLabelValue('累计缴费金额', row.f_cumulative_payment_money)
|
|
937
|
+
|
|
938
|
+
this.show_data.parentApply = JSON.parse(JSON.stringify(row))
|
|
939
|
+
|
|
940
|
+
delete row.id
|
|
941
|
+
delete row.actid
|
|
942
|
+
delete row.defid
|
|
943
|
+
delete row.defname
|
|
944
|
+
delete row.version
|
|
945
|
+
delete row.f_apply_num
|
|
946
|
+
delete row.f_sub_state
|
|
947
|
+
delete row.f_apply_type
|
|
948
|
+
delete row.f_process_id
|
|
949
|
+
|
|
950
|
+
this.show_data = Object.assign({}, this.show_data, row)
|
|
951
|
+
|
|
952
|
+
this.show_data.f_parent_process_id = this.show_data.parentApply.f_process_id
|
|
953
|
+
},
|
|
954
|
+
// 是否终止
|
|
955
|
+
'isStopChange' (index) {
|
|
956
|
+
let f_is_stop = this.show_data.f_is_stop
|
|
957
|
+
|
|
958
|
+
for (const item of this.show_data.fields) {
|
|
959
|
+
if (f_is_stop === '是') {
|
|
960
|
+
if (item.label === '终止原因') {
|
|
961
|
+
item.hidden = false
|
|
962
|
+
item.required = true
|
|
963
|
+
}
|
|
964
|
+
} else {
|
|
965
|
+
if (item.label === '终止原因') {
|
|
966
|
+
item.hidden = true
|
|
967
|
+
item.required = false
|
|
968
|
+
}
|
|
969
|
+
}
|
|
970
|
+
}
|
|
971
|
+
},
|
|
972
|
+
// 终止报建初始化
|
|
973
|
+
async 'stopApplyReadyEvent' () {
|
|
974
|
+
|
|
975
|
+
let f_is_stop = this.getLableValue('是否终止')
|
|
976
|
+
|
|
977
|
+
for (const item of this.show_data.fields) {
|
|
978
|
+
if (f_is_stop === '是') {
|
|
979
|
+
if (item.label === '终止原因') {
|
|
980
|
+
item.hidden = false
|
|
981
|
+
item.required = true
|
|
982
|
+
}
|
|
983
|
+
} else {
|
|
984
|
+
if (item.label === '终止原因') {
|
|
985
|
+
item.hidden = true
|
|
986
|
+
item.required = false
|
|
987
|
+
}
|
|
988
|
+
}
|
|
989
|
+
}
|
|
990
|
+
|
|
991
|
+
if (isEmpty(this.show_data.f_parent_process_id)) {
|
|
992
|
+
return
|
|
993
|
+
}
|
|
994
|
+
let data = {
|
|
995
|
+
condition: `f_process_id = '${this.show_data.f_parent_process_id}'`,
|
|
996
|
+
data: {
|
|
997
|
+
id: this.$login.f.id,
|
|
998
|
+
orgid: this.$login.f.orgid
|
|
999
|
+
}
|
|
1000
|
+
}
|
|
1001
|
+
let res = await this.$resetpost(
|
|
1002
|
+
`rs/sql/supervisory`,
|
|
1003
|
+
{data: data},
|
|
1004
|
+
{resolveMsg: null, rejectMsg: '项目查询失败!!!'}
|
|
1005
|
+
)
|
|
1006
|
+
this.show_data.parentApply = res.data[0]
|
|
1007
|
+
},
|
|
1008
|
+
// 选择客户档案信息
|
|
1009
|
+
'selectUserinfo' (row) {
|
|
1010
|
+
this.setLabelValue('客户编号', row.f_userinfo_code)
|
|
1011
|
+
this.setLabelValue('入户证号', row.f_entry_number)
|
|
1012
|
+
this.setLabelValue('客户名称', row.f_user_name)
|
|
1013
|
+
this.setLabelValue('客户电话', row.f_user_phone)
|
|
1014
|
+
this.setLabelValue('证件类型', row.f_credentials)
|
|
1015
|
+
this.setLabelValue('证件号码', row.f_idnumber)
|
|
1016
|
+
this.setLabelValue('地址', row.f_address)
|
|
1017
|
+
|
|
1018
|
+
this.show_data.f_userinfo_id = row.f_userinfo_id
|
|
1019
|
+
this.show_data.f_userinfo_code = row.f_userinfo_code
|
|
1020
|
+
this.show_data.f_entry_number = row.f_enter_number
|
|
1021
|
+
this.show_data.f_pcd = row.f_pcd
|
|
1022
|
+
this.show_data.f_street = row.f_street
|
|
1023
|
+
this.show_data.f_residential_area = row.f_residential_area
|
|
1024
|
+
this.show_data.f_building = row.f_building
|
|
1025
|
+
this.show_data.f_unit = row.f_unit
|
|
1026
|
+
this.show_data.f_floor = row.f_floor
|
|
1027
|
+
this.show_data.f_room = row.f_room
|
|
1028
|
+
this.show_data.f_room_suffix = row.f_room_suffix
|
|
1029
|
+
},
|
|
1030
|
+
// 通气点火初始化
|
|
1031
|
+
async 'gasReadyEvent' () {
|
|
1032
|
+
// 是否有气价信息
|
|
1033
|
+
if (!isEmpty(this.show_data.f_price_id)) {
|
|
1034
|
+
let priceList = await this.getPrice(this.show_data.f_price_id)
|
|
1035
|
+
this.setLabelValue('气价名称', priceList[0].value)
|
|
1036
|
+
}
|
|
1037
|
+
},
|
|
1038
|
+
// 合同金额失去焦点
|
|
1039
|
+
async 'contractMoneyChange' (index) {
|
|
1040
|
+
let data = {
|
|
1041
|
+
operator: '+',
|
|
1042
|
+
num1: this.show_data.f_contract_money || 0,
|
|
1043
|
+
num2: this.getLableValue('追加金额') || 0
|
|
1044
|
+
}
|
|
1045
|
+
let res = await this.$resetpost(
|
|
1046
|
+
`rs/logic/compute`,
|
|
1047
|
+
{data: data},
|
|
1048
|
+
{resolveMsg: null, rejectMsg: '金额计算失败!!!'}
|
|
1049
|
+
)
|
|
1050
|
+
//转成千分位
|
|
1051
|
+
let money= this.formatCurrency(res.data,2)
|
|
1052
|
+
this.setLabelValue('应交金额', money)
|
|
1053
|
+
//合同金额
|
|
1054
|
+
let contract= this.formatCurrency( this.show_data.f_contract_money,2)
|
|
1055
|
+
this.setLabelValue('合同金额', contract)
|
|
1056
|
+
},
|
|
1057
|
+
// 街道失去焦点
|
|
1058
|
+
async 'streetChange' (index) {
|
|
1059
|
+
if (isEmpty(this.show_data.f_street)) {
|
|
1060
|
+
return
|
|
1061
|
+
}
|
|
1062
|
+
|
|
1063
|
+
this.setLabelValue('小区', null)
|
|
1064
|
+
|
|
1065
|
+
let data = {
|
|
1066
|
+
tablename: 't_area',
|
|
1067
|
+
condition: `f_filialeid = '${this.$login.f.orgid}' and f_street = '${this.show_data.f_street}'`
|
|
1068
|
+
}
|
|
1069
|
+
let http = new HttpResetClass()
|
|
1070
|
+
let res = await http.load(
|
|
1071
|
+
'POST',
|
|
1072
|
+
`rs/sql/apply_singleTable`,
|
|
1073
|
+
{data: data},
|
|
1074
|
+
{resolveMsg: null, rejectMsg: '小区查询失败!!!'}
|
|
1075
|
+
)
|
|
1076
|
+
|
|
1077
|
+
this.setLabelOptions('小区', res.data.map(item => {
|
|
1078
|
+
return {
|
|
1079
|
+
label: item.f_residential_area,
|
|
1080
|
+
value: item.f_residential_area
|
|
1081
|
+
}
|
|
1082
|
+
}))
|
|
1083
|
+
},
|
|
1084
|
+
// 区县失去焦点
|
|
1085
|
+
async 'pcdChange' (index) {
|
|
1086
|
+
if (isEmpty(this.show_data.f_pcd)) {
|
|
1087
|
+
return
|
|
1088
|
+
}
|
|
1089
|
+
|
|
1090
|
+
this.setLabelValue('街道/乡镇', null)
|
|
1091
|
+
this.setLabelValue('小区', null)
|
|
1092
|
+
|
|
1093
|
+
|
|
1094
|
+
|
|
1095
|
+
let data = {
|
|
1096
|
+
tablename: 't_street',
|
|
1097
|
+
condition: `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}'`
|
|
1098
|
+
}
|
|
1099
|
+
let f_address_type = this.getLableValue('地址类型')
|
|
1100
|
+
|
|
1101
|
+
if (f_address_type === '民用市区') {
|
|
1102
|
+
data.condition = `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}' and f_iscity = '市区'`
|
|
1103
|
+
}
|
|
1104
|
+
if (f_address_type === '民用乡镇') {
|
|
1105
|
+
data.condition = `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}' and f_iscity = '乡镇'`
|
|
1106
|
+
}
|
|
1107
|
+
|
|
1108
|
+
let http = new HttpResetClass()
|
|
1109
|
+
let res = await http.load(
|
|
1110
|
+
'POST',
|
|
1111
|
+
`rs/sql/apply_singleTable`,
|
|
1112
|
+
{data: data},
|
|
1113
|
+
{resolveMsg: null, rejectMsg: '街道/乡镇查询失败!!!'}
|
|
1114
|
+
)
|
|
1115
|
+
|
|
1116
|
+
this.setLabelOptions('街道/乡镇', res.data.map(item => {
|
|
1117
|
+
return {
|
|
1118
|
+
label: item.f_street,
|
|
1119
|
+
value: item.f_street
|
|
1120
|
+
}
|
|
1121
|
+
}))
|
|
1122
|
+
},
|
|
1123
|
+
// 搜索楼号
|
|
1124
|
+
async 'searchbuilding' (index) {
|
|
1125
|
+
this.setLabelValue('楼号/组', null)
|
|
1126
|
+
if (isEmpty(this.show_data.f_residential_area)){
|
|
1127
|
+
return
|
|
1128
|
+
}
|
|
1129
|
+
let data = {
|
|
1130
|
+
items:'b.f_building',
|
|
1131
|
+
orderitem: 'b.id',
|
|
1132
|
+
tablename: 't_building b left join t_area a on b.f_residential_area_id = a.id',
|
|
1133
|
+
condition: `b.f_filialeid = '${this.$login.f.orgid}' and b.f_residential_area like '%${this.show_data.f_residential_area}%' and a.f_street = '${this.show_data.f_street}'`
|
|
1134
|
+
}
|
|
1135
|
+
let http = new HttpResetClass()
|
|
1136
|
+
let res = await http.load(
|
|
1137
|
+
'POST',
|
|
1138
|
+
`rs/sql/tel_singleTable_OrderBy`,
|
|
1139
|
+
{data: data},
|
|
1140
|
+
{resolveMsg: null, rejectMsg: '楼号查询失败!!!'}
|
|
1141
|
+
)
|
|
1142
|
+
|
|
1143
|
+
if (res.data.length === 0) {
|
|
1144
|
+
return
|
|
1145
|
+
}
|
|
1146
|
+
|
|
1147
|
+
this.setLabelOptions('楼号/组', res.data.map(item => {
|
|
1148
|
+
return {
|
|
1149
|
+
label: item.f_building,
|
|
1150
|
+
value: item.f_building
|
|
1151
|
+
}
|
|
1152
|
+
}))
|
|
1153
|
+
},
|
|
1154
|
+
// 地址类型失去焦点
|
|
1155
|
+
'addressTypeChange' (index) {
|
|
1156
|
+
},
|
|
1157
|
+
// 居民团体单户报建初始化
|
|
1158
|
+
'apply2ReadyEvent' () {
|
|
1159
|
+
if (this.show_data.f_apply_source === '线下发起') {
|
|
1160
|
+
this.addressInitialization()
|
|
1161
|
+
this.hideLabels('客户编号')
|
|
1162
|
+
this.electiveLabels('客户编号')
|
|
1163
|
+
this.showLabels('片区', '地址类型')
|
|
1164
|
+
this.requiredLabels('片区', '地址类型')
|
|
1165
|
+
}
|
|
1166
|
+
if (this.show_data.f_apply_source === '自动发起') {
|
|
1167
|
+
this.hideLabels('片区', '地址类型')
|
|
1168
|
+
this.electiveLabels('片区', '地址类型',)
|
|
1169
|
+
}
|
|
1170
|
+
},
|
|
1171
|
+
// 申请节点初始化
|
|
1172
|
+
'applyReadyEvent' () {
|
|
1173
|
+
this.addressInitialization()
|
|
1174
|
+
this.pcdChange()
|
|
1175
|
+
this.streetChange()
|
|
1176
|
+
this.searchbuilding()
|
|
1177
|
+
},
|
|
1178
|
+
// ===========================================
|
|
1179
|
+
async 'button'() {
|
|
1180
|
+
if (this.show_data.button.before) {
|
|
1181
|
+
await this[this.show_data.button.before]()
|
|
1182
|
+
}
|
|
1183
|
+
// 点击重置按钮就重置数据
|
|
1184
|
+
if (this.show_data.button.button_name === '重置') {
|
|
1185
|
+
this.$dispatch('breakControl', this.selectdata)
|
|
1186
|
+
return
|
|
1187
|
+
}
|
|
1188
|
+
if ((this.show_data.f_apply_type == '居民用户报建' || this.show_data.f_apply_type == '非居用户报建' || this.show_data.f_apply_type == '其他报建' ) && this.show_data.defname == '报装申请' && this.show_data.f_is_have == '否' && this.show_data.button.button_name == '提交' ){
|
|
1189
|
+
this.show_data.button.button_name = '跳过'
|
|
1190
|
+
}
|
|
1191
|
+
this.show_data.user = this.$login.f
|
|
1192
|
+
this.show_data.start_activity = this.$workflow_vue.start_activity
|
|
1193
|
+
this.show_data.xmlfilename = this.$workflow_vue.workflow_xmlfilename
|
|
1194
|
+
//将千分位金额转成数字
|
|
1195
|
+
for (const item of this.show_data.fields) {
|
|
1196
|
+
if (item.percentiles) {
|
|
1197
|
+
if(item.value.includes(",")){
|
|
1198
|
+
let Money=this.parseCurrency(item.value)
|
|
1199
|
+
this.show_data[item.field]=Money
|
|
1200
|
+
debugger
|
|
1201
|
+
}else{
|
|
1202
|
+
//转为数字
|
|
1203
|
+
let Money= Number(item.value)
|
|
1204
|
+
this.show_data[item.field]=Money
|
|
1205
|
+
debugger
|
|
1206
|
+
}
|
|
1207
|
+
}
|
|
1208
|
+
}
|
|
1209
|
+
let res = await this.$resetpost(
|
|
1210
|
+
`rs/logic/ApplyProductService`,
|
|
1211
|
+
{data: this.show_data},
|
|
1212
|
+
{resolveMsg: null, rejectMsg: '数据保存失败'}
|
|
1213
|
+
)
|
|
1214
|
+
|
|
1215
|
+
if (this.show_data.button.after) {
|
|
1216
|
+
this[this.show_data.button.after]()
|
|
1217
|
+
}
|
|
1218
|
+
this.$dispatch('loadPage')
|
|
1219
|
+
},
|
|
1220
|
+
// 失去焦点出触发事件
|
|
1221
|
+
'onchange' (index) {
|
|
1222
|
+
let http = new HttpResetClass()
|
|
1223
|
+
if (this.show_data.defname === '报装申请' || this.show_data.defname === '信息确认') {
|
|
1224
|
+
|
|
1225
|
+
if (
|
|
1226
|
+
this.show_data.fields[index].label === '区/县' ||
|
|
1227
|
+
this.show_data.fields[index].label === '街道/乡镇' ||
|
|
1228
|
+
this.show_data.fields[index].label === '小区' ||
|
|
1229
|
+
this.show_data.fields[index].label === '楼号/组' ||
|
|
1230
|
+
this.show_data.fields[index].label === '单元/排' ||
|
|
1231
|
+
this.show_data.fields[index].label === '楼层' ||
|
|
1232
|
+
this.show_data.fields[index].label === '门牌号' ||
|
|
1233
|
+
this.show_data.fields[index].label === '地址杂项'
|
|
1234
|
+
) {
|
|
1235
|
+
if (this.show_data.fields[index].label === '单元/排' || this.show_data.fields[index].label === '楼层' || this.show_data.fields[index].label === '门牌号'){
|
|
1236
|
+
if (this.show_data.fields[index].value.length == 1){
|
|
1237
|
+
this.show_data.fields[index].value = '0'+ this.show_data.fields[index].value
|
|
1238
|
+
}
|
|
1239
|
+
}
|
|
1240
|
+
console.log('地址参数',this.config)
|
|
1241
|
+
let f_pcd = this.getLableValue('区/县') || ''
|
|
1242
|
+
let f_street = this.getLableValue('街道/乡镇') || ''
|
|
1243
|
+
let f_residential_area = this.getLableValue('小区') || ''
|
|
1244
|
+
let f_building = this.getLableValue('楼号/组') || ''
|
|
1245
|
+
let f_building_suffix = f_building ? this.config.f_building_suffix : ''
|
|
1246
|
+
//let f_building_suffix = f_building ? '号楼' : ''
|
|
1247
|
+
let f_unit = this.getLableValue('单元/排') || ''
|
|
1248
|
+
let f_unit_suffix = f_unit ? this.config.f_unit_suffix : ''
|
|
1249
|
+
//let f_unit_suffix = f_unit ? '单元' : ''
|
|
1250
|
+
let f_floor = this.getLableValue('楼层') || ''
|
|
1251
|
+
let f_floor_suffix = f_floor ? this.config.f_floor_suffix : ''
|
|
1252
|
+
//let f_floor_suffix = f_floor ? '层' : ''
|
|
1253
|
+
let f_room = this.getLableValue('门牌号') || ''
|
|
1254
|
+
//let f_room_suffix = f_room ? this.config.f_room_suffix : ''
|
|
1255
|
+
//let f_room_suffix = f_room ? '室' : ''
|
|
1256
|
+
let f_room_suffix = this.getLableValue('地址杂项') || ''
|
|
1257
|
+
|
|
1258
|
+
let f_address = f_pcd + f_street + f_residential_area + f_building + f_building_suffix + f_unit + f_unit_suffix + f_floor + f_floor_suffix + f_room + f_room_suffix
|
|
1259
|
+
this.setLabelValue("地址", f_address)
|
|
1260
|
+
}
|
|
1261
|
+
}
|
|
1262
|
+
if (this.show_data.fields[index].label == '入户证号'){
|
|
1263
|
+
let data = {
|
|
1264
|
+
tablename: `t_apply`,
|
|
1265
|
+
condition: `f_entry_number='${this.show_data.fields[index].value}' and f_sub_state in ('正在进行','完工')`
|
|
1266
|
+
}
|
|
1267
|
+
http.load('post','rs/sql/apply_singleTable',{data: data},
|
|
1268
|
+
{resolveMsg: null, rejectMsg: '查询失败'}).then(row=>{
|
|
1269
|
+
if (row.data.length > 0){
|
|
1270
|
+
this.$showMessage('请注意入户证号重复!!!')
|
|
1271
|
+
}
|
|
1272
|
+
})
|
|
1273
|
+
}
|
|
1274
|
+
},
|
|
1275
|
+
selectSearch (val, index) {},
|
|
1276
|
+
'onblur' (index) {},
|
|
1277
|
+
'oninput' (index) {
|
|
1278
|
+
},
|
|
1279
|
+
'initializtionView' () {},
|
|
1280
|
+
async 'onchangeModal' (index, fieldIndex) {
|
|
1281
|
+
},
|
|
1282
|
+
async 'onblurModal' (index, fieldIndex) {
|
|
1283
|
+
|
|
1284
|
+
},
|
|
1285
|
+
async 'oninputModal' (index, fieldIndex) {
|
|
1286
|
+
|
|
1287
|
+
},
|
|
1288
|
+
async 'onetomanydelete' (index, rowIndex) {
|
|
1289
|
+
|
|
1290
|
+
let http = new HttpResetClass()
|
|
1291
|
+
|
|
1292
|
+
let res = await http.load(
|
|
1293
|
+
'DELETE',
|
|
1294
|
+
`rs/entity/${this.show_data.onetomany[index].tables[0]}/${this.show_data.onetomany[index].rows[rowIndex].id}`,
|
|
1295
|
+
null,
|
|
1296
|
+
{resolveMsg: null, rejectMsg: '删除失败!!!'}
|
|
1297
|
+
)
|
|
1298
|
+
|
|
1299
|
+
res = await this.$resetpost(
|
|
1300
|
+
'rs/entity/t_apply',
|
|
1301
|
+
this.show_data
|
|
1302
|
+
)
|
|
1303
|
+
|
|
1304
|
+
this.$dispatch('breakControl', this.show_data)
|
|
1305
|
+
},
|
|
1306
|
+
async 'onetomanyupdate' (index, rowIndex) {
|
|
1307
|
+
let data = this.show_data.onetomany[index].rows[rowIndex]
|
|
1308
|
+
|
|
1309
|
+
this.show_data.onetomany[index].fields.forEach(item => {
|
|
1310
|
+
data[item.field] = item.value
|
|
1311
|
+
})
|
|
1312
|
+
let res = await this.$resetpost(
|
|
1313
|
+
`rs/entity/${this.show_data.onetomany[index].tables[0]}`,
|
|
1314
|
+
data
|
|
1315
|
+
)
|
|
1316
|
+
|
|
1317
|
+
res = await this.$resetpost(
|
|
1318
|
+
'rs/entity/t_apply',
|
|
1319
|
+
this.show_data
|
|
1320
|
+
)
|
|
1321
|
+
|
|
1322
|
+
this.$dispatch('breakControl', this.show_data)
|
|
1323
|
+
},
|
|
1324
|
+
async 'onetomanyadd' (index) {
|
|
1325
|
+
let data = {
|
|
1326
|
+
f_process_id : this.show_data.f_process_id,
|
|
1327
|
+
f_operator_id: this.$login.f.id,
|
|
1328
|
+
f_operator: this.$login.f.name,
|
|
1329
|
+
f_operation_date: new Date().Format('yyyy-MM-dd HH:mm:ss'),
|
|
1330
|
+
f_orgid: this.$login.f.orgid,
|
|
1331
|
+
f_orgname: this.$login.f.orgs
|
|
1332
|
+
}
|
|
1333
|
+
this.show_data.onetomany[index].fields.forEach(item => {
|
|
1334
|
+
data[item.field] = item.value
|
|
1335
|
+
})
|
|
1336
|
+
let res = await this.$resetpost(
|
|
1337
|
+
`rs/entity/${this.show_data.onetomany[index].tables[0]}`,
|
|
1338
|
+
data
|
|
1339
|
+
)
|
|
1340
|
+
|
|
1341
|
+
res = await this.$resetpost(
|
|
1342
|
+
'rs/entity/t_apply',
|
|
1343
|
+
this.show_data
|
|
1344
|
+
)
|
|
1345
|
+
|
|
1346
|
+
this.$dispatch('breakControl', this.show_data)
|
|
1347
|
+
},
|
|
1348
|
+
async 'importEvent' (index, table, configName, filepath) {
|
|
1349
|
+
let data = {
|
|
1350
|
+
selectdata: this.show_data,
|
|
1351
|
+
table: table,
|
|
1352
|
+
filepath: filepath,
|
|
1353
|
+
configName: configName,
|
|
1354
|
+
user: this.$login.f
|
|
1355
|
+
}
|
|
1356
|
+
|
|
1357
|
+
let res = await this.$resetpost(
|
|
1358
|
+
`rs/logic/importEvent`,
|
|
1359
|
+
data
|
|
1360
|
+
)
|
|
1361
|
+
|
|
1362
|
+
this.$dispatch('breakControl', this.show_data)
|
|
1363
|
+
},
|
|
1364
|
+
'onbutchange' (index) {
|
|
1365
|
+
|
|
1366
|
+
},
|
|
1367
|
+
'onbutblur' (index) {
|
|
1368
|
+
|
|
1369
|
+
},
|
|
1370
|
+
'onbutinput' (index) {
|
|
1371
|
+
|
|
1372
|
+
|
|
1373
|
+
}
|
|
1374
|
+
},
|
|
1375
|
+
watch: {
|
|
1376
|
+
}
|
|
1377
|
+
}
|
|
1378
|
+
</script>
|
|
1379
|
+
<style scoped>
|
|
1380
|
+
/*清除model中的浮动*/
|
|
1381
|
+
.clearfix:after,.clearfix:before{
|
|
1382
|
+
display: table;
|
|
1383
|
+
}
|
|
1384
|
+
.clearfix:after{
|
|
1385
|
+
clear: both;
|
|
1386
|
+
}
|
|
1387
|
+
</style>
|