sale-client 3.6.19 → 3.6.21

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.
@@ -0,0 +1,336 @@
1
+ <template>
2
+ <div>
3
+ <validator name='v' @valid="$emit('valid')" @invalid="$emit('invalid')">
4
+ <form class="form-horizontal select-overspread ">
5
+ <div class="row">
6
+ <div class="col-sm-4 form-group " :class="[$v.f_user_name.required ? 'has-error' : '']">
7
+ <label for="f_user_name" class="font_normal_body">*客户姓名</label>
8
+ <input type="text" v-model="baseinfo.base.f_user_name" v-validate:f_user_name='{required: true }'
9
+ class="input_search" style="width:60%" placeholder="客户名称" v-next-el="phone">
10
+ </div>
11
+ <div style="" class="col-sm-4 form-group"
12
+ :class="[$v.f_user_phone.minlength || $v.f_user_phone.maxlength ? 'has-error' : '']">
13
+ <label for="f_user_phone" class="font_normal_body">*客户电话</label>
14
+ <input type="text" maxlength="11" v-model="baseinfo.base.f_user_phone"
15
+ v-validate:f_user_phone="{minlength: 11, maxlength: 11 }" class="input_search" style="width:60%"
16
+ placeholder="客户电话" v-el:phone v-next-el="area">
17
+ <button type="button" class="glyphicon glyphicon-plus" @click.stop="phoneManage()"></button>
18
+ </div>
19
+
20
+ <div style="" class="col-sm-4 form-group">
21
+ <label for="f_rent_phone" class="font_normal_body">&ensp;曾用电话</label>
22
+ <input type="text" v-model="baseinfo.base.f_rent_phone" class="input_search" style="width:60%"
23
+ placeholder="曾用电话">
24
+ </div>
25
+
26
+ <div class="col-sm-4 form-group" style="" v-if="true">
27
+ <label for="f_user_state" class="font_normal_body">&ensp;客户状态</label>
28
+ <v-select :value.sync="baseinfo.base.f_user_state"
29
+ :disabled="true"
30
+ :value-single="true"
31
+ :options='userstates' placeholder='客户状态'
32
+ close-on-select></v-select>
33
+ </div>
34
+ </div>
35
+ <div class="row">
36
+ <div style="" class="col-sm-4 form-group">
37
+ <label for="f_credentials" class="font_normal_body">&ensp;证件类型</label>
38
+ <v-select id="idCardType" :value.sync="baseinfo.base.f_credentials"
39
+ v-model="baseinfo.base.f_credentials"
40
+ :value-single="true"
41
+ :options='credentials' placeholder='证件类型'
42
+ style="width: 65%"
43
+ close-on-select></v-select>
44
+ </div>
45
+ <div style="" class="col-sm-8 form-group"
46
+
47
+ v-if="baseinfo.base.f_credentials === '身份证'">
48
+ <label for="f_idnumber" class="font_normal_body">*证件号码</label>
49
+ <input type="text" maxlength="18" v-model="baseinfo.base.f_idnumber"
50
+ class="input_search" style="width:80%"
51
+ placeholder="证件号码">
52
+ </div>
53
+ <div style="" class="col-sm-8 form-group" v-if="baseinfo.base.f_credentials !== '身份证'">
54
+ <label class="font_normal_body">&ensp;证件号码</label>
55
+ <input type="text" v-model="baseinfo.base.f_idnumber" class="input_search" style="width:80%"
56
+ placeholder="证件号码">
57
+ </div>
58
+ </div>
59
+ <div class="row">
60
+ <div class="col-sm-12 form-group" :class="[$v.f_address.required ? 'has-error' : '']">
61
+ <label for="f_address" class="font_normal_body">*地址信息</label>
62
+ <input type="text" v-model="addressinfo.f_address" :value.sync="addressinfo.f_address" v-validate:f_address='{required: true }'
63
+ class="input_search" disabled="disabled" style="width:75%;" placeholder="用户地址" >
64
+ <span>
65
+ <button class="button_search button_spacing" type="button" style="width: max-content" v-if="!isedit" @click="selectaddress()">选择地址</button>
66
+ <!-- <button class="button_search button_spacing" type="button" style="width: max-content" v-if="isedit" @click="modifyaddress()">修改地址</button>-->
67
+ <button class="button_search button_spacing" type="button" style="width: max-content" v-if="isedit" @click="selectaddress()">修改地址</button>
68
+ </span>
69
+ </div>
70
+ </div>
71
+ <div class="row">
72
+ <div style="" class="col-sm-4 form-group">
73
+ <label for="f_used_name" class="font_normal_body">&ensp;曾&ensp;用&ensp;名</label>
74
+ <input type="text" v-model="baseinfo.base.f_used_name" class="input_search" style="width:60%"
75
+ placeholder="曾用名">
76
+ </div>
77
+ <div class="col-sm-4 form-group" :class="[$v.f_people_num.dctest ? 'has-error' : '']">
78
+ <label for="f_people_num" class="font_normal_body">&ensp;人&ensp;口&ensp;数</label>
79
+ <input type="number" v-model="baseinfo.base.f_people_num" v-validate:f_people_num='{dctest: [0, ">=" ]}'
80
+ :disabled="!jurisdiction.includes('修改人口数')" class="input_search" style="width:60%"
81
+ placeholder="家庭人口数">
82
+ </div>
83
+ </div>
84
+ <div class="row">
85
+ <div style="" class="col-sm-4 form-group">
86
+ <label for="f_balance" class="font_normal_body">&ensp;用户余额</label>
87
+ <input type="text" v-model="baseinfo.base.f_balance" class="input_search" style="width:60%"
88
+ placeholder="用户余额" :disabled="!jurisdiction.includes('档案信息查询修改')">
89
+ </div>
90
+ <div style="" class="col-sm-4 form-group">
91
+ <label for="f_is_mgq" class="font_normal_body ">煤&ensp;改&ensp;气&ensp;</label>
92
+ <v-select id="f_is_mgq" :value.sync="baseinfo.base.f_is_mgq" v-model="baseinfo.base.f_is_mgq"
93
+ :options='mgq' placeholder='是否煤改气' style="width: 65%" close-on-select></v-select>
94
+ </div>
95
+ <div class="col-sm-4 form-group">
96
+ <label for="f_contract" class="font_normal_body">&ensp;燃气本号</label>
97
+ <input type="text" v-model="baseinfo.base.f_book_no" class="input_search" style="width:60%" placeholder="用户证号">
98
+ </div>
99
+ </div>
100
+ <div class="row">
101
+ <div style="" class="col-sm-4 form-group">
102
+ <label for="f_rent_name" class="font_normal_body">&ensp;租户姓名</label>
103
+ <input type="text" v-model="baseinfo.base.f_rent_name" class="input_search" style="width:60%"
104
+ placeholder="租户姓名">
105
+ </div>
106
+ <div style="" class="col-sm-4 form-group">
107
+ <label for="f_zuhu_phone" class="font_normal_body">&ensp;租户电话</label>
108
+ <input type="text" v-model="baseinfo.base.f_zuhu_phone" class="input_search" style="width:60%"
109
+ placeholder="租户电话">
110
+ </div>
111
+ </div>
112
+ <div class="row">
113
+ <div style="" class="col-sm-8 form-group">
114
+ <label for="f_zuhu_idnumber" class="font_normal_body">租户身份证</label>
115
+ <input type="text" v-model="baseinfo.base.f_zuhu_idnumber" class="input_search" style="width:80%"
116
+ placeholder="租户身份证">
117
+ </div>
118
+ <div style="" class="col-sm-4 form-group">
119
+ <label for="f_is_mgq" class="font_normal_body ">&ensp;付款类型</label>
120
+ <v-select id="f_is_mgq" :value.sync="baseinfo.base.f_cost_type" v-model="baseinfo.base.f_cost_type"
121
+ :options='costtype' placeholder='付款类型' style="width: 65%" close-on-select></v-select>
122
+ </div>
123
+ </div>
124
+ <div class="row">
125
+ <div class="col-sm-8 form-group">
126
+ <label for="f_contract" class="font_normal_body">&ensp;合同编号</label>
127
+ <input type="text" v-model="baseinfo.base.f_contract_id" class="input_search" style="width:80%"
128
+ placeholder="合同编号">
129
+ </div>
130
+ <div class="col-sm-4 form-group">
131
+ <label for="f_user_state" class="font_normal_body">&ensp;房屋类型</label>
132
+ <input type="text" v-show="false" v-model="baseinfo.base.f_house_type">
133
+ <v-select :value.sync="baseinfo.base.f_house_type" :search="false" :value-single="true"
134
+ :options='housetype' placeholder='房屋类型' close-on-select>
135
+ </v-select>
136
+ </div>
137
+ </div>
138
+ <div class="row">
139
+ <div style="" class="col-sm-4 form-group">
140
+ <label for="f_user_level" class="font_normal_body ">&ensp;用户等级</label>
141
+ <v-select :value.sync="baseinfo.base.f_user_level" :search="false" :value-single="true"
142
+ :options='userlevel' placeholder='用户等级' close-on-select>
143
+ </v-select>
144
+ </div>
145
+ <div class="col-sm-4 form-group">
146
+ <label for="f_user_nature" class="font_normal_body" title="用户性质">&ensp;用气类型</label>
147
+ <input type="text" v-show="false" v-model="baseinfo.base.f_user_nature">
148
+ <v-select :value.sync="baseinfo.base.f_user_nature" :search="false" :value-single="true"
149
+ :options='usernature' placeholder='用气类型' close-on-select>
150
+ </v-select>
151
+ </div>
152
+ <div class="col-sm-4 form-group">
153
+ <label for="f_user_nature" class="font_normal_body">&ensp;档案编号</label>
154
+ <input type="text" v-model="baseinfo.base.f_olduserinfo_code" class="input_search" style="width:60%"
155
+ placeholder="档案编号">
156
+ </div>
157
+ </div>
158
+ <div class="row">
159
+ <div style="" class="col-sm-12 form-group">
160
+ <label for="f_paper_account" class="font_normal_body ">&ensp;备&emsp;&emsp;注</label>
161
+ <input class="input_search" style="width:86.5%;height: 40px" v-model="baseinfo.base.f_comments"/>
162
+ </div>
163
+ </div>
164
+
165
+ <div class="row" style="margin-top: 2%;">
166
+ <a style="font-size: 16px;font-weight: 500;"
167
+ v-if="baseinfo.base.f_cost_type[0] === '银行代扣'">银行信息</a>
168
+ </div>
169
+ <div v-if="baseinfo.base.f_cost_type[0] === '银行代扣'">
170
+ <div class="row">
171
+ <div class="col-sm-4 form-group"
172
+ :class="[$v.f_bank_accopen.required ? 'has-error' : '']">
173
+ <label for="f_username" class="font_normal_body">银行户名</label>
174
+ <input type="text" v-model="baseinfo.bank.f_bank_accopen"
175
+ class="input_search" style="width:60%" id="f_username" placeholder="客户名称"
176
+ v-validate:f_bank_accopen='{required: true}'
177
+ v-next-el="bankaccount">
178
+ </div>
179
+ <div class="col-sm-4 form-group" id=userfiles-useEssInf-银行名称>
180
+ <label for="f_username" class="font_normal_body ">银行名称</label>
181
+ <v-select :value.sync="baseinfo.bank.f_bank_name"
182
+ :options='banknames' placeholder='银行名称'
183
+ close-on-select></v-select>
184
+ </div>
185
+ <div class="col-sm-4 form-group">
186
+ <label for="f_bank_idnumber" class="font_normal_body">缴费编号</label>
187
+ <input type="text" v-model="baseinfo.bank.f_bank_pay_number"
188
+ class="input_search" style="width:60%"
189
+ aria-describedby="helpBlock" placeholder="缴费编号" v-el:bankpaynumber>
190
+ </div>
191
+ <div class="col-sm-12 form-group">
192
+ <label for="f_bank_idnumber" class="font_normal_body">身份证号</label>
193
+ <input type="text" v-model="baseinfo.bank.f_bank_idnumber"
194
+ class="input_search" style="width:54%"
195
+ aria-describedby="helpBlock" placeholder="身份证号" v-el:bankidnumber>
196
+ </div>
197
+ <div class="col-sm-12 form-group"
198
+ :class="[$v.f_bank_account.required ? 'has-error' : '']">
199
+ <label for="f_userid" class="font_normal_body">银行账号</label>
200
+ <input type="text" v-model="baseinfo.bank.f_bank_account" class="input_search" style="width:54%"
201
+ v-validate:f_bank_account='{required: true}' placeholder="银行账号" v-el:bankaccount
202
+ v-next-el="bankidnumber">
203
+ </div>
204
+ </div>
205
+ </div>
206
+ </form>
207
+ </validator>
208
+ <modal v-if="showselectaddress" :show.sync="showselectaddress" width="50%" height="80%" title="地址信息" v-ref:modal large backdrop="false">
209
+ <article slot="modal-body" class="modal-body" style="height: 700px;padding: 0!important;">
210
+ <file-address-manage :is-select="isSelect" :fileinfo="addressinfo"
211
+ @address-valid="doNothing" :showselectaddress.sync="showselectaddress" v-ref:fileaddress ></file-address-manage>
212
+ </article>
213
+ <footer slot="modal-footer" class="modal-footer">
214
+ </footer>
215
+ </modal>
216
+ <file-user-phone :show.sync="showphone" :userphonelist="userphonelist" :f_userinfo_id="baseinfo.base.f_userinfo_id"></file-user-phone>
217
+ </div>
218
+ </template>
219
+
220
+ <script>
221
+ import {HttpResetClass} from 'vue-client'
222
+ // import HighMeter from '../../plugins/HighMeterPlugin'
223
+
224
+ let getEditUserState = async function (self) {
225
+ try {
226
+ let http = new HttpResetClass()
227
+ let result = await http.load('GET', `rs/vue/EditUserState.json`, {}, {resolveMsg: null, rejectMsg: null})
228
+ console.log(result.data.EditUserState)
229
+ self.edituserstate = result.data.EditUserState
230
+ } catch (e) {
231
+ console.log(e)
232
+ }
233
+ }
234
+
235
+ export default {
236
+ title: '基本信息',
237
+ props: ['baseinfo', 'addressinfo', 'isedit', 'userphonelist'],
238
+ data () {
239
+ return {
240
+ showselectaddress: false,
241
+ site: '',
242
+ showphone: false,
243
+ areas: [],
244
+ streets: [],
245
+ residentials: [],
246
+ inputtores: this.$appdata.getParam('抄表员'),
247
+ credentials: this.$appdata.getParam('证件类型'),
248
+ costtypes: this.$appdata.getParam('缴费类型'),
249
+ banknames: this.$appdata.getParam('银行名称'),
250
+ userstates: this.$appdata.getParam('用户状态'),
251
+ mgq: this.$appdata.getParam('是否煤改气'),
252
+ costtype: this.$appdata.getParam('付款类型'),
253
+ usernature: this.$appdata.getParam('用户性质'),
254
+ userlevel: this.$appdata.getParam('用户等级'),
255
+ housetype: this.$appdata.getParam('房屋类型'),
256
+ jurisdiction: this.$login.r,
257
+ edituserstate: false,
258
+ // highMeterPlugin: {},
259
+ readCardFlag: true,
260
+
261
+ isSelect: false
262
+ }
263
+ },
264
+ ready () {
265
+ getEditUserState(this)
266
+ this.$resetValidation()
267
+ // this.highMeterPlugin = new HighMeter(this,this.readIDCardCallback)
268
+ },
269
+ beforeDestroy () {
270
+ // this.highMeterPlugin.Stop()
271
+ },
272
+ methods: {
273
+ selectaddress () {
274
+ this.showselectaddress = true
275
+ this.isSelect = true
276
+ },
277
+ modifyaddress () {
278
+ this.showselectaddress = true
279
+ this.isSelect = false
280
+ },
281
+ onValid (res) {
282
+ this.$dispatch('valid')
283
+ },
284
+ onInvalid (res) {
285
+ this.$dispatch('invalid')
286
+ },
287
+ doNothing () {
288
+ },
289
+ readIDCardCallback (compoent, msg) {
290
+ console.log('进入高拍仪', msg)
291
+ if (msg.err !== 0) {
292
+ return
293
+ }
294
+ // document.getElementById("idCardType").getElementsByClassName("btn-content")[0].innerHTML="身份证"
295
+ compoent.baseinfo.base.f_idnumber = msg.strID
296
+ compoent.baseinfo.base.f_user_name = msg.strName.trim()
297
+ // compoent.baseinfo.base.f_credentials=["身份证"]
298
+ },
299
+ phoneManage () {
300
+ this.showphone = true
301
+ console.log('查看用户备用电话信息', this.userphonelist)
302
+ }
303
+ },
304
+ watch: {
305
+ // 重置验证结果,当证件类型切换时,验证结果不能立即刷新,需要重置
306
+ 'baseinfo.base.f_credentials[0]' () {
307
+ console.log('验证器重置')
308
+ this.$resetValidation()
309
+ },
310
+ 'baseinfo.base.f_cost_type[0]' () {
311
+ console.log('验证器重置')
312
+ this.$resetValidation()
313
+ }
314
+ // 当选择销户,需要给其提醒是否进行销户
315
+ // 'baseinfo.base.f_user_state'(val) {
316
+ // // if (val[0] === '销户') {
317
+ // // this.$showMessage('是否要对该客户进行销户操作?', ['confirm', 'cancel']).then((res) => {
318
+ // // if (res !== 'confirm') {
319
+ // // this.baseinfo.base.f_user_state = ['正常']
320
+ // // }
321
+ // // })
322
+ // // }
323
+ // }
324
+ },
325
+ computed: {},
326
+ events: {
327
+ 'confirmaddress' (res) {
328
+ console.log('选定地址', res)
329
+ this.showselectaddress = false
330
+ this.addressinfo.f_address = res.f_address
331
+ this.addressinfo.id = res.id
332
+ this.$dispatch('defaultOtheret', res)
333
+ }
334
+ }
335
+ }
336
+ </script>
@@ -548,9 +548,17 @@ let asyncMachineMeterCenter = async function (self) {
548
548
  orderitem: 'f_input_date desc'
549
549
  }
