apply-clients 7.1.36-yuchuan-71 → 7.1.36-yuchuan-73

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "apply-clients",
3
- "version": "7.1.36-yuchuan-71",
3
+ "version": "7.1.36-yuchuan-73",
4
4
  "description": "报建前端模块",
5
5
  "main": "src/index.js",
6
6
  "directories": {
@@ -486,8 +486,11 @@ export default {
486
486
  // let code = '012199312345'
487
487
  console.log('===========扫码结果=============')
488
488
  console.log(code)
489
+ if (isEmpty(code)){
490
+ return
491
+ }
489
492
  if (!/^\d{12}$/.test(code)) {
490
- this.$showMessage('表号不符合规则')
493
+ this.$showAlert('表号不符合规则', 'danger', 3000)
491
494
  return
492
495
  }
493
496
  // 解析厂家
@@ -499,7 +502,7 @@ export default {
499
502
  }
500
503
  }
501
504
  if (isEmpty(factory)) {
502
- this.$showMessage('未知厂家!!!')
505
+ this.$showAlert('未知厂家!!!', 'danger', 3000)
503
506
  return
504
507
  }
505
508
  console.log(factory)
@@ -512,7 +515,7 @@ export default {
512
515
  }
513
516
  }
514
517
  if (isEmpty(ips)) {
515
- this.$showMessage('未知运营商!!!')
518
+ this.$showAlert('未知运营商!!!', 'danger', 3000)
516
519
  return
517
520
  }
518
521
  console.log(ips)
