apply-clients 3.5.5-7 → 3.5.5-9

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.
Files changed (50) hide show
  1. package/build/dev-server.js +6 -15
  2. package/package.json +1 -1
  3. package/src/App.vue +25 -25
  4. package/src/apply.js +141 -141
  5. package/src/components/android/AppCheckTakePic.vue +168 -168
  6. package/src/components/android/Process/AppServiceControl.vue +1755 -1755
  7. package/src/components/product/Function/Service/FunctionServiceControl.vue +497 -497
  8. package/src/components/product/MaterialsManage/MaterialsBase.vue +181 -181
  9. package/src/components/product/MaterialsManage/MaterialsManage.vue +60 -60
  10. package/src/components/product/PcZhihuanManagement.vue +160 -160
  11. package/src/components/product/Print/BuildOrder/buildOrderList.vue +339 -339
  12. package/src/components/product/Process/Processes/contractModel.vue +424 -454
  13. package/src/components/product/Process/Processes/selectApply.vue +251 -251
  14. package/src/components/product/Process/Processes/selectBcakApply.vue +250 -250
  15. package/src/components/product/Supervisory/SupervisoryList.vue +452 -452
  16. package/src/filiale/dingcheng/pc/SupervisoryList.vue +441 -441
  17. package/src/filiale/fugou/android/AppAddMaterialScience.vue +444 -440
  18. package/src/filiale/fugou/android/AppAddReplacement.vue +341 -341
  19. package/src/filiale/fugou/android/AppChargeManagement.vue +739 -739
  20. package/src/filiale/fugou/android/AppZhihuanManagement.vue +230 -230
  21. package/src/filiale/fugou/pc/AddReplacement.vue +340 -340
  22. package/src/filiale/fugou/pc/ApplyChargeList.vue +480 -480
  23. package/src/filiale/fugou/pc/SupervisoryServiceControl.vue +881 -0
  24. package/src/filiale/fugou/pc/addMaterialScience.vue +481 -481
  25. package/src/filiale/fugou/pc/addressAndUserinfoManagement.vue +216 -216
  26. package/src/filiale/fugou/pc/chargeReport.vue +143 -143
  27. package/src/filiale/fugou/pc.js +2 -1
  28. package/src/filiale/gongyi/android/AppDisclosurerecord.vue +214 -214
  29. package/src/filiale/gongyi/android/AppInstallationDetails.vue +500 -500
  30. package/src/filiale/gongyi/android/AppLegacyIssues.vue +309 -309
  31. package/src/filiale/gongyi/android/AppSign.vue +170 -170
  32. package/src/filiale/gongyi/android/AppSupplementalAgreement.vue +298 -298
  33. package/src/filiale/gongyi/android.js +18 -18
  34. package/src/filiale/gongyi/pc/ApplyUpload.vue +371 -371
  35. package/src/filiale/gongyi/pc/PcAddLogs.vue +221 -221
  36. package/src/filiale/gongyi/pc/PcDisclosurerecord.vue +218 -218
  37. package/src/filiale/gongyi/pc/PcLegacyIssues.vue +309 -309
  38. package/src/filiale/gongyi/pc/SupervisoryServiceControl.vue +894 -894
  39. package/src/filiale/gongyi/pc/SupervisoryServiceView.vue +1005 -1005
  40. package/src/filiale/gongyi/pc/addMaterialScience.vue +575 -575
  41. package/src/filiale/gongyi/pc/chargeManagement.vue +765 -765
  42. package/src/filiale/gongyi/pc/supplementalAgreement.vue +277 -277
  43. package/src/filiale/gongyi/pc.js +24 -24
  44. package/src/filiale/hongda/pc/SupervisoryList.vue +422 -422
  45. package/src/filiale/jingyang/pc/SupervisoryList.vue +459 -459
  46. package/src/main.js +1 -2
  47. package/src/test/SessionTestServlet.java +69 -0
  48. package/webapp/WEB-INF/web.xml +52 -0
  49. package/webapp/session-test.jsp +59 -0
  50. package/~/chatbot/main.py +0 -57