550
550
  let res = await HttpReset.load('POST', 'rs/sql/singleTable_OrderBy', { data: data }, {resolveMsg: null, rejectMsg: '获取用气月份失败!'})
551
+ let date1
552
+ let date2
551
553
  if (res.data.length > 1) {
552
554
  let len = res.data.length
553
- this.gasMonth = res.data[len - 1].f_input_date.substring(5, 7) + '-' + res.data[0].f_input_date.substring(5, 7)
555
+ date1 = new Date(res.data[len - 1].f_input_date)
556
+ date1.setMonth(date1.getMonth() - 1)
557
+ date2 = new Date(res.data[0].f_input_date)
558
+ date2.setMonth(date2.getMonth() - 1)
559
+ console.log('date1.toISOString()', date1.toISOString())
560
+ console.log('date2.toISOString()', date2.toISOString())
561
+ this.gasMonth = date1.toISOString().substring(5, 7) + '-' + date2.toISOString().substring(5, 7)
554
562
  } else if (res.data.length === 1) {
555
563
  let condition2 = `f_userinfo_id = ${this.data.f_userinfo_id} and f_whether_pay ='是' AND f_hand_state = '有效' and f_meter_state = '已抄表' AND f_oughtfee !=0 and f_input_date < '${res.data[0].f_input_date}'`
556
564
  let param = {
@@ -561,9 +569,18 @@ let asyncMachineMeterCenter = async function (self) {
561
569
  }
562
570
  let res2 = await HttpReset.load('POST', 'rs/sql/singleTable_OrderBy', {data: param}, {resolveMsg: null, rejectMsg: '获取用气月份失败!'})
563
571
  if (res2.data.length > 0) {
564
- this.gasMonth = res2.data[0].f_input_date.substring(5, 7) + '-' + res.data[0].f_input_date.substring(5, 7)
572
+ date1 = new Date(res2.data[0].f_input_date)
573
+ date1.setMonth(date1.getMonth() - 1)
574
+ date2 = new Date(res.data[0].f_input_date)
575
+ date2.setMonth(date2.getMonth() - 1)
576
+ console.log('date1.toISOString()', date1.toISOString())
577
+ console.log('date2.toISOString()', date2.toISOString())
578
+ this.gasMonth = date1.toISOString().substring(5, 7) + '-' + date2.toISOString().substring(5, 7)
565
579
  } else {
566
- this.gasMonth = res.data[0].f_input_date.substring(5, 7)
580
+ date1 = new Date(res.data[0].f_input_date)
581
+ date1.setMonth(date1.getMonth() - 1)
582
+ console.log('date1.toISOString()', date1.toISOString())
583
+ this.gasMonth = date1.toISOString().substring(5, 7)
567
584
  }
568
585
  }
569
586
  },
@@ -5,4 +5,9 @@ export default function () {
5
5
  Vue.component('machine-meter-center', (resolve) => { require(['.//MachineMeterCenter'], resolve) })
6
6
  // 欠费查询
7
7
  Vue.component('sale-arrears-query', (resolve) => { require(['./ArrearsQuery'], resolve) })
8
+ // 用户基本信息test
9
+ Vue.component('file-user-essential-info', (resolve) => { require(['./FilesManage/UserEssentialInfoTest'], resolve) })
10
+ // 单个表具信息
11
+ Vue.component('file-meter-info', (resolve) => { require(['./FilesManage/MeterinfoTest'], resolve) })
12
+
8
13
  }