@@ -534,7 +537,7 @@ export default {
534
537
  this.userfile.f_gasmodel_id = value
535
538
  } else if (code.substring(4, 5) == 8 ||code.substring(4, 5) == 1) {
536
539
 
537
- await this.gasbrandValue('JGD2.5-NNB物联网表')
540
+ await this.gasbrandValue('JGD2.5-NNB物联网表')
538
541
  const value1=this.modelCode
539
542
  this.userfile.f_gasmodel_id =value1
540
543
  } else if (code.substring(4, 5) == 9 ||code.substring(4, 5) == 2) {
@@ -549,7 +552,7 @@ export default {
549
552
  // 顺序号
550
553
  console.log(code.substring(7, 12))
551
554
  if (code.substring(7, 12) < this.scanCodeConfig.number.min || code.substring(7, 12) > this.scanCodeConfig.number.max) {
552
- this.$showMessage('顺序号超出范围!!!')
555
+ this.$showAlert('顺序号超出范围!!!', 'danger', 3000)
553
556
  return
554
557
  }
555
558
  for (const item of this.meterBrandList) {
@@ -620,15 +623,15 @@ export default {
620
623
  async saveUserFile() {
621
624
  if (this.selectdata.defname === '工程施工') {
622
625
  this.meternumberValidate()
623
- if( this.selectdata.f_apply_type === '民用报建'){
624
- if (this.userfile.f_meter_base - 0 === 0 || this.userfile.f_meter_base - 0 > 1.5) {
625
- this.$showMessage('表读数必须大于0小于或等于1.5!')
626
- throw '表读数必须大于0小于或等于1.5!'
626
+ if( this.selectdata.f_apply_type === '民用报建'){
627
+ if (this.userfile.f_meter_base - 0 === 0 || this.userfile.f_meter_base - 0 > 1.5) {
628
+ this.$showAlert('表读数必须大于0小于或等于1.5!', 'warning', 3000)
629
+ throw '表读数必须大于0小于或等于1.5!'
630
+ }
627
631
  }
628
- }
629
632
  if( this.selectdata.f_apply_type === '非民用报建'){
630
633
  if (this.userfile.f_meter_base - 0 === 0 || this.userfile.f_meter_base - 0 >30) {
631
- this.$showMessage('表读数必须大于0小于或等于30!')
634
+ this.$showAlert('表读数必须大于0小于或等于30!', 'warning', 3000)
632
635
  throw '表读数必须大于0小于或等于30!'
633
636
  }
634
637
  }
@@ -650,14 +653,14 @@ export default {
650
653
  console.log(res.data)
651
654
  if (!/^\d{12}$/.test(this.userfile.f_meternumber)) {
652
655
  if(!/^\d{14}$/.test(this.userfile.f_meternumber)){
653
- this.$showMessage('表号不符合规则')
656
+ this.$showAlert('表号不符合规则', 'danger', 3000)
654
657
  return
655
658
  }
656
659
  }
657
660
  if (res.data === '表号已存在' || res.data === '表号无效') {
658
661
  this.userfile.f_meternumber = ''
659
- this.$showMessage(res.data)
660
- return
662
+ this.$showAlert(res.data, 'danger', 3000)
663
+ throw res.data
661
664
  }
662
665
  }
663
666
  let data = {
@@ -671,7 +674,7 @@ export default {
671
674
  rejectMsg: '用户档案添加失败!!!'
672
675
  })
673
676
  // this.$showMessage('用户档案添加成功!!!')
674
- this.$showMessage('用户档案添加成功!!!')
677
+ this.$showAlert('用户档案添加成功!!!', 'success', 3000)
675
678
  // this.search() 避免分页时,点击确定后,分页返回第一页
676
679
  this.showModal= false
677
680
  console.log("分页数据",this.model)
@@ -690,7 +693,7 @@ export default {
690
693
  async meternumberValidate() {
691
694
  if (!this.userfile.f_gasbrand_id) {
692
695
  this.userfile.f_meternumber = ''
693
- this.$showMessage('请先选择气表品牌!!!')
696
+ this.$showAlert('请先选择气表品牌!!!', 'warning', 3000)
694
697
  return
695
698
  }
696
699
  if (this.userfile.f_gasbrand_id && this.userfile.f_meternumber) {
@@ -710,13 +713,13 @@ export default {
710
713
  console.log(res.data)
711
714
  if (!/^\d{12}$/.test(this.userfile.f_meternumber)) {
712
715
  if(!/^\d{14}$/.test(this.userfile.f_meternumber)){
713
- this.$showMessage('表号不符合规则')
716
+ this.$showAlert('表号不符合规则', 'danger', 3000)
714
717
  return
715
718
  }
716
719
  }
717
720
  if (res.data === '表号已存在' || res.data === '表号无效') {
718
721
  this.userfile.f_meternumber = ''
719
- this.$showMessage(res.data)
722
+ this.$showAlert(res.data, 'warning', 3000)
720
723
  }
721
724
  }
722
725
  },
@@ -1003,27 +1006,27 @@ export default {
1003
1006
  }
1004
1007
  </script>
1005
1008
  <style scoped>
1006
- .panel {
1007
- margin-bottom: 8px;
1008
- }
1009
- .panel-self{
1010
- border-radius: 10px;
1011
- border:1px solid #499EDF;
1012
- padding: 8px;
1013
- }
1014
- .button_shrink_top {
1015
- width: 34px;
1016
- height: 34px;
1017
- border: solid 1px #6aa6e2;
1018
- background-size: 100%;
1019
- background-image: url("../../../../../static/newStyle/stretch_top.png")
1020
- }
1009
+ .panel {
1010
+ margin-bottom: 8px;
1011
+ }
1012
+ .panel-self{
1013
+ border-radius: 10px;
1014
+ border:1px solid #499EDF;
1015
+ padding: 8px;
1016
+ }
1017
+ .button_shrink_top {
1018
+ width: 34px;
1019
+ height: 34px;
1020
+ border: solid 1px #6aa6e2;
1021
+ background-size: 100%;
1022
+ background-image: url("../../../../../static/newStyle/stretch_top.png")
1023
+ }
1021
1024
 
1022
- .button_shrink_bottom {
1023
- width: 34px;
1024
- height: 34px;
1025
- border: solid 1px #6aa6e2;
1026
- background-size: 100%;
1027
- background-image: url("../../../../../static/newStyle/stretch_bottom.png")
1028
- }
1025
+ .button_shrink_bottom {
1026
+ width: 34px;
1027
+ height: 34px;
1028
+ border: solid 1px #6aa6e2;
1029
+ background-size: 100%;
1030
+ background-image: url("../../../../../static/newStyle/stretch_bottom.png")
1031
+ }
1029
1032
  </style>
@@ -1,281 +1,314 @@
1
- <template>
2
- <style id="printGaiXianOrderStyle">
3
- td{
4
- height: 30px;
5
- text-align: center;
6
- }
7
- table{
8
- width: 100%;
9
- margin: 0;
10
- padding: 0;
11
- border: 1px solid black;
12
- border-collapse:collapse;
13
- }
14
- h1,h2,h3,h4,h5,h6 {
15
- text-align: center;
16
- }
17
- .merge-content {
18
- text-align: left;
19
- vertical-align: top;
20
- padding: 10px;
21
- }
22
- .sign {
23
- height: 80px;
24
- }
25
- .sign_img {
26
- width: 60px;
27
- transform: rotate(0deg);
28
- }
29
- .replace_img{
30
- width: 60px;
31
- transform: rotate(0deg);
32
- }
33
- </style>
34
- <div style="margin-bottom: 20px" class="form-group select-overspread">
35
- <label class="control-label-justify control-label col-sm-10">打印派工单</label>
36
- <div class="col-sm-2">
37
- <button class="button_search button_spacing" type="button" style="width: max-content;position: absolute"
38
- @click="openModal()">打印预览
39
- </button>
40
- </div>
41
- </div>
42
- <modal v-if="showModal" :show.sync="showModal" title="打印预览" v-ref:modal large backdrop="false">
43
- <header slot="modal-header" class="modal-header">
44
- <button type="button" class="close" @click="colseModal()"><span>&times;</span></button>
45
- <h4 class="modal-title">打印预览</h4>
46
- </header>
47
- <article slot="modal-body" class="modal-body">
48
- <div id="printGaiXianOrder">
49
- <h2><span style="letter-spacing: 0px">天然气用户改线申请表</span></h2>
50
- <table>编号:{{ selectdata.f_apply_num }}</table>
51
- <table border="1" cellspacing="0" cellpadding="0">
52
- <tr>
53
- <td colspan="2">填写人</td>
54
- <td colspan="2">{{ selectdata.pgname }}</td>
55
- <td colspan="2">所属部门</td>
56
- <td colspan="2">{{ selectdata.user_dep }}</td>
57
- <td colspan="2">填写时间</td>
58
- <td colspan="2">{{ selectdata.finishtime }}</td>
59
- </tr>
60
- <tr>
61
- <td colspan="2">用户联系人</td>
62
- <td colspan="2">{{ selectdata.f_contact }}</td>
63
- <td colspan="2">单位</td>
64
- <td colspan="2">{{ selectdata.f_user_name }}</td>
65
- <td colspan="2">联系电话</td>
66
- <td colspan="2">{{ selectdata.f_phone }}</td>
67
- </tr>
68
- <tr>
69
- <td colspan="2">申请时间</td>
70
- <td colspan="2">{{ selectdata.f_apply_date }}</td>
71
- <td colspan="2">用户编号</td>
72
- <td colspan="2">{{ selectdata.f_userinfo_id }}</td>
73
- <td colspan="2">用气性质</td>
74
- <td colspan="2">{{ selectdata.f_apply_nature }}</td>
75
- </tr>
76
- <tr>
77
- <td colspan="2">详细地址</td>
78
- <td colspan="6">{{ selectdata.f_address }}</td>
79
- <td colspan="2">气表型号</td>
80
- <td colspan="2">{{ selectdata.f_meter_style }}</td>
81
- </tr>
82
- <tr>
83
- <td colspan="12"><h4>工程技术部现场勘察意见及材料预算</h4></td>
84
- </tr>
85
- <tr>
86
- <td colspan="3">申请类别</td>
87
- <td colspan="3">{{ selectdata.f_user_classification }}</td>
88
- <td colspan="3">改造原因</td>
89
- <td colspan="3">{{ selectdata.f_prospecting_result }}</td>
90
- </tr>
91
- <tr>
92
- <td colspan="2">工程整改方案</td>
93
- <td colspan="10">
94
- <p style="margin: 0px 0px 30px 0px">{{ selectdata.f_modify_plan }}</p>
95
- </td>
96
- </tr>
97
- <!-- <tr>-->
98
- <!-- <td colspan="6" class="merge-content">-->
99
- <!-- <p style="margin: 0px 0px 10px 0px">工程部审核意见:</p>-->
100
- <!-- <p style="margin: 0px 0px 30px 0px"></p>-->
101
- <!-- </td>-->
102
- <!-- </tr>-->
103
- <tr>
104
- <td colspan="2">整改收费</td>
105
- <td colspan="10">
106
- <p>金额小写:{{ selectdata.f_due_money}},金额大写:{{ selectdata.f_amount_words}}</p>
107
- </td>
108
- </tr>
109
- <tr>
110
- <td colspan="12"><h4>审批流程</h4></td>
111
- </tr>
112
- <tr>
113
- <td colspan="3">工程技术部负责人意见</td>
114
- <td colspan="3">
115
- <p>&emsp;</p>
116
- <p>&emsp;</p>
117
- <p>&emsp;</p>
118
- </td>
119
- <td colspan="3">分管领导意见</td>
120
- <td colspan="3">
121
- <p>&emsp;</p>
122
- <p>&emsp;</p>
123
- <p>&emsp;</p>
124
- </td>
125
- </tr>
126
- <tr>
127
- <td colspan="3">用户管理部收费情况</td>
128
- <td colspan="3">
129
- <p>已收费</p>
130
- <p>{{ selectdata.f_charge_user }}</p>
131
- <p>{{ selectdata.f_charge_date }}</p>
132
- </td>
133
- <td colspan="3">开材料意见</td>
134
- <td colspan="3">
135
- <p>{{ selectdata.f_material_number }}</p>
136
- <p>{{ selectdata.pgname }}</p>
137
- <p>{{ selectdata.finishtime }}</p>
138
- </td>
139
- </tr>
140
- <tr>
141
- <td colspan="3">维修中心意见</td>
142
- <td colspan="3">
143
- <p>&emsp;</p>
144
- <p>&emsp;</p>
145
- <p>&emsp;</p>
146
- </td>
147
- <td colspan="3">省安一/二/三意见</td>
148
- <td colspan="3">
149
- <p>&emsp;</p>
150
- <p>&emsp;</p>
151
- <p>&emsp;</p>
152
- </td>
153
- </tr>
154
- <tr>
155
- <td colspan="3">用户确认签字</td>
156
- <td colspan="9">
157
- <p>&emsp;</p>
158
- <p>&emsp;</p>
159
- <p>&emsp;</p>
160
- </td>
161
- </tr>
162
- </table>
163
- </div>
164
- </article>
165
- <footer slot="modal-footer" class="modal-footer">
166
- <button type="button" class="btn btn-primary" @click="print()">打印</button>
167
- </footer>
168
- </modal>
169
-
170
- <print-element v-show="false" v-ref:print id='printGaiXianOrder' styleid='printGaiXianOrderStyle'
171
- top='20' left='30' width='100%' height='100%'>
172
- </print-element>
173
- </template>
174
-
175
- <script>
176
- import {isEmpty} from '../../../Util'
177
- import {HttpResetClass} from "vue-client";
178
-
179
- Date.prototype.Format = function (fmt) {
180
- var o = {
181
- 'M+': this.getMonth() + 1, // 月份
182
- 'd+': this.getDate(), // 日
183
- 'H+': this.getHours(), // 小时
184
- 'm+': this.getMinutes(), //
185
- 's+': this.getSeconds(), //
186
- 'q+': Math.floor((this.getMonth() + 3) / 3), // 季度
187
- 'S': this.getMilliseconds() // 毫秒
188
- }
189
- if (/(y+)/.test(fmt)) fmt = fmt.replace(RegExp.$1, (this.getFullYear() + '').substr(4 - RegExp.$1.length))
190
- for (var k in o)
191
- if (new RegExp('(' + k + ')').test(fmt)) fmt = fmt.replace(RegExp.$1, (RegExp.$1.length === 1) ? (o[k]) : (('00' + o[k]).substr(('' + o[k]).length)))
192
- return fmt
193
- }
194
- export default {
195
- title: '打印派工单',
196
- props: ['selectdata'],
197
- data () {
198
- return {
199
- showModal: false,
200
- device: null
201
- }
202
- },
203
- ready () {
204
- this.getGaiXianData(this.selectdata.f_process_id)
205
- },
206
- methods: {
207
- openModal () {
208
- if (this.selectdata.f_due_money >= 0 ) {
209
- this.smalltoBIG(this.selectdata.f_due_money)
210
- }
211
- this.showModal = true
212
- },
213
- colseModal () {
214
- this.showModal = false
215
- },
216
- print () {
217
- this.showInput = false
218
- setTimeout(() => {
219
- this.$refs.print.PrintTable()
220
- }, 10)
221
- },
222
- // 金额转大写
223
- smalltoBIG (n) {
224
- let fraction = ['', '分']
225
- let digit = ['', '壹', '贰', '叁', '肆', '伍', '陆', '柒', '捌', '玖']
226
- let unit = [['元', '万', '亿'], ['', '拾', '佰', '仟']]
227
- let head = n < 0 ? '' : ''
228
- n = Math.abs(n)
229
-
230
- let s = ''
231
-
232
- for (var i = 0; i < fraction.length; i++) {
233
- s += (digit[Math.floor(n * 10 * Math.pow(10, i)) % 10] + fraction[i]).replace(/零./, '')
234
- }
235
- s = s || '整'
236
- n = Math.floor(n)
237
-
238
- for (var i = 0; i < unit[0].length && n > 0; i++) {
239
- let p = ''
240
- for (var j = 0; j < unit[1].length && n > 0; j++) {
241
- p = digit[n % 10] + unit[1][j] + p
242
- n = Math.floor(n / 10)
243
- }
244
- s = p.replace(/(零.)*零$/, '').replace(/^$/, '零') + unit[0][i] + s
245
- }
246
- let result = head + s.replace(/(零.)*零元/, '元').replace(/(零.)+/g, '零').replace(/^整$/, '零元整')
247
- console.log('当前大写', result)
248
- this.selectdata.f_amount_words = result
249
- },
250
- async getGaiXianData(index) {
251
- let data = {
252
- condition: `1=1`,
253
- f_process_id: index
254
- }
255
- let http = new HttpResetClass()
256
- let res = await http.load(
257
- 'POST',
258
- `rs/sql/applyGetGaixian`,
259
- {data: data},
260
- {resolveMsg: null, rejectMsg: '改线数据查询失败!!!'}
261
- )
262
- this.selectdata.f_charge_user = res.data[0].jfname
263
- this.selectdata.f_charge_date = res.data[0].finishtime
264
- this.selectdata.pgname = res.data[0].pgname
265
- this.selectdata.user_dep = res.data[0].departmentname
266
- }
267
- },
268
- computed: {
269
- orgs () {
270
- return this.$login.f.f_fengongsi
271
- },
272
- src () {
273
- // return require(`./img/${this.$login.f.number}.png`)
274
- }
275
- }
276
- }
277
- </script>
278
-
279
- <style scoped>
280
-
281
- </style>
1
+ <template>
2
+ <style id="printGaiXianOrderStyle">
3
+ td{
4
+ height: 30px;
5
+ text-align: center;
6
+ }
7
+ table{
8
+ width: 100%;
9
+ margin: 0;
10
+ padding: 0;
11
+ border: 1px solid black;
12
+ border-collapse:collapse;
13
+ }
14
+ h1,h2,h3,h4,h5,h6 {
15
+ text-align: center;
16
+ }
17
+ .merge-content {
18
+ text-align: left;
19
+ vertical-align: top;
20
+ padding: 10px;
21
+ }
22
+ .sign {
23
+ height: 80px;
24
+ }
25
+ .sign_img {
26
+ width: 60px;
27
+ transform: rotate(0deg);
28
+ }
29
+ .replace_img{
30
+ width: 60px;
31
+ transform: rotate(0deg);
32
+ }
33
+ </style>
34
+ <div style="margin-bottom: 20px" class="form-group select-overspread">
35
+ <label class="control-label-justify control-label col-sm-10">打印派工单</label>
36
+ <div class="col-sm-2">
37
+ <button class="button_search button_spacing" type="button" style="width: max-content;position: absolute"
38
+ @click="openModal()">打印预览
39
+ </button>
40
+ </div>
41
+ </div>
42
+ <modal v-if="showModal" :show.sync="showModal" title="打印预览" v-ref:modal large backdrop="false">
43
+ <header slot="modal-header" class="modal-header">
44
+ <button type="button" class="close" @click="colseModal()"><span>&times;</span></button>
45
+ <h4 class="modal-title">打印预览</h4>
46
+ </header>
47
+ <article slot="modal-body" class="modal-body">
48
+ <div id="printGaiXianOrder">
49
+ <h2><span style="letter-spacing: 0px">天然气用户改线申请表</span></h2>
50
+ <table>编号:{{ selectdata.f_apply_num }}</table>
51
+ <table border="1" cellspacing="0" cellpadding="0">
52
+ <tr>
53
+ <td colspan="2">填写人</td>
54
+ <td colspan="2">{{ selectdata.pgname }}</td>
55
+ <td colspan="2">所属部门</td>
56
+ <td colspan="2">{{ selectdata.user_dep }}</td>
57
+ <td colspan="2">填写时间</td>
58
+ <td colspan="2">{{ selectdata.finishtime }}</td>
59
+ </tr>
60
+ <tr>
61
+ <td colspan="2">用户联系人</td>
62
+ <td colspan="2">{{ selectdata.f_contact }}</td>
63
+ <td colspan="2">单位</td>
64
+ <td colspan="2">{{ selectdata.f_user_name }}</td>
65
+ <td colspan="2">联系电话</td>
66
+ <td colspan="2">{{ selectdata.f_phone }}</td>
67
+ </tr>
68
+ <tr>
69
+ <td colspan="2">申请时间</td>
70
+ <td colspan="2">{{ selectdata.f_apply_date }}</td>
71
+ <td colspan="2">用户编号</td>
72
+ <td colspan="2">{{ selectdata.f_userinfo_id }}</td>
73
+ <td colspan="2">用气性质</td>
74
+ <td colspan="2">{{ selectdata.f_apply_nature }}</td>
75
+ </tr>
76
+ <tr>
77
+ <td colspan="2">详细地址</td>
78
+ <td colspan="6">{{ selectdata.f_address }}</td>
79
+ <td colspan="2">气表型号</td>
80
+ <td colspan="2">{{ selectdata.f_meter_style }}</td>
81
+ </tr>
82
+ <tr>
83
+ <td colspan="12"><h4>工程技术部现场勘察意见及材料预算</h4></td>
84
+ </tr>
85
+ <tr>
86
+ <td colspan="3">申请类别</td>
87
+ <td colspan="3">{{ selectdata.f_user_classification }}</td>
88
+ <td colspan="3">改造原因</td>
89
+ <td colspan="3">{{ selectdata.f_prospecting_result }}</td>
90
+ </tr>
91
+ <tr>
92
+ <td colspan="2">工程整改方案</td>
93
+ <td colspan="10">
94
+ <p style="margin: 0px 0px 30px 0px">{{ selectdata.f_modify_plan }}</p>
95
+ </td>
96
+ </tr>
97
+ <tr>
98
+ <td colspan="2">整改收费</td>
99
+ <td colspan="10">
100
+ <p>金额小写:{{ selectdata.f_due_money}},金额大写:{{ selectdata.f_amount_words}}</p>
101
+ </td>
102
+ </tr>
103
+ <tr>
104
+ <td colspan="3">监理单位</td>
105
+ <td colspan="3">{{ supervisorOperatorName }}</td>
106
+ <td colspan="3">土建建单位</td>
107
+ <td colspan="3">{{ engineeringOperatorName }}</td>
108
+ </tr>
109
+ <tr>
110
+ <td colspan="2">检测单位</td>
111
+ <td colspan="2">{{ checkOperatorName }}</td>
112
+ <td colspan="2">项目负责人</td>
113
+ <td colspan="2">{{ constructOperatorName }}</td>
114
+ <td colspan="2">安装单位</td>
115
+ <td colspan="2">{{ constructionUnitName }}</td>
116
+ </tr>
117
+ <tr>
118
+ <td colspan="12"><h4>审批流程</h4></td>
119
+ </tr>
120
+ <tr>
121
+ <td colspan="3">工程技术部负责人意见</td>
122
+ <td colspan="3">
123
+ <p>&emsp;</p>
124
+ <p>&emsp;</p>
125
+ <p>&emsp;</p>
126
+ </td>
127
+ <td colspan="3">分管领导意见</td>
128
+ <td colspan="3">
129
+ <p>&emsp;</p>
130
+ <p>&emsp;</p>
131
+ <p>&emsp;</p>
132
+ </td>
133
+ </tr>
134
+ <tr>
135
+ <td colspan="3">用户管理部收费情况</td>
136
+ <td colspan="3">
137
+ <p>已收费</p>
138
+ <p>{{ selectdata.f_charge_user }}</p>
139
+ <p>{{ selectdata.f_charge_date }}</p>
140
+ </td>
141
+ <td colspan="3">开材料意见</td>
142
+ <td colspan="3">
143
+ <p>{{ selectdata.f_material_number }}</p>
144
+ <p>{{ selectdata.pgname }}</p>
145
+ <p>{{ selectdata.finishtime }}</p>
146
+ </td>
147
+ </tr>
148
+ <tr>
149
+ <td colspan="3">工程技术部改线组意见</td>
150
+ <td colspan="3">
151
+ <p>&emsp;</p>
152
+ <p>&emsp;</p>
153
+ <p>&emsp;</p>
154
+ </td>
155
+ <td colspan="3">省安一/二/三意见</td>
156
+ <td colspan="3">
157
+ <p>&emsp;</p>
158
+ <p>&emsp;</p>
159
+ <p>&emsp;</p>
160
+ </td>
161
+ </tr>
162
+ <tr>
163
+ <td colspan="3">用户确认签字</td>
164
+ <td colspan="9">
165
+ <p>&emsp;</p>
166
+ <p>&emsp;</p>
167
+ <p>&emsp;</p>
168
+ </td>
169
+ </tr>
170
+ </table>
171
+ </div>
172
+ </article>
173
+ <footer slot="modal-footer" class="modal-footer">
174
+ <button type="button" class="btn btn-primary" @click="print()">打印</button>
175
+ </footer>
176
+ </modal>
177
+
178
+ <print-element v-show="false" v-ref:print id='printGaiXianOrder' styleid='printGaiXianOrderStyle'
179
+ top='20' left='30' width='100%' height='100%'>
180
+ </print-element>
181
+ </template>
182
+
183
+ <script>
184
+ import {isEmpty} from '../../../Util'
185
+ import {HttpResetClass} from "vue-client";
186
+
187
+ Date.prototype.Format = function (fmt) {
188
+ var o = {
189
+ 'M+': this.getMonth() + 1, // 月份
190
+ 'd+': this.getDate(), //
191
+ 'H+': this.getHours(), // 小时
192
+ 'm+': this.getMinutes(), // 分
193
+ 's+': this.getSeconds(), // 秒
194
+ 'q+': Math.floor((this.getMonth() + 3) / 3), // 季度
195
+ 'S': this.getMilliseconds() // 毫秒
196
+ }
197
+ if (/(y+)/.test(fmt)) fmt = fmt.replace(RegExp.$1, (this.getFullYear() + '').substr(4 - RegExp.$1.length))
198
+ for (var k in o)
199
+ if (new RegExp('(' + k + ')').test(fmt)) fmt = fmt.replace(RegExp.$1, (RegExp.$1.length === 1) ? (o[k]) : (('00' + o[k]).substr(('' + o[k]).length)))
200
+ return fmt
201
+ }
202
+ export default {
203
+ title: '打印派工单',
204
+ props: ['selectdata'],
205
+ data () {
206
+ return {
207
+ supervisorOperatorName: '无',
208
+ engineeringOperatorName: '无',
209
+ checkOperatorName: '无',
210
+ constructOperatorName: '无',
211
+ constructionUnitName: '无',
212
+ showModal: false,
213
+ device: null
214
+ }
215
+ },
216
+ ready () {
217
+ this.getGaiXianData(this.selectdata.f_process_id)
218
+ },
219
+ methods: {
220
+ async getUserName( param) {
221
+ let http = new HttpResetClass()
222
+ if(!isEmpty(param)){
223
+ let data = {
224
+ tablename: 't_user',
225
+ condition: `id='${param}'`
226
+ }
227
+ let res = await http.load('POST', 'rs/sql/applySingleTable', {data: data},
228
+ {resolveMsg: null, rejectMsg: '流程标识获取失败!!!'}
229
+ )
230
+ return res.data[0].name
231
+ }else {
232
+ return '无'
233
+ }
234
+ },
235
+ openModal () {
236
+ if (this.selectdata.f_due_money >= 0 ) {
237
+ this.smalltoBIG(this.selectdata.f_due_money)
238
+ }
239
+ this.showModal = true
240
+ },
241
+ colseModal () {
242
+ this.showModal = false
243
+ },
244
+ print () {
245
+ this.showInput = false
246
+ setTimeout(() => {
247
+ this.$refs.print.PrintTable()
248
+ }, 10)
249
+ },
250
+ // 金额转大写
251
+ smalltoBIG (n) {
252
+ let fraction = ['角', '分']
253
+ let digit = ['零', '壹', '贰', '叁', '肆', '伍', '陆', '柒', '捌', '玖']
254
+ let unit = [['元', '万', '亿'], ['', '拾', '佰', '仟']]
255
+ let head = n < 0 ? '欠' : ''
256
+ n = Math.abs(n)
257
+
258
+ let s = ''
259
+
260
+ for (var i = 0; i < fraction.length; i++) {
261
+ s += (digit[Math.floor(n * 10 * Math.pow(10, i)) % 10] + fraction[i]).replace(/零./, '')
262
+ }
263
+ s = s || '整'
264
+ n = Math.floor(n)
265
+
266
+ for (var i = 0; i < unit[0].length && n > 0; i++) {
267
+ let p = ''
268
+ for (var j = 0; j < unit[1].length && n > 0; j++) {
269
+ p = digit[n % 10] + unit[1][j] + p
270
+ n = Math.floor(n / 10)
271
+ }
272
+ s = p.replace(/(零.)*零$/, '').replace(/^$/, '零') + unit[0][i] + s
273
+ }
274
+ let result = head + s.replace(/(零.)*零元/, '元').replace(/(零.)+/g, '零').replace(/^整$/, '零元整')
275
+ console.log('当前大写', result)
276
+ this.selectdata.f_amount_words = result
277
+ },
278
+ async getGaiXianData(index) {
279
+ let data = {
280
+ condition: `1=1`,
281
+ f_process_id: index
282
+ }
283
+ let http = new HttpResetClass()
284
+ let res = await http.load(
285
+ 'POST',
286
+ `rs/sql/applyGetGaixian`,
287
+ {data: data},
288
+ {resolveMsg: null, rejectMsg: '改线数据查询失败!!!'}
289
+ )
290
+ this.selectdata.f_charge_user = res.data[0].jfname
291
+ this.selectdata.f_charge_date = res.data[0].finishtime
292
+ this.selectdata.pgname = res.data[0].pgname
293
+ this.selectdata.user_dep = res.data[0].departmentname
294
+ this.supervisorOperatorName = await this.getUserName(this.selectdata.f_supervisor_operator);
295
+ this.engineeringOperatorName = await this.getUserName(this.selectdata.f_engineering_operator_id);
296
+ this.checkOperatorName = await this.getUserName(this.selectdata.f_check_operator_id);
297
+ this.constructOperatorName = await this.getUserName(this.selectdata.f_construct_operator_id);
298
+ this.constructionUnitName = await this.getUserName(this.selectdata.f_construction_unit);
299
+ }
300
+ },
301
+ computed: {
302
+ orgs () {
303
+ return this.$login.f.f_fengongsi
304
+ },
305
+ src () {
306
+ // return require(`./img/${this.$login.f.number}.png`)
307
+ }
308
+ }
309
+ }
310
+ </script>
311
+
312
+ <style scoped>
313
+
314
+ </style>