@@ -1,454 +1,424 @@
1
- <template>
2
- <div style="margin-bottom: 20px" class="form-group select-overspread">
3
- <label class="control-label-justify control-label col-sm-3">签订合同</label>
4
- <div class="col-sm-10" >
5
- <button class="button_search button_spacing" type="button" style="width: max-content;position: absolute" @click="openSelect" :disabled="mark === 1">选择</button>
6
- </div>
7
- </div>
8
- <modal v-if="showselect" :show.sync="showselect" title="签订合同" v-ref:modal :large="true" :backdrop="false">
9
- <article slot="modal-header" class="modal-header" >
10
- <div>
11
- <criteria-paged :model="model" v-ref:cp :pager="false" v-if="selectList">
12
- <data-grid :model="model" partial='list' v-ref:grid class="list_area table_sy" style="height: 100%">
13
- <template partial='head'>
14
- <tr>
15
- <th style="white-space: nowrap;">序号</th>
16
- <th style="white-space: nowrap;">合同编号</th>
17
- <th style="white-space: nowrap;">合同名称</th>
18
- <th style="white-space: nowrap;">合同类型</th>
19
- <th style="white-space: nowrap;">合同状态</th>
20
- <th style="white-space: nowrap;">选择</th>
21
- </tr>
22
- </template>
23
- <template partial='body'>
24
- <tr >
25
- <td style="text-align: center;">
26
- <nobr><font>{{$index+1}}</font></nobr>
27
- </td>
28
- <td style="text-align: center;">
29
- <nobr><font>{{ row.f_contract_code}}</font></nobr>
30
- </td>
31
- <td style="text-align: center;">
32
- <nobr><font>{{ row.f_contract_name }}</font></nobr>
33
- </td>
34
- <td style="text-align: center;">
35
- <nobr><font>{{ row.f_contract_type }}</font></nobr>
36
- </td>
37
- <td style="text-align: center;">
38
- <nobr><font>{{ row.f_contract_state }}</font></nobr>
39
- </td>
40
- <td style="text-align: center;">
41
- <nobr><font>
42
- <button type="button" name="button" class="button_export" @click.prevent="$parent.$parent.$parent.$parent.select(row)">确认选择</button>
43
- </font></nobr>
44
- </td>
45
- </tr>
46
- </template>
47
- </data-grid>
48
- </criteria-paged>
49
- </div>
50
- <div>
51
- <div class="form-group col-sm-12" >
52
- <label class="col-sm-2 control-label">甲方:</label>
53
- <div class="col-sm-10">
54
- <input type="text"
55
- class="form-control input_view"
56
- style="width: 100%"
57
- v-model="userRecord.f_lessor"
58
- :value.sync="userRecord.f_lessor"
59
- />
60
- </div>
61
- </div>
62
- <div class="form-group col-sm-12" >
63
- <label class="col-sm-2 control-label">项目地点及名称:</label>
64
- <div class="col-sm-10">
65
- <input type="text"
66
- class="form-control input_view"
67
- style="width: 100%"
68
- v-model="userRecord.f_project_address"
69
- :value.sync="userRecord.f_project_address"
70
- />
71
- </div>
72
- </div>
73
- <div class="form-group col-sm-12" >
74
- <label class="col-sm-2 control-label">户数:</label>
75
- <div class="col-sm-10">
76
- <input type="text"
77
- class="form-control input_view"
78
- style="width: 100%"
79
- v-model="userRecord.f_households"
80
- :value.sync="userRecord.f_households"
81
- />
82
- </div>
83
- </div>
84
- <div class="form-group col-sm-12" >
85
- <label class="col-sm-2 control-label">金额:</label>
86
- <div class="col-sm-10">
87
- <input type="text"
88
- class="form-control input_view"
89
- style="width: 100%"
90
- placeholder="0.00"
91
- @keyup="handleInput"
92
- v-model="userRecord.f_cost" />
93
- </div>
94
- </div>
95
- <div class="form-group col-sm-12">
96
- <label class="col-sm-2 control-label">金额大写:</label>
97
- <div class="col-sm-10">
98
- <input type="text"
99
- class="form-control input_view"
100
- style="width: 100%"
101
- :value="smalltoBIG(0)"
102
- readonly
103
- v-model.sync="userRecord.f_amount_capital" />
104
- </div>
105
- </div>
106
- <div class="form-group col-sm-12" >
107
- <label class="col-sm-2 control-label">付款方式:</label>
108
- <div class="col-sm-10">
109
- <input-select
110
- placeholder='请选择' width="100%"
111
- v-model="userRecord.f_payment_method"
112
- :value.sync="userRecord.f_payment_method"
113
- :options='paymentMethod'
114
- class="select select_list"
115
- :value-single="true"
116
- close-on-select ></input-select>
117
- </div>
118
- </div>
119
- <div class="form-group col-sm-12">
120
- <label class="col-sm-2 control-label">工期:</label>
121
- <div class="col-sm-10">
122
- <input type="text"
123
- class="form-control input_view"
124
- style="width: 100%"
125
- placeholder="请输入"
126
- :value.sync="userRecord.f_duration"
127
- v-model.sync="userRecord.f_duration" />
128
- </div>
129
- </div>
130
- <div class="form-group col-sm-12">
131
- <label class="col-sm-2 control-label">指定人员:</label>
132
- <div class="col-sm-10">
133
- <input type="text"
134
- class="form-control input_view"
135
- style="width: 100%"
136
- placeholder="请输入"
137
- :value.sync="userRecord.f_personnel"
138
- v-model.sync="userRecord.f_personnel" />
139
- </div>
140
- </div>
141
- <div class="form-group col-sm-12">
142
- <label class="col-sm-2 control-label">联系电话:</label>
143
- <div class="col-sm-10">
144
- <input type="text"
145
- class="form-control input_view"
146
- style="width: 100%"
147
- placeholder="请输入"
148
- :value.sync="userRecord.f_contact_phone"
149
- v-model.sync="userRecord.f_contact_phone" />
150
- </div>
151
- </div>
152
- <div class="form-group col-sm-12">
153
- <label class="col-sm-2 control-label">甲方单位(盖章):</label>
154
- <div class="col-sm-10">
155
- <input type="text"
156
- class="form-control input_view"
157
- style="width: 100%"
158
- placeholder="请输入"
159
- :value.sync="userRecord.f_unit"
160
- v-model.sync="userRecord.f_unit" />
161
- </div>
162
- </div>
163
- <div class="form-group col-sm-12">
164
- <label class="col-sm-2 control-label">甲方法定代表人或授权代表:</label>
165
- <div class="col-sm-10">
166
- <input type="text"
167
- class="form-control input_view"
168
- style="width: 100%"
169
- placeholder="请输入"
170
- :value.sync="userRecord.f_representative"
171
- v-model.sync="userRecord.f_representative" />
172
- </div>
173
- </div>
174
- </div>
175
- </article>
176
- <footer slot="modal-footer" class="modal-footer">
177
- <button type="button" class="btn btn-primary" @click="save()">确认</button>
178
- <button type="button" class="btn btn-primary" @click="NoSelect()">取消</button>
179
- </footer>
180
- </modal>
181
- </template>
182
- <script>
183
- import {HttpResetClass} from "vue-client";
184
- import {isEmpty} from "../../../Util";
185
-
186
- export default {
187
- title: '合同签订',
188
- props: {
189
- selectdata: {
190
- type: Object
191
- },
192
- mark: {
193
- type: Number,
194
- default: 0
195
- }
196
- },
197
- data () {
198
- return {
199
- model:{
200
- rows:[]
201
- },
202
- showselect: false,
203
- selectList:false,
204
- Options:this.$appdata.getParam("合同模板"),
205
- credOptions:this.$appdata.getParam('证件类型'),
206
- templatename:'',
207
- contractInfo: {
208
- f_contract_id: '',
209
- f_contract_signature_id: null,
210
- f_contract_name: '',
211
- f_contract_date: '',
212
- f_contract_type: "",
213
- f_file_id: "",
214
- f_contract_arguments: [],
215
- f_signature_location: "",
216
- f_state: "",
217
- f_contract_url: null,
218
- f_template_url: "",
219
- f_signature_url: null
220
- },
221
- userRecord: {
222
- f_userinfo_id: this.selectdata.f_userinfo_id?this.selectdata.f_userinfo_id:this.selectdata.f_process_id,
223
- f_filialeid:this.$login.f.orgid,
224
- f_userinfo_code: this.selectdata.f_userinfo_code?this.selectdata.f_userinfo_code:this.selectdata.f_process_id,
225
- f_user_name:this.selectdata.f_user_name?this.selectdata.f_user_name:"",
226
- f_credentials: this.selectdata.f_credentials?this.selectdata.f_credentials:"",
227
- f_idnumber: this.selectdata.f_idnumber?this.selectdata.f_idnumber:"",
228
- f_address: this.selectdata.f_address?this.selectdata.f_address:"",
229
- f_user_phone:this.selectdata.f_phone?this.selectdata.f_phone:"",
230
- //甲方
231
- f_lessor:"",
232
- //项目地点及名称
233
- f_project_address: "",
234
- //户数
235
- f_households: "",
236
- //费用
237
- f_cost: "",
238
- //金额大写
239
- f_amount_capital: "",
240
- //付款方式
241
- f_payment_method: "",
242
- //工期
243
- f_duration: "",
244
- //指定人员
245
- f_personnel: "",
246
- //联系电话
247
- f_contact_phone: "",
248
- //甲方单位(盖章)
249
- f_unit: "",
250
- //甲方法定代表人或授权代表
251
- f_representative: ""
252
- },
253
- loginInfo: {
254
- f_operatorid: this.$login.f.id,
255
- f_operator: this.$login.f.name,
256
- f_orgid: this.$login.f.orgid
257
- }
258
- }
259
- },
260
- ready () {
261
- this.getContractTemplate()
262
- },
263
- methods: {
264
- select(row){
265
- this.$showMessage(`是否选择当前合同`, ['confirm']).then((res) => {
266
- if (res === 'confirm') {
267
- this.contractInfo.f_contract_id=row.f_contract_id
268
- this.contractInfo.f_contract_signature_id=row.f_contract_signature_id
269
- this.contractInfo.f_contract_name=row.f_contract_name
270
- this.contractInfo.f_contract_date=row.f_contract_date
271
- this.contractInfo.f_contract_type=row.f_contract_type
272
- this.contractInfo.f_file_id=row.f_file_id
273
- this.contractInfo.f_contract_arguments=row.f_contract_arguments
274
- this.contractInfo.f_signature_location=row.f_signature_location
275
- this.contractInfo.f_state=row.f_state
276
- this.contractInfo.f_contract_url=row.f_contract_url
277
- this.contractInfo.f_template_url=row.f_template_url
278
- this.contractInfo. f_signature_url=row.f_signature_url
279
- this.selectList=false
280
- }
281
- })
282
- },
283
- async getContractTemplate(){
284
- let data = {
285
- tablename: 't_contract_template',
286
- condition: `f_contract_state='有效' and f_orgid='${this.$login.f.orgid}'`
287
- }
288
- let http = new HttpResetClass()
289
- await http.load('POST', 'rs/sql/apply_singleTable', {data: data}, {resolveMsg: null, rejectMsg: '合同信息查询失败!!!'}).then(res => {
290
- if (res.data.length> 0) {
291
- this.model.rows = res.data
292
- }
293
- })
294
- },
295
- handleInput(e) {
296
- // 通过正则过滤小数点后两位
297
- e.target.value = (e.target.value.match(/^\d*(\.?\d{0,2})/g)[0]) || null
298
- this.contractInfo.f_amount_capital = this.smalltoBIG(e.target.value)
299
- },
300
- // 金额转大写
301
- smalltoBIG(n) {
302
- let fraction = ['', '分'];
303
- let digit = ['', '壹', '贰', '叁', '肆', '伍', '陆', '柒', '捌', '玖'];
304
- let unit = [['元', '万', '亿'], ['', '拾', '佰', '仟']];
305
- let head = n < 0 ? '欠' : '';
306
- n = Math.abs(n);
307
- let s = '';
308
- for (var i = 0; i < fraction.length; i++) {
309
- s += (digit[Math.floor(n * 10 * Math.pow(10, i)) % 10] + fraction[i]).replace(/零./, '');
310
- }
311
- s = s || '整';
312
- n = Math.floor(n);
313
- for (var i = 0; i < unit[0].length && n > 0; i++) {
314
- let p = '';
315
- for (var j = 0; j < unit[1].length && n > 0; j++) {
316
- p = digit[n % 10] + unit[1][j] + p;
317
- n = Math.floor(n / 10);
318
- }
319
- s = p.replace(/(零.)*零$/, '').replace(/^$/, '零') + unit[0][i] + s;
320
- }
321
- return head + s.replace(/(零.)*零元/, '元').replace(/(零.)+/g, '零').replace(/^整$/, '零元整')
322
- },
323
- async save() {
324
- if(isEmpty(this.contractInfo.f_contract_name)){
325
- this.$showMessage(`请选择需要签订的合同`)
326
- return
327
- }else{
328
- this.$showMessage(`是否确认生成此合同`, ['confirm']).then(async (res) => {
329
- if (res === 'confirm') {
330
- let http = new HttpResetClass()
331
- let data = {
332
- contractInfo:this.contractInfo,
333
- userRecord:this.userRecord,
334
- loginInfo:this.loginInfo
335
- }
336
- await http.load('POST', 'api/af-revenue/logic/generateContract', {data: data}, {
337
- resolveMsg: null,
338
- rejectMsg: '合同信息查询失败!!!'
339
- }).then(async res => {
340
- //保存合同信息
341
- if (res.data.code == 200) {
342
- //保存到t_files表
343
- let param={
344
- f_blobid:this.selectdata.f_process_id,
345
- fusetype:"报装合同",
346
- f_filename:res.data.f_contract_name,
347
- f_uploaddate:res.data.f_create_date,
348
- f_downloadpath:res.data.f_signature_url,
349
- f_realpath:res.data.f_signature_path
350
- }
351
- await this.$resetpost('rs/entity/t_files', param).then(res => {
352
- this.$showMessage(`合同生成成功!!!`),
353
- this.selectList=false
354
- this.showselect = false
355
- })
356
- } else {
357
- this.selectList=false
358
- this.showselect = false
359
- this.$showMessage(`合同生成失败!!!,原因为${res.data.msg}`)
360
- }
361
- })
362
- }
363
- })
364
- }
365
- },
366
- clear () {
367
- },
368
- openSelect () {
369
- this.selectList=true
370
- this.showselect = true
371
- },
372
- NoSelect () {
373
- //清除数据
374
- this.userRecord={
375
- f_userinfo_id: this.selectdata.f_userinfo_id?this.selectdata.f_userinfo_id:this.selectdata.f_process_id,
376
- f_filialeid:this.$login.f.orgid,
377
- f_userinfo_code: this.selectdata.f_userinfo_code?this.selectdata.f_userinfo_code:this.selectdata.f_process_id,
378
- f_user_name:this.selectdata.f_user_name?this.selectdata.f_user_name:"",
379
- f_credentials: this.selectdata.f_credentials?this.selectdata.f_credentials:"",
380
- f_idnumber: this.selectdata.f_idnumber?this.selectdata.f_idnumber:"",
381
- f_address: this.selectdata.f_address?this.selectdata.f_address:"",
382
- f_user_phone:this.selectdata.f_phone?this.selectdata.f_phone:"",
383
- //甲方
384
- f_lessor:"",
385
- //项目地点及名称
386
- f_project_address: "",
387
- //户数
388
- f_households: "",
389
- //费用
390
- f_cost: "",
391
- //金额大写
392
- f_amount_capital: "",
393
- //付款方式
394
- f_payment_method: "",
395
- //工期
396
- f_duration: "",
397
- //指定人员
398
- f_personnel: "",
399
- //联系电话
400
- f_contact_phone: "",
401
- //甲方单位(盖章)
402
- f_unit: "",
403
- //甲方法定代表人或授权代表
404
- f_representative: "",
405
- },
406
- this.selectList=false
407
- this.showselect = false
408
- }
409
- },
410
- events: {
411
- },
412
- computed: {
413
- paymentMethod() {
414
- return this.$appdata.getParam("付款方式")
415
- }
416
- },
417
- watch: {
418
- }
419
- }
420
- </script>
421
- <style scoped>
422
- .control-label-justify {
423
- display: inline-block;
424
- vertical-align: top;
425
- width: 110px;
426
- text-align: justify;
427
- font-family: PingFang-SC-Bold;
428
- }
429
-
430
- .control-label-justify::after {
431
- content: "";
432
- display: inline-block;
433
- width: 100%;
434
- overflow: hidden;
435
- height: 0;
436
- }
437
- .input_view{
438
- padding: 8px;
439
- background-color: #ffffff;
440
- border-radius: 2px;
441
- border: solid 1px #c7c7c7!important;
442
- color: #333333!important;
443
- font-size: 15px!important;
444
- }
445
-
446
- .input_view[readonly]{
447
- border: 1px solid #DDD!important;
448
- color:#ACA899!important;
449
- }
450
- .input_view:disabled{
451
- border: 1px solid #DDD!important;
452
- color:#ACA899!important;
453
- }
454
- </style>
1
+ <template>
2
+ <div style="margin-bottom: 20px" class="form-group select-overspread">
3
+ <label class="control-label-justify control-label col-sm-3">签订合同</label>
4
+ <div class="col-sm-10" >
5
+ <button class="button_search button_spacing" type="button" style="width: max-content;position: absolute" @click="openSelect" :disabled="mark === 1">选择</button>
6
+ </div>
7
+ </div>
8
+ <modal v-if="showselect" :show.sync="showselect" title="签订合同" v-ref:modal :large="true" :backdrop="false">
9
+ <article slot="modal-header" class="modal-header" >
10
+ <div>
11
+ <criteria-paged :model="model" v-ref:cp :pager="false" v-if="selectList">
12
+ <data-grid :model="model" partial='list' v-ref:grid class="list_area table_sy" style="height: 100%">
13
+ <template partial='head'>
14
+ <tr>
15
+ <th style="white-space: nowrap;">序号</th>
16
+ <th style="white-space: nowrap;">合同编号</th>
17
+ <th style="white-space: nowrap;">合同名称</th>
18
+ <th style="white-space: nowrap;">合同类型</th>
19
+ <th style="white-space: nowrap;">合同状态</th>
20
+ <th style="white-space: nowrap;">选择</th>
21
+ </tr>
22
+ </template>
23
+ <template partial='body'>
24
+ <tr >
25
+ <td style="text-align: center;">
26
+ <nobr><font>{{$index+1}}</font></nobr>
27
+ </td>
28
+ <td style="text-align: center;">
29
+ <nobr><font>{{ row.f_contract_code}}</font></nobr>
30
+ </td>
31
+ <td style="text-align: center;">
32
+ <nobr><font>{{ row.f_contract_name }}</font></nobr>
33
+ </td>
34
+ <td style="text-align: center;">
35
+ <nobr><font>{{ row.f_contract_type }}</font></nobr>
36
+ </td>
37
+ <td style="text-align: center;">
38
+ <nobr><font>{{ row.f_contract_state }}</font></nobr>
39
+ </td>
40
+ <td style="text-align: center;">
41
+ <nobr><font>
42
+ <button type="button" name="button" class="button_export" @click.prevent="$parent.$parent.$parent.$parent.select(row)">确认选择</button>
43
+ </font></nobr>
44
+ </td>
45
+ </tr>
46
+ </template>
47
+ </data-grid>
48
+ </criteria-paged>
49
+ </div>
50
+ <div>
51
+ <div class="form-group col-sm-12" >
52
+ <label class="col-sm-2 control-label">甲方:</label>
53
+ <div class="col-sm-10">
54
+ <input type="text"
55
+ class="form-control input_view"
56
+ style="width: 100%"
57
+ v-model="userRecord.f_lessor"
58
+ :value.sync="userRecord.f_lessor"
59
+ />
60
+ </div>
61
+ </div>
62
+ <div class="form-group col-sm-12" >
63
+ <label class="col-sm-2 control-label">项目地点及名称:</label>
64
+ <div class="col-sm-10">
65
+ <input type="text"
66
+ class="form-control input_view"
67
+ style="width: 100%"
68
+ v-model="userRecord.f_project_address"
69
+ :value.sync="userRecord.f_project_address"
70
+ />
71
+ </div>
72
+ </div>
73
+ <div class="form-group col-sm-12" >
74
+ <label class="col-sm-2 control-label">户数:</label>
75
+ <div class="col-sm-10">
76
+ <input type="text"
77
+ class="form-control input_view"
78
+ style="width: 100%"
79
+ v-model="userRecord.f_households"
80
+ :value.sync="userRecord.f_households"
81
+ />
82
+ </div>
83
+ </div>
84
+ <div class="form-group col-sm-12" >
85
+ <label class="col-sm-2 control-label">金额:</label>
86
+ <div class="col-sm-10">
87
+ <input type="text"
88
+ class="form-control input_view"
89
+ style="width: 100%"
90
+ placeholder="0.00"
91
+ @keyup="handleInput"
92
+ v-model="userRecord.f_cost" />
93
+ </div>
94
+ </div>
95
+ <div class="form-group col-sm-12">
96
+ <label class="col-sm-2 control-label">金额大写:</label>
97
+ <div class="col-sm-10">
98
+ <input type="text"
99
+ class="form-control input_view"
100
+ style="width: 100%"
101
+ :value="smalltoBIG(0)"
102
+ readonly
103
+ v-model.sync="userRecord.f_amount_capital" />
104
+ </div>
105
+ </div>
106
+ <div class="form-group col-sm-12" >
107
+ <label class="col-sm-2 control-label">付款方式:</label>
108
+ <div class="col-sm-10">
109
+ <input-select
110
+ placeholder='请选择' width="100%"
111
+ v-model="userRecord.f_payment_method"
112
+ :value.sync="userRecord.f_payment_method"
113
+ :options='paymentMethod'
114
+ class="select select_list"
115
+ :value-single="true"
116
+ close-on-select ></input-select>
117
+ </div>
118
+ </div>
119
+ <div class="form-group col-sm-12">
120
+ <label class="col-sm-2 control-label">工期:</label>
121
+ <div class="col-sm-10">
122
+ <input type="text"
123
+ class="form-control input_view"
124
+ style="width: 100%"
125
+ placeholder="请输入"
126
+ :value.sync="userRecord.f_duration"
127
+ v-model.sync="userRecord.f_duration" />
128
+ </div>
129
+ </div>
130
+ <div class="form-group col-sm-12">
131
+ <label class="col-sm-2 control-label">指定人员:</label>
132
+ <div class="col-sm-10">
133
+ <input type="text"
134
+ class="form-control input_view"
135
+ style="width: 100%"
136
+ placeholder="请输入"
137
+ :value.sync="userRecord.f_personnel"
138
+ v-model.sync="userRecord.f_personnel" />
139
+ </div>
140
+ </div>
141
+ <div class="form-group col-sm-12">
142
+ <label class="col-sm-2 control-label">联系电话:</label>
143
+ <div class="col-sm-10">
144
+ <input type="text"
145
+ class="form-control input_view"
146
+ style="width: 100%"
147
+ placeholder="请输入"
148
+ :value.sync="userRecord.f_contact_phone"
149
+ v-model.sync="userRecord.f_contact_phone" />
150
+ </div>
151
+ </div>
152
+ </div>
153
+ </article>
154
+ <footer slot="modal-footer" class="modal-footer">
155
+ <button type="button" class="btn btn-primary" @click="save()">确认</button>
156
+ <button type="button" class="btn btn-primary" @click="NoSelect()">取消</button>
157
+ </footer>
158
+ </modal>
159
+ </template>
160
+ <script>
161
+ import {HttpResetClass} from "vue-client";
162
+ import {isEmpty} from "../../../Util";
163
+
164
+ export default {
165
+ title: '合同签订',
166
+ props: {
167
+ selectdata: {
168
+ type: Object
169
+ },
170
+ mark: {
171
+ type: Number,
172
+ default: 0
173
+ }
174
+ },
175
+ data () {
176
+ return {
177
+ model:{
178
+ rows:[]
179
+ },
180
+ showselect: false,
181
+ selectList:false,
182
+ Options:this.$appdata.getParam("合同模板"),
183
+ credOptions:this.$appdata.getParam('证件类型'),
184
+ templatename:'',
185
+ contractInfo: {
186
+ f_contract_id: '',
187
+ f_contract_signature_id: null,
188
+ f_contract_name: '',
189
+ f_contract_date: '',
190
+ f_contract_type: "",
191
+ f_file_id: "",
192
+ f_contract_arguments: [],
193
+ f_signature_location: "",
194
+ f_state: "",
195
+ f_contract_url: null,
196
+ f_template_url: "",
197
+ f_signature_url: null
198
+ },
199
+ userRecord: {
200
+ f_userinfo_id: this.selectdata.f_userinfo_id?this.selectdata.f_userinfo_id:this.selectdata.f_process_id,
201
+ f_filialeid:this.$login.f.orgid,
202
+ f_userinfo_code: this.selectdata.f_userinfo_code?this.selectdata.f_userinfo_code:this.selectdata.f_process_id,
203
+ f_user_name:this.selectdata.f_user_name?this.selectdata.f_user_name:"",
204
+ f_credentials: this.selectdata.f_credentials?this.selectdata.f_credentials:"",
205
+ f_idnumber: this.selectdata.f_idnumber?this.selectdata.f_idnumber:"",
206
+ f_address: this.selectdata.f_address?this.selectdata.f_address:"",
207
+ f_user_phone:this.selectdata.f_phone?this.selectdata.f_phone:"",
208
+ //甲方
209
+ f_lessor:"",
210
+ //项目地点及名称
211
+ f_project_address: "",
212
+ //户数
213
+ f_households: "",
214
+ //费用
215
+ f_cost: "",
216
+ //金额大写
217
+ f_amount_capital: "",
218
+ //付款方式
219
+ f_payment_method: "",
220
+ //工期
221
+ f_duration: "",
222
+ //指定人员
223
+ f_personnel: "",
224
+ //联系电话
225
+ f_contact_phone: "",
226
+ },
227
+ loginInfo: {
228
+ f_operatorid: this.$login.f.id,
229
+ f_operator: this.$login.f.name,
230
+ f_orgid: this.$login.f.orgid
231
+ }
232
+ }
233
+ },
234
+ ready () {
235
+ this.getContractTemplate()
236
+ },
237
+ methods: {
238
+ select(row){
239
+ this.$showMessage(`是否选择当前合同`, ['confirm']).then((res) => {
240
+ if (res === 'confirm') {
241
+ this.contractInfo.f_contract_id=row.f_contract_id
242
+ this.contractInfo.f_contract_signature_id=row.f_contract_signature_id
243
+ this.contractInfo.f_contract_name=row.f_contract_name
244
+ this.contractInfo.f_contract_date=row.f_contract_date
245
+ this.contractInfo.f_contract_type=row.f_contract_type
246
+ this.contractInfo.f_file_id=row.f_file_id
247
+ this.contractInfo.f_contract_arguments=row.f_contract_arguments
248
+ this.contractInfo.f_signature_location=row.f_signature_location
249
+ this.contractInfo.f_state=row.f_state
250
+ this.contractInfo.f_contract_url=row.f_contract_url
251
+ this.contractInfo.f_template_url=row.f_template_url
252
+ this.contractInfo. f_signature_url=row.f_signature_url
253
+ this.selectList=false
254
+ }
255
+ })
256
+ },
257
+ async getContractTemplate(){
258
+ let data = {
259
+ tablename: 't_contract_template',
260
+ condition: `f_contract_state='有效' and f_orgid='${this.$login.f.orgid}'`
261
+ }
262
+ let http = new HttpResetClass()
263
+ await http.load('POST', 'rs/sql/apply_singleTable', {data: data}, {resolveMsg: null, rejectMsg: '合同信息查询失败!!!'}).then(res => {
264
+ if (res.data.length> 0) {
265
+ this.model.rows = res.data
266
+ }
267
+ })
268
+ },
269
+ handleInput(e) {
270
+ // 通过正则过滤小数点后两位
271
+ e.target.value = (e.target.value.match(/^\d*(\.?\d{0,2})/g)[0]) || null
272
+ this.contractInfo.f_amount_capital = this.smalltoBIG(e.target.value)
273
+ },
274
+ // 金额转大写
275
+ smalltoBIG(n) {
276
+ let fraction = ['角', '分'];
277
+ let digit = ['零', '壹', '贰', '叁', '肆', '伍', '陆', '柒', '捌', '玖'];
278
+ let unit = [['元', '万', '亿'], ['', '拾', '佰', '仟']];
279
+ let head = n < 0 ? '欠' : '';
280
+ n = Math.abs(n);
281
+ let s = '';
282
+ for (var i = 0; i < fraction.length; i++) {
283
+ s += (digit[Math.floor(n * 10 * Math.pow(10, i)) % 10] + fraction[i]).replace(/零./, '');
284
+ }
285
+ s = s || '';
286
+ n = Math.floor(n);
287
+ for (var i = 0; i < unit[0].length && n > 0; i++) {
288
+ let p = '';
289
+ for (var j = 0; j < unit[1].length && n > 0; j++) {
290
+ p = digit[n % 10] + unit[1][j] + p;
291
+ n = Math.floor(n / 10);
292
+ }
293
+ s = p.replace(/(零.)*零$/, '').replace(/^$/, '零') + unit[0][i] + s;
294
+ }
295
+ return head + s.replace(/(零.)*零元/, '元').replace(/(零.)+/g, '零').replace(/^整$/, '零元整')
296
+ },
297
+ async save() {
298
+ if(isEmpty(this.contractInfo.f_contract_name)){
299
+ this.$showMessage(`请选择需要签订的合同`)
300
+ return
301
+ }else{
302
+ this.$showMessage(`是否确认生成此合同`, ['confirm']).then(async (res) => {
303
+ if (res === 'confirm') {
304
+ let http = new HttpResetClass()
305
+ let data = {
306
+ contractInfo:this.contractInfo,
307
+ userRecord:this.userRecord,
308
+ loginInfo:this.loginInfo
309
+ }
310
+ await http.load('POST', 'api/af-revenue/logic/generateContract', {data: data}, {
311
+ resolveMsg: null,
312
+ rejectMsg: '合同信息查询失败!!!'
313
+ }).then(async res => {
314
+ //保存合同信息
315
+ if (res.data.code == 200) {
316
+ //保存到t_files表
317
+ let param={
318
+ f_blobid:this.selectdata.f_process_id,
319
+ fusetype:"报装合同",
320
+ f_filename:res.data.f_contract_name,
321
+ f_uploaddate:res.data.f_create_date,
322
+ f_downloadpath:res.data.f_signature_url,
323
+ f_realpath:res.data.f_signature_path
324
+ }
325
+ await this.$resetpost('rs/entity/t_files', param).then(res => {
326
+ this.$showMessage(`合同生成成功!!!`),
327
+ this.selectList=false
328
+ this.showselect = false
329
+ })
330
+ } else {
331
+ this.selectList=false
332
+ this.showselect = false
333
+ this.$showMessage(`合同生成失败!!!,原因为${res.data.msg}`)
334
+ }
335
+ })
336
+ }
337
+ })
338
+ }
339
+ },
340
+ clear () {
341
+ },
342
+ openSelect () {
343
+ this.selectList=true
344
+ this.showselect = true
345
+ },
346
+ NoSelect () {
347
+ //清除数据
348
+ this.userRecord={
349
+ f_userinfo_id: this.selectdata.f_userinfo_id?this.selectdata.f_userinfo_id:this.selectdata.f_process_id,
350
+ f_filialeid:this.$login.f.orgid,
351
+ f_userinfo_code: this.selectdata.f_userinfo_code?this.selectdata.f_userinfo_code:this.selectdata.f_process_id,
352
+ f_user_name:this.selectdata.f_user_name?this.selectdata.f_user_name:"",
353
+ f_credentials: this.selectdata.f_credentials?this.selectdata.f_credentials:"",
354
+ f_idnumber: this.selectdata.f_idnumber?this.selectdata.f_idnumber:"",
355
+ f_address: this.selectdata.f_address?this.selectdata.f_address:"",
356
+ f_user_phone:this.selectdata.f_phone?this.selectdata.f_phone:"",
357
+ //甲方
358
+ f_lessor:"",
359
+ //项目地点及名称
360
+ f_project_address: "",
361
+ //户数
362
+ f_households: "",
363
+ //费用
364
+ f_cost: "",
365
+ //金额大写
366
+ f_amount_capital: "",
367
+ //付款方式
368
+ f_payment_method: "",
369
+ //工期
370
+ f_duration: "",
371
+ //指定人员
372
+ f_personnel: "",
373
+ //联系电话
374
+ f_contact_phone: ""
375
+ },
376
+ this.selectList=false
377
+ this.showselect = false
378
+ }
379
+ },
380
+ events: {
381
+ },
382
+ computed: {
383
+ paymentMethod() {
384
+ return this.$appdata.getParam("付款方式")
385
+ }
386
+ },
387
+ watch: {
388
+ }
389
+ }
390
+ </script>
391
+ <style scoped>
392
+ .control-label-justify {
393
+ display: inline-block;
394
+ vertical-align: top;
395
+ width: 110px;
396
+ text-align: justify;
397
+ font-family: PingFang-SC-Bold;
398
+ }
399
+
400
+ .control-label-justify::after {
401
+ content: "";
402
+ display: inline-block;
403
+ width: 100%;
404
+ overflow: hidden;
405
+ height: 0;
406
+ }
407
+ .input_view{
408
+ padding: 8px;
409
+ background-color: #ffffff;
410
+ border-radius: 2px;
411
+ border: solid 1px #c7c7c7!important;
412
+ color: #333333!important;
413
+ font-size: 15px!important;
414
+ }
415
+
416
+ .input_view[readonly]{
417
+ border: 1px solid #DDD!important;
418
+ color:#ACA899!important;
419
+ }
420
+ .input_view:disabled{
421
+ border: 1px solid #DDD!important;
422
+ color:#ACA899!important;
423
+ }
424
+ </style>