apply-clients 3.4.4 → 3.4.6
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 +119 -119
- package/package.json +1 -1
- package/src/components/android/Process/AppExplorationUser.vue +500 -500
- package/src/components/product/Material/MaterialDetailed.vue +262 -262
- package/src/components/product/Process/ExplorationSelect.vue +495 -495
- package/src/components/product/Process/Processes/addressAndUserinfoManagement.vue +211 -211
- package/src/components/product/Process/Service/ServiceControl.vue +1661 -1651
- package/src/main.js +4 -4
|
@@ -5,1868 +5,1878 @@
|
|
|
5
5
|
</div>
|
|
6
6
|
</template>
|
|
7
7
|
<script>
|
|
8
|
-
import Vue from 'vue'
|
|
9
|
-
import {HttpResetClass} from 'vue-client'
|
|
10
|
-
import {isEmpty} from "../../../Util";
|
|
11
|
-
|
|
12
|
-
// Date格式化
|
|
13
|
-
Date.prototype.Format = function (fmt) {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
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
|
-
this.servicer()
|
|
45
|
-
},
|
|
46
|
-
methods: {
|
|
47
|
-
async servicer(){
|
|
48
|
-
debugger
|
|
49
|
-
let data = {
|
|
50
|
-
tablename: 't_user',
|
|
51
|
-
condition: `1=1`
|
|
52
|
-
}
|
|
53
|
-
let http = new HttpResetClass()
|
|
54
|
-
let res = await http.load(
|
|
55
|
-
'POST',
|
|
56
|
-
`rs/sql/singleTable`,
|
|
57
|
-
{data: data},
|
|
58
|
-
{resolveMsg: null, rejectMsg: '服务人查询失败!!!'}
|
|
59
|
-
)
|
|
60
|
-
debugger
|
|
61
|
-
this.setLabelOptions('服务人', res.data.map(item => {
|
|
62
|
-
return {
|
|
63
|
-
label: item.name,
|
|
64
|
-
value: item.name
|
|
65
|
-
}
|
|
66
|
-
}))
|
|
67
|
-
},
|
|
68
|
-
// 组件初始化操作
|
|
69
|
-
async refurbish() {
|
|
70
|
-
this.json_datas = this.$workflow_vue
|
|
71
|
-
let sum = 0
|
|
72
|
-
let jsonData = {}
|
|
73
|
-
if (!this.json_datas || !this.json_datas.activitys || this.json_datas.activitys.length === 0) {
|
|
74
|
-
this.$showMessage("网络故障,请刷新页面")
|
|
75
|
-
return
|
|
76
|
-
}
|
|
77
|
-
this.json_datas.activitys.forEach(item => {
|
|
78
|
-
if (this.selectdata.defname === item.title) {
|
|
79
|
-
jsonData = item // 拿到当前节点的json配置信息
|
|
80
|
-
sum++ // 节点名一样的个数
|
|
81
|
-
}
|
|
82
|
-
return this.selectdata.defname === item.title // 拿到当前节点的json配置信息
|
|
83
|
-
})
|
|
84
|
-
|
|
85
|
-
if (sum === 0) {
|
|
86
|
-
this.$showMessage(`没有在JSON配置文件中找到活动名为:(${this.selectdata.defname})的节点配置`)
|
|
87
|
-
return
|
|
88
|
-
}
|
|
89
|
-
if (sum > 1) {
|
|
90
|
-
this.$showMessage(`在JSON配置文件中找到活动名为:(${this.selectdata.defname})的节点配置:${sum}个`)
|
|
91
|
-
return
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
this.selectdata = Object.assign({}, this.selectdata, jsonData)
|
|
8
|
+
import Vue from 'vue'
|
|
9
|
+
import {HttpResetClass} from 'vue-client'
|
|
10
|
+
import {isEmpty} from "../../../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
|
+
}
|
|
95
28
|
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
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
|
+
this.servicer()
|
|
45
|
+
},
|
|
46
|
+
methods: {
|
|
47
|
+
async servicer(){
|
|
48
|
+
debugger
|
|
49
|
+
let data = {
|
|
50
|
+
tablename: 't_user',
|
|
51
|
+
condition: `1=1`
|
|
100
52
|
}
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
}
|
|
106
|
-
|
|
53
|
+
let http = new HttpResetClass()
|
|
54
|
+
let res = await http.load(
|
|
55
|
+
'POST',
|
|
56
|
+
`rs/sql/singleTable`,
|
|
57
|
+
{data: data},
|
|
58
|
+
{resolveMsg: null, rejectMsg: '服务人查询失败!!!'}
|
|
59
|
+
)
|
|
60
|
+
debugger
|
|
61
|
+
this.setLabelOptions('服务人', res.data.map(item => {
|
|
62
|
+
return {
|
|
63
|
+
label: item.name,
|
|
64
|
+
value: item.name
|
|
107
65
|
}
|
|
66
|
+
}))
|
|
67
|
+
},
|
|
68
|
+
// 组件初始化操作
|
|
69
|
+
async refurbish() {
|
|
70
|
+
this.json_datas = this.$workflow_vue
|
|
71
|
+
let sum = 0
|
|
72
|
+
let jsonData = {}
|
|
73
|
+
if (!this.json_datas || !this.json_datas.activitys || this.json_datas.activitys.length === 0) {
|
|
74
|
+
this.$showMessage("网络故障,请刷新页面")
|
|
75
|
+
return
|
|
108
76
|
}
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
item.value = JSON.parse(this.selectdata[item.field])
|
|
114
|
-
} else {
|
|
115
|
-
item.value = this.selectdata[item.field]
|
|
77
|
+
this.json_datas.activitys.forEach(item => {
|
|
78
|
+
if (this.selectdata.defname === item.title) {
|
|
79
|
+
jsonData = item // 拿到当前节点的json配置信息
|
|
80
|
+
sum++ // 节点名一样的个数
|
|
116
81
|
}
|
|
82
|
+
return this.selectdata.defname === item.title // 拿到当前节点的json配置信息
|
|
83
|
+
})
|
|
84
|
+
|
|
85
|
+
if (sum === 0) {
|
|
86
|
+
this.$showMessage(`没有在JSON配置文件中找到活动名为:(${this.selectdata.defname})的节点配置`)
|
|
87
|
+
return
|
|
117
88
|
}
|
|
118
|
-
if (
|
|
119
|
-
|
|
89
|
+
if (sum > 1) {
|
|
90
|
+
this.$showMessage(`在JSON配置文件中找到活动名为:(${this.selectdata.defname})的节点配置:${sum}个`)
|
|
91
|
+
return
|
|
120
92
|
}
|
|
121
93
|
|
|
122
|
-
|
|
123
|
-
if (item.type === 'datepicker' && !item.value && item.default) {
|
|
124
|
-
item.value = new Date().Format(`${item.format ? item.format : 'yyyy-MM-dd HH:mm:ss'}`)
|
|
125
|
-
}
|
|
94
|
+
this.selectdata = Object.assign({}, this.selectdata, jsonData)
|
|
126
95
|
|
|
127
|
-
//
|
|
128
|
-
|
|
129
|
-
if (item.
|
|
130
|
-
|
|
96
|
+
// fields 字段填充值
|
|
97
|
+
for (const item of this.selectdata.fields) {
|
|
98
|
+
if (!item.value) {
|
|
99
|
+
item.value = null
|
|
100
|
+
}
|
|
131
101
|
|
|
132
|
-
|
|
133
|
-
|
|
102
|
+
if (!item.value && (item.default || item.default === 0) && item.type !== 'datepicker') {
|
|
103
|
+
if (item.eval) {
|
|
104
|
+
item.value = eval(item.default)
|
|
105
|
+
} else {
|
|
106
|
+
item.value = item.default
|
|
134
107
|
}
|
|
108
|
+
}
|
|
135
109
|
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
110
|
+
if (this.selectdata[item.field]) {
|
|
111
|
+
// 将json字符串格式化赋值给value
|
|
112
|
+
if (String(this.selectdata[item.field]).startsWith("{")) {
|
|
113
|
+
item.value = JSON.parse(this.selectdata[item.field])
|
|
114
|
+
} else {
|
|
115
|
+
item.value = this.selectdata[item.field]
|
|
141
116
|
}
|
|
142
117
|
}
|
|
118
|
+
if (this.selectdata[item.field] === 0) {
|
|
119
|
+
item.value = 0
|
|
120
|
+
}
|
|
143
121
|
|
|
144
|
-
|
|
145
|
-
|
|
122
|
+
// datepicker
|
|
123
|
+
if (item.type === 'datepicker' && !item.value && item.default) {
|
|
124
|
+
item.value = new Date().Format(`${item.format ? item.format : 'yyyy-MM-dd HH:mm:ss'}`)
|
|
146
125
|
}
|
|
147
|
-
}
|
|
148
126
|
|
|
127
|
+
// 如果配置类型为select,优先从参数列表获取options
|
|
128
|
+
if (item.type === 'select' || item.type === 'checkbox') {
|
|
129
|
+
if (item.param) {
|
|
130
|
+
let temp = this.$appdata.getParam(item.label)
|
|
149
131
|
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
} else {
|
|
154
|
-
item.value = []
|
|
155
|
-
}
|
|
156
|
-
}
|
|
132
|
+
if (temp && temp.length > 0) {
|
|
133
|
+
item.options = temp
|
|
134
|
+
}
|
|
157
135
|
|
|
158
|
-
|
|
159
|
-
|
|
136
|
+
if (item.paramLabel) {
|
|
137
|
+
temp = this.$appdata.getParam(item.paramLabel)
|
|
138
|
+
if (temp && temp.length > 0) {
|
|
139
|
+
item.options = temp
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
}
|
|
160
143
|
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
if (!item.mark) {
|
|
165
|
-
item.mark = 0
|
|
144
|
+
if (item.ready) {
|
|
145
|
+
item.options = await this[item.ready]()
|
|
146
|
+
}
|
|
166
147
|
}
|
|
167
|
-
})
|
|
168
|
-
}
|
|
169
148
|
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
} else {
|
|
177
|
-
let data = {
|
|
178
|
-
tablename: item.tables[0],
|
|
179
|
-
condition: `f_process_id='${this.selectdata.f_process_id}'`
|
|
149
|
+
|
|
150
|
+
if (item.type === 'checkbox') {
|
|
151
|
+
if (this.selectdata[item.field]) {
|
|
152
|
+
item.value = JSON.parse(this.selectdata[item.field])
|
|
153
|
+
} else {
|
|
154
|
+
item.value = []
|
|
180
155
|
}
|
|
181
|
-
res = await this.$resetpost(
|
|
182
|
-
'rs/sql/singleTable',
|
|
183
|
-
{data: data},
|
|
184
|
-
{resolveMsg: null, rejectMsg: 'onetomany查询失败'}
|
|
185
|
-
)
|
|
186
156
|
}
|
|
187
157
|
|
|
188
|
-
item.
|
|
158
|
+
this.selectdata[item.field] = item.value
|
|
159
|
+
}
|
|
189
160
|
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
}
|
|
161
|
+
// 控制组件
|
|
162
|
+
if (this.selectdata.components) {
|
|
163
|
+
this.selectdata.components.forEach(item => {
|
|
164
|
+
if (!item.mark) {
|
|
165
|
+
item.mark = 0
|
|
196
166
|
}
|
|
167
|
+
})
|
|
168
|
+
}
|
|
197
169
|
|
|
198
|
-
|
|
199
|
-
|
|
170
|
+
// 初始化onetomany
|
|
171
|
+
if (this.selectdata.onetomany) {
|
|
172
|
+
for (const item of this.selectdata.onetomany) {
|
|
173
|
+
let res = null
|
|
174
|
+
if (item.queryEvent) {
|
|
175
|
+
res = this[item.queryEvent]()
|
|
176
|
+
} else {
|
|
177
|
+
let data = {
|
|
178
|
+
tablename: item.tables[0],
|
|
179
|
+
condition: `f_process_id='${this.selectdata.f_process_id}'`
|
|
180
|
+
}
|
|
181
|
+
res = await this.$resetpost(
|
|
182
|
+
'rs/sql/singleTable',
|
|
183
|
+
{data: data},
|
|
184
|
+
{resolveMsg: null, rejectMsg: 'onetomany查询失败'}
|
|
185
|
+
)
|
|
200
186
|
}
|
|
201
187
|
|
|
202
|
-
|
|
203
|
-
if (field.type === 'datepicker' && !field.value && field.default) {
|
|
204
|
-
field.value = new Date().Format(`${field.format ? field.format : 'yyyy-MM-dd HH:mm:ss'}`)
|
|
205
|
-
}
|
|
188
|
+
item.rows = res.data
|
|
206
189
|
|
|
207
|
-
|
|
190
|
+
// 初始化onetomany中的fields
|
|
191
|
+
for (const field of item.fields) {
|
|
192
|
+
if (!field.value) {
|
|
193
|
+
if (field.value !== 0) {
|
|
194
|
+
field.value = null
|
|
195
|
+
}
|
|
196
|
+
}
|
|
208
197
|
|
|
209
|
-
|
|
198
|
+
if (field.default || field.default === 0) {
|
|
199
|
+
field.value = field.default
|
|
200
|
+
}
|
|
210
201
|
|
|
211
|
-
|
|
212
|
-
|
|
202
|
+
// datepicker
|
|
203
|
+
if (field.type === 'datepicker' && !field.value && field.default) {
|
|
204
|
+
field.value = new Date().Format(`${field.format ? field.format : 'yyyy-MM-dd HH:mm:ss'}`)
|
|
213
205
|
}
|
|
214
206
|
|
|
215
|
-
if (field.
|
|
216
|
-
|
|
207
|
+
if (field.type === 'select') {
|
|
208
|
+
|
|
209
|
+
let temp = this.$appdata.getParam(field.label)
|
|
210
|
+
|
|
217
211
|
if (temp && temp.length > 0) {
|
|
218
|
-
|
|
212
|
+
field.options = temp
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
if (field.paramLabel) {
|
|
216
|
+
temp = this.$appdata.getParam(field.paramLabel)
|
|
217
|
+
if (temp && temp.length > 0) {
|
|
218
|
+
item.options = temp
|
|
219
|
+
}
|
|
219
220
|
}
|
|
220
221
|
}
|
|
221
222
|
}
|
|
222
223
|
}
|
|
223
224
|
}
|
|
224
|
-
}
|
|
225
225
|
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
226
|
+
// 初始化 buttons_fields
|
|
227
|
+
for (const item of this.selectdata.buttons) {
|
|
228
|
+
if (item.button_name === '下发') {
|
|
229
229
|
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
230
|
+
let data = {
|
|
231
|
+
source: item.source,
|
|
232
|
+
userid: this.$login.f.id
|
|
233
|
+
}
|
|
234
|
+
if (item.sourceMethod) {
|
|
235
|
+
data.source = this[item.sourceMethod]()
|
|
236
|
+
}
|
|
237
|
+
if (!data.source) {
|
|
238
|
+
this.$showMessage("请配置获取人员表达式")
|
|
239
|
+
return
|
|
240
|
+
}
|
|
241
241
|
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
242
|
+
let res = await this.$resetpost(
|
|
243
|
+
'rs/search',
|
|
244
|
+
{data: data},
|
|
245
|
+
{resolveMsg: null, rejectMsg: '下发人员查询失败!!!'}
|
|
246
|
+
)
|
|
247
|
+
|
|
248
|
+
let options = res.data.map(source => {
|
|
249
|
+
return {
|
|
250
|
+
"label": source.name,
|
|
251
|
+
"value": source.id
|
|
252
|
+
}
|
|
253
|
+
})
|
|
247
254
|
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
"value": source.id
|
|
255
|
+
if (item.button_fields.length !== 1) {
|
|
256
|
+
this.$showMessage("下发有且只能有一个字段!!!")
|
|
257
|
+
return
|
|
252
258
|
}
|
|
253
|
-
})
|
|
254
259
|
|
|
255
|
-
|
|
256
|
-
this.$showMessage("下发有且只能有一个字段!!!")
|
|
257
|
-
return
|
|
260
|
+
item.button_fields[0].options = options
|
|
258
261
|
}
|
|
262
|
+
if (item.button_fields) {
|
|
263
|
+
item.button_fields.forEach(x => {
|
|
264
|
+
// 如果配置类型为select,优先从参数列表获取options
|
|
265
|
+
if (x.type === 'select') {
|
|
259
266
|
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
if (item.button_fields) {
|
|
263
|
-
item.button_fields.forEach(x => {
|
|
264
|
-
// 如果配置类型为select,优先从参数列表获取options
|
|
265
|
-
if (x.type === 'select') {
|
|
266
|
-
|
|
267
|
-
if (x.param) {
|
|
268
|
-
let temp = this.$appdata.getParam(x.label)
|
|
269
|
-
|
|
270
|
-
if (temp && temp.length > 0) {
|
|
271
|
-
x.options = temp
|
|
272
|
-
}
|
|
267
|
+
if (x.param) {
|
|
268
|
+
let temp = this.$appdata.getParam(x.label)
|
|
273
269
|
|
|
274
|
-
if (x.paramLabel) {
|
|
275
|
-
temp = this.$appdata.getParam(x.paramLabel)
|
|
276
270
|
if (temp && temp.length > 0) {
|
|
277
271
|
x.options = temp
|
|
278
272
|
}
|
|
273
|
+
|
|
274
|
+
if (x.paramLabel) {
|
|
275
|
+
temp = this.$appdata.getParam(x.paramLabel)
|
|
276
|
+
if (temp && temp.length > 0) {
|
|
277
|
+
x.options = temp
|
|
278
|
+
}
|
|
279
|
+
}
|
|
279
280
|
}
|
|
280
|
-
}
|
|
281
281
|
|
|
282
|
-
|
|
283
|
-
|
|
282
|
+
}
|
|
283
|
+
})
|
|
284
|
+
}
|
|
284
285
|
}
|
|
285
|
-
}
|
|
286
|
-
|
|
287
|
-
// 消除双向绑定,避免子组件(显示层)数据更改,父组件(控制层)也更改
|
|
288
|
-
let temp = JSON.parse(JSON.stringify(this.selectdata))
|
|
289
|
-
console.log('打印下temp',temp)
|
|
290
|
-
this.show_data = temp
|
|
291
|
-
this.$nextTick(() => {
|
|
292
|
-
this.showview = true
|
|
293
|
-
})
|
|
294
|
-
},
|
|
295
|
-
// 金额转大写
|
|
296
|
-
smalltoBIG(n) {
|
|
297
|
-
let fraction = ['角', '分'];
|
|
298
|
-
let digit = ['零', '壹', '贰', '叁', '肆', '伍', '陆', '柒', '捌', '玖'];
|
|
299
|
-
let unit = [['元', '万', '亿'], ['', '拾', '佰', '仟']];
|
|
300
|
-
let head = n < 0 ? '欠' : '';
|
|
301
|
-
n = Math.abs(n);
|
|
302
|
-
|
|
303
|
-
let s = '';
|
|
304
|
-
|
|
305
|
-
for (var i = 0; i < fraction.length; i++) {
|
|
306
|
-
s += (digit[Math.floor(n * 10 * Math.pow(10, i)) % 10] + fraction[i]).replace(/零./, '');
|
|
307
|
-
}
|
|
308
|
-
s = s || '整';
|
|
309
|
-
n = Math.floor(n);
|
|
310
286
|
|
|
311
|
-
|
|
312
|
-
let
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
}
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
this.show_data[item.field] = value
|
|
343
|
-
}
|
|
344
|
-
}
|
|
345
|
-
},
|
|
346
|
-
setLabelOptions(label, options) {
|
|
347
|
-
for (const item of this.show_data.fields) {
|
|
348
|
-
if (item.label === label) {
|
|
349
|
-
item.options = options
|
|
350
|
-
}
|
|
351
|
-
}
|
|
352
|
-
},
|
|
353
|
-
showLabels(...labels) {
|
|
354
|
-
for (const item of this.show_data.fields) {
|
|
355
|
-
if (labels.includes(item.label)) {
|
|
356
|
-
item.hidden = false
|
|
357
|
-
}
|
|
358
|
-
}
|
|
359
|
-
},
|
|
360
|
-
hideLabels(...labels) {
|
|
361
|
-
for (const item of this.show_data.fields) {
|
|
362
|
-
if (labels.includes(item.label)) {
|
|
363
|
-
item.hidden = true
|
|
364
|
-
}
|
|
365
|
-
}
|
|
366
|
-
},
|
|
367
|
-
requiredLabels(...labels) {
|
|
368
|
-
for (const item of this.show_data.fields) {
|
|
369
|
-
if (labels.includes(item.label)) {
|
|
370
|
-
item.required = true
|
|
371
|
-
}
|
|
372
|
-
}
|
|
373
|
-
},
|
|
374
|
-
electiveLabels(...labels) {
|
|
375
|
-
for (const item of this.show_data.fields) {
|
|
376
|
-
if (labels.includes(item.label)) {
|
|
377
|
-
item.required = false
|
|
378
|
-
}
|
|
379
|
-
}
|
|
380
|
-
},
|
|
381
|
-
readonlyLabels(...labels) {
|
|
382
|
-
for (const item of this.show_data.fields) {
|
|
383
|
-
if (labels.includes(item.label)) {
|
|
384
|
-
item.readonly = true
|
|
385
|
-
item.disabled = true
|
|
287
|
+
// 消除双向绑定,避免子组件(显示层)数据更改,父组件(控制层)也更改
|
|
288
|
+
let temp = JSON.parse(JSON.stringify(this.selectdata))
|
|
289
|
+
console.log('打印下temp',temp)
|
|
290
|
+
this.show_data = temp
|
|
291
|
+
this.$nextTick(() => {
|
|
292
|
+
this.showview = true
|
|
293
|
+
})
|
|
294
|
+
},
|
|
295
|
+
// 金额转大写
|
|
296
|
+
smalltoBIG(n) {
|
|
297
|
+
let fraction = ['角', '分'];
|
|
298
|
+
let digit = ['零', '壹', '贰', '叁', '肆', '伍', '陆', '柒', '捌', '玖'];
|
|
299
|
+
let unit = [['元', '万', '亿'], ['', '拾', '佰', '仟']];
|
|
300
|
+
let head = n < 0 ? '欠' : '';
|
|
301
|
+
n = Math.abs(n);
|
|
302
|
+
|
|
303
|
+
let s = '';
|
|
304
|
+
|
|
305
|
+
for (var i = 0; i < fraction.length; i++) {
|
|
306
|
+
s += (digit[Math.floor(n * 10 * Math.pow(10, i)) % 10] + fraction[i]).replace(/零./, '');
|
|
307
|
+
}
|
|
308
|
+
s = s || '整';
|
|
309
|
+
n = Math.floor(n);
|
|
310
|
+
|
|
311
|
+
for (var i = 0; i < unit[0].length && n > 0; i++) {
|
|
312
|
+
let p = '';
|
|
313
|
+
for (var j = 0; j < unit[1].length && n > 0; j++) {
|
|
314
|
+
p = digit[n % 10] + unit[1][j] + p;
|
|
315
|
+
n = Math.floor(n / 10);
|
|
316
|
+
}
|
|
317
|
+
s = p.replace(/(零.)*零$/, '').replace(/^$/, '零') + unit[0][i] + s;
|
|
386
318
|
}
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
319
|
+
return head + s.replace(/(零.)*零元/, '元').replace(/(零.)+/g, '零').replace(/^整$/, '零元整')
|
|
320
|
+
},
|
|
321
|
+
getLableValue(label) {
|
|
322
|
+
for (const item of this.show_data.fields) {
|
|
323
|
+
if (item.label === label && item.type !== 'number') {
|
|
324
|
+
return item.value || ''
|
|
325
|
+
}
|
|
326
|
+
if (item.label === label && item.type === 'number') {
|
|
327
|
+
return item.value || 0
|
|
328
|
+
}
|
|
394
329
|
}
|
|
395
|
-
}
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
330
|
+
},
|
|
331
|
+
getLableOptions(label) {
|
|
332
|
+
for (const item of this.show_data.fields) {
|
|
333
|
+
if (item.label === label) {
|
|
334
|
+
return item.options
|
|
335
|
+
}
|
|
401
336
|
}
|
|
402
|
-
}
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
337
|
+
},
|
|
338
|
+
setLabelValue(label, value) {
|
|
339
|
+
for (const item of this.show_data.fields) {
|
|
340
|
+
if (item.label === label) {
|
|
341
|
+
item.value = value
|
|
342
|
+
this.show_data[item.field] = value
|
|
343
|
+
}
|
|
408
344
|
}
|
|
409
|
-
}
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
345
|
+
},
|
|
346
|
+
setLabelOptions(label, options) {
|
|
347
|
+
for (const item of this.show_data.fields) {
|
|
348
|
+
if (item.label === label) {
|
|
349
|
+
item.options = options
|
|
350
|
+
}
|
|
415
351
|
}
|
|
416
|
-
}
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
352
|
+
},
|
|
353
|
+
showLabels(...labels) {
|
|
354
|
+
for (const item of this.show_data.fields) {
|
|
355
|
+
if (labels.includes(item.label)) {
|
|
356
|
+
item.hidden = false
|
|
357
|
+
}
|
|
422
358
|
}
|
|
423
|
-
}
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
condition: `${this.show_data.fields[index].field} = '${this.show_data.fields[index].value}'`
|
|
430
|
-
}
|
|
431
|
-
let res = await http.load('POST', 'rs/sql/singleTable', {data: data}, {
|
|
432
|
-
resolveMsg: null,
|
|
433
|
-
rejectMsg: `${this.show_data.fields[index].label}查询失败`
|
|
434
|
-
})
|
|
435
|
-
if (res.data.length > 0) {
|
|
436
|
-
this.show_data.fields[index].value = null
|
|
437
|
-
this.$showAlert(`${this.show_data.fields[index].label}已存在!!!`, 'warning', 3000)
|
|
438
|
-
}
|
|
439
|
-
},
|
|
440
|
-
// 获取片区
|
|
441
|
-
async getSliceArea () {
|
|
442
|
-
let data = {
|
|
443
|
-
source: 'this.getParentByType($organization$).getAllChildrens().where(row.getType() == $zone$)',
|
|
444
|
-
userid: this.$login.f.id
|
|
445
|
-
}
|
|
446
|
-
|
|
447
|
-
let http = new HttpResetClass()
|
|
448
|
-
let res = await http.load(
|
|
449
|
-
'POST',
|
|
450
|
-
`rs/search`,
|
|
451
|
-
{data: data},
|
|
452
|
-
{resolveMsg: null, rejectMsg: '片区查询失败!!!'}
|
|
453
|
-
)
|
|
454
|
-
|
|
455
|
-
return res.data.map(item => {
|
|
456
|
-
return {
|
|
457
|
-
label: item.name,
|
|
458
|
-
value: item.name
|
|
359
|
+
},
|
|
360
|
+
hideLabels(...labels) {
|
|
361
|
+
for (const item of this.show_data.fields) {
|
|
362
|
+
if (labels.includes(item.label)) {
|
|
363
|
+
item.hidden = true
|
|
364
|
+
}
|
|
459
365
|
}
|
|
460
|
-
}
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
let data = {
|
|
465
|
-
tablename: 't_pcd',
|
|
466
|
-
condition: `f_filialeid = '${this.$login.f.orgid}'`
|
|
467
|
-
}
|
|
468
|
-
let http = new HttpResetClass()
|
|
469
|
-
let res = await http.load(
|
|
470
|
-
'POST',
|
|
471
|
-
`rs/sql/singleTable`,
|
|
472
|
-
{data: data},
|
|
473
|
-
{resolveMsg: null, rejectMsg: '区县查询失败!!!'}
|
|
474
|
-
)
|
|
475
|
-
|
|
476
|
-
return res.data.map(item => {
|
|
477
|
-
return {
|
|
478
|
-
label: item.f_pcd,
|
|
479
|
-
value: item.f_pcd
|
|
480
|
-
}
|
|
481
|
-
})
|
|
482
|
-
},
|
|
483
|
-
// 获取集收单位
|
|
484
|
-
async getArea () {
|
|
485
|
-
let data = {
|
|
486
|
-
tablename: 't_area',
|
|
487
|
-
condition: `f_filialeid = '${this.$login.f.orgid}'`
|
|
488
|
-
}
|
|
489
|
-
let http = new HttpResetClass()
|
|
490
|
-
let res = await http.load(
|
|
491
|
-
'POST',
|
|
492
|
-
`rs/sql/singleTable`,
|
|
493
|
-
{data: data},
|
|
494
|
-
{resolveMsg: null, rejectMsg: '集收单位查询失败!!!'}
|
|
495
|
-
)
|
|
496
|
-
|
|
497
|
-
return res.data.map(item => {
|
|
498
|
-
return {
|
|
499
|
-
label: item.f_residential_area,
|
|
500
|
-
value: item.f_residential_area
|
|
501
|
-
}
|
|
502
|
-
})
|
|
503
|
-
},
|
|
504
|
-
// 缴费前置
|
|
505
|
-
chargeBefore () {
|
|
506
|
-
if (Number(this.show_data.f_due_money) > Number(this.show_data.f_cumulative_payment_money) || Number(this.show_data.f_surplus_money) > 0) {
|
|
507
|
-
this.$showAlert('费用未结清!!!', 'warning', 3000)
|
|
508
|
-
throw null
|
|
509
|
-
}
|
|
510
|
-
},
|
|
511
|
-
// 施工前置 加表具后状态是待开通 提交后是正常 所以这里的判断条件需改正 (and uf.f_meter_classify is null and f_meternumber is null)
|
|
512
|
-
async constructionBefore () {
|
|
513
|
-
let http = new HttpResetClass()
|
|
514
|
-
let data = {
|
|
515
|
-
condition: `ui.f_process_id = '${this.show_data.f_process_id}' and uf.f_meter_classify is null and f_meternumber is null`
|
|
516
|
-
}
|
|
517
|
-
let res = await http.load(
|
|
518
|
-
'POST',
|
|
519
|
-
'rs/sql/countApplyUserinfo',
|
|
520
|
-
{data: data},
|
|
521
|
-
{
|
|
522
|
-
resolveMsg: null,
|
|
523
|
-
rejectMsg: '安装明细查询失败!!!'
|
|
524
|
-
})
|
|
525
|
-
if (res.data[0].num > 0) {
|
|
526
|
-
this.$showAlert(`还有${res.data[0].num}户未安装,无法提交`, 'warning', 3000)
|
|
527
|
-
throw `还有${res.data[0].num}户未安装,无法提交`
|
|
528
|
-
}
|
|
529
|
-
},
|
|
530
|
-
changePipeBuild () {
|
|
531
|
-
if (this.selectdata.f_process_dep === '工程部') {
|
|
532
|
-
return 'this.getParentByType($organization$).getChildByName($工程部报装$).getChildren()'
|
|
533
|
-
}
|
|
534
|
-
if (this.selectdata.f_process_dep === '运营部') {
|
|
535
|
-
return 'this.getParentByType($organization$).getChildByName($运营部报装$).getChildren()'
|
|
536
|
-
}
|
|
537
|
-
return 'this.getParentByType($organization$).getChildByName($工程部报装$).getChildren()'
|
|
538
|
-
},
|
|
539
|
-
async getDevInfo () {
|
|
540
|
-
let data = {
|
|
541
|
-
tablename: 't_dev_info',
|
|
542
|
-
condition: `f_orgid = '${this.$login.f.orgid}'`
|
|
543
|
-
}
|
|
544
|
-
let http = new HttpResetClass()
|
|
545
|
-
let res = await http.load(
|
|
546
|
-
'POST',
|
|
547
|
-
`rs/sql/singleTable`,
|
|
548
|
-
{data: data},
|
|
549
|
-
{resolveMsg: null, rejectMsg: '公司查询失败!!!'}
|
|
550
|
-
)
|
|
551
|
-
|
|
552
|
-
return res.data.map(item => {
|
|
553
|
-
return {
|
|
554
|
-
label: item.f_dev_name,
|
|
555
|
-
value: item.f_dev_name
|
|
556
|
-
}
|
|
557
|
-
})
|
|
558
|
-
},
|
|
559
|
-
async getPrice (f_price_id) {
|
|
560
|
-
console.log('=======================')
|
|
561
|
-
console.log(f_price_id)
|
|
562
|
-
|
|
563
|
-
let data = {
|
|
564
|
-
condition: `sp.f_filialeid = '${this.$login.f.orgid}'`
|
|
565
|
-
}
|
|
566
|
-
if(this.Pricetype==='机表'){
|
|
567
|
-
data.condition=`sp.f_custom = '机表'`
|
|
568
|
-
}
|
|
569
|
-
if(this.Pricetype==='非机表'){
|
|
570
|
-
data.condition=`sp.f_custom = '非机表'`
|
|
571
|
-
}
|
|
572
|
-
|
|
573
|
-
if (!isEmpty(f_price_id)) {
|
|
574
|
-
data.condition = `sp.f_filialeid = '${this.$login.f.orgid}' and sp.f_price_id = ${f_price_id}`
|
|
575
|
-
}
|
|
576
|
-
let http = new HttpResetClass()
|
|
577
|
-
let res = await http.load(
|
|
578
|
-
'POST',
|
|
579
|
-
`rs/sql/applyGetPrice`,
|
|
580
|
-
{data: data},
|
|
581
|
-
{resolveMsg: null, rejectMsg: '气价查询失败!!!'}
|
|
582
|
-
)
|
|
583
|
-
|
|
584
|
-
let a= res.data.map(item => {
|
|
585
|
-
return {
|
|
586
|
-
label: item.f_price_name,
|
|
587
|
-
value: item
|
|
588
|
-
}
|
|
589
|
-
})
|
|
590
|
-
this.selectdata.fields.forEach(field => {
|
|
591
|
-
if (field.label === '气价名称') {
|
|
592
|
-
field.options = a}
|
|
593
|
-
})
|
|
594
|
-
return a
|
|
595
|
-
},
|
|
596
|
-
addressInitialization () {
|
|
597
|
-
this.$getConfig(this, 'UserAddress')
|
|
598
|
-
|
|
599
|
-
let f_address_type = this.show_data.f_address_type
|
|
600
|
-
|
|
601
|
-
for (const item of this.show_data.fields) {
|
|
602
|
-
if (f_address_type === '民用市区') {
|
|
603
|
-
if (item.label === '区/县' || item.label === '街道/乡镇' || item.label === '集收单位' || item.label === '门牌号') {
|
|
604
|
-
item.hidden = false
|
|
366
|
+
},
|
|
367
|
+
requiredLabels(...labels) {
|
|
368
|
+
for (const item of this.show_data.fields) {
|
|
369
|
+
if (labels.includes(item.label)) {
|
|
605
370
|
item.required = true
|
|
606
371
|
}
|
|
607
|
-
|
|
608
|
-
|
|
372
|
+
}
|
|
373
|
+
},
|
|
374
|
+
electiveLabels(...labels) {
|
|
375
|
+
for (const item of this.show_data.fields) {
|
|
376
|
+
if (labels.includes(item.label)) {
|
|
609
377
|
item.required = false
|
|
610
378
|
}
|
|
611
|
-
|
|
379
|
+
}
|
|
380
|
+
},
|
|
381
|
+
readonlyLabels(...labels) {
|
|
382
|
+
for (const item of this.show_data.fields) {
|
|
383
|
+
if (labels.includes(item.label)) {
|
|
612
384
|
item.readonly = true
|
|
385
|
+
item.disabled = true
|
|
613
386
|
}
|
|
614
387
|
}
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
item.hidden = false
|
|
622
|
-
item.required = false
|
|
623
|
-
}
|
|
624
|
-
if (item.label === '楼层') {
|
|
625
|
-
item.hidden = true
|
|
626
|
-
item.required = false
|
|
388
|
+
},
|
|
389
|
+
readwriteLabels(...labels) {
|
|
390
|
+
for (const item of this.show_data.fields) {
|
|
391
|
+
if (labels.includes(item.label)) {
|
|
392
|
+
item.readonly = false
|
|
393
|
+
item.disabled = false
|
|
627
394
|
}
|
|
628
|
-
|
|
629
|
-
|
|
395
|
+
}
|
|
396
|
+
},
|
|
397
|
+
disabledButtons(...buttons) {
|
|
398
|
+
for (const item of this.show_data.buttons) {
|
|
399
|
+
if (buttons.includes(item.button_name)) {
|
|
400
|
+
item.disabled = true
|
|
630
401
|
}
|
|
631
402
|
}
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
403
|
+
},
|
|
404
|
+
enableButtons(...buttons) {
|
|
405
|
+
for (const item of this.show_data.buttons) {
|
|
406
|
+
if (buttons.includes(item.button_name)) {
|
|
407
|
+
item.disabled = false
|
|
636
408
|
}
|
|
637
|
-
|
|
409
|
+
}
|
|
410
|
+
},
|
|
411
|
+
showButtons(...buttons) {
|
|
412
|
+
for (const item of this.show_data.buttons) {
|
|
413
|
+
if (buttons.includes(item.button_name)) {
|
|
638
414
|
item.hidden = false
|
|
639
|
-
if (this.show_data.f_apply_type === '工商户报建'){
|
|
640
|
-
item.required = true
|
|
641
|
-
} else {
|
|
642
|
-
item.required = false
|
|
643
|
-
}
|
|
644
|
-
|
|
645
415
|
}
|
|
646
|
-
|
|
416
|
+
}
|
|
417
|
+
},
|
|
418
|
+
hideButtons(...buttons) {
|
|
419
|
+
for (const item of this.show_data.buttons) {
|
|
420
|
+
if (buttons.includes(item.button_name)) {
|
|
647
421
|
item.hidden = true
|
|
648
|
-
item.required = false
|
|
649
|
-
}
|
|
650
|
-
if (item.label === '地址') {
|
|
651
|
-
item.readonly = false
|
|
652
422
|
}
|
|
653
423
|
}
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
424
|
+
},
|
|
425
|
+
async checkDuplicate(index) {
|
|
426
|
+
let http = new HttpResetClass()
|
|
427
|
+
let data = {
|
|
428
|
+
tablename: 't_apply',
|
|
429
|
+
condition: `${this.show_data.fields[index].field} = '${this.show_data.fields[index].value}'`
|
|
430
|
+
}
|
|
431
|
+
let res = await http.load('POST', 'rs/sql/singleTable', {data: data}, {
|
|
432
|
+
resolveMsg: null,
|
|
433
|
+
rejectMsg: `${this.show_data.fields[index].label}查询失败`
|
|
434
|
+
})
|
|
435
|
+
if (res.data.length > 0) {
|
|
436
|
+
this.show_data.fields[index].value = null
|
|
437
|
+
this.$showAlert(`${this.show_data.fields[index].label}已存在!!!`, 'warning', 3000)
|
|
438
|
+
}
|
|
439
|
+
},
|
|
440
|
+
// 获取片区
|
|
441
|
+
async getSliceArea () {
|
|
442
|
+
let data = {
|
|
443
|
+
source: 'this.getParentByType($organization$).getAllChildrens().where(row.getType() == $zone$)',
|
|
444
|
+
userid: this.$login.f.id
|
|
657
445
|
}
|
|
658
|
-
}
|
|
659
|
-
},
|
|
660
|
-
async streetChange () {
|
|
661
|
-
if (isEmpty(this.show_data.f_street)) {
|
|
662
|
-
return
|
|
663
|
-
}
|
|
664
446
|
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
`rs/sql/singleTable`,
|
|
673
|
-
{data: data},
|
|
674
|
-
{resolveMsg: null, rejectMsg: '集收单位查询失败!!!'}
|
|
675
|
-
)
|
|
676
|
-
|
|
677
|
-
this.setLabelOptions('集收单位', res.data.map(item => {
|
|
678
|
-
return {
|
|
679
|
-
label: item.f_residential_area,
|
|
680
|
-
value: item.f_residential_area
|
|
681
|
-
}
|
|
682
|
-
}))
|
|
683
|
-
},
|
|
684
|
-
async pcdChange () {
|
|
685
|
-
if (isEmpty(this.show_data.f_pcd)) {
|
|
686
|
-
return
|
|
687
|
-
}
|
|
447
|
+
let http = new HttpResetClass()
|
|
448
|
+
let res = await http.load(
|
|
449
|
+
'POST',
|
|
450
|
+
`rs/search`,
|
|
451
|
+
{data: data},
|
|
452
|
+
{resolveMsg: null, rejectMsg: '片区查询失败!!!'}
|
|
453
|
+
)
|
|
688
454
|
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
455
|
+
return res.data.map(item => {
|
|
456
|
+
return {
|
|
457
|
+
label: item.name,
|
|
458
|
+
value: item.name
|
|
459
|
+
}
|
|
460
|
+
})
|
|
461
|
+
},
|
|
462
|
+
// 获取区县
|
|
463
|
+
async getPcd () {
|
|
464
|
+
let data = {
|
|
465
|
+
tablename: 't_pcd',
|
|
466
|
+
condition: `f_filialeid = '${this.$login.f.orgid}'`
|
|
467
|
+
}
|
|
468
|
+
let http = new HttpResetClass()
|
|
469
|
+
let res = await http.load(
|
|
470
|
+
'POST',
|
|
471
|
+
`rs/sql/singleTable`,
|
|
472
|
+
{data: data},
|
|
473
|
+
{resolveMsg: null, rejectMsg: '区县查询失败!!!'}
|
|
474
|
+
)
|
|
694
475
|
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
476
|
+
return res.data.map(item => {
|
|
477
|
+
return {
|
|
478
|
+
label: item.f_pcd,
|
|
479
|
+
value: item.f_pcd
|
|
480
|
+
}
|
|
481
|
+
})
|
|
482
|
+
},
|
|
483
|
+
// 获取集收单位
|
|
484
|
+
async getArea () {
|
|
485
|
+
let data = {
|
|
486
|
+
tablename: 't_area',
|
|
487
|
+
condition: `f_filialeid = '${this.$login.f.orgid}'`
|
|
488
|
+
}
|
|
489
|
+
let http = new HttpResetClass()
|
|
490
|
+
let res = await http.load(
|
|
491
|
+
'POST',
|
|
492
|
+
`rs/sql/singleTable`,
|
|
493
|
+
{data: data},
|
|
494
|
+
{resolveMsg: null, rejectMsg: '集收单位查询失败!!!'}
|
|
495
|
+
)
|
|
496
|
+
|
|
497
|
+
return res.data.map(item => {
|
|
498
|
+
return {
|
|
499
|
+
label: item.f_residential_area,
|
|
500
|
+
value: item.f_residential_area
|
|
501
|
+
}
|
|
502
|
+
})
|
|
503
|
+
},
|
|
504
|
+
// 缴费前置
|
|
505
|
+
chargeBefore () {
|
|
506
|
+
if (Number(this.show_data.f_due_money) > Number(this.show_data.f_cumulative_payment_money) || Number(this.show_data.f_surplus_money) > 0) {
|
|
507
|
+
this.$showAlert('费用未结清!!!', 'warning', 3000)
|
|
508
|
+
throw null
|
|
509
|
+
}
|
|
510
|
+
},
|
|
511
|
+
// 施工前置 加表具后状态是待开通 提交后是正常 所以这里的判断条件需改正 (and uf.f_meter_classify is null and f_meternumber is null)
|
|
512
|
+
async constructionBefore () {
|
|
513
|
+
let http = new HttpResetClass()
|
|
514
|
+
let data = {
|
|
515
|
+
condition: `ui.f_process_id = '${this.show_data.f_process_id}' and uf.f_meter_classify is null and f_meternumber is null`
|
|
516
|
+
}
|
|
517
|
+
let res = await http.load(
|
|
518
|
+
'POST',
|
|
519
|
+
'rs/sql/countApplyUserinfo',
|
|
520
|
+
{data: data},
|
|
521
|
+
{
|
|
522
|
+
resolveMsg: null,
|
|
523
|
+
rejectMsg: '安装明细查询失败!!!'
|
|
524
|
+
})
|
|
525
|
+
if (res.data[0].num > 0) {
|
|
526
|
+
this.$showAlert(`还有${res.data[0].num}户未安装,无法提交`, 'warning', 3000)
|
|
527
|
+
throw `还有${res.data[0].num}户未安装,无法提交`
|
|
528
|
+
}
|
|
529
|
+
},
|
|
530
|
+
changePipeBuild () {
|
|
531
|
+
if (this.selectdata.f_process_dep === '工程部') {
|
|
532
|
+
return 'this.getParentByType($organization$).getChildByName($工程部报装$).getChildren()'
|
|
533
|
+
}
|
|
534
|
+
if (this.selectdata.f_process_dep === '运营部') {
|
|
535
|
+
return 'this.getParentByType($organization$).getChildByName($运营部报装$).getChildren()'
|
|
536
|
+
}
|
|
537
|
+
return 'this.getParentByType($organization$).getChildByName($工程部报装$).getChildren()'
|
|
538
|
+
},
|
|
539
|
+
async getDevInfo () {
|
|
540
|
+
let data = {
|
|
541
|
+
tablename: 't_dev_info',
|
|
542
|
+
condition: `f_orgid = '${this.$login.f.orgid}'`
|
|
543
|
+
}
|
|
544
|
+
let http = new HttpResetClass()
|
|
545
|
+
let res = await http.load(
|
|
546
|
+
'POST',
|
|
547
|
+
`rs/sql/singleTable`,
|
|
548
|
+
{data: data},
|
|
549
|
+
{resolveMsg: null, rejectMsg: '公司查询失败!!!'}
|
|
550
|
+
)
|
|
701
551
|
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
552
|
+
return res.data.map(item => {
|
|
553
|
+
return {
|
|
554
|
+
label: item.f_dev_name,
|
|
555
|
+
value: item.f_dev_name
|
|
556
|
+
}
|
|
557
|
+
})
|
|
558
|
+
},
|
|
559
|
+
async getPrice (f_price_id) {
|
|
560
|
+
console.log('=======================')
|
|
561
|
+
console.log(f_price_id)
|
|
709
562
|
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
label: item.f_street,
|
|
713
|
-
value: item.f_street
|
|
563
|
+
let data = {
|
|
564
|
+
condition: `sp.f_filialeid = '${this.$login.f.orgid}'`
|
|
714
565
|
}
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
566
|
+
if(this.Pricetype==='机表'){
|
|
567
|
+
data.condition=`sp.f_custom = '机表'`
|
|
568
|
+
}
|
|
569
|
+
if(this.Pricetype==='非机表'){
|
|
570
|
+
data.condition=`sp.f_custom = '非机表'`
|
|
571
|
+
}
|
|
572
|
+
|
|
573
|
+
if (!isEmpty(f_price_id)) {
|
|
574
|
+
data.condition = `sp.f_filialeid = '${this.$login.f.orgid}' and sp.f_price_id = ${f_price_id}`
|
|
575
|
+
}
|
|
576
|
+
let http = new HttpResetClass()
|
|
577
|
+
let res = await http.load(
|
|
578
|
+
'POST',
|
|
579
|
+
`rs/sql/applyGetPrice`,
|
|
580
|
+
{data: data},
|
|
581
|
+
{resolveMsg: null, rejectMsg: '气价查询失败!!!'}
|
|
582
|
+
)
|
|
583
|
+
|
|
584
|
+
let a= res.data.map(item => {
|
|
585
|
+
return {
|
|
586
|
+
label: item.f_price_name,
|
|
587
|
+
value: item
|
|
588
|
+
}
|
|
589
|
+
})
|
|
590
|
+
this.selectdata.fields.forEach(field => {
|
|
591
|
+
if (field.label === '气价名称') {
|
|
592
|
+
field.options = a}
|
|
593
|
+
})
|
|
594
|
+
return a
|
|
595
|
+
},
|
|
596
|
+
addressInitialization () {
|
|
597
|
+
this.$getConfig(this, 'UserAddress')
|
|
598
|
+
|
|
599
|
+
let f_address_type = this.show_data.f_address_type
|
|
600
|
+
|
|
601
|
+
for (const item of this.show_data.fields) {
|
|
602
|
+
if (f_address_type === '民用市区') {
|
|
603
|
+
if (item.label === '区/县' || item.label === '街道/乡镇' || item.label === '集收单位' || item.label === '门牌号') {
|
|
604
|
+
item.hidden = false
|
|
605
|
+
item.required = true
|
|
606
|
+
}
|
|
607
|
+
if (item.label === '楼号/组' || item.label === '单元/排' || item.label === '楼层') {
|
|
608
|
+
item.hidden = false
|
|
609
|
+
item.required = false
|
|
610
|
+
}
|
|
611
|
+
if (item.label === '地址') {
|
|
612
|
+
item.readonly = true
|
|
613
|
+
}
|
|
614
|
+
}
|
|
615
|
+
if (f_address_type === '民用乡镇') {
|
|
616
|
+
if (item.label === '区/县' || item.label === '街道/乡镇' || item.label === '集收单位' || item.label === '门牌号') {
|
|
617
|
+
item.hidden = false
|
|
618
|
+
item.required = true
|
|
619
|
+
}
|
|
620
|
+
if (item.label === '楼号/组' || item.label === '单元/排' || item.label === '楼层') {
|
|
621
|
+
item.hidden = false
|
|
622
|
+
item.required = false
|
|
623
|
+
}
|
|
624
|
+
if (item.label === '楼层') {
|
|
625
|
+
item.hidden = true
|
|
626
|
+
item.required = false
|
|
627
|
+
}
|
|
628
|
+
if (item.label === '地址') {
|
|
629
|
+
item.readonly = true
|
|
630
|
+
}
|
|
631
|
+
}
|
|
632
|
+
if (f_address_type === '特殊地址') {
|
|
633
|
+
if (item.label === '区/县' || item.label === '街道/乡镇') {
|
|
634
|
+
item.hidden = false
|
|
635
|
+
item.required = true
|
|
636
|
+
}
|
|
637
|
+
if (item.label === '集收单位') {
|
|
638
|
+
item.hidden = false
|
|
639
|
+
if (this.show_data.f_apply_type === '工商户报建'){
|
|
640
|
+
item.required = false
|
|
641
|
+
} else {
|
|
642
|
+
item.required = false
|
|
643
|
+
}
|
|
644
|
+
|
|
645
|
+
}
|
|
646
|
+
if (item.label === '楼号/组' || item.label === '单元/排' || item.label === '楼层' || item.label === '门牌号') {
|
|
647
|
+
item.hidden = true
|
|
648
|
+
item.required = false
|
|
649
|
+
}
|
|
650
|
+
if (item.label === '地址') {
|
|
651
|
+
item.readonly = false
|
|
652
|
+
}
|
|
653
|
+
}
|
|
735
654
|
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
655
|
+
if (this.show_data.f_apply_source === '线下发起' && item.label === '预约地址') {
|
|
656
|
+
item.hidden = true
|
|
657
|
+
}
|
|
658
|
+
}
|
|
659
|
+
},
|
|
660
|
+
async streetChange () {
|
|
661
|
+
if (isEmpty(this.show_data.f_street)) {
|
|
662
|
+
return
|
|
663
|
+
}
|
|
743
664
|
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
value: item.id
|
|
665
|
+
let data = {
|
|
666
|
+
tablename: 't_area',
|
|
667
|
+
condition: `f_filialeid = '${this.$login.f.orgid}' and f_street = '${this.show_data.f_street}'`
|
|
748
668
|
}
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
669
|
+
let http = new HttpResetClass()
|
|
670
|
+
let res = await http.load(
|
|
671
|
+
'POST',
|
|
672
|
+
`rs/sql/singleTable`,
|
|
673
|
+
{data: data},
|
|
674
|
+
{resolveMsg: null, rejectMsg: '集收单位查询失败!!!'}
|
|
675
|
+
)
|
|
753
676
|
|
|
754
|
-
|
|
677
|
+
this.setLabelOptions('集收单位', res.data.map(item => {
|
|
678
|
+
return {
|
|
679
|
+
label: item.f_residential_area,
|
|
680
|
+
value: item.f_residential_area
|
|
681
|
+
}
|
|
682
|
+
}))
|
|
683
|
+
},
|
|
684
|
+
async pcdChange () {
|
|
685
|
+
if (isEmpty(this.show_data.f_pcd)) {
|
|
686
|
+
return
|
|
687
|
+
}
|
|
755
688
|
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
689
|
+
let data = {
|
|
690
|
+
tablename: 't_street',
|
|
691
|
+
condition: `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}'`
|
|
692
|
+
}
|
|
693
|
+
let f_address_type = this.getLableValue('地址类型')
|
|
760
694
|
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
695
|
+
if (f_address_type === '民用市区') {
|
|
696
|
+
data.condition = `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}' and f_iscity = '市区'`
|
|
697
|
+
}
|
|
698
|
+
if (f_address_type === '民用乡镇') {
|
|
699
|
+
data.condition = `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}' and f_iscity = '乡镇'`
|
|
700
|
+
}
|
|
766
701
|
|
|
767
|
-
|
|
702
|
+
let http = new HttpResetClass()
|
|
703
|
+
let res = await http.load(
|
|
704
|
+
'POST',
|
|
705
|
+
`rs/sql/singleTable`,
|
|
706
|
+
{data: data},
|
|
707
|
+
{resolveMsg: null, rejectMsg: '街道/乡镇查询失败!!!'}
|
|
708
|
+
)
|
|
768
709
|
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
710
|
+
this.setLabelOptions('街道/乡镇', res.data.map(item => {
|
|
711
|
+
return {
|
|
712
|
+
label: item.f_street,
|
|
713
|
+
value: item.f_street
|
|
714
|
+
}
|
|
715
|
+
}))
|
|
716
|
+
},
|
|
717
|
+
async addressTips () {
|
|
718
|
+
// console.log('======================='+this.show_data.f_apply_type)
|
|
719
|
+
let res = ''
|
|
720
|
+
if (this.show_data.f_apply_type === '报警器报建' || this.show_data.f_apply_type === '工商业报警器报建') {
|
|
721
|
+
res = await this.$showMessage('报警器报建下单后将不能修改用户信息,请确认用户信息地址等是否正确,如不完善可在档案中进行修正!!!')
|
|
722
|
+
}else{
|
|
723
|
+
res = await this.$showMessage('增容改管下单后将不能修改用户信息,请确认用户信息地址等是否正确,如不完善可在档案中进行修正!!!')
|
|
724
|
+
}
|
|
725
|
+
if (res == 'confirm') {
|
|
726
|
+
return
|
|
727
|
+
}
|
|
728
|
+
throw '用户信息确认!!!'
|
|
729
|
+
},
|
|
730
|
+
async getDesignerPeople () {
|
|
731
|
+
let data = {
|
|
732
|
+
source: 'this.getParentByType($organization$).getChildByName($设计部报装$).getChildren()',
|
|
733
|
+
userid: this.$login.f.id
|
|
734
|
+
}
|
|
735
|
+
|
|
736
|
+
let http = new HttpResetClass()
|
|
737
|
+
let res = await http.load(
|
|
738
|
+
'POST',
|
|
739
|
+
`rs/search`,
|
|
740
|
+
{data: data},
|
|
741
|
+
{resolveMsg: null, rejectMsg: '设计人员查询失败!!!'}
|
|
742
|
+
)
|
|
743
|
+
|
|
744
|
+
return res.data.map(item => {
|
|
745
|
+
return {
|
|
746
|
+
label: item.name,
|
|
747
|
+
value: item.id
|
|
748
|
+
}
|
|
749
|
+
})
|
|
750
|
+
},
|
|
751
|
+
async surveyStopApply () {
|
|
752
|
+
console.log('终止报建!!!!!')
|
|
753
|
+
|
|
754
|
+
this.show_data.f_stop_reason = '现场勘察不符合报装条件'
|
|
755
|
+
|
|
756
|
+
let data = {
|
|
757
|
+
data: this.show_data,
|
|
758
|
+
user: this.$login.f
|
|
759
|
+
}
|
|
760
|
+
|
|
761
|
+
let res = await this.$resetpost(
|
|
762
|
+
`rs/logic/surveyStopApply`,
|
|
763
|
+
{data: data},
|
|
764
|
+
{resolveMsg: null, rejectMsg: '终止报建失败!!!'}
|
|
765
|
+
)
|
|
766
|
+
|
|
767
|
+
this.$dispatch('loadPage')
|
|
768
|
+
|
|
769
|
+
throw '终止报建!!!'
|
|
770
|
+
},
|
|
771
|
+
async contract_number() {
|
|
772
|
+
console.log("进入编号合同编号生成",this.$login.f.orgs)
|
|
773
|
+
let f_contract_number = ''
|
|
774
|
+
const nowDate = new Date();
|
|
775
|
+
const date = {
|
|
776
|
+
year: nowDate.getFullYear(),
|
|
777
|
+
month: nowDate.getMonth() + 1,
|
|
778
|
+
day: nowDate.getDate()
|
|
779
|
+
}
|
|
780
|
+
|
|
781
|
+
function upperCaseChars(dir) {
|
|
782
|
+
let string = '';
|
|
783
|
+
switch (dir){
|
|
784
|
+
case '周口市天然气有限公司':
|
|
785
|
+
string = 'ZK' // 当表达式的结果等于 房产 时,则执行该代码
|
|
786
|
+
break;
|
|
787
|
+
case '项城市天然气有限公司':
|
|
788
|
+
string = "XC" // 当表达式的结果等于 自建房 时,则执行该代码
|
|
789
|
+
break;
|
|
790
|
+
case '西华县天然气有限公司':
|
|
791
|
+
string = 'XH' // 当表达式的结果等于 商业 时,则执行该代码
|
|
792
|
+
break;
|
|
793
|
+
case '鹿邑县天然气有限公司':
|
|
794
|
+
string = 'LY' // 当表达式的结果等于 工业 时,则执行该代码
|
|
795
|
+
break;
|
|
796
|
+
case '郸城县天然气有限公司':
|
|
797
|
+
string = 'DC' // 当表达式的结果等于 中压 时,则执行该代码
|
|
798
|
+
break;
|
|
799
|
+
case '测试公司(一)':
|
|
800
|
+
string = 'CS' // 当表达式的结果等于 中压 时,则执行该代码
|
|
801
|
+
break;
|
|
802
|
+
default :
|
|
803
|
+
break; // 如果没有与表达式相同的值,则执行该代码
|
|
804
|
+
}
|
|
805
|
+
return string;
|
|
806
|
+
}
|
|
807
|
+
|
|
808
|
+
const dir = upperCaseChars(this.$login.f.orgs) //分公司
|
|
809
|
+
|
|
810
|
+
let type = 0 //类型
|
|
811
|
+
|
|
812
|
+
switch (this.show_data.f_entry_type){
|
|
813
|
+
case '城区/县城':
|
|
814
|
+
type = 1 // 当表达式的结果等于 城区 时,则执行该代码
|
|
815
|
+
break;
|
|
816
|
+
case '新农村':
|
|
817
|
+
type = 2 // 当表达式的结果等于 新农村 时,则执行该代码
|
|
818
|
+
break;
|
|
819
|
+
case '测试':
|
|
820
|
+
type = 3 // 当表达式的结果等于 新农村 时,则执行该代码
|
|
821
|
+
break;
|
|
822
|
+
default :
|
|
823
|
+
break; // 如果没有与表达式相同的值,则执行该代码
|
|
824
|
+
}
|
|
780
825
|
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
826
|
+
let nature = 0 // 性质
|
|
827
|
+
switch (this.show_data.f_apply_nature){
|
|
828
|
+
case '楼房':
|
|
829
|
+
nature = 1 // 当表达式的结果等于 楼房 时,则执行该代码
|
|
830
|
+
break;
|
|
831
|
+
case '房产':
|
|
832
|
+
nature = 1 // 当表达式的结果等于 房产 时,则执行该代码
|
|
833
|
+
break;
|
|
834
|
+
case '自建房':
|
|
835
|
+
nature = 2 // 当表达式的结果等于 自建房 时,则执行该代码
|
|
836
|
+
break;
|
|
837
|
+
case '商业':
|
|
838
|
+
nature = 3 // 当表达式的结果等于 商业 时,则执行该代码
|
|
839
|
+
break;
|
|
840
|
+
case '学校':
|
|
841
|
+
nature = 3 // 当表达式的结果等于 学校 时,则执行该代码
|
|
786
842
|
break;
|
|
787
|
-
case '
|
|
788
|
-
|
|
843
|
+
case '福利机构':
|
|
844
|
+
nature = 3 // 当表达式的结果等于 福利机构 时,则执行该代码
|
|
789
845
|
break;
|
|
790
|
-
case '
|
|
791
|
-
|
|
846
|
+
case '其他':
|
|
847
|
+
nature = 3 // 当表达式的结果等于 其他 时,则执行该代码
|
|
792
848
|
break;
|
|
793
|
-
case '
|
|
794
|
-
|
|
849
|
+
case '工业':
|
|
850
|
+
nature = 4 // 当表达式的结果等于 工业 时,则执行该代码
|
|
795
851
|
break;
|
|
796
|
-
case '
|
|
797
|
-
|
|
852
|
+
case '中压':
|
|
853
|
+
nature = 5 // 当表达式的结果等于 中压 时,则执行该代码
|
|
854
|
+
break;
|
|
855
|
+
case '测试':
|
|
856
|
+
nature = 6 // 当表达式的结果等于 中压 时,则执行该代码
|
|
798
857
|
break;
|
|
799
858
|
default :
|
|
800
859
|
break; // 如果没有与表达式相同的值,则执行该代码
|
|
801
860
|
}
|
|
802
|
-
return string;
|
|
803
|
-
}
|
|
804
|
-
|
|
805
|
-
const dir = upperCaseChars(this.$login.f.orgs) //分公司
|
|
806
861
|
|
|
807
|
-
|
|
862
|
+
const newMonth = date.month >= 10 ? date.month : '0' + date.month //月份
|
|
863
|
+
const dataYm = date.year + '-01-01'
|
|
864
|
+
const newYear = date.year + 1
|
|
865
|
+
const year = date.year.toString().substring(2,4) //年份
|
|
808
866
|
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
break;
|
|
813
|
-
case '新农村':
|
|
814
|
-
type = 2 // 当表达式的结果等于 新农村 时,则执行该代码
|
|
815
|
-
break;
|
|
816
|
-
default :
|
|
817
|
-
break; // 如果没有与表达式相同的值,则执行该代码
|
|
818
|
-
}
|
|
819
|
-
|
|
820
|
-
let nature = 0 // 性质
|
|
821
|
-
switch (this.show_data.f_apply_nature){
|
|
822
|
-
case '楼房':
|
|
823
|
-
nature = 1 // 当表达式的结果等于 楼房 时,则执行该代码
|
|
824
|
-
break;
|
|
825
|
-
case '房产':
|
|
826
|
-
nature = 1 // 当表达式的结果等于 房产 时,则执行该代码
|
|
827
|
-
break;
|
|
828
|
-
case '自建房':
|
|
829
|
-
nature = 2 // 当表达式的结果等于 自建房 时,则执行该代码
|
|
830
|
-
break;
|
|
831
|
-
case '商业':
|
|
832
|
-
nature = 3 // 当表达式的结果等于 商业 时,则执行该代码
|
|
833
|
-
break;
|
|
834
|
-
case '学校':
|
|
835
|
-
nature = 3 // 当表达式的结果等于 学校 时,则执行该代码
|
|
836
|
-
break;
|
|
837
|
-
case '福利机构':
|
|
838
|
-
nature = 3 // 当表达式的结果等于 福利机构 时,则执行该代码
|
|
839
|
-
break;
|
|
840
|
-
case '其他':
|
|
841
|
-
nature = 3 // 当表达式的结果等于 其他 时,则执行该代码
|
|
842
|
-
break;
|
|
843
|
-
case '工业':
|
|
844
|
-
nature = 4 // 当表达式的结果等于 工业 时,则执行该代码
|
|
845
|
-
break;
|
|
846
|
-
case '中压':
|
|
847
|
-
nature = 5 // 当表达式的结果等于 中压 时,则执行该代码
|
|
848
|
-
break;
|
|
849
|
-
default :
|
|
850
|
-
break; // 如果没有与表达式相同的值,则执行该代码
|
|
851
|
-
}
|
|
852
|
-
|
|
853
|
-
const newMonth = date.month >= 10 ? date.month : '0' + date.month //月份
|
|
854
|
-
const dataYm = date.year + '-01-01'
|
|
855
|
-
const newYear = date.year + 1
|
|
856
|
-
const year = date.year.toString().substring(2,4) //年份
|
|
857
|
-
|
|
858
|
-
let data = {
|
|
859
|
-
orgid: this.$login.f.orgid
|
|
860
|
-
}
|
|
867
|
+
let data = {
|
|
868
|
+
orgid: this.$login.f.orgid
|
|
869
|
+
}
|
|
861
870
|
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
+
let http = new HttpResetClass()
|
|
872
|
+
let res = await http.load('POST', 'rs/sql/contractCount', {data:data}, {
|
|
873
|
+
resolveMsg: null,
|
|
874
|
+
rejectMsg: null
|
|
875
|
+
})
|
|
876
|
+
let oldDate
|
|
877
|
+
for (const item of res.data) {
|
|
878
|
+
if (item.name === '合同编号最后更新日期'){
|
|
879
|
+
oldDate = item.value
|
|
880
|
+
}
|
|
871
881
|
}
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
+
for (const item of res.data){
|
|
883
|
+
if (item.name === '合同编号'){
|
|
884
|
+
if (item.value === 0 || Date.parse(oldDate) < Date.parse(dataYm)) {
|
|
885
|
+
f_contract_number = dir + type + nature + year + newMonth + '001'
|
|
886
|
+
console.log("触发if", f_contract_number)
|
|
887
|
+
} else {
|
|
888
|
+
let count = item.value
|
|
889
|
+
f_contract_number = dir + type + nature + year + newMonth + this.PrefixInteger(count, 3)
|
|
890
|
+
console.log("触发else", f_contract_number)
|
|
891
|
+
}
|
|
882
892
|
}
|
|
883
893
|
}
|
|
894
|
+
this.selectdata.f_contract_number = f_contract_number
|
|
895
|
+
this.show_data.f_contract_number = f_contract_number
|
|
896
|
+
return f_contract_number
|
|
897
|
+
},
|
|
898
|
+
PrefixInteger(num, n) {
|
|
899
|
+
return (Array(n).join(0) + num).slice(-n);
|
|
884
900
|
}
|
|
885
|
-
this.selectdata.f_contract_number = f_contract_number
|
|
886
|
-
this.show_data.f_contract_number = f_contract_number
|
|
887
|
-
return f_contract_number
|
|
888
901
|
},
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
+
events: {
|
|
903
|
+
'priceType'(index){
|
|
904
|
+
this.Pricetype = this.getLableValue('所属类型')
|
|
905
|
+
console.log('打印方法值',this.getPrice(this.show_data.f_price_id))
|
|
906
|
+
for (const item of this.show_data.fields) {
|
|
907
|
+
if (this.show_data.f_sprice_type !=null && this.show_data.f_sprice_type !='') {
|
|
908
|
+
if(item.label==='气价名称'){
|
|
909
|
+
this.getPrice(this.show_data.f_price_id).then(value =>{
|
|
910
|
+
item.options=value
|
|
911
|
+
})
|
|
912
|
+
console.log('最终',item.options)
|
|
913
|
+
}
|
|
914
|
+
}
|
|
915
|
+
}
|
|
916
|
+
},
|
|
917
|
+
'complyInstallation' (index) {
|
|
918
|
+
if (this.show_data.f_is_have === '否') {
|
|
919
|
+
this.hideButtons('提交', '出图', '缴费')
|
|
920
|
+
this.showButtons('终止')
|
|
921
|
+
}
|
|
922
|
+
if (this.show_data.f_is_have === '是') {
|
|
923
|
+
this.hideButtons('终止')
|
|
924
|
+
this.showButtons('提交', '出图', '缴费')
|
|
925
|
+
}
|
|
926
|
+
},
|
|
927
|
+
async 'igniteDispatchReadyEvent' () {
|
|
928
|
+
let data = {
|
|
929
|
+
tablename: 'activityins',
|
|
930
|
+
condition: `processid = '${this.show_data.f_process_id}' and defname = '工程施工' and state = '结束'`
|
|
931
|
+
}
|
|
932
|
+
let http = new HttpResetClass()
|
|
933
|
+
let res = await http.load(
|
|
934
|
+
'POST',
|
|
935
|
+
`rs/sql/singleTable`,
|
|
936
|
+
{data: data},
|
|
937
|
+
{resolveMsg: null, rejectMsg: '查询失败!!!'}
|
|
938
|
+
)
|
|
939
|
+
if (res.data.length <= 0) {
|
|
940
|
+
console.log('+++++++++++++++++++++++++++++')
|
|
941
|
+
console.log('没有施工,不能退回')
|
|
942
|
+
this.hideButtons('退回')
|
|
943
|
+
}
|
|
944
|
+
},
|
|
945
|
+
'buildReadyEvent' () {
|
|
946
|
+
this.setLabelValue('施工单位', this.$login.f.name)
|
|
947
|
+
this.setLabelValue('施工安装时间', new Date().Format('yyyy-MM-dd HH:mm:ss'))
|
|
948
|
+
},
|
|
949
|
+
// 选择材料
|
|
950
|
+
async materialNameChenge (index, fieldIndex) {
|
|
951
|
+
let material = this.show_data.onetomany[index].fields[fieldIndex].value
|
|
952
|
+
|
|
953
|
+
this.show_data.onetomany[index].fields.forEach(item => {
|
|
954
|
+
if (material[item.field]) {
|
|
955
|
+
item.value = material[item.field]
|
|
956
|
+
}
|
|
957
|
+
})
|
|
958
|
+
},
|
|
959
|
+
// 打开模态框获取材料
|
|
960
|
+
async 'getMaterialName' (index) {
|
|
961
|
+
let data = {
|
|
962
|
+
condition: `1=1`
|
|
963
|
+
}
|
|
964
|
+
let http = new HttpResetClass()
|
|
965
|
+
let res = await http.load(
|
|
966
|
+
'POST',
|
|
967
|
+
`rs/sql/getStockMaterial`,
|
|
968
|
+
{data: data},
|
|
969
|
+
{resolveMsg: null, rejectMsg: '材料查询失败!!!'}
|
|
970
|
+
)
|
|
971
|
+
|
|
972
|
+
this.show_data.onetomany[index].fields.forEach(field => {
|
|
973
|
+
if (field.label === '选择材料') {
|
|
974
|
+
field.options = res.data.map(item => {
|
|
975
|
+
return {
|
|
976
|
+
'label': `${item.f_material_name}--${item.f_material_style}--${item.f_material_unit}`,
|
|
977
|
+
'value': item
|
|
978
|
+
}
|
|
902
979
|
})
|
|
903
|
-
console.log('最终',item.options)
|
|
904
980
|
}
|
|
981
|
+
})
|
|
982
|
+
},
|
|
983
|
+
// 搜索小区
|
|
984
|
+
async 'searchArea' (area, index) {
|
|
985
|
+
let data = {
|
|
986
|
+
tablename: 't_area',
|
|
987
|
+
condition: `f_filialeid = '${this.$login.f.orgid}' and f_street = '${this.show_data.f_street}' and f_residential_area like '%${area}%'`
|
|
905
988
|
}
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
if (this.show_data.f_is_have === '是') {
|
|
914
|
-
this.hideButtons('终止')
|
|
915
|
-
this.showButtons('提交', '出图', '缴费')
|
|
916
|
-
}
|
|
917
|
-
},
|
|
918
|
-
async 'igniteDispatchReadyEvent' () {
|
|
919
|
-
let data = {
|
|
920
|
-
tablename: 'activityins',
|
|
921
|
-
condition: `processid = '${this.show_data.f_process_id}' and defname = '工程施工' and state = '结束'`
|
|
922
|
-
}
|
|
923
|
-
let http = new HttpResetClass()
|
|
924
|
-
let res = await http.load(
|
|
925
|
-
'POST',
|
|
926
|
-
`rs/sql/singleTable`,
|
|
927
|
-
{data: data},
|
|
928
|
-
{resolveMsg: null, rejectMsg: '查询失败!!!'}
|
|
929
|
-
)
|
|
930
|
-
if (res.data.length <= 0) {
|
|
931
|
-
console.log('+++++++++++++++++++++++++++++')
|
|
932
|
-
console.log('没有施工,不能退回')
|
|
933
|
-
this.hideButtons('退回')
|
|
934
|
-
}
|
|
935
|
-
},
|
|
936
|
-
'buildReadyEvent' () {
|
|
937
|
-
this.setLabelValue('施工单位', this.$login.f.name)
|
|
938
|
-
this.setLabelValue('施工安装时间', new Date().Format('yyyy-MM-dd HH:mm:ss'))
|
|
939
|
-
},
|
|
940
|
-
// 选择材料
|
|
941
|
-
async materialNameChenge (index, fieldIndex) {
|
|
942
|
-
let material = this.show_data.onetomany[index].fields[fieldIndex].value
|
|
989
|
+
let http = new HttpResetClass()
|
|
990
|
+
let res = await http.load(
|
|
991
|
+
'POST',
|
|
992
|
+
`rs/sql/singleTable`,
|
|
993
|
+
{data: data},
|
|
994
|
+
{resolveMsg: null, rejectMsg: '集收单位查询失败!!!'}
|
|
995
|
+
)
|
|
943
996
|
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
item.value = material[item.field]
|
|
997
|
+
if (res.data.length === 0) {
|
|
998
|
+
return
|
|
947
999
|
}
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
)
|
|
962
|
-
|
|
963
|
-
this.show_data.onetomany[index].fields.forEach(field => {
|
|
964
|
-
if (field.label === '选择材料') {
|
|
965
|
-
field.options = res.data.map(item => {
|
|
966
|
-
return {
|
|
967
|
-
'label': `${item.f_material_name}--${item.f_material_style}--${item.f_material_unit}`,
|
|
968
|
-
'value': item
|
|
969
|
-
}
|
|
970
|
-
})
|
|
1000
|
+
|
|
1001
|
+
this.setLabelOptions('集收单位', res.data.map(item => {
|
|
1002
|
+
return {
|
|
1003
|
+
label: item.f_residential_area,
|
|
1004
|
+
value: item.f_residential_area
|
|
1005
|
+
}
|
|
1006
|
+
}))
|
|
1007
|
+
},
|
|
1008
|
+
// 搜索小区
|
|
1009
|
+
async 'searchAreaCollective' (area, index) {
|
|
1010
|
+
let data = {
|
|
1011
|
+
tablename: 't_area',
|
|
1012
|
+
condition: `f_filialeid = '${this.$login.f.orgid}' and f_residential_area like '%${area}%'`
|
|
971
1013
|
}
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
}
|
|
980
|
-
let http = new HttpResetClass()
|
|
981
|
-
let res = await http.load(
|
|
982
|
-
'POST',
|
|
983
|
-
`rs/sql/singleTable`,
|
|
984
|
-
{data: data},
|
|
985
|
-
{resolveMsg: null, rejectMsg: '集收单位查询失败!!!'}
|
|
986
|
-
)
|
|
987
|
-
|
|
988
|
-
if (res.data.length === 0) {
|
|
989
|
-
return
|
|
990
|
-
}
|
|
1014
|
+
let http = new HttpResetClass()
|
|
1015
|
+
let res = await http.load(
|
|
1016
|
+
'POST',
|
|
1017
|
+
`rs/sql/singleTable`,
|
|
1018
|
+
{data: data},
|
|
1019
|
+
{resolveMsg: null, rejectMsg: '集收单位查询失败!!!'}
|
|
1020
|
+
)
|
|
991
1021
|
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
label: item.f_residential_area,
|
|
995
|
-
value: item.f_residential_area
|
|
1022
|
+
if (res.data.length === 0) {
|
|
1023
|
+
return
|
|
996
1024
|
}
|
|
997
|
-
}))
|
|
998
|
-
},
|
|
999
|
-
// 搜索小区
|
|
1000
|
-
async 'searchAreaCollective' (area, index) {
|
|
1001
|
-
let data = {
|
|
1002
|
-
tablename: 't_area',
|
|
1003
|
-
condition: `f_filialeid = '${this.$login.f.orgid}' and f_residential_area like '%${area}%'`
|
|
1004
|
-
}
|
|
1005
|
-
let http = new HttpResetClass()
|
|
1006
|
-
let res = await http.load(
|
|
1007
|
-
'POST',
|
|
1008
|
-
`rs/sql/singleTable`,
|
|
1009
|
-
{data: data},
|
|
1010
|
-
{resolveMsg: null, rejectMsg: '集收单位查询失败!!!'}
|
|
1011
|
-
)
|
|
1012
|
-
|
|
1013
|
-
if (res.data.length === 0) {
|
|
1014
|
-
return
|
|
1015
|
-
}
|
|
1016
1025
|
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1026
|
+
this.setLabelOptions('集收单位', res.data.map(item => {
|
|
1027
|
+
return {
|
|
1028
|
+
label: item.f_residential_area,
|
|
1029
|
+
value: item.f_residential_area
|
|
1030
|
+
}
|
|
1031
|
+
}))
|
|
1032
|
+
},
|
|
1033
|
+
// 选择气价
|
|
1034
|
+
'priceChange' (index) {
|
|
1035
|
+
debugger
|
|
1036
|
+
if (isEmpty(this.show_data.stairPrice)) {
|
|
1037
|
+
return
|
|
1021
1038
|
}
|
|
1022
|
-
}))
|
|
1023
|
-
},
|
|
1024
|
-
// 选择气价
|
|
1025
|
-
'priceChange' (index) {
|
|
1026
|
-
debugger
|
|
1027
|
-
if (isEmpty(this.show_data.stairPrice)) {
|
|
1028
|
-
return
|
|
1029
|
-
}
|
|
1030
1039
|
|
|
1031
|
-
|
|
1040
|
+
let stairPrice = this.getLableValue('气价名称')
|
|
1032
1041
|
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1042
|
+
this.setLabelValue('气价类型', stairPrice.f_price_type)
|
|
1043
|
+
this.setLabelValue('用气性质', stairPrice.f_gasproperties)
|
|
1044
|
+
this.setLabelValue('价格', stairPrice.f_price)
|
|
1045
|
+
this.setLabelValue('客户类型', stairPrice.f_user_type)
|
|
1037
1046
|
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1047
|
+
this.show_data.f_price_id = stairPrice.f_price_id
|
|
1048
|
+
this.show_data.f_price_name = stairPrice.f_price_name
|
|
1049
|
+
},
|
|
1050
|
+
// 选择开发商
|
|
1051
|
+
async 'devInfoChange' (index) {
|
|
1052
|
+
if (isEmpty(this.show_data.f_company_name)) {
|
|
1053
|
+
return
|
|
1054
|
+
}
|
|
1055
|
+
let data = {
|
|
1056
|
+
tablename: 't_dev_info',
|
|
1057
|
+
condition: `f_orgid = '${this.$login.f.orgid}' and f_dev_name = '${this.show_data.f_company_name}'`
|
|
1058
|
+
}
|
|
1059
|
+
let res = await this.$resetpost(
|
|
1060
|
+
`rs/sql/singleTable`,
|
|
1061
|
+
{data: data},
|
|
1062
|
+
{resolveMsg: null, rejectMsg: '公司查询失败!!!'}
|
|
1063
|
+
)
|
|
1064
|
+
this.show_data.f_dev_id = res.data[0].id
|
|
1065
|
+
this.show_data.f_dev_code = res.data[0].f_dev_code
|
|
1066
|
+
this.setLabelValue('法人名称', res.data[0].f_legal_person)
|
|
1067
|
+
this.setLabelValue('身份证', res.data[0].f_idnumber)
|
|
1068
|
+
this.setLabelValue('营业执照', res.data[0].f_license_num)
|
|
1069
|
+
},
|
|
1070
|
+
// 退款金额
|
|
1071
|
+
'refundMoneyChange' (index) {
|
|
1072
|
+
let f_cumulative_payment_money = this.show_data.f_cumulative_payment_money
|
|
1073
|
+
let f_refund_money = this.show_data.fields[index].value
|
|
1074
|
+
|
|
1075
|
+
if (f_refund_money > f_cumulative_payment_money) {
|
|
1076
|
+
this.$showAlert('退款金额不能大于累计缴费金额!!!', 'warning', 3000)
|
|
1077
|
+
this.show_data.fields[index].value = null
|
|
1078
|
+
}
|
|
1079
|
+
},
|
|
1080
|
+
// 检查重复
|
|
1081
|
+
'checkRepeat' (index) {
|
|
1082
|
+
this.checkDuplicate(index)
|
|
1083
|
+
},
|
|
1084
|
+
// 选择报建项目
|
|
1085
|
+
'selectApply' (row) {
|
|
1086
|
+
this.setLabelValue('工程名称', row.f_entry_name)
|
|
1087
|
+
this.setLabelValue('工程编号', row.f_apply_num)
|
|
1088
|
+
this.setLabelValue('报建类型', row.f_apply_type)
|
|
1089
|
+
this.setLabelValue('用户名称', row.f_user_name)
|
|
1090
|
+
this.setLabelValue('用户电话', row.f_phone)
|
|
1091
|
+
this.setLabelValue('证件类型', row.f_credentials)
|
|
1092
|
+
this.setLabelValue('证件号码', row.f_idnumber)
|
|
1093
|
+
this.setLabelValue('地址', row.f_address)
|
|
1094
|
+
this.setLabelValue('累计缴费金额', row.f_cumulative_payment_money)
|
|
1095
|
+
|
|
1096
|
+
this.show_data.parentApply = JSON.parse(JSON.stringify(row))
|
|
1097
|
+
|
|
1098
|
+
delete row.id
|
|
1099
|
+
delete row.actid
|
|
1100
|
+
delete row.defid
|
|
1101
|
+
delete row.defname
|
|
1102
|
+
delete row.version
|
|
1103
|
+
delete row.f_apply_num
|
|
1104
|
+
delete row.f_sub_state
|
|
1105
|
+
delete row.f_apply_type
|
|
1106
|
+
delete row.f_process_id
|
|
1107
|
+
|
|
1108
|
+
this.show_data = Object.assign({}, this.show_data, row)
|
|
1109
|
+
|
|
1110
|
+
this.show_data.f_parent_process_id = this.show_data.parentApply.f_process_id
|
|
1111
|
+
},
|
|
1112
|
+
// 是否终止
|
|
1113
|
+
'isStopChange' (index) {
|
|
1114
|
+
let f_is_stop = this.show_data.f_is_stop
|
|
1106
1115
|
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1116
|
+
for (const item of this.show_data.fields) {
|
|
1117
|
+
if (f_is_stop === '是') {
|
|
1118
|
+
if (item.label === '终止原因') {
|
|
1119
|
+
item.hidden = false
|
|
1120
|
+
item.required = true
|
|
1121
|
+
}
|
|
1122
|
+
} else {
|
|
1123
|
+
if (item.label === '终止原因') {
|
|
1124
|
+
item.hidden = true
|
|
1125
|
+
item.required = false
|
|
1126
|
+
}
|
|
1117
1127
|
}
|
|
1118
1128
|
}
|
|
1119
|
-
}
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
async 'stopApplyReadyEvent' () {
|
|
1129
|
+
},
|
|
1130
|
+
// 终止报建初始化
|
|
1131
|
+
async 'stopApplyReadyEvent' () {
|
|
1123
1132
|
|
|
1124
|
-
|
|
1133
|
+
let f_is_stop = this.getLableValue('是否终止')
|
|
1125
1134
|
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1135
|
+
for (const item of this.show_data.fields) {
|
|
1136
|
+
if (f_is_stop === '是') {
|
|
1137
|
+
if (item.label === '终止原因') {
|
|
1138
|
+
item.hidden = false
|
|
1139
|
+
item.required = true
|
|
1140
|
+
}
|
|
1141
|
+
} else {
|
|
1142
|
+
if (item.label === '终止原因') {
|
|
1143
|
+
item.hidden = true
|
|
1144
|
+
item.required = false
|
|
1145
|
+
}
|
|
1136
1146
|
}
|
|
1137
1147
|
}
|
|
1138
|
-
}
|
|
1139
1148
|
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
}
|
|
1143
|
-
let data = {
|
|
1144
|
-
condition: `f_process_id = '${this.show_data.f_parent_process_id}'`,
|
|
1145
|
-
data: {
|
|
1146
|
-
id: this.$login.f.id,
|
|
1147
|
-
orgid: this.$login.f.orgid
|
|
1149
|
+
if (isEmpty(this.show_data.f_parent_process_id)) {
|
|
1150
|
+
return
|
|
1148
1151
|
}
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
)
|
|
1155
|
-
this.show_data.parentApply = res.data[0]
|
|
1156
|
-
},
|
|
1157
|
-
// 选择用户档案信息
|
|
1158
|
-
'selectUserinfo' (row) {
|
|
1159
|
-
this.setLabelValue('用户编号', row.f_userinfo_code)
|
|
1160
|
-
this.setLabelValue('用户名称', row.f_user_name)
|
|
1161
|
-
this.setLabelValue('用户电话', row.f_user_phone)
|
|
1162
|
-
this.setLabelValue('证件类型', row.f_credentials)
|
|
1163
|
-
this.setLabelValue('证件号码', row.f_idnumber)
|
|
1164
|
-
this.setLabelValue('地址', row.f_address)
|
|
1165
|
-
|
|
1166
|
-
this.show_data.f_userinfo_id = row.f_userinfo_id
|
|
1167
|
-
this.show_data.f_userinfo_code = row.f_userinfo_code
|
|
1168
|
-
},
|
|
1169
|
-
// 是否购买保险
|
|
1170
|
-
async 'isInsureChange' (index) {
|
|
1171
|
-
if (!this.show_data.f_is_insure) {
|
|
1172
|
-
return
|
|
1173
|
-
}
|
|
1174
|
-
let f_is_insure = this.show_data.f_is_insure
|
|
1175
|
-
for (const item of this.show_data.fields) {
|
|
1176
|
-
if (f_is_insure === '是') {
|
|
1177
|
-
if (item.label === '保费开始日期' || item.label === '保费结束日期' || item.label === '险种' || item.label === '保费金额') {
|
|
1178
|
-
item.hidden = false
|
|
1179
|
-
item.required = true
|
|
1180
|
-
}
|
|
1181
|
-
if (item.label === '保险备注') {
|
|
1182
|
-
item.hidden = false
|
|
1183
|
-
}
|
|
1184
|
-
} else {
|
|
1185
|
-
if (item.label === '保费开始日期' || item.label === '保费结束日期' || item.label === '险种' || item.label === '保费金额' || item.label === '保险备注') {
|
|
1186
|
-
item.hidden = true
|
|
1187
|
-
item.required = false
|
|
1152
|
+
let data = {
|
|
1153
|
+
condition: `f_process_id = '${this.show_data.f_parent_process_id}'`,
|
|
1154
|
+
data: {
|
|
1155
|
+
id: this.$login.f.id,
|
|
1156
|
+
orgid: this.$login.f.orgid
|
|
1188
1157
|
}
|
|
1189
1158
|
}
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
)
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
for (const item of this.show_data.fields) {
|
|
1214
|
-
if (item.label === '保费开始日期' || item.label === '是否购买保险' || item.label === '保费结束日期' || item.label === '险种' || item.label === '保费金额' || item.label === '保险备注') {
|
|
1215
|
-
item.hidden = true
|
|
1216
|
-
item.required = false
|
|
1217
|
-
item.value = null
|
|
1218
|
-
}
|
|
1159
|
+
let res = await this.$resetpost(
|
|
1160
|
+
`rs/sql/supervisory`,
|
|
1161
|
+
{data: data},
|
|
1162
|
+
{resolveMsg: null, rejectMsg: '项目查询失败!!!'}
|
|
1163
|
+
)
|
|
1164
|
+
this.show_data.parentApply = res.data[0]
|
|
1165
|
+
},
|
|
1166
|
+
// 选择用户档案信息
|
|
1167
|
+
'selectUserinfo' (row) {
|
|
1168
|
+
this.setLabelValue('用户编号', row.f_userinfo_code)
|
|
1169
|
+
this.setLabelValue('用户名称', row.f_user_name)
|
|
1170
|
+
this.setLabelValue('用户电话', row.f_user_phone)
|
|
1171
|
+
this.setLabelValue('证件类型', row.f_credentials)
|
|
1172
|
+
this.setLabelValue('证件号码', row.f_idnumber)
|
|
1173
|
+
this.setLabelValue('地址', row.f_address)
|
|
1174
|
+
|
|
1175
|
+
this.show_data.f_userinfo_id = row.f_userinfo_id
|
|
1176
|
+
this.show_data.f_userinfo_code = row.f_userinfo_code
|
|
1177
|
+
},
|
|
1178
|
+
// 是否购买保险
|
|
1179
|
+
async 'isInsureChange' (index) {
|
|
1180
|
+
if (!this.show_data.f_is_insure) {
|
|
1181
|
+
return
|
|
1219
1182
|
}
|
|
1220
|
-
|
|
1221
|
-
this.setLabelValue('待执行保险', '否')
|
|
1183
|
+
let f_is_insure = this.show_data.f_is_insure
|
|
1222
1184
|
for (const item of this.show_data.fields) {
|
|
1223
|
-
if (
|
|
1224
|
-
item.
|
|
1225
|
-
|
|
1185
|
+
if (f_is_insure === '是') {
|
|
1186
|
+
if (item.label === '保费开始日期' || item.label === '保费结束日期' || item.label === '险种' || item.label === '保费金额') {
|
|
1187
|
+
item.hidden = false
|
|
1188
|
+
item.required = true
|
|
1189
|
+
}
|
|
1190
|
+
if (item.label === '保险备注') {
|
|
1191
|
+
item.hidden = false
|
|
1192
|
+
}
|
|
1193
|
+
} else {
|
|
1194
|
+
if (item.label === '保费开始日期' || item.label === '保费结束日期' || item.label === '险种' || item.label === '保费金额' || item.label === '保险备注') {
|
|
1195
|
+
item.hidden = true
|
|
1196
|
+
item.required = false
|
|
1197
|
+
}
|
|
1226
1198
|
}
|
|
1227
1199
|
}
|
|
1228
|
-
}
|
|
1200
|
+
},
|
|
1201
|
+
// 通气点火初始化
|
|
1202
|
+
async 'gasReadyEvent' () {
|
|
1203
|
+
// 是否有气价信息
|
|
1204
|
+
if (!isEmpty(this.show_data.f_price_id)) {
|
|
1205
|
+
let priceList = await this.getPrice(this.show_data.f_price_id)
|
|
1206
|
+
this.setLabelValue('气价名称', priceList[0].value)
|
|
1207
|
+
}
|
|
1229
1208
|
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1209
|
+
let data = {
|
|
1210
|
+
tablename: 't_userfees',
|
|
1211
|
+
condition: `f_orgid = '${this.$login.f.orgid}' and f_userinfo_id = '${this.show_data.f_userinfo_id}' and f_state = '待执行'`
|
|
1212
|
+
}
|
|
1213
|
+
let http = new HttpResetClass()
|
|
1214
|
+
let res = await http.load(
|
|
1215
|
+
'POST',
|
|
1216
|
+
`rs/sql/singleTable`,
|
|
1217
|
+
{data: data},
|
|
1218
|
+
{resolveMsg: null, rejectMsg: '保险查询失败!!!'}
|
|
1219
|
+
)
|
|
1220
|
+
if (res.data.length > 0) {
|
|
1221
|
+
this.setLabelValue('待执行保险', '是')
|
|
1222
|
+
for (const item of this.show_data.fields) {
|
|
1223
|
+
if (item.label === '保费开始日期' || item.label === '是否购买保险' || item.label === '保费结束日期' || item.label === '险种' || item.label === '保费金额' || item.label === '保险备注') {
|
|
1224
|
+
item.hidden = true
|
|
1225
|
+
item.required = false
|
|
1226
|
+
item.value = null
|
|
1227
|
+
}
|
|
1240
1228
|
}
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1229
|
+
} else {
|
|
1230
|
+
this.setLabelValue('待执行保险', '否')
|
|
1231
|
+
for (const item of this.show_data.fields) {
|
|
1232
|
+
if (item.label === '是否购买保险' || item.label === '保费开始日期' || item.label === '保费结束日期' || item.label === '险种' || item.label === '保费金额' || item.label === '保险备注') {
|
|
1233
|
+
item.hidden = false
|
|
1234
|
+
item.required = true
|
|
1235
|
+
}
|
|
1245
1236
|
}
|
|
1246
1237
|
}
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1238
|
+
|
|
1239
|
+
// 保险初始化显示内容
|
|
1240
|
+
let f_is_insure = this.getLableValue('是否购买保险')
|
|
1241
|
+
for (const item of this.show_data.fields) {
|
|
1242
|
+
if (f_is_insure === '是') {
|
|
1243
|
+
if (item.label === '保费开始日期' || item.label === '保费结束日期' || item.label === '险种' || item.label === '保费金额') {
|
|
1244
|
+
item.hidden = false
|
|
1245
|
+
item.required = true
|
|
1246
|
+
}
|
|
1247
|
+
if (item.label === '保险备注') {
|
|
1248
|
+
item.hidden = false
|
|
1249
|
+
}
|
|
1250
|
+
// 本期保费到期时间默认一年
|
|
1251
|
+
if (isEmpty(this.selectdata.f_ins_expiration_date)) {
|
|
1252
|
+
let f_ins_expiration_date = new Date().setFullYear(new Date().getFullYear() + 1)
|
|
1253
|
+
this.setLabelValue("保费结束日期", new Date(f_ins_expiration_date).Format('yyyy-MM-dd'))
|
|
1254
|
+
}
|
|
1255
|
+
}
|
|
1256
|
+
if (f_is_insure === '否') {
|
|
1257
|
+
if (item.label === '保费开始日期' || item.label === '保费结束日期' || item.label === '险种' || item.label === '保费金额' || item.label === '保险备注') {
|
|
1258
|
+
item.hidden = true
|
|
1259
|
+
item.required = false
|
|
1260
|
+
}
|
|
1251
1261
|
}
|
|
1252
1262
|
}
|
|
1253
|
-
}
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
)
|
|
1267
|
-
|
|
1268
|
-
this.setLabelValue('应交金额', res.data)
|
|
1269
|
-
},
|
|
1270
|
-
// 街道失去焦点
|
|
1271
|
-
async 'streetChange' (index) {
|
|
1272
|
-
if (isEmpty(this.show_data.f_street)) {
|
|
1273
|
-
return
|
|
1274
|
-
}
|
|
1275
|
-
|
|
1276
|
-
this.setLabelValue('集收单位', null)
|
|
1263
|
+
},
|
|
1264
|
+
// 合同金额失去焦点
|
|
1265
|
+
async 'contractMoneyChange' (index) {
|
|
1266
|
+
let data = {
|
|
1267
|
+
operator: '+',
|
|
1268
|
+
num1: this.show_data.f_contract_money || 0,
|
|
1269
|
+
num2: this.getLableValue('追加金额') || 0
|
|
1270
|
+
}
|
|
1271
|
+
let res = await this.$resetpost(
|
|
1272
|
+
`rs/logic/compute`,
|
|
1273
|
+
{data: data},
|
|
1274
|
+
{resolveMsg: null, rejectMsg: '金额计算失败!!!'}
|
|
1275
|
+
)
|
|
1277
1276
|
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
`rs/sql/singleTable`,
|
|
1286
|
-
{data: data},
|
|
1287
|
-
{resolveMsg: null, rejectMsg: '集收单位查询失败!!!'}
|
|
1288
|
-
)
|
|
1289
|
-
|
|
1290
|
-
this.setLabelOptions('集收单位', res.data.map(item => {
|
|
1291
|
-
return {
|
|
1292
|
-
label: item.f_residential_area,
|
|
1293
|
-
value: item.f_residential_area
|
|
1294
|
-
}
|
|
1295
|
-
}))
|
|
1296
|
-
},
|
|
1297
|
-
// 区县失去焦点
|
|
1298
|
-
async 'pcdChange' (index) {
|
|
1299
|
-
if (isEmpty(this.show_data.f_pcd)) {
|
|
1300
|
-
return
|
|
1301
|
-
}
|
|
1277
|
+
this.setLabelValue('应交金额', res.data)
|
|
1278
|
+
},
|
|
1279
|
+
// 街道失去焦点
|
|
1280
|
+
async 'streetChange' (index) {
|
|
1281
|
+
if (isEmpty(this.show_data.f_street)) {
|
|
1282
|
+
return
|
|
1283
|
+
}
|
|
1302
1284
|
|
|
1303
|
-
|
|
1304
|
-
this.setLabelValue('集收单位', null)
|
|
1285
|
+
this.setLabelValue('集收单位', null)
|
|
1305
1286
|
|
|
1287
|
+
let data = {
|
|
1288
|
+
tablename: 't_area',
|
|
1289
|
+
condition: `f_filialeid = '${this.$login.f.orgid}' and f_street = '${this.show_data.f_street}'`
|
|
1290
|
+
}
|
|
1291
|
+
let http = new HttpResetClass()
|
|
1292
|
+
let res = await http.load(
|
|
1293
|
+
'POST',
|
|
1294
|
+
`rs/sql/singleTable`,
|
|
1295
|
+
{data: data},
|
|
1296
|
+
{resolveMsg: null, rejectMsg: '集收单位查询失败!!!'}
|
|
1297
|
+
)
|
|
1306
1298
|
|
|
1299
|
+
this.setLabelOptions('集收单位', res.data.map(item => {
|
|
1300
|
+
return {
|
|
1301
|
+
label: item.f_residential_area,
|
|
1302
|
+
value: item.f_residential_area
|
|
1303
|
+
}
|
|
1304
|
+
}))
|
|
1305
|
+
},
|
|
1306
|
+
// 区县失去焦点
|
|
1307
|
+
async 'pcdChange' (index) {
|
|
1308
|
+
if (isEmpty(this.show_data.f_pcd)) {
|
|
1309
|
+
return
|
|
1310
|
+
}
|
|
1307
1311
|
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
condition: `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}'`
|
|
1311
|
-
}
|
|
1312
|
-
let f_address_type = this.getLableValue('地址类型')
|
|
1312
|
+
this.setLabelValue('街道/乡镇', null)
|
|
1313
|
+
this.setLabelValue('集收单位', null)
|
|
1313
1314
|
|
|
1314
|
-
if (f_address_type === '民用市区') {
|
|
1315
|
-
data.condition = `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}' and f_iscity = '市区'`
|
|
1316
|
-
}
|
|
1317
|
-
if (f_address_type === '民用乡镇') {
|
|
1318
|
-
data.condition = `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}' and f_iscity = '乡镇'`
|
|
1319
|
-
}
|
|
1320
1315
|
|
|
1321
|
-
let http = new HttpResetClass()
|
|
1322
|
-
let res = await http.load(
|
|
1323
|
-
'POST',
|
|
1324
|
-
`rs/sql/singleTable`,
|
|
1325
|
-
{data: data},
|
|
1326
|
-
{resolveMsg: null, rejectMsg: '街道/乡镇查询失败!!!'}
|
|
1327
|
-
)
|
|
1328
1316
|
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
value: item.f_street
|
|
1317
|
+
let data = {
|
|
1318
|
+
tablename: 't_street',
|
|
1319
|
+
condition: `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}'`
|
|
1333
1320
|
}
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
// 地址类型失去焦点
|
|
1337
|
-
'addressTypeChange' (index) {
|
|
1338
|
-
this.setLabelValue('街道/乡镇', null)
|
|
1339
|
-
this.setLabelValue('集收单位', null)
|
|
1340
|
-
let f_address_type = this.show_data.fields[index].value
|
|
1341
|
-
for (const item of this.show_data.fields) {
|
|
1321
|
+
let f_address_type = this.getLableValue('地址类型')
|
|
1322
|
+
|
|
1342
1323
|
if (f_address_type === '民用市区') {
|
|
1343
|
-
|
|
1344
|
-
item.hidden = false
|
|
1345
|
-
item.required = true
|
|
1346
|
-
item.value = null
|
|
1347
|
-
}
|
|
1348
|
-
if (item.label === '楼号/组' || item.label === '单元/排' || item.label === '楼层') {
|
|
1349
|
-
item.hidden = false
|
|
1350
|
-
item.required = false
|
|
1351
|
-
item.value = null
|
|
1352
|
-
}
|
|
1353
|
-
if (item.label === '地址') {
|
|
1354
|
-
item.readonly = true
|
|
1355
|
-
item.value = null
|
|
1356
|
-
}
|
|
1324
|
+
data.condition = `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}' and f_iscity = '市区'`
|
|
1357
1325
|
}
|
|
1358
1326
|
if (f_address_type === '民用乡镇') {
|
|
1359
|
-
|
|
1360
|
-
item.hidden = false
|
|
1361
|
-
item.required = true
|
|
1362
|
-
item.value = null
|
|
1363
|
-
}
|
|
1364
|
-
if (item.label === '楼号/组' || item.label === '单元/排' || item.label === '楼层') {
|
|
1365
|
-
item.hidden = false
|
|
1366
|
-
item.required = false
|
|
1367
|
-
item.value = null
|
|
1368
|
-
}
|
|
1369
|
-
if (item.label === '楼层') {
|
|
1370
|
-
item.hidden = true
|
|
1371
|
-
item.required = false
|
|
1372
|
-
item.value = null
|
|
1373
|
-
}
|
|
1374
|
-
if (item.label === '地址') {
|
|
1375
|
-
item.readonly = true
|
|
1376
|
-
item.value = null
|
|
1377
|
-
}
|
|
1378
|
-
}
|
|
1379
|
-
if (f_address_type === '特殊地址') {
|
|
1380
|
-
if (item.label === '区/县' || item.label === '街道/乡镇') {
|
|
1381
|
-
item.hidden = false
|
|
1382
|
-
item.required = true
|
|
1383
|
-
item.value = null
|
|
1384
|
-
}
|
|
1385
|
-
if (item.label === '集收单位') {
|
|
1386
|
-
item.hidden = false
|
|
1387
|
-
item.required = false
|
|
1388
|
-
item.value = null
|
|
1389
|
-
}
|
|
1390
|
-
if (item.label === '楼号/组' || item.label === '单元/排' || item.label === '楼层' || item.label === '门牌号') {
|
|
1391
|
-
item.hidden = true
|
|
1392
|
-
item.required = false
|
|
1393
|
-
item.value = null
|
|
1394
|
-
}
|
|
1395
|
-
if (item.label === '地址') {
|
|
1396
|
-
item.readonly = false
|
|
1397
|
-
item.value = null
|
|
1398
|
-
}
|
|
1327
|
+
data.condition = `f_filialeid = '${this.$login.f.orgid}' and f_pcd = '${this.show_data.f_pcd}' and f_iscity = '乡镇'`
|
|
1399
1328
|
}
|
|
1400
|
-
}
|
|
1401
|
-
},
|
|
1402
|
-
// 团购转散户初始化
|
|
1403
|
-
'apply2ReadyEvent' () {
|
|
1404
|
-
if (this.show_data.f_apply_source === '线下发起') {
|
|
1405
|
-
this.addressInitialization()
|
|
1406
|
-
this.hideLabels('用户编号')
|
|
1407
|
-
this.electiveLabels('用户编号')
|
|
1408
|
-
this.showLabels('片区', '地址类型')
|
|
1409
|
-
this.requiredLabels('片区', '地址类型')
|
|
1410
|
-
}
|
|
1411
|
-
if (this.show_data.f_apply_source === '自动发起') {
|
|
1412
|
-
this.hideLabels('片区', '地址类型')
|
|
1413
|
-
this.electiveLabels('片区', '地址类型',)
|
|
1414
|
-
}
|
|
1415
|
-
},
|
|
1416
|
-
// 申请节点初始化
|
|
1417
|
-
'applyReadyEvent' () {
|
|
1418
|
-
this.addressInitialization()
|
|
1419
|
-
this.pcdChange()
|
|
1420
|
-
this.streetChange()
|
|
1421
|
-
},
|
|
1422
|
-
// ===========================================
|
|
1423
|
-
async 'button'() {
|
|
1424
|
-
if (this.show_data.button.before) {
|
|
1425
|
-
await this[this.show_data.button.before]()
|
|
1426
|
-
}
|
|
1427
|
-
// 点击重置按钮就重置数据
|
|
1428
|
-
if (this.show_data.button.button_name === '重置') {
|
|
1429
|
-
this.$dispatch('breakControl', this.selectdata)
|
|
1430
|
-
return
|
|
1431
|
-
}
|
|
1432
|
-
|
|
1433
|
-
this.show_data.user = this.$login.f
|
|
1434
|
-
this.show_data.start_activity = this.$workflow_vue.start_activity
|
|
1435
|
-
this.show_data.xmlfilename = this.$workflow_vue.workflow_xmlfilename
|
|
1436
|
-
|
|
1437
|
-
if ((this.show_data.f_apply_type === '报警器报建' || this.show_data.f_apply_type === '工商业报警器报建') && this.show_data.defname === '工程施工' && this.show_data.f_sub_state !='完工' && this.show_data.button.button_name === '完工'){
|
|
1438
|
-
//判断是否添加报警器材料
|
|
1439
|
-
let bjqlag = false
|
|
1440
|
-
let datatemp = {
|
|
1441
|
-
'bjqid':"",
|
|
1442
|
-
'fprocessid':"",
|
|
1443
|
-
'sqvalue':"",
|
|
1444
|
-
'f_bjq_sid':"",
|
|
1445
|
-
'f_material_code':"",
|
|
1446
|
-
'f_bjq_baidu_lng':"",
|
|
1447
|
-
'f_bjq_baidu_lat':"",
|
|
1448
|
-
'f_bjq_gaode_lng':"",
|
|
1449
|
-
'f_bjq_gaode_lat':""
|
|
1450
|
-
}
|
|
1451
|
-
|
|
1452
|
-
let bjqststedata = {
|
|
1453
|
-
"sid":"",
|
|
1454
|
-
"bjqtype":"",
|
|
1455
|
-
"f_process_id":"",
|
|
1456
|
-
"bjqstate":"",
|
|
1457
|
-
"f_userinfo_code":""
|
|
1458
|
-
}
|
|
1459
|
-
let numOne = [];
|
|
1460
1329
|
|
|
1461
1330
|
let http = new HttpResetClass()
|
|
1462
|
-
let data = {
|
|
1463
|
-
tablename: `t_material_apply`,
|
|
1464
|
-
condition: `f_process_id='${this.show_data.f_process_id}'`
|
|
1465
|
-
}
|
|
1466
1331
|
let res = await http.load(
|
|
1467
1332
|
'POST',
|
|
1468
1333
|
`rs/sql/singleTable`,
|
|
1469
1334
|
{data: data},
|
|
1470
|
-
{resolveMsg: null, rejectMsg: '
|
|
1335
|
+
{resolveMsg: null, rejectMsg: '街道/乡镇查询失败!!!'}
|
|
1471
1336
|
)
|
|
1472
|
-
res.data.forEach(item => {
|
|
1473
|
-
if (item.f_material_name.substr(0,3) === '报警器'){
|
|
1474
|
-
var bjname = item.f_material_name.split("-")
|
|
1475
|
-
bjqststedata.sid = item.f_bjq_sid
|
|
1476
|
-
bjqststedata.f_process_id = item.f_process_id
|
|
1477
|
-
bjqststedata.bjqtype = bjname[1]
|
|
1478
|
-
//====================================
|
|
1479
|
-
bjqlag = true
|
|
1480
|
-
datatemp.bjqid = item.id
|
|
1481
|
-
datatemp.fprocessid = item.f_process_id
|
|
1482
|
-
datatemp.f_bjq_sid = item.f_bjq_sid
|
|
1483
|
-
datatemp.f_material_code = item.f_material_code
|
|
1484
|
-
datatemp.f_bjq_lng = item.f_bjq_lng
|
|
1485
|
-
datatemp.f_bjq_lat = item.f_bjq_lat
|
|
1486
|
-
datatemp.f_bjq_gaode_lng = item.f_bjq_gaode_lng
|
|
1487
|
-
datatemp.f_bjq_gaode_lat = item.f_bjq_gaode_lng
|
|
1488
|
-
datatemp.f_bjq_baidu_lng = item.f_bjq_baidu_lng
|
|
1489
|
-
datatemp.f_bjq_baidu_lat = item.f_bjq_baidu_lat
|
|
1490
|
-
numOne.push(item.f_bjq_sid)
|
|
1491
|
-
}
|
|
1492
|
-
})
|
|
1493
1337
|
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
|
|
1514
|
-
|
|
1338
|
+
this.setLabelOptions('街道/乡镇', res.data.map(item => {
|
|
1339
|
+
return {
|
|
1340
|
+
label: item.f_street,
|
|
1341
|
+
value: item.f_street
|
|
1342
|
+
}
|
|
1343
|
+
}))
|
|
1344
|
+
},
|
|
1345
|
+
// 地址类型失去焦点
|
|
1346
|
+
'addressTypeChange' (index) {
|
|
1347
|
+
this.setLabelValue('街道/乡镇', null)
|
|
1348
|
+
this.setLabelValue('集收单位', null)
|
|
1349
|
+
let f_address_type = this.show_data.fields[index].value
|
|
1350
|
+
for (const item of this.show_data.fields) {
|
|
1351
|
+
if (f_address_type === '民用市区') {
|
|
1352
|
+
if (item.label === '区/县' || item.label === '街道/乡镇' || item.label === '集收单位' || item.label === '门牌号') {
|
|
1353
|
+
item.hidden = false
|
|
1354
|
+
item.required = true
|
|
1355
|
+
item.value = null
|
|
1356
|
+
}
|
|
1357
|
+
if (item.label === '楼号/组' || item.label === '单元/排' || item.label === '楼层') {
|
|
1358
|
+
item.hidden = false
|
|
1359
|
+
item.required = false
|
|
1360
|
+
item.value = null
|
|
1361
|
+
}
|
|
1362
|
+
if (item.label === '地址') {
|
|
1363
|
+
item.readonly = true
|
|
1364
|
+
item.value = null
|
|
1365
|
+
}
|
|
1366
|
+
}
|
|
1367
|
+
if (f_address_type === '民用乡镇') {
|
|
1368
|
+
if (item.label === '区/县' || item.label === '街道/乡镇' || item.label === '集收单位' || item.label === '门牌号') {
|
|
1369
|
+
item.hidden = false
|
|
1370
|
+
item.required = true
|
|
1371
|
+
item.value = null
|
|
1372
|
+
}
|
|
1373
|
+
if (item.label === '楼号/组' || item.label === '单元/排' || item.label === '楼层') {
|
|
1374
|
+
item.hidden = false
|
|
1375
|
+
item.required = false
|
|
1376
|
+
item.value = null
|
|
1377
|
+
}
|
|
1378
|
+
if (item.label === '楼层') {
|
|
1379
|
+
item.hidden = true
|
|
1380
|
+
item.required = false
|
|
1381
|
+
item.value = null
|
|
1382
|
+
}
|
|
1383
|
+
if (item.label === '地址') {
|
|
1384
|
+
item.readonly = true
|
|
1385
|
+
item.value = null
|
|
1386
|
+
}
|
|
1387
|
+
}
|
|
1388
|
+
if (f_address_type === '特殊地址') {
|
|
1389
|
+
if (item.label === '区/县' || item.label === '街道/乡镇') {
|
|
1390
|
+
item.hidden = false
|
|
1391
|
+
item.required = true
|
|
1392
|
+
item.value = null
|
|
1393
|
+
}
|
|
1394
|
+
if (item.label === '集收单位') {
|
|
1395
|
+
item.hidden = false
|
|
1396
|
+
item.required = false
|
|
1397
|
+
item.value = null
|
|
1398
|
+
}
|
|
1399
|
+
if (item.label === '楼号/组' || item.label === '单元/排' || item.label === '楼层' || item.label === '门牌号') {
|
|
1400
|
+
item.hidden = true
|
|
1401
|
+
item.required = false
|
|
1402
|
+
item.value = null
|
|
1403
|
+
}
|
|
1404
|
+
if (item.label === '地址') {
|
|
1405
|
+
item.readonly = false
|
|
1406
|
+
item.value = null
|
|
1407
|
+
}
|
|
1408
|
+
}
|
|
1515
1409
|
}
|
|
1516
|
-
|
|
1517
|
-
|
|
1410
|
+
},
|
|
1411
|
+
// 团购转散户初始化
|
|
1412
|
+
'apply2ReadyEvent' () {
|
|
1413
|
+
if (this.show_data.f_apply_source === '线下发起') {
|
|
1414
|
+
this.addressInitialization()
|
|
1415
|
+
this.hideLabels('用户编号')
|
|
1416
|
+
this.electiveLabels('用户编号')
|
|
1417
|
+
this.showLabels('片区', '地址类型')
|
|
1418
|
+
this.requiredLabels('片区', '地址类型')
|
|
1419
|
+
}
|
|
1420
|
+
if (this.show_data.f_apply_source === '自动发起') {
|
|
1421
|
+
this.hideLabels('片区', '地址类型')
|
|
1422
|
+
this.electiveLabels('片区', '地址类型',)
|
|
1423
|
+
}
|
|
1424
|
+
},
|
|
1425
|
+
// 申请节点初始化
|
|
1426
|
+
'applyReadyEvent' () {
|
|
1427
|
+
this.addressInitialization()
|
|
1428
|
+
this.pcdChange()
|
|
1429
|
+
this.streetChange()
|
|
1430
|
+
},
|
|
1431
|
+
// ===========================================
|
|
1432
|
+
async 'button'() {
|
|
1433
|
+
if (this.show_data.button.before) {
|
|
1434
|
+
await this[this.show_data.button.before]()
|
|
1435
|
+
}
|
|
1436
|
+
// 点击重置按钮就重置数据
|
|
1437
|
+
if (this.show_data.button.button_name === '重置') {
|
|
1438
|
+
this.$dispatch('breakControl', this.selectdata)
|
|
1518
1439
|
return
|
|
1519
1440
|
}
|
|
1520
|
-
datatemp.sqvalue = this.show_data.areaData.sqvalue
|
|
1521
|
-
datatemp.f_bjq_baidu_lng = this.show_data.templatlng.baidutemplng
|
|
1522
|
-
datatemp.f_bjq_baidu_lat = this.show_data.templatlng.baidutemplat
|
|
1523
|
-
datatemp.f_bjq_gaode_lng = this.show_data.templatlng.gaodetemplng
|
|
1524
|
-
datatemp.f_bjq_gaode_lat = this.show_data.templatlng.gaodetemplat
|
|
1525
|
-
datatemp.f_bjq_lng = this.show_data.templatlng.baidutemplng
|
|
1526
|
-
datatemp.f_bjq_lat = this.show_data.templatlng.baidutemplat
|
|
1527
|
-
|
|
1528
|
-
bjqststedata.f_userinfo_code = this.show_data.f_userinfo_code
|
|
1529
|
-
|
|
1530
|
-
//判断是否推送 及推送的状态
|
|
1531
|
-
//查询是否存在, 以型号及厂家判断
|
|
1532
|
-
let bjqres = await this.$resetpost(
|
|
1533
|
-
`rs/logic/getbjqsyncinfo`,
|
|
1534
|
-
bjqststedata
|
|
1535
|
-
)
|
|
1536
|
-
if (bjqres.data.bjqstate != "成功"){
|
|
1537
|
-
//区域地址存入材料记录表
|
|
1538
|
-
let areares = await this.$resetpost(
|
|
1539
|
-
`rs/logic/saveArea`,
|
|
1540
|
-
{data: datatemp},
|
|
1541
|
-
{resolveMsg: null, rejectMsg: '区域地址保存失败'}
|
|
1542
|
-
)
|
|
1543
1441
|
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1442
|
+
this.show_data.user = this.$login.f
|
|
1443
|
+
this.show_data.start_activity = this.$workflow_vue.start_activity
|
|
1444
|
+
this.show_data.xmlfilename = this.$workflow_vue.workflow_xmlfilename
|
|
1445
|
+
|
|
1446
|
+
if ((this.show_data.f_apply_type === '报警器报建' || this.show_data.f_apply_type === '工商业报警器报建') && this.show_data.defname === '工程施工' && this.show_data.f_sub_state !='完工' && this.show_data.button.button_name === '完工'){
|
|
1447
|
+
//判断是否添加报警器材料
|
|
1448
|
+
let bjqlag = false
|
|
1449
|
+
let datatemp = {
|
|
1450
|
+
'bjqid':"",
|
|
1451
|
+
'fprocessid':"",
|
|
1452
|
+
'sqvalue':"",
|
|
1453
|
+
'f_bjq_sid':"",
|
|
1454
|
+
'f_material_code':"",
|
|
1455
|
+
'f_bjq_baidu_lng':"",
|
|
1456
|
+
'f_bjq_baidu_lat':"",
|
|
1457
|
+
'f_bjq_gaode_lng':"",
|
|
1458
|
+
'f_bjq_gaode_lat':""
|
|
1459
|
+
}
|
|
1460
|
+
|
|
1461
|
+
let bjqststedata = {
|
|
1462
|
+
"sid":"",
|
|
1463
|
+
"bjqtype":"",
|
|
1464
|
+
"f_process_id":"",
|
|
1465
|
+
"bjqstate":"",
|
|
1466
|
+
"f_userinfo_code":""
|
|
1467
|
+
}
|
|
1468
|
+
let numOne = [];
|
|
1469
|
+
|
|
1470
|
+
let http = new HttpResetClass()
|
|
1471
|
+
let data = {
|
|
1472
|
+
tablename: `t_material_apply`,
|
|
1473
|
+
condition: `f_process_id='${this.show_data.f_process_id}'`
|
|
1474
|
+
}
|
|
1475
|
+
let res = await http.load(
|
|
1476
|
+
'POST',
|
|
1477
|
+
`rs/sql/singleTable`,
|
|
1478
|
+
{data: data},
|
|
1479
|
+
{resolveMsg: null, rejectMsg: 'onetomany查询失败'}
|
|
1562
1480
|
)
|
|
1563
|
-
|
|
1564
|
-
if (
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1481
|
+
res.data.forEach(item => {
|
|
1482
|
+
if (item.f_material_name.substr(0,3) === '报警器'){
|
|
1483
|
+
var bjname = item.f_material_name.split("-")
|
|
1484
|
+
bjqststedata.sid = item.f_bjq_sid
|
|
1485
|
+
bjqststedata.f_process_id = item.f_process_id
|
|
1486
|
+
bjqststedata.bjqtype = bjname[1]
|
|
1487
|
+
//====================================
|
|
1488
|
+
bjqlag = true
|
|
1489
|
+
datatemp.bjqid = item.id
|
|
1490
|
+
datatemp.fprocessid = item.f_process_id
|
|
1491
|
+
datatemp.f_bjq_sid = item.f_bjq_sid
|
|
1492
|
+
datatemp.f_material_code = item.f_material_code
|
|
1493
|
+
datatemp.f_bjq_lng = item.f_bjq_lng
|
|
1494
|
+
datatemp.f_bjq_lat = item.f_bjq_lat
|
|
1495
|
+
datatemp.f_bjq_gaode_lng = item.f_bjq_gaode_lng
|
|
1496
|
+
datatemp.f_bjq_gaode_lat = item.f_bjq_gaode_lng
|
|
1497
|
+
datatemp.f_bjq_baidu_lng = item.f_bjq_baidu_lng
|
|
1498
|
+
datatemp.f_bjq_baidu_lat = item.f_bjq_baidu_lat
|
|
1499
|
+
numOne.push(item.f_bjq_sid)
|
|
1570
1500
|
}
|
|
1571
|
-
|
|
1501
|
+
})
|
|
1502
|
+
|
|
1503
|
+
// this.show_data.onetomany.forEach(item=>{
|
|
1504
|
+
// console.log("查看报警器材料",item)
|
|
1505
|
+
// item.rows.forEach(i=>{
|
|
1506
|
+
// if (i.f_material_name.substr(0,3) === '报警器'){
|
|
1507
|
+
// var bjname = i.f_material_name.split("-")
|
|
1508
|
+
// bjqststedata.sid = i.f_bjq_sid
|
|
1509
|
+
// bjqststedata.f_process_id = i.f_process_id
|
|
1510
|
+
// bjqststedata.bjqtype = bjname[1]
|
|
1511
|
+
// //====================================
|
|
1512
|
+
// bjqlag = true
|
|
1513
|
+
// datatemp.bjqid = i.id
|
|
1514
|
+
// datatemp.fprocessid = i.f_process_id
|
|
1515
|
+
// datatemp.f_bjq_sid = i.f_bjq_sid
|
|
1516
|
+
// datatemp.f_material_code = i.f_material_code
|
|
1517
|
+
// numOne.push(i.f_bjq_sid)
|
|
1518
|
+
// }
|
|
1519
|
+
// })
|
|
1520
|
+
// })
|
|
1521
|
+
if (!bjqlag){
|
|
1522
|
+
this.$showMessage('请添加报警器物料信息!!!')
|
|
1523
|
+
return
|
|
1524
|
+
}
|
|
1525
|
+
if (numOne.length > 1){
|
|
1526
|
+
this.$showMessage("暂时支持单个报警器物料安装!!!")
|
|
1572
1527
|
return
|
|
1573
1528
|
}
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1578
|
-
|
|
1579
|
-
|
|
1529
|
+
datatemp.sqvalue = this.show_data.areaData.sqvalue
|
|
1530
|
+
datatemp.f_bjq_baidu_lng = this.show_data.templatlng.baidutemplng
|
|
1531
|
+
datatemp.f_bjq_baidu_lat = this.show_data.templatlng.baidutemplat
|
|
1532
|
+
datatemp.f_bjq_gaode_lng = this.show_data.templatlng.gaodetemplng
|
|
1533
|
+
datatemp.f_bjq_gaode_lat = this.show_data.templatlng.gaodetemplat
|
|
1534
|
+
datatemp.f_bjq_lng = this.show_data.templatlng.baidutemplng
|
|
1535
|
+
datatemp.f_bjq_lat = this.show_data.templatlng.baidutemplat
|
|
1536
|
+
|
|
1537
|
+
bjqststedata.f_userinfo_code = this.show_data.f_userinfo_code
|
|
1538
|
+
|
|
1539
|
+
//判断是否推送 及推送的状态
|
|
1540
|
+
//查询是否存在, 以型号及厂家判断
|
|
1541
|
+
let bjqres = await this.$resetpost(
|
|
1542
|
+
`rs/logic/getbjqsyncinfo`,
|
|
1543
|
+
bjqststedata
|
|
1544
|
+
)
|
|
1545
|
+
if (bjqres.data.bjqstate != "成功"){
|
|
1546
|
+
//区域地址存入材料记录表
|
|
1547
|
+
let areares = await this.$resetpost(
|
|
1548
|
+
`rs/logic/saveArea`,
|
|
1549
|
+
{data: datatemp},
|
|
1550
|
+
{resolveMsg: null, rejectMsg: '区域地址保存失败'}
|
|
1580
1551
|
)
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
let
|
|
1584
|
-
|
|
1585
|
-
|
|
1552
|
+
|
|
1553
|
+
//完工之后推送数据到汉威
|
|
1554
|
+
let adddata = {
|
|
1555
|
+
f_bjq_sid : datatemp.f_bjq_sid,
|
|
1556
|
+
f_material_code : datatemp.f_material_code,
|
|
1557
|
+
f_bjq_address: this.show_data.areaData.sqvalue,
|
|
1558
|
+
f_user_name: this.show_data.f_user_name,
|
|
1559
|
+
f_address: this.show_data.f_address,
|
|
1560
|
+
f_user_phone: this.show_data.f_phone,
|
|
1561
|
+
f_userinfo_code: this.show_data.f_userinfo_code,
|
|
1562
|
+
installtime: this.show_data.f_construction_date,
|
|
1563
|
+
f_orgid : this.show_data.f_orgid,
|
|
1564
|
+
f_bjq_lng: datatemp.f_bjq_baidu_lng,
|
|
1565
|
+
f_bjq_lat: datatemp.f_bjq_baidu_lat
|
|
1566
|
+
}
|
|
1567
|
+
let res = await this.$resetpost(
|
|
1568
|
+
`ncc/rs/logic/bjqadduser`,
|
|
1569
|
+
// `rs/logic/bjqadduser`,
|
|
1570
|
+
adddata
|
|
1586
1571
|
)
|
|
1572
|
+
if (res.data.code != 200){
|
|
1573
|
+
if (bjqres.data.bjqstate.length == 0){
|
|
1574
|
+
bjqststedata.bjqstate = "失败"
|
|
1575
|
+
let bjqres3 = await this.$resetpost(
|
|
1576
|
+
`rs/logic/addbjqsyncinfo`,
|
|
1577
|
+
bjqststedata
|
|
1578
|
+
)
|
|
1579
|
+
}
|
|
1580
|
+
this.$showMessage(res.data.msg)
|
|
1581
|
+
return
|
|
1582
|
+
}
|
|
1583
|
+
//更改记录表状态
|
|
1584
|
+
if (bjqres.data.bjqstate === "失败"){
|
|
1585
|
+
bjqststedata.bjqstate = "成功"
|
|
1586
|
+
let bjqres1 = await this.$resetpost(
|
|
1587
|
+
`rs/logic/updatebjqsyncinfo`,
|
|
1588
|
+
bjqststedata
|
|
1589
|
+
)
|
|
1590
|
+
}else{
|
|
1591
|
+
bjqststedata.bjqstate = "成功"
|
|
1592
|
+
let bjqres2 = await this.$resetpost(
|
|
1593
|
+
`rs/logic/addbjqsyncinfo`,
|
|
1594
|
+
bjqststedata
|
|
1595
|
+
)
|
|
1596
|
+
}
|
|
1587
1597
|
}
|
|
1588
1598
|
}
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1599
|
+
if ((this.show_data.f_apply_type === '工商户报建' || this.show_data.f_apply_type === '团购报建')
|
|
1600
|
+
&& (this.show_data.defname === '报装申请') && this.show_data.button.button_name === '提交'){
|
|
1601
|
+
await this.contract_number()
|
|
1602
|
+
}
|
|
1603
|
+
if(this.show_data.f_apply_type === '散户报建' && this.show_data.defname === '合同签订' && (this.show_data.button.button_name === '保存'||this.show_data.button.button_name === '提交')){
|
|
1604
|
+
let dataz = {
|
|
1605
|
+
condition: `u.id = ${this.show_data.id}`,
|
|
1606
|
+
data: {
|
|
1607
|
+
id: this.$login.f.id,
|
|
1608
|
+
orgid: this.$login.f.orgid
|
|
1609
|
+
}
|
|
1600
1610
|
}
|
|
1611
|
+
let http = new HttpResetClass()
|
|
1612
|
+
let restpz = await http.load(
|
|
1613
|
+
'POST',
|
|
1614
|
+
`rs/sql/checkuser`,
|
|
1615
|
+
{data: dataz},
|
|
1616
|
+
{resolveMsg: null, rejectMsg: '报建数据查询失败!!!'}
|
|
1617
|
+
)
|
|
1618
|
+
this.show_data.actid=restpz.data[0].actid
|
|
1601
1619
|
}
|
|
1602
|
-
let
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
{data: dataz},
|
|
1607
|
-
{resolveMsg: null, rejectMsg: '报建数据查询失败!!!'}
|
|
1620
|
+
let res = await this.$resetpost(
|
|
1621
|
+
`rs/logic/ApplyProductService`,
|
|
1622
|
+
{data: this.show_data},
|
|
1623
|
+
{resolveMsg: null, rejectMsg: '数据保存失败'}
|
|
1608
1624
|
)
|
|
1609
|
-
this.show_data.actid=restpz.data[0].actid
|
|
1610
|
-
}
|
|
1611
|
-
let res = await this.$resetpost(
|
|
1612
|
-
`rs/logic/ApplyProductService`,
|
|
1613
|
-
{data: this.show_data},
|
|
1614
|
-
{resolveMsg: null, rejectMsg: '数据保存失败'}
|
|
1615
|
-
)
|
|
1616
1625
|
|
|
1617
1626
|
|
|
1618
|
-
|
|
1619
|
-
|
|
1620
|
-
}
|
|
1621
|
-
// 改管报建 增容报建 优化
|
|
1622
|
-
if((this.show_data.f_apply_type === '改管报建'||this.show_data.f_apply_type === '增容报建') && this.show_data.defname === '报装申请' && this.show_data.button.button_name === '缴费'){
|
|
1623
|
-
let datagg = {
|
|
1624
|
-
condition: `t.f_process_id='${this.show_data.f_process_id}'`,
|
|
1627
|
+
if (this.show_data.button.after) {
|
|
1628
|
+
this[this.show_data.button.after]()
|
|
1625
1629
|
}
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
|
|
1639
|
-
|
|
1630
|
+
// 改管报建 增容报建 优化
|
|
1631
|
+
if((this.show_data.f_apply_type === '改管报建'||this.show_data.f_apply_type === '增容报建') && this.show_data.defname === '报装申请' && this.show_data.button.button_name === '缴费'){
|
|
1632
|
+
let datagg = {
|
|
1633
|
+
condition: `t.f_process_id='${this.show_data.f_process_id}'`,
|
|
1634
|
+
}
|
|
1635
|
+
let http = new HttpResetClass()
|
|
1636
|
+
let restgg = await http.load(
|
|
1637
|
+
'POST',
|
|
1638
|
+
`rs/sql/checkusertwo`,
|
|
1639
|
+
{data: datagg},
|
|
1640
|
+
{resolveMsg: null, rejectMsg: '报建数据查询失败!!!'}
|
|
1641
|
+
)
|
|
1642
|
+
debugger
|
|
1643
|
+
if(this.show_data.f_apply_type === '改管报建'){
|
|
1644
|
+
restgg.data[0].processname = '改管报建流程'
|
|
1645
|
+
restgg.data[0].defname = '报装缴费'
|
|
1646
|
+
}else{
|
|
1647
|
+
restgg.data[0].processname = '增容报建流程'
|
|
1648
|
+
restgg.data[0].defname = '报装缴费'
|
|
1649
|
+
}
|
|
1650
|
+
restgg.data[0].actid = restgg.data[0].actid + 1
|
|
1651
|
+
this.$dispatch('apply',restgg.data[0])
|
|
1652
|
+
|
|
1640
1653
|
}
|
|
1641
|
-
restgg.data[0].actid = restgg.data[0].actid + 1
|
|
1642
|
-
this.$dispatch('apply',restgg.data[0])
|
|
1643
1654
|
|
|
1644
|
-
|
|
1655
|
+
// 退款报建 优化
|
|
1656
|
+
if(this.show_data.f_apply_type === '退款报建' && this.show_data.defname === '终止报建' && this.show_data.button.button_name === '提交'){
|
|
1657
|
+
let datatk = {
|
|
1658
|
+
condition: `t.f_process_id='${this.show_data.f_process_id}'`,
|
|
1659
|
+
}
|
|
1660
|
+
let http = new HttpResetClass()
|
|
1661
|
+
let resttk = await http.load(
|
|
1662
|
+
'POST',
|
|
1663
|
+
`rs/sql/checkusertwo`,
|
|
1664
|
+
{data: datatk},
|
|
1665
|
+
{resolveMsg: null, rejectMsg: '报建数据查询失败!!!'}
|
|
1666
|
+
)
|
|
1667
|
+
debugger
|
|
1668
|
+
resttk.data[0].processname = '退款报建流程'
|
|
1669
|
+
resttk.data[0].defname = '退款'
|
|
1670
|
+
this.$dispatch('apply',resttk.data[0])
|
|
1645
1671
|
|
|
1646
|
-
// 退款报建 优化
|
|
1647
|
-
if(this.show_data.f_apply_type === '退款报建' && this.show_data.defname === '终止报建' && this.show_data.button.button_name === '提交'){
|
|
1648
|
-
let datatk = {
|
|
1649
|
-
condition: `t.f_process_id='${this.show_data.f_process_id}'`,
|
|
1650
1672
|
}
|
|
1651
|
-
let http = new HttpResetClass()
|
|
1652
|
-
let resttk = await http.load(
|
|
1653
|
-
'POST',
|
|
1654
|
-
`rs/sql/checkusertwo`,
|
|
1655
|
-
{data: datatk},
|
|
1656
|
-
{resolveMsg: null, rejectMsg: '报建数据查询失败!!!'}
|
|
1657
|
-
)
|
|
1658
|
-
debugger
|
|
1659
|
-
resttk.data[0].processname = '退款报建流程'
|
|
1660
|
-
resttk.data[0].defname = '退款'
|
|
1661
|
-
this.$dispatch('apply',resttk.data[0])
|
|
1662
|
-
|
|
1663
|
-
}
|
|
1664
1673
|
|
|
1665
1674
|
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
}
|
|
1671
|
-
let http = new HttpResetClass()
|
|
1672
|
-
let restp = await http.load(
|
|
1673
|
-
'POST',
|
|
1674
|
-
`rs/sql/singleTable`,
|
|
1675
|
-
{data: data},
|
|
1676
|
-
{resolveMsg: null, rejectMsg: '报建数据查询失败!!!'}
|
|
1677
|
-
)
|
|
1678
|
-
debugger
|
|
1679
|
-
restp.data[0].processname = '散户报建流程'
|
|
1680
|
-
restp.data[0].defname = '合同签订'
|
|
1681
|
-
this.$dispatch('apply',restp.data[0])
|
|
1682
|
-
|
|
1683
|
-
} else if(this.show_data.f_apply_type === '散户报建' && this.show_data.defname === '合同签订' && this.show_data.button.button_name === '提交'){
|
|
1684
|
-
let data2 = {
|
|
1685
|
-
condition: `u.id = ${this.show_data.id}`,
|
|
1686
|
-
data: {
|
|
1687
|
-
id: this.$login.f.id,
|
|
1688
|
-
orgid: this.$login.f.orgid
|
|
1675
|
+
if(this.show_data.f_apply_type === '散户报建' && this.show_data.defname === '报装申请' && this.show_data.button.button_name === '合同'){
|
|
1676
|
+
let data = {
|
|
1677
|
+
tablename: 't_apply',
|
|
1678
|
+
condition: `f_process_id='${this.show_data.f_process_id}'`
|
|
1689
1679
|
}
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
|
|
1700
|
-
|
|
1701
|
-
|
|
1702
|
-
this
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1680
|
+
let http = new HttpResetClass()
|
|
1681
|
+
let restp = await http.load(
|
|
1682
|
+
'POST',
|
|
1683
|
+
`rs/sql/singleTable`,
|
|
1684
|
+
{data: data},
|
|
1685
|
+
{resolveMsg: null, rejectMsg: '报建数据查询失败!!!'}
|
|
1686
|
+
)
|
|
1687
|
+
debugger
|
|
1688
|
+
restp.data[0].processname = '散户报建流程'
|
|
1689
|
+
restp.data[0].defname = '合同签订'
|
|
1690
|
+
this.$dispatch('apply',restp.data[0])
|
|
1691
|
+
|
|
1692
|
+
} else if(this.show_data.f_apply_type === '散户报建' && this.show_data.defname === '合同签订' && this.show_data.button.button_name === '提交'){
|
|
1693
|
+
let data2 = {
|
|
1694
|
+
condition: `u.id = ${this.show_data.id}`,
|
|
1695
|
+
data: {
|
|
1696
|
+
id: this.$login.f.id,
|
|
1697
|
+
orgid: this.$login.f.orgid
|
|
1698
|
+
}
|
|
1709
1699
|
}
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
)
|
|
1718
|
-
debugger
|
|
1719
|
-
console.log('打印查询的内容',restp2)
|
|
1720
|
-
if(restp2.length>0){
|
|
1721
|
-
this.$dispatch('apply',restp2.data[0])
|
|
1722
|
-
}else{
|
|
1700
|
+
let http = new HttpResetClass()
|
|
1701
|
+
let restp1 = await http.load(
|
|
1702
|
+
'POST',
|
|
1703
|
+
`rs/sql/checkuser`,
|
|
1704
|
+
{data: data2},
|
|
1705
|
+
{resolveMsg: null, rejectMsg: '报建数据查询失败!!!'}
|
|
1706
|
+
)
|
|
1723
1707
|
debugger
|
|
1724
|
-
|
|
1708
|
+
console.log('有没有发请求打印查询的内容restp1',restp1)
|
|
1709
|
+
// restp1.data[0].processname = '散户报建流程'
|
|
1710
|
+
// restp1.data[0].defname = '报装缴费'
|
|
1711
|
+
this.$dispatch('apply',restp1.data[0])
|
|
1712
|
+
}else if(this.show_data.f_apply_type === '散户报建' && this.show_data.defname === '报装缴费' && this.show_data.button.button_name === '提交'){
|
|
1713
|
+
let data3 = {
|
|
1714
|
+
condition: `u.id = ${this.show_data.id}`,
|
|
1715
|
+
data: {
|
|
1716
|
+
id: this.$login.f.id,
|
|
1717
|
+
orgid: this.$login.f.orgid
|
|
1718
|
+
}
|
|
1719
|
+
}
|
|
1720
|
+
let http = new HttpResetClass()
|
|
1721
|
+
let restp2 = await http.load(
|
|
1722
|
+
'POST',
|
|
1723
|
+
`rs/sql/checkuser`,
|
|
1724
|
+
{data: data3},
|
|
1725
|
+
{resolveMsg: null, rejectMsg: '报建数据查询失败!!!'}
|
|
1726
|
+
)
|
|
1727
|
+
debugger
|
|
1728
|
+
console.log('打印查询的内容',restp2)
|
|
1729
|
+
if(restp2.length>0){
|
|
1730
|
+
this.$dispatch('apply',restp2.data[0])
|
|
1731
|
+
}else{
|
|
1732
|
+
debugger
|
|
1733
|
+
this.$dispatch('loadPage')
|
|
1734
|
+
}
|
|
1725
1735
|
}
|
|
1726
|
-
|
|
1727
|
-
else{
|
|
1736
|
+
else{
|
|
1728
1737
|
this.$dispatch('loadPage')
|
|
1729
|
-
|
|
1738
|
+
}
|
|
1730
1739
|
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
|
|
1735
|
-
|
|
1736
|
-
|
|
1737
|
-
|
|
1738
|
-
|
|
1739
|
-
|
|
1740
|
-
|
|
1741
|
-
|
|
1742
|
-
|
|
1743
|
-
|
|
1744
|
-
|
|
1745
|
-
|
|
1746
|
-
|
|
1747
|
-
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1752
|
-
|
|
1753
|
-
|
|
1754
|
-
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1740
|
+
},
|
|
1741
|
+
// 失去焦点出触发事件
|
|
1742
|
+
'onchange' (index) {
|
|
1743
|
+
if (this.show_data.defname === '报装申请' || this.show_data.defname === '信息确认') {
|
|
1744
|
+
if (
|
|
1745
|
+
this.show_data.fields[index].label === '区/县' ||
|
|
1746
|
+
this.show_data.fields[index].label === '街道/乡镇' ||
|
|
1747
|
+
this.show_data.fields[index].label === '集收单位' ||
|
|
1748
|
+
this.show_data.fields[index].label === '楼号/组' ||
|
|
1749
|
+
this.show_data.fields[index].label === '单元/排' ||
|
|
1750
|
+
this.show_data.fields[index].label === '楼层' ||
|
|
1751
|
+
this.show_data.fields[index].label === '门牌号'
|
|
1752
|
+
) {
|
|
1753
|
+
|
|
1754
|
+
let f_pcd = this.getLableValue('区/县') || ''
|
|
1755
|
+
let f_street = this.getLableValue('街道/乡镇') || ''
|
|
1756
|
+
let f_residential_area = this.getLableValue('集收单位') || ''
|
|
1757
|
+
let f_building = this.getLableValue('楼号/组') || ''
|
|
1758
|
+
let f_building_suffix = f_building ? this.config.f_building_suffix : ''
|
|
1759
|
+
let f_unit = this.getLableValue('单元/排') || ''
|
|
1760
|
+
let f_unit_suffix = f_unit ? this.config.f_unit_suffix : ''
|
|
1761
|
+
let f_floor = this.getLableValue('楼层') || ''
|
|
1762
|
+
let f_floor_suffix = f_floor ? this.config.f_floor_suffix : ''
|
|
1763
|
+
let f_room = this.getLableValue('门牌号') || ''
|
|
1764
|
+
let f_room_suffix = f_room ? this.config.f_room_suffix : ''
|
|
1765
|
+
|
|
1766
|
+
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
|
|
1767
|
+
this.setLabelValue("地址", f_address)
|
|
1768
|
+
}
|
|
1759
1769
|
}
|
|
1760
|
-
}
|
|
1761
|
-
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
|
-
|
|
1768
|
-
async 'onblurModal' (index, fieldIndex) {
|
|
1770
|
+
},
|
|
1771
|
+
selectSearch (val, index) {},
|
|
1772
|
+
'onblur' (index) {},
|
|
1773
|
+
'oninput' (index) {},
|
|
1774
|
+
'initializtionView' () {},
|
|
1775
|
+
async 'onchangeModal' (index, fieldIndex) {
|
|
1776
|
+
},
|
|
1777
|
+
async 'onblurModal' (index, fieldIndex) {
|
|
1769
1778
|
|
|
1770
|
-
|
|
1771
|
-
|
|
1779
|
+
},
|
|
1780
|
+
async 'oninputModal' (index, fieldIndex) {
|
|
1772
1781
|
|
|
1773
|
-
|
|
1774
|
-
|
|
1782
|
+
},
|
|
1783
|
+
async 'onetomanydelete' (index, rowIndex) {
|
|
1775
1784
|
|
|
1776
|
-
|
|
1785
|
+
let http = new HttpResetClass()
|
|
1777
1786
|
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
|
|
1787
|
+
let res = await http.load(
|
|
1788
|
+
'DELETE',
|
|
1789
|
+
`rs/entity/${this.show_data.onetomany[index].tables[0]}/${this.show_data.onetomany[index].rows[rowIndex].id}`,
|
|
1790
|
+
null,
|
|
1791
|
+
{resolveMsg: null, rejectMsg: '删除失败!!!'}
|
|
1792
|
+
)
|
|
1784
1793
|
|
|
1785
|
-
|
|
1786
|
-
|
|
1787
|
-
|
|
1788
|
-
|
|
1794
|
+
res = await this.$resetpost(
|
|
1795
|
+
'rs/entity/t_apply',
|
|
1796
|
+
this.show_data
|
|
1797
|
+
)
|
|
1789
1798
|
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
this.show_data.onetomany[index].fields.forEach(item => {
|
|
1796
|
-
data[item.field] = item.value
|
|
1797
|
-
})
|
|
1798
|
-
let res = await this.$resetpost(
|
|
1799
|
-
`rs/entity/${this.show_data.onetomany[index].tables[0]}`,
|
|
1800
|
-
data
|
|
1801
|
-
)
|
|
1802
|
-
|
|
1803
|
-
res = await this.$resetpost(
|
|
1804
|
-
'rs/entity/t_apply',
|
|
1805
|
-
this.show_data
|
|
1806
|
-
)
|
|
1807
|
-
|
|
1808
|
-
this.$dispatch('breakControl', this.show_data)
|
|
1809
|
-
},
|
|
1810
|
-
async 'onetomanyadd' (index) {
|
|
1811
|
-
let data = {
|
|
1812
|
-
f_process_id : this.show_data.f_process_id,
|
|
1813
|
-
f_operator_id: this.$login.f.id,
|
|
1814
|
-
f_operator: this.$login.f.name,
|
|
1815
|
-
f_operation_date: new Date().Format('yyyy-MM-dd HH:mm:ss'),
|
|
1816
|
-
f_orgid: this.$login.f.orgid,
|
|
1817
|
-
f_orgname: this.$login.f.orgs
|
|
1818
|
-
}
|
|
1819
|
-
this.show_data.onetomany[index].fields.forEach(item => {
|
|
1820
|
-
data[item.field] = item.value
|
|
1821
|
-
})
|
|
1822
|
-
let res = await this.$resetpost(
|
|
1823
|
-
`rs/entity/${this.show_data.onetomany[index].tables[0]}`,
|
|
1824
|
-
data
|
|
1825
|
-
)
|
|
1826
|
-
|
|
1827
|
-
res = await this.$resetpost(
|
|
1828
|
-
'rs/entity/t_apply',
|
|
1829
|
-
this.show_data
|
|
1830
|
-
)
|
|
1831
|
-
|
|
1832
|
-
this.$dispatch('breakControl', this.show_data)
|
|
1833
|
-
},
|
|
1834
|
-
async 'importEvent' (index, table, configName, filepath) {
|
|
1835
|
-
let data = {
|
|
1836
|
-
selectdata: this.show_data,
|
|
1837
|
-
table: table,
|
|
1838
|
-
filepath: filepath,
|
|
1839
|
-
configName: configName,
|
|
1840
|
-
user: this.$login.f
|
|
1841
|
-
}
|
|
1799
|
+
this.$dispatch('breakControl', this.show_data)
|
|
1800
|
+
},
|
|
1801
|
+
async 'onetomanyupdate' (index, rowIndex) {
|
|
1802
|
+
let data = this.show_data.onetomany[index].rows[rowIndex]
|
|
1842
1803
|
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1804
|
+
this.show_data.onetomany[index].fields.forEach(item => {
|
|
1805
|
+
data[item.field] = item.value
|
|
1806
|
+
})
|
|
1807
|
+
let res = await this.$resetpost(
|
|
1808
|
+
`rs/entity/${this.show_data.onetomany[index].tables[0]}`,
|
|
1809
|
+
data
|
|
1810
|
+
)
|
|
1847
1811
|
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
1812
|
+
res = await this.$resetpost(
|
|
1813
|
+
'rs/entity/t_apply',
|
|
1814
|
+
this.show_data
|
|
1815
|
+
)
|
|
1851
1816
|
|
|
1852
|
-
|
|
1853
|
-
|
|
1817
|
+
this.$dispatch('breakControl', this.show_data)
|
|
1818
|
+
},
|
|
1819
|
+
async 'onetomanyadd' (index) {
|
|
1820
|
+
let data = {
|
|
1821
|
+
f_process_id : this.show_data.f_process_id,
|
|
1822
|
+
f_operator_id: this.$login.f.id,
|
|
1823
|
+
f_operator: this.$login.f.name,
|
|
1824
|
+
f_operation_date: new Date().Format('yyyy-MM-dd HH:mm:ss'),
|
|
1825
|
+
f_orgid: this.$login.f.orgid,
|
|
1826
|
+
f_orgname: this.$login.f.orgs
|
|
1827
|
+
}
|
|
1828
|
+
this.show_data.onetomany[index].fields.forEach(item => {
|
|
1829
|
+
data[item.field] = item.value
|
|
1830
|
+
})
|
|
1831
|
+
let res = await this.$resetpost(
|
|
1832
|
+
`rs/entity/${this.show_data.onetomany[index].tables[0]}`,
|
|
1833
|
+
data
|
|
1834
|
+
)
|
|
1854
1835
|
|
|
1855
|
-
|
|
1856
|
-
|
|
1836
|
+
res = await this.$resetpost(
|
|
1837
|
+
'rs/entity/t_apply',
|
|
1838
|
+
this.show_data
|
|
1839
|
+
)
|
|
1840
|
+
|
|
1841
|
+
this.$dispatch('breakControl', this.show_data)
|
|
1842
|
+
},
|
|
1843
|
+
async 'importEvent' (index, table, configName, filepath) {
|
|
1844
|
+
let data = {
|
|
1845
|
+
selectdata: this.show_data,
|
|
1846
|
+
table: table,
|
|
1847
|
+
filepath: filepath,
|
|
1848
|
+
configName: configName,
|
|
1849
|
+
user: this.$login.f
|
|
1850
|
+
}
|
|
1851
|
+
|
|
1852
|
+
let res = await this.$resetpost(
|
|
1853
|
+
`rs/logic/importEvent`,
|
|
1854
|
+
data
|
|
1855
|
+
)
|
|
1857
1856
|
|
|
1857
|
+
this.$dispatch('breakControl', this.show_data)
|
|
1858
|
+
},
|
|
1859
|
+
'onbutchange' (index) {
|
|
1860
|
+
|
|
1861
|
+
},
|
|
1862
|
+
'onbutblur' (index) {
|
|
1863
|
+
|
|
1864
|
+
},
|
|
1865
|
+
'onbutinput' (index) {
|
|
1866
|
+
|
|
1867
|
+
|
|
1868
|
+
}
|
|
1869
|
+
},
|
|
1870
|
+
watch: {
|
|
1858
1871
|
}
|
|
1859
|
-
},
|
|
1860
|
-
watch: {
|
|
1861
1872
|
}
|
|
1862
|
-
}
|
|
1863
1873
|
</script>
|
|
1864
1874
|
<style scoped>
|
|
1865
|
-
/*清除model中的浮动*/
|
|
1866
|
-
.clearfix:after,.clearfix:before{
|
|
1867
|
-
|
|
1868
|
-
}
|
|
1869
|
-
.clearfix:after{
|
|
1870
|
-
|
|
1871
|
-
}
|
|
1875
|
+
/*清除model中的浮动*/
|
|
1876
|
+
.clearfix:after,.clearfix:before{
|
|
1877
|
+
display: table;
|
|
1878
|
+
}
|
|
1879
|
+
.clearfix:after{
|
|
1880
|
+
clear: both;
|
|
1881
|
+
}
|
|
1872
1882
|
</style>
|