apply-clients 3.5.4-8 → 3.5.4-81
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/app/src/main/java/com/example/phonechatbot/MainActivity.java +50 -0
- package/build/dev-server.js +12 -4
- package/package.json +2 -2
- package/src/App.vue +5 -5
- package/src/apply.js +2 -3
- package/src/applyAndroid.js +2 -0
- package/src/assets//344/270/213/350/275/275.png +0 -0
- package/src/components/android/AppCheckTakePic.vue +168 -0
- package/src/components/android/Process/AppServiceControl.vue +4 -0
- package/src/components/android/Process/Processes/AppChargeManagementNew.vue +637 -0
- package/src/components/image/dxf.png +0 -0
- package/src/components/product/Function/Service/FunctionServiceControl.vue +497 -497
- package/src/components/product/Material/MaterialDetailed.vue +1 -1
- package/src/components/product/MaterialsManage/MaterialsBase.vue +181 -177
- package/src/components/product/MaterialsManage/MaterialsManage.vue +60 -60
- package/src/components/product/PcZhihuanManagement.vue +160 -0
- package/src/components/product/Process/ExplorationSelect.vue +4 -1
- package/src/components/product/Process/ExplorationUser.vue +1 -0
- package/src/components/product/Process/Processes/chargeManagement.vue +656 -656
- package/src/components/product/ServiceView.vue +1026 -1005
- package/src/components/product/Supervisory/SupervisoryControl.vue +1 -0
- package/src/filiale/baiyin/android/AppServiceControl.vue +1762 -0
- package/src/filiale/baiyin/android/ByAddMaterialScience.vue +824 -0
- package/src/filiale/baiyin/android/ByDeviceManagement.vue +916 -0
- package/src/filiale/baiyin/android.js +8 -0
- package/src/filiale/fugou/android/AppAddMaterialScience.vue +448 -0
- package/src/filiale/fugou/android/AppAddReplacement.vue +341 -0
- package/src/filiale/fugou/android/AppChargeManagement.vue +126 -12
- package/src/filiale/fugou/android/AppDevicesManagement.vue +519 -0
- package/src/filiale/fugou/android/AppInstallationDetails.vue +541 -0
- package/src/filiale/fugou/android/AppServiceControl.vue +38 -5
- package/src/filiale/fugou/android/AppZhihuanManagement.vue +191 -0
- package/src/filiale/fugou/android.js +7 -1
- package/src/filiale/fugou/pc/AddReplacement.vue +340 -0
- package/src/filiale/fugou/pc/ExplorationSelect.vue +525 -0
- package/src/filiale/fugou/pc/InstallationDetails.vue +54 -43
- package/src/filiale/fugou/pc/ServiceControl.vue +125 -379
- package/src/filiale/fugou/pc/ServiceView.vue +941 -0
- package/src/filiale/fugou/pc/addMaterialScience.vue +481 -0
- package/src/filiale/fugou/pc/addressAndUserinfoManagement.vue +216 -0
- package/src/filiale/fugou/pc/devicesManagement.vue +483 -0
- package/src/filiale/fugou/pc.js +7 -1
- package/src/filiale/gongyi/android/AppAddMaterialScience.vue +20 -8
- package/src/filiale/gongyi/android/AppDisclosurerecord.vue +214 -0
- package/src/filiale/gongyi/android/AppInstallationDetails.vue +500 -495
- package/src/filiale/gongyi/android/AppLegacyIssues.vue +309 -0
- package/src/filiale/gongyi/android/AppSign.vue +170 -157
- package/src/filiale/gongyi/android/AppSupplementalAgreement.vue +298 -0
- package/src/filiale/gongyi/android.js +18 -15
- package/src/filiale/gongyi/pc/ApplyUpload.vue +371 -379
- package/src/filiale/gongyi/pc/PcAddLogs.vue +221 -213
- package/src/filiale/gongyi/pc/PcDisclosurerecord.vue +218 -0
- package/src/filiale/gongyi/pc/PcLegacyIssues.vue +309 -0
- package/src/filiale/gongyi/pc/SupervisoryServiceControl.vue +894 -894
- package/src/filiale/gongyi/pc/SupervisoryServiceView.vue +1005 -0
- package/src/filiale/gongyi/pc/addMaterialScience.vue +575 -539
- package/src/filiale/gongyi/pc/chargeManagement.vue +765 -0
- package/src/filiale/gongyi/pc/supplementalAgreement.vue +277 -0
- package/src/filiale/gongyi/pc.js +24 -19
- package/src/filiale/hongda/pc/SupervisoryList.vue +422 -409
- package/src/filiale/jinhuang/pc/ServiceControl.vue +1925 -0
- package/src/filiale/jinhuang/pc/chargeManagementNew.vue +589 -0
- package/src/filiale/jinhuang/pc.js +7 -0
- package/src/filiale/qianneng/android/AppChargeManagement.vue +686 -0
- package/src/filiale/qianneng/android/AppExplorationUser.vue +490 -490
- package/src/filiale/qianneng/android/AppInstallationDetails.vue +541 -541
- package/src/filiale/qianneng/android.js +2 -1
- package/src/filiale/qianneng/pc/ApplyUpload.vue +5 -4
- package/src/filiale/qianneng/pc/Applybatchdispatch.vue +704 -704
- package/src/filiale/qianneng/pc/Applydetail.vue +0 -5
- package/src/filiale/qianneng/pc/InstallFunction.vue +2 -2
- package/src/filiale/qianneng/pc/InstallationDetails.vue +614 -587
- package/src/filiale/qianneng/pc/ServiceControl.vue +1384 -1384
- package/src/filiale/qianneng/pc/printactivatecard.vue +311 -311
- package/src/filiale/ruihua/pc/ServiceControl.vue +20 -0
- package/src/filiale/ruihua/pc/printVentilation.vue +21 -6
- package/src/filiale/shexian/android/AppServiceControl.vue +12 -2
- package/src/filiale/shexian/android/AppTakePic.vue +15 -55
- package/src/filiale/siyangRH/android/AppAddMaterialScience.vue +0 -2
- package/src/filiale/siyangRH/pc/ApplyUpload.vue +324 -324
- package/src/filiale/siyangRH/pc/chargeManagement.vue +810 -0
- package/src/filiale/siyangRH/pc.js +1 -0
- package/src/filiale/yangchunboneng/android/AppChargeManagement.vue +17 -1
- package/src/filiale/yangchunboneng/android/AppDevicesManagement.vue +32 -2
- package/src/filiale/yangchunboneng/android/AppExplorationUser.vue +12 -0
- package/src/filiale/yangchunboneng/android/AppInstallationMaterial.vue +956 -961
- package/src/filiale/yangchunboneng/android/AppServiceControl.vue +34 -1
- package/src/filiale/yangchunboneng/android/AppSuperServiceControl.vue +1 -1
- package/src/filiale/yangchunboneng/android/AppUpload.vue +78 -9
- package/src/filiale/yangchunboneng/android/MaterIialOne.vue +31 -19
- package/src/filiale/yangchunboneng/android.js +1 -1
- package/src/filiale/yangchunboneng/pc/ApplyUpload.vue +235 -218
- package/src/filiale/yangchunboneng/pc/ExplorationSelect.vue +59 -19
- package/src/filiale/yangchunboneng/pc/ExplorationUser.vue +191 -0
- package/src/filiale/yangchunboneng/pc/ServiceControl.vue +207 -3
- package/src/filiale/yangchunboneng/pc/SupervisoryControlNew.vue +142 -0
- package/src/filiale/yangchunboneng/pc/SupervisoryList.vue +69 -14
- package/src/filiale/yangchunboneng/pc/SupervisoryListNew.vue +628 -0
- package/src/filiale/yangchunboneng/pc/SupervisoryServiceControl.vue +902 -0
- package/src/filiale/yangchunboneng/pc/SupervisoryServiceControlNew.vue +901 -0
- package/src/filiale/yangchunboneng/pc/SupervisoryServiceView.vue +1117 -0
- package/src/filiale/yangchunboneng/pc/chargeManagement.vue +112 -13
- package/src/filiale/yangchunboneng/pc.js +7 -1
- package/src/main.js +3 -3
- package/~/chatbot/main.py +57 -0
|
@@ -0,0 +1,341 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div>
|
|
3
|
+
<data-grid :model="onetomany" class="list_area table_sy">
|
|
4
|
+
<template partial='head'>
|
|
5
|
+
<tr>
|
|
6
|
+
<th class="textNoLineBreak">记录人</th>
|
|
7
|
+
<th class="textNoLineBreak">添加日期</th>
|
|
8
|
+
<th class="textNoLineBreak">设备</th>
|
|
9
|
+
<th class="textNoLineBreak">内容</th>
|
|
10
|
+
<th class="textNoLineBreak" >
|
|
11
|
+
<button v-if="$parent.$parent.mark === 0" type="button" class="btn btn-primary" @click="$parent.$parent.openMaterialModal()">添加
|
|
12
|
+
</button>
|
|
13
|
+
</th>
|
|
14
|
+
</tr>
|
|
15
|
+
</template>
|
|
16
|
+
<template partial='body'>
|
|
17
|
+
<tr>
|
|
18
|
+
<td style="text-align: center;">
|
|
19
|
+
<nobr>{{row.f_operator}}</nobr>
|
|
20
|
+
</td>
|
|
21
|
+
<td style="text-align: center;">
|
|
22
|
+
<nobr>{{row.f_operation_date}}</nobr>
|
|
23
|
+
</td>
|
|
24
|
+
<td style="text-align: center;">
|
|
25
|
+
<nobr>{{row.f_content}}</nobr>
|
|
26
|
+
</td>
|
|
27
|
+
<td style="text-align: center;">
|
|
28
|
+
<nobr>
|
|
29
|
+
{{$parent.$parent.toArry(row.f_content_value)}}
|
|
30
|
+
</nobr>
|
|
31
|
+
</td>
|
|
32
|
+
<td style="text-align: center;">
|
|
33
|
+
<button v-if="$parent.$parent.mark === 0" type="button" class="button_delete button_spacing" @click="$parent.$parent.deletelogs(row)">删除
|
|
34
|
+
</button>
|
|
35
|
+
</td>
|
|
36
|
+
</tr>
|
|
37
|
+
</template>
|
|
38
|
+
</data-grid>
|
|
39
|
+
<modal v-if="showMaterialModal" :show.sync="showMaterialModal" v-ref:modal :large="true"
|
|
40
|
+
:backdrop="false" :title="title">
|
|
41
|
+
<header slot="modal-header" class="modal-header">
|
|
42
|
+
<button type="button" class="close" @click="closeMaterials"><span>×</span></button>
|
|
43
|
+
<h4 class="modal-title">{{title}}</h4>
|
|
44
|
+
</header>
|
|
45
|
+
<article slot="modal-body" class="modal-body clearfix">
|
|
46
|
+
<div class="form-group col-sm-6">
|
|
47
|
+
<label class="col-sm-4 control-label">设备:</label>
|
|
48
|
+
<div class="col-sm-8">
|
|
49
|
+
<input-select
|
|
50
|
+
class="select select_list"
|
|
51
|
+
:value.sync="device"
|
|
52
|
+
v-model="device"
|
|
53
|
+
:options="logOptions"
|
|
54
|
+
:disable="mark === 1"
|
|
55
|
+
:valueSingle="true"></input-select>
|
|
56
|
+
</div>
|
|
57
|
+
</div>
|
|
58
|
+
<div v-for="(i,item) in materials" class="form-group col-sm-12 panel panel-info">
|
|
59
|
+
<div class="panel-body">
|
|
60
|
+
<div class="row">
|
|
61
|
+
<div class="form-group col-sm-6">
|
|
62
|
+
<label class="col-sm-4 control-label">内容:</label>
|
|
63
|
+
<div class="col-sm-8">
|
|
64
|
+
<input-select
|
|
65
|
+
class="select select_list"
|
|
66
|
+
:value.sync="item.f_content"
|
|
67
|
+
v-model="item.f_content"
|
|
68
|
+
:options="Options"
|
|
69
|
+
:disable="mark === 1"
|
|
70
|
+
:valueSingle="true"></input-select>
|
|
71
|
+
</div>
|
|
72
|
+
</div>
|
|
73
|
+
<div class="form-group col-sm-6">
|
|
74
|
+
<label class="col-sm-4 control-label">值:</label>
|
|
75
|
+
<div class="col-sm-8">
|
|
76
|
+
<input
|
|
77
|
+
class="form-control"
|
|
78
|
+
v-model="item.f_content_value"
|
|
79
|
+
:value.sync="item.f_content_value"
|
|
80
|
+
rows="3"
|
|
81
|
+
:readonly="mark === 1"
|
|
82
|
+
></input>
|
|
83
|
+
</div>
|
|
84
|
+
</div>
|
|
85
|
+
<div v-if="mark !== 1 && materials.length > 1" class="form-group col-sm-12 text-center">
|
|
86
|
+
<button type="button" class="btn btn-danger" @click="removeMaterial(i)">
|
|
87
|
+
<i class="fa fa-minus"></i> 移除
|
|
88
|
+
</button>
|
|
89
|
+
</div>
|
|
90
|
+
</div>
|
|
91
|
+
</div>
|
|
92
|
+
</div>
|
|
93
|
+
<div v-if="mark !== 1" class="form-group col-sm-12 text-center">
|
|
94
|
+
<button type="button" class="btn btn-success" @click="addMaterial()">
|
|
95
|
+
<i class="fa fa-plus"></i> 添加
|
|
96
|
+
</button>
|
|
97
|
+
</div>
|
|
98
|
+
</article>
|
|
99
|
+
<footer slot="modal-footer" class="modal-footer">
|
|
100
|
+
<template v-if="mark!== 1">
|
|
101
|
+
<button type="button" class="btn btn-primary" v-if="title==='新增'" @click="addlogs()"
|
|
102
|
+
:disabled="!$v.valid">确认
|
|
103
|
+
</button>
|
|
104
|
+
</template>
|
|
105
|
+
</footer>
|
|
106
|
+
</modal>
|
|
107
|
+
</div>
|
|
108
|
+
</template>
|
|
109
|
+
|
|
110
|
+
<script>
|
|
111
|
+
import {HttpResetClass} from 'vue-client'
|
|
112
|
+
import Vue from "vue";
|
|
113
|
+
export default {
|
|
114
|
+
name: 'replacement',
|
|
115
|
+
props: {
|
|
116
|
+
selectdata: {
|
|
117
|
+
type: Object
|
|
118
|
+
},
|
|
119
|
+
mark: {
|
|
120
|
+
type: Number,
|
|
121
|
+
default: 0
|
|
122
|
+
}
|
|
123
|
+
},
|
|
124
|
+
data() {
|
|
125
|
+
return {
|
|
126
|
+
onetomany: {
|
|
127
|
+
rows: []
|
|
128
|
+
},
|
|
129
|
+
logOptions: this.$appdata.getParam('置换设备'),
|
|
130
|
+
Options: this.$appdata.getParam('置换内容'),
|
|
131
|
+
device:'',
|
|
132
|
+
title: '新增',
|
|
133
|
+
deviceArry:[],
|
|
134
|
+
showMaterialModal: false,
|
|
135
|
+
materials: [
|
|
136
|
+
{
|
|
137
|
+
|
|
138
|
+
}
|
|
139
|
+
],
|
|
140
|
+
meterialOptions: [],
|
|
141
|
+
row: {},
|
|
142
|
+
bjqChecklag:[],
|
|
143
|
+
fmaterialname:{}
|
|
144
|
+
}
|
|
145
|
+
},
|
|
146
|
+
ready() {
|
|
147
|
+
this.getOnetoManyData()
|
|
148
|
+
},
|
|
149
|
+
methods: {
|
|
150
|
+
toArry(row){
|
|
151
|
+
//将row放进数组中
|
|
152
|
+
if (!row) return "无";
|
|
153
|
+
try {
|
|
154
|
+
// 添加方括号使其成为有效的JSON数组
|
|
155
|
+
const jsonStr = '[' + row + ']';
|
|
156
|
+
// 尝试解析字符串为JSON数组
|
|
157
|
+
const jsonArray = JSON.parse(jsonStr);
|
|
158
|
+
// 将解析后的数据保存到deviceArry中
|
|
159
|
+
this.deviceArry = jsonArray;
|
|
160
|
+
|
|
161
|
+
// 格式化显示数据
|
|
162
|
+
let result = '';
|
|
163
|
+
for (let i = 0; i < this.deviceArry.length; i++) {
|
|
164
|
+
const item = this.deviceArry[i];
|
|
165
|
+
result += `${item.f_content}:${item.f_content_value}`;
|
|
166
|
+
if (i < this.deviceArry.length - 1) {
|
|
167
|
+
result += ',';
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
return result;
|
|
171
|
+
} catch (err) {
|
|
172
|
+
console.error('解析JSON数据失败:', err);
|
|
173
|
+
return "无";
|
|
174
|
+
}
|
|
175
|
+
},
|
|
176
|
+
look(row){
|
|
177
|
+
this.title = '查看'
|
|
178
|
+
this.materials = [
|
|
179
|
+
{
|
|
180
|
+
id: row.id,
|
|
181
|
+
f_log_type:row.f_log_type,
|
|
182
|
+
f_log_content:row.f_log_content
|
|
183
|
+
}
|
|
184
|
+
],
|
|
185
|
+
this.showMaterialModal = true
|
|
186
|
+
},
|
|
187
|
+
|
|
188
|
+
changelogs(){
|
|
189
|
+
let http = new HttpResetClass()
|
|
190
|
+
let data = {
|
|
191
|
+
data: {
|
|
192
|
+
id: this.materials[0].id,
|
|
193
|
+
f_process_id:this.selectdata.f_process_id,
|
|
194
|
+
f_log_type:this.materials[0].f_log_type,
|
|
195
|
+
f_log_content:this.materials[0].f_log_content,
|
|
196
|
+
user:this.$login.f
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
http.load(
|
|
200
|
+
'POST',
|
|
201
|
+
`/rs/logic/addLogs`,
|
|
202
|
+
data,
|
|
203
|
+
{resolveMsg: '修改成功', rejectMsg: '添加失败'}
|
|
204
|
+
).then(res => {
|
|
205
|
+
this.closeMaterials()
|
|
206
|
+
})
|
|
207
|
+
},
|
|
208
|
+
addlogs(){
|
|
209
|
+
let value=[]
|
|
210
|
+
let http = new HttpResetClass()
|
|
211
|
+
this.materials.forEach(material => {
|
|
212
|
+
let obj={}
|
|
213
|
+
obj.f_content=material.f_content
|
|
214
|
+
obj.f_content_value=material.f_content_value
|
|
215
|
+
//obj转为字符串
|
|
216
|
+
obj = JSON.stringify(obj)
|
|
217
|
+
value.push(obj)
|
|
218
|
+
});
|
|
219
|
+
let s = {
|
|
220
|
+
f_process_id: this.selectdata.f_process_id,
|
|
221
|
+
f_operation_date: new Date().Format('yyyy-MM-dd HH:mm:ss'),
|
|
222
|
+
f_content_value:`${value}` ,
|
|
223
|
+
f_content: this.device,
|
|
224
|
+
f_operator: Vue.user.name,
|
|
225
|
+
f_operator_id: Vue.user.id
|
|
226
|
+
}
|
|
227
|
+
let data = {
|
|
228
|
+
tableName: 't_replacement',
|
|
229
|
+
model: s
|
|
230
|
+
}
|
|
231
|
+
http.load(
|
|
232
|
+
'POST',
|
|
233
|
+
`${this.$androidUtil.getProxyUrl()}/rs/logic/entitySingleTable`,
|
|
234
|
+
data,
|
|
235
|
+
{resolveMsg: null, rejectMsg: '添加失败'}
|
|
236
|
+
).then(res => {
|
|
237
|
+
this.getOnetoManyData()
|
|
238
|
+
this.showMaterialModal=false
|
|
239
|
+
})
|
|
240
|
+
},
|
|
241
|
+
deletelogs(row){
|
|
242
|
+
let http = new HttpResetClass()
|
|
243
|
+
this.$showMessage('删除后不可恢复,确认删除吗?', ['confirm', 'cancel']).then((res) => {
|
|
244
|
+
if (res === 'confirm') {
|
|
245
|
+
let data = {
|
|
246
|
+
tableName:'t_replacement',
|
|
247
|
+
id:row.id
|
|
248
|
+
}
|
|
249
|
+
http.load(
|
|
250
|
+
'POST',
|
|
251
|
+
`${this.$androidUtil.getProxyUrl()}/rs/logic/delentitySingleTable`,
|
|
252
|
+
data,
|
|
253
|
+
{resolveMsg: '删除成功', rejectMsg: '删除失败'}
|
|
254
|
+
).then(res => {
|
|
255
|
+
this.getOnetoManyData()
|
|
256
|
+
})
|
|
257
|
+
}
|
|
258
|
+
})
|
|
259
|
+
},
|
|
260
|
+
async getOnetoManyData () {
|
|
261
|
+
let http = new HttpResetClass()
|
|
262
|
+
let data = {
|
|
263
|
+
tablename: `t_replacement`,
|
|
264
|
+
condition: `f_process_id='${this.selectdata.f_process_id}'`
|
|
265
|
+
}
|
|
266
|
+
let res = await http.load(
|
|
267
|
+
'POST',
|
|
268
|
+
`${this.$androidUtil.getProxyUrl()}/rs/sql/apply_singleTable?aaa=123`,
|
|
269
|
+
{data: data},
|
|
270
|
+
{resolveMsg: null, rejectMsg: 'onetomany查询失败'}
|
|
271
|
+
)
|
|
272
|
+
this.onetomany.rows = res.data
|
|
273
|
+
},
|
|
274
|
+
async openMaterialModal() {
|
|
275
|
+
this.title = '新增'
|
|
276
|
+
this.materials = [
|
|
277
|
+
{
|
|
278
|
+
f_devices: '',
|
|
279
|
+
f_content: '',
|
|
280
|
+
f_content_value: ''
|
|
281
|
+
}
|
|
282
|
+
];
|
|
283
|
+
this.showMaterialModal = true
|
|
284
|
+
},
|
|
285
|
+
|
|
286
|
+
closeMaterials() {
|
|
287
|
+
this.getOnetoManyData()
|
|
288
|
+
this.showMaterialModal = false
|
|
289
|
+
},
|
|
290
|
+
removeMaterial(index) {
|
|
291
|
+
if (this.materials.length > 1) {
|
|
292
|
+
this.materials.splice(index, 1);
|
|
293
|
+
} else {
|
|
294
|
+
this.$showMessage('至少需要保留一组数据');
|
|
295
|
+
}
|
|
296
|
+
},
|
|
297
|
+
addMaterial() {
|
|
298
|
+
// 获取最后一个材料的设备值,如果存在的话
|
|
299
|
+
const lastDevice = this.materials.length > 0 ? this.materials[this.materials.length - 1].f_devices : '';
|
|
300
|
+
|
|
301
|
+
this.materials.push({
|
|
302
|
+
f_devices: lastDevice, // 复制上一个设备的值
|
|
303
|
+
f_content: '',
|
|
304
|
+
f_content_value: ''
|
|
305
|
+
});
|
|
306
|
+
},
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
</script>
|
|
311
|
+
|
|
312
|
+
<style scoped>
|
|
313
|
+
.panel-info {
|
|
314
|
+
border: 1px solid #bce8f1;
|
|
315
|
+
margin-bottom: 15px;
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
.panel-heading {
|
|
319
|
+
background-color: #d9edf7;
|
|
320
|
+
border-bottom: 1px solid #bce8f1;
|
|
321
|
+
color: #31708f;
|
|
322
|
+
padding: 10px 15px;
|
|
323
|
+
}
|
|
324
|
+
|
|
325
|
+
.panel-body {
|
|
326
|
+
padding: 15px;
|
|
327
|
+
}
|
|
328
|
+
|
|
329
|
+
.form-group {
|
|
330
|
+
margin-bottom: 15px;
|
|
331
|
+
}
|
|
332
|
+
|
|
333
|
+
.btn-success {
|
|
334
|
+
margin-top: 10px;
|
|
335
|
+
}
|
|
336
|
+
|
|
337
|
+
.modal-body {
|
|
338
|
+
max-height: 500px;
|
|
339
|
+
overflow-y: auto;
|
|
340
|
+
}
|
|
341
|
+
</style>
|
|
@@ -345,16 +345,31 @@
|
|
|
345
345
|
</footer>
|
|
346
346
|
</modal>
|
|
347
347
|
|
|
348
|
-
|
|
348
|
+
|
|
349
|
+
<modal v-if="showQrCode" :show.sync="showQrCode" v-ref:modal :large="true" :backdrop="false" title="二维码">
|
|
349
350
|
<header slot="modal-header" class="modal-header">
|
|
350
|
-
<button type="button" class="close" @click="
|
|
351
|
-
<h4 class="modal-title">打印预览</h4>
|
|
351
|
+
<button type="button" class="close" @click="closeQrCode"><span>×</span></button>
|
|
352
352
|
</header>
|
|
353
353
|
<article slot="modal-body" class="modal-body clearfix">
|
|
354
|
-
<
|
|
354
|
+
<div partial>
|
|
355
|
+
<div class="" align="center">
|
|
356
|
+
<div style="margin-bottom:10px "><img src="../../../assets/scanCode.png">请扫描下方二维码进行付款</div>
|
|
357
|
+
<div class="row app-row">
|
|
358
|
+
<div class="col-xs-12">
|
|
359
|
+
<label class="font text-left">订单编号:{{ order.body.tradeNo }}</label>
|
|
360
|
+
</div>
|
|
361
|
+
</div>
|
|
362
|
+
</div>
|
|
363
|
+
<div class="" align="center">
|
|
364
|
+
<div class="QR-code" >
|
|
365
|
+
<img src="../../../assets/qrcode_no.png" style="width: 266px;height: 266px"/>
|
|
366
|
+
<div id="qrcode" style="margin-top: 25px;width: 266px;height: 266px"></div>
|
|
367
|
+
</div>
|
|
368
|
+
</div>
|
|
369
|
+
</div>
|
|
355
370
|
</article>
|
|
356
371
|
<footer slot="modal-footer" class="modal-footer">
|
|
357
|
-
<button type="button" class="btn btn-primary" @click="
|
|
372
|
+
<button type="button" class="btn btn-primary" @click="closeQrCode()">关闭</button>
|
|
358
373
|
</footer>
|
|
359
374
|
</modal>
|
|
360
375
|
</div>
|
|
@@ -364,6 +379,7 @@ import {getNowDate,isEmpty} from '../../../components/Util'
|
|
|
364
379
|
import {PagedList} from 'vue-client'
|
|
365
380
|
import {HttpResetClass} from 'vue-client'
|
|
366
381
|
import Vue from 'vue'
|
|
382
|
+
import QRCode from "qrcodejs2";
|
|
367
383
|
|
|
368
384
|
export default {
|
|
369
385
|
title: '收费管理',
|
|
@@ -380,20 +396,120 @@ export default {
|
|
|
380
396
|
return {
|
|
381
397
|
showCharge: false, // 收费明细
|
|
382
398
|
showInvalid: false, // 作废
|
|
383
|
-
showPrint: false, // 打印
|
|
384
399
|
model: {
|
|
385
400
|
data: null
|
|
386
401
|
}, // 记录
|
|
387
402
|
useraddresList: [], // 地址列表
|
|
388
403
|
charge: {
|
|
389
404
|
|
|
390
|
-
}
|
|
405
|
+
},
|
|
406
|
+
order:'',
|
|
407
|
+
isTimeout:false,
|
|
408
|
+
showQrCode:false
|
|
391
409
|
}
|
|
392
410
|
},
|
|
393
411
|
ready () {
|
|
394
412
|
this.search()
|
|
395
413
|
},
|
|
396
414
|
methods: {
|
|
415
|
+
closeQrCode(){
|
|
416
|
+
document.getElementById('qrcode').innerHTML = ''
|
|
417
|
+
},
|
|
418
|
+
async openQrCode() {
|
|
419
|
+
const merchantMsg =this.$appdata.getSingleValue('商户号')
|
|
420
|
+
if (!merchantMsg){
|
|
421
|
+
this.$showMessage('未配备商户号,请联系管理员!')
|
|
422
|
+
return
|
|
423
|
+
}
|
|
424
|
+
const outTradeNo = this.generateRandomString(30)
|
|
425
|
+
// 下订单
|
|
426
|
+
let http = new HttpResetClass()
|
|
427
|
+
const val = {
|
|
428
|
+
"body": this.charge.f_payment_term,
|
|
429
|
+
"detail": this.charge.f_payment_term,
|
|
430
|
+
"totalAmount": (this.charge.f_charge_money).toString(),
|
|
431
|
+
"merchantMsg": merchantMsg,//商户id
|
|
432
|
+
"outTradeNo": outTradeNo,//随机数30位
|
|
433
|
+
"service": "nativePay",//死值
|
|
434
|
+
"tradeType": "wechat_jsapi"//死值
|
|
435
|
+
}
|
|
436
|
+
try {
|
|
437
|
+
let res = await http.load('POST', `${this.$androidUtil.getProxyUrl()}/bank/rs/logic/BC_10001`, {data: val}, {
|
|
438
|
+
resolveMsg: null,
|
|
439
|
+
rejectMsg: null
|
|
440
|
+
})
|
|
441
|
+
if (res.data.status === 200) {
|
|
442
|
+
console.log("调用结果", res.data, res.data.body.url)
|
|
443
|
+
try {
|
|
444
|
+
this.order = res.data
|
|
445
|
+
this.isTimeout = false
|
|
446
|
+
this.showQrCode = true
|
|
447
|
+
console.log(this.order)
|
|
448
|
+
this.$nextTick(() => {
|
|
449
|
+
this.qrcode(res.data.body.url)
|
|
450
|
+
})
|
|
451
|
+
if (this.order.body.tradeNo) {
|
|
452
|
+
this.timer1 = window.setInterval(this.getOrderInformation, 3000)
|
|
453
|
+
}
|
|
454
|
+
} catch (e) {
|
|
455
|
+
this.$showMessage('创建订单失败!')
|
|
456
|
+
}
|
|
457
|
+
} else {
|
|
458
|
+
this.$showMessage('获取二维码失败!')
|
|
459
|
+
}
|
|
460
|
+
} catch (e) {
|
|
461
|
+
this.$showMessage('获取二维码失败,请检查网络!')
|
|
462
|
+
}
|
|
463
|
+
},
|
|
464
|
+
// 获取订单信息
|
|
465
|
+
async getOrderInformation() {
|
|
466
|
+
const merchantMsg =this.$appdata.getSingleValue('商户号')
|
|
467
|
+
// 查询订单信息
|
|
468
|
+
console.log('查询订单信息!!!', this.order)
|
|
469
|
+
try {
|
|
470
|
+
let http = new HttpResetClass()
|
|
471
|
+
let res = await http.load('POST', `${this.$androidUtil.getProxyUrl()}/bank/rs/logic/BC_10003`, {
|
|
472
|
+
data: {
|
|
473
|
+
"service": "queryOrder",
|
|
474
|
+
"outTradeNo": this.order.body.outTradeNo,
|
|
475
|
+
"merchantMsg": merchantMsg,
|
|
476
|
+
"tradeNo": ""
|
|
477
|
+
}
|
|
478
|
+
}, {
|
|
479
|
+
resolveMsg: null,
|
|
480
|
+
rejectMsg: null
|
|
481
|
+
})
|
|
482
|
+
// 支付成功
|
|
483
|
+
this.orderstatus = res.data
|
|
484
|
+
console.log('查询结果=======', res.data)
|
|
485
|
+
if (res.data.status == '200') {
|
|
486
|
+
window.clearInterval(this.timer1)
|
|
487
|
+
console.log('支付成功', this.orderstatus)
|
|
488
|
+
this.order = {}
|
|
489
|
+
}
|
|
490
|
+
} catch (e) {
|
|
491
|
+
window.clearInterval(this.timer1)
|
|
492
|
+
this.$showMessage('创建订单失败!')
|
|
493
|
+
this.order = {}
|
|
494
|
+
}
|
|
495
|
+
},
|
|
496
|
+
qrcode(url) {
|
|
497
|
+
new QRCode('qrcode', {
|
|
498
|
+
text: url, // 设置二维码内容或跳转地址
|
|
499
|
+
width: 266, // 设置宽度,单位像素
|
|
500
|
+
height: 266, // 设置高度,单位像素
|
|
501
|
+
correctLevel: QRCode.CorrectLevel.L //容错率,L/M/Hs
|
|
502
|
+
})
|
|
503
|
+
},
|
|
504
|
+
generateRandomString(length) {
|
|
505
|
+
let result = new Date().getTime().toString()
|
|
506
|
+
const characters = 'abcdefghijklmnopqrstuvwxyz0123456789';
|
|
507
|
+
const charactersLength = characters.length;
|
|
508
|
+
for (let i = 0; i < length; i++) {
|
|
509
|
+
result += characters.charAt(Math.floor(Math.random() * charactersLength));
|
|
510
|
+
}
|
|
511
|
+
return result.substring(0, 30);
|
|
512
|
+
},
|
|
397
513
|
async payerNumberChange () {
|
|
398
514
|
if (isEmpty(this.charge.f_payer_number)) {
|
|
399
515
|
return
|
|
@@ -415,10 +531,6 @@ export default {
|
|
|
415
531
|
print () {
|
|
416
532
|
this.$refs.print.$refs.print.PrintTable()
|
|
417
533
|
},
|
|
418
|
-
showPrintModal(row) {
|
|
419
|
-
this.charge = row
|
|
420
|
-
this.showPrint = true
|
|
421
|
-
},
|
|
422
534
|
selectAddres () {
|
|
423
535
|
if (this.charge.useraddres) {
|
|
424
536
|
this.charge.f_cumulative_payment_money = this.charge.useraddres.f_cumulative_payment_money
|
|
@@ -452,6 +564,9 @@ export default {
|
|
|
452
564
|
},
|
|
453
565
|
// 新增收费
|
|
454
566
|
async saveCharge() {
|
|
567
|
+
if(this.charge.f_payment_method=='二维码收费'){
|
|
568
|
+
this.openQrCode()
|
|
569
|
+
}
|
|
455
570
|
let http = new HttpResetClass()
|
|
456
571
|
let data = {
|
|
457
572
|
apply: this.selectdata,
|
|
@@ -591,7 +706,6 @@ export default {
|
|
|
591
706
|
closeModal() {
|
|
592
707
|
this.showCharge = false
|
|
593
708
|
this.showInvalid = false
|
|
594
|
-
this.showPrint = false
|
|
595
709
|
this.charge = {}
|
|
596
710
|
this.search()
|
|
597
711
|
}
|