system-clients 3.2.71 → 3.2.72
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
package/src/components/Main.vue
CHANGED
@@ -140,6 +140,26 @@
|
|
140
140
|
</footer>
|
141
141
|
</modal>
|
142
142
|
|
143
|
+
<modal v-show="showRemind" :show.sync="showRemind" :backdrop="false">
|
144
|
+
<header slot="modal-header" class="text-center"><h3>卡表动态库到期</h3></header>
|
145
|
+
<article slot="modal-body" class="modal-body">
|
146
|
+
<form class="form-horizontal">
|
147
|
+
<div class="row">
|
148
|
+
<div class="col-sm-3 " v-for="item in dataRemind">
|
149
|
+
<label class="col-sm-3">{{ item.type }}:</label>
|
150
|
+
<span style="font-weight:normal">{{item.brand}}</span>
|
151
|
+
</div>
|
152
|
+
<div class="col-sm-12 text-right">
|
153
|
+
<span style="font-weight:normal">卡表动态库到期,请联系售后尽快注册!</span>
|
154
|
+
</div>
|
155
|
+
</div>
|
156
|
+
</form>
|
157
|
+
</article>
|
158
|
+
<footer slot="modal-footer" style="height: 8vh" class="modal-footer">
|
159
|
+
<button class="button_search" @click="showRemind = false">确认</button>
|
160
|
+
</footer>
|
161
|
+
</modal>
|
162
|
+
|
143
163
|
<!-- 变更录入 模态框 -->
|
144
164
|
<add-changemsg :show="AddChangeMsgShow" v-on:toggle="AddChangeMsgShow = false"></add-changemsg>
|
145
165
|
<!-- 修改密码组件 -->
|
@@ -246,6 +266,9 @@ let createWaterMark = function (userName) {
|
|
246
266
|
setting: true,
|
247
267
|
srcsetting: '../../static/newStyle/setting.png',
|
248
268
|
showwatermakeflag: false,
|
269
|
+
gasbrandIdData: [],
|
270
|
+
showRemind: false,
|
271
|
+
dataRemind: [],
|
249
272
|
// headerHint: true, // 右侧顶部提示信息
|
250
273
|
// value: 25645.26,
|
251
274
|
// AddChangeMsgShow: false,
|
@@ -312,6 +335,8 @@ let createWaterMark = function (userName) {
|
|
312
335
|
if (this.config.approve) {
|
313
336
|
this.getFlowList()
|
314
337
|
}
|
338
|
+
// 获取卡表动态库到期时间
|
339
|
+
this.getExpireDate()
|
315
340
|
},
|
316
341
|
methods: {
|
317
342
|
getOrderList(){
|
@@ -325,7 +350,6 @@ let createWaterMark = function (userName) {
|
|
325
350
|
console.log('捕获到异常', error)
|
326
351
|
}
|
327
352
|
},
|
328
|
-
// 获取审核待办
|
329
353
|
getFlowList(){
|
330
354
|
console.log('======获取流程审核待办=====')
|
331
355
|
let times = this.config.approveTimes * 60 * 1000
|
@@ -338,16 +362,6 @@ let createWaterMark = function (userName) {
|
|
338
362
|
console.log('捕获到异常', error)
|
339
363
|
}
|
340
364
|
},
|
341
|
-
getTimesgotoWorkOrderSite(){
|
342
|
-
let teltimes = 2*60*1000 // 两分钟
|
343
|
-
try {
|
344
|
-
this.intervaltx =setInterval(()=>{
|
345
|
-
this.gotoWorkOrderSite()
|
346
|
-
},teltimes)
|
347
|
-
}catch (e) {
|
348
|
-
console.log('捕获到异常', e)
|
349
|
-
}
|
350
|
-
},
|
351
365
|
async getFlowDaiBan(){
|
352
366
|
this.flowDaiBan = ''
|
353
367
|
let http = new HttpResetClass()
|
@@ -369,6 +383,16 @@ let createWaterMark = function (userName) {
|
|
369
383
|
this.newTipShow = true
|
370
384
|
}
|
371
385
|
},
|
386
|
+
getTimesgotoWorkOrderSite(){
|
387
|
+
let teltimes = 2*60*1000 // 两分钟
|
388
|
+
try {
|
389
|
+
this.intervaltx =setInterval(()=>{
|
390
|
+
this.gotoWorkOrderSite()
|
391
|
+
},teltimes)
|
392
|
+
}catch (e) {
|
393
|
+
console.log('捕获到异常', e)
|
394
|
+
}
|
395
|
+
},
|
372
396
|
async getDaiBan(){
|
373
397
|
this.OrderDaiBan = ''
|
374
398
|
this.AppDaiBan = ''
|
@@ -417,6 +441,58 @@ let createWaterMark = function (userName) {
|
|
417
441
|
this.newTipShow = true
|
418
442
|
}
|
419
443
|
},
|
444
|
+
// 获取动态库卡表到期日
|
445
|
+
async getExpireDate(){
|
446
|
+
// 获取分公司的表品牌id
|
447
|
+
let http = new HttpResetClass()
|
448
|
+
await http.load('POST', '/rs/sql/singleTable', {data: {
|
449
|
+
tablename:'t_gasbrand_orgid',
|
450
|
+
condition:`f_using_orgid ='${this.$login.f.orgid}'`
|
451
|
+
}}, {
|
452
|
+
resolveMsg: null,
|
453
|
+
rejectMsg: null
|
454
|
+
}).then((res) => {
|
455
|
+
if (res.data.length > 0) {
|
456
|
+
res.data.forEach(item => {
|
457
|
+
this.gasbrandIdData.push(item.f_gasbrand_id)
|
458
|
+
})
|
459
|
+
}
|
460
|
+
if (this.gasbrandIdData.length > 0) {
|
461
|
+
// 获取卡表到期时间
|
462
|
+
http.load('POST', '/rs/sql/singleTable', {data: {
|
463
|
+
tablename:'t_gasbrand',
|
464
|
+
condition:`id in (${this.gasbrandIdData}) and f_meter_type like '%卡表%'`
|
465
|
+
}}, {
|
466
|
+
resolveMsg: null,
|
467
|
+
rejectMsg: null
|
468
|
+
}).then((res) => {
|
469
|
+
if (res.data.length > 0) {
|
470
|
+
res.data.forEach(itre => {
|
471
|
+
let band = null
|
472
|
+
if ('f_dynamic_expire' in itre) {
|
473
|
+
console.log(itre.f_dynamic_expire)
|
474
|
+
if (itre.f_dynamic_expire !== null && itre.f_dynamic_expire !== '') {
|
475
|
+
let todayold = new Date(itre.f_dynamic_expire)
|
476
|
+
todayold.setDate(todayold.getDate() - parseInt(this.$appdata.getSingleValue('动态库提醒天数设置')))
|
477
|
+
let today = new Date()
|
478
|
+
if (today > todayold) {
|
479
|
+
band = {type:'卡表',brand:itre.f_meter_brand}
|
480
|
+
this.dataRemind.push(band)
|
481
|
+
}
|
482
|
+
}
|
483
|
+
}
|
484
|
+
})
|
485
|
+
|
486
|
+
}
|
487
|
+
if (this.dataRemind.length > 0) {
|
488
|
+
this.showRemind = true
|
489
|
+
// this.$showMessage(band + '。' +
|
490
|
+
// '卡表动态库到期,请联系售后尽快注册!')
|
491
|
+
}
|
492
|
+
})
|
493
|
+
}
|
494
|
+
})
|
495
|
+
},
|
420
496
|
// 提醒框被点击
|
421
497
|
tipClick(){
|
422
498
|
this.newTipShow = false
|
@@ -0,0 +1,566 @@
|
|
1
|
+
<template>
|
2
|
+
<div class="syslogin">
|
3
|
+
<div class="login-title" >
|
4
|
+
<div class="row auto">
|
5
|
+
<marquee style="width:80%;margin-top:25px"><span style="font-size: 1.8rem;color: white;">{{notice}}</span></marquee>
|
6
|
+
<div class="login-title-chi" style="white-space: nowrap;margin-right:0">
|
7
|
+
<button class="my_button_search button_spacing" style="margin-right: 5px" title="点击清除浏览器缓存" @click.stop="delCookie">
|
8
|
+
<img
|
9
|
+
src="../../assets/clear-cookie.png" style="height: 25px; width: 95px;margin-bottom: 3px;">
|
10
|
+
</button>
|
11
|
+
<span v-if="$login.versionTime">>构建时间:{{ vTime }}</span>
|
12
|
+
<div v-if="titleShow">
|
13
|
+
<img src="../../../static/newStyle/login-info.png"/>
|
14
|
+
<span @click="showus=true">关于我们</span>
|
15
|
+
</div>
|
16
|
+
<!-- <img src="../../../static/newStyle/login-con.png"/>-->
|
17
|
+
<!-- <span>联系我们</span>-->
|
18
|
+
</div>
|
19
|
+
</div>
|
20
|
+
</div>
|
21
|
+
|
22
|
+
<modal :show.sync="showus" backdrop="true" width="50%" style="width:auto;">
|
23
|
+
<article slot="modal-body" class="modal-body" >
|
24
|
+
<img style="height:100%;width:100%" src="../../../static/newStyle/about-us.png"/>
|
25
|
+
</article>
|
26
|
+
<footer slot="modal-footer" class="modal-footer">
|
27
|
+
</footer>
|
28
|
+
</modal>
|
29
|
+
|
30
|
+
|
31
|
+
<div class="logoew" v-if="logoandroid" >
|
32
|
+
<div v-if="logoandroid" class="imglogo"></div>
|
33
|
+
<p class="logocontent">燃气客服系统Android版</p>
|
34
|
+
<p class="logofooter">(仅浏览器扫描)</p>
|
35
|
+
</div>
|
36
|
+
<!--输入框-->
|
37
|
+
<div class="loginmain">
|
38
|
+
<!-- <img src="../../../static/login_title1.png" alt="图片加载未完成" class="img-responsive" style="margin: 0 auto; padding-top: 150px;" /> -->
|
39
|
+
<div class="loginmain-left">
|
40
|
+
<img class="loginmain-left-img" src="../../../static/newStyle/login-left.png">
|
41
|
+
</div>
|
42
|
+
<div class="loginmain-right">
|
43
|
+
|
44
|
+
<p @click="theme()" style="white-space: nowrap">{{config.title}}</p>
|
45
|
+
|
46
|
+
<form v-show="!login">
|
47
|
+
<!-- <input type="text" placeholder="用户名" v-model="model.ename" class="usericon">-->
|
48
|
+
<div class="login-input">
|
49
|
+
<img src="../../../static/newStyle/login-user.png"/>
|
50
|
+
<input type="text" style="display: inline;background-color: white!important;" placeholder="用户名" v-model="model.ename"/>
|
51
|
+
</div>
|
52
|
+
<div class="login-input">
|
53
|
+
<img src="../../../static/newStyle/login-pwd.png"/>
|
54
|
+
<input type="password" placeholder="密码" style="display: inline;background-color: darkgray;" v-model="model.password"
|
55
|
+
@keyup.enter="confirm('key')"/>
|
56
|
+
</div>
|
57
|
+
<div class="login-input-1" v-if="$login.Verification">
|
58
|
+
<img src="../../../static/newStyle/login-check.png"/>
|
59
|
+
<input v-if="$login.Verification" class="login-check" type="text" placeholder="请输入验证码"
|
60
|
+
v-model="picLyanzhengma" @keyup.enter="confirm('key')"/>
|
61
|
+
</div>
|
62
|
+
<div class="login-input-2" >
|
63
|
+
<input v-if="$login.Verification" class="login-check-1" style="display: inline;background-color:#eeeeee !important;"
|
64
|
+
type="button" @click="createCode" v-model="checkCode"/>
|
65
|
+
</div>
|
66
|
+
<div class="login-bt">
|
67
|
+
<button type="button" id="login-button" class="login-button" @click.prevent="confirm('click')">登录</button>
|
68
|
+
</div>
|
69
|
+
<!-- <input type="password" placeholder="密码" v-model="model.password" class="psicon"-->
|
70
|
+
<!-- @keyup.enter="confirm('key')">-->
|
71
|
+
<!-- <input v-if="$login.Verification" styljiaoyane="width: 40%; display: inline" type="text" placeholder="请输入验证码"-->
|
72
|
+
<!-- v-model="picLyanzhengma" @keyup.enter="confirm('key')">-->
|
73
|
+
<!-- <input v-if="$login.Verification" style="width: 30%; display: inline;background-color: darkgray;"-->
|
74
|
+
<!-- type="button" @click="createCode" v-model="checkCode"/><br>-->
|
75
|
+
|
76
|
+
<!-- <button type="button" id="login-button" @click.prevent="confirm()"><strong>注册</strong></button> -->
|
77
|
+
<!-- <span @click="register()">还没有注册,现在注册>>></span> -->
|
78
|
+
</form>
|
79
|
+
<div v-show="login" class="login_load">
|
80
|
+
<img src="../../../static/newStyle/login-do.gif">
|
81
|
+
</div>
|
82
|
+
</div>
|
83
|
+
</div>
|
84
|
+
<div class="login-foot" v-show="false">
|
85
|
+
技术支持:西安奥枫软件有限公司
|
86
|
+
</div>
|
87
|
+
<div class="login-foot" v-show="$login.BAinformation">
|
88
|
+
{{{ $login.BAinformation }}}
|
89
|
+
</div>
|
90
|
+
|
91
|
+
<modal v-if="depPromptShow" :show.sync="depPromptShow" :backdrop="false" v-ref:modal >
|
92
|
+
<header slot="modal-header" style="height: 8vh" class="modal-header">
|
93
|
+
<!--<h4 class="modal-title">登录信息</h4>-->
|
94
|
+
</header>
|
95
|
+
<article slot="modal-body" class="modal-body">
|
96
|
+
<form class="form-horizontal">
|
97
|
+
<div class="row">
|
98
|
+
<div class="col-sm-12 form-group">
|
99
|
+
<label class="col-sm-5 ">当前登录人:</label>
|
100
|
+
<label style="font-weight:normal">{{$login.f.name}}</label>
|
101
|
+
</div>
|
102
|
+
<!--<div class="col-sm-12 form-group" v-if="$login.f.number">-->
|
103
|
+
<!--<label class="col-sm-5 ">组 织 编 码:</label>-->
|
104
|
+
<!--<label style="font-weight:normal">{{$login.f.number}}</label>-->
|
105
|
+
<!-- <div class="col-sm-7">
|
106
|
+
<span >{{$login.f.number}}</span>
|
107
|
+
</div> -->
|
108
|
+
<!--</div>-->
|
109
|
+
<div class="col-sm-12 form-group">
|
110
|
+
<label class="col-sm-5">所在销售点:</label>
|
111
|
+
<label style="font-weight:normal">{{$login.f.deps}}</label>
|
112
|
+
<!-- <div class="col-sm-7">
|
113
|
+
<span >{{$login.f.deps}}</span>
|
114
|
+
</div> -->
|
115
|
+
</div>
|
116
|
+
<div class="col-sm-12 " v-if="AppDaiBan !==''">
|
117
|
+
<label class="col-sm-2">报装待办:</label>
|
118
|
+
<span style="font-weight:normal">{{AppDaiBan}}</span>
|
119
|
+
</div>
|
120
|
+
<div class="col-sm-12 " v-if="OrderDaiBan !==''">
|
121
|
+
<label class="col-sm-2">预约待办:</label>
|
122
|
+
<span style="font-weight:normal">{{OrderDaiBan}}</span>
|
123
|
+
</div>
|
124
|
+
<div class="col-sm-12 " v-for="daibanitem in safecheckDaiBan">
|
125
|
+
<label class="col-sm-2">{{daibanitem.oldData.title}}:</label>
|
126
|
+
<span style="font-weight:normal">{{daibanitem.text}}</span>
|
127
|
+
</div>
|
128
|
+
</div>
|
129
|
+
</form>
|
130
|
+
</article>
|
131
|
+
<footer slot="modal-footer" style="height: 8vh" class="modal-footer">
|
132
|
+
<button class="button_search" @click="depPromptConfirm">确认</button>
|
133
|
+
<button class="button_clear" @click="depPromptCancel">取消</button>
|
134
|
+
</footer>
|
135
|
+
</modal>
|
136
|
+
|
137
|
+
<!-- 修改密码组件 -->
|
138
|
+
<modify-pw :show.sync="modifyPwShow" v-if="modifyPwShow"></modify-pw>
|
139
|
+
</div>
|
140
|
+
|
141
|
+
</template>
|
142
|
+
|
143
|
+
<script>
|
144
|
+
import co from 'co'
|
145
|
+
import $ from 'jquery'
|
146
|
+
import Vue from 'vue'
|
147
|
+
import {HttpResetClass} from 'vue-client'
|
148
|
+
|
149
|
+
let daibanJson = require('../../util/Daiban.json')
|
150
|
+
|
151
|
+
|
152
|
+
let saveGen = function *(self) {
|
153
|
+
try {
|
154
|
+
if(self.$login){
|
155
|
+
// 账号ename,密码password,是否显示异地登陆
|
156
|
+
yield self.$login.login(self.model.ename, self.model.password, self.$login.showYiDi)
|
157
|
+
}
|
158
|
+
if(self.$appdata){
|
159
|
+
yield self.$appdata.load()
|
160
|
+
}
|
161
|
+
if (Vue.$heatCompatibility) {
|
162
|
+
try {
|
163
|
+
if(self.$loginHeat){
|
164
|
+
yield self.$loginHeat.login(self.model.ename, self.model.password)
|
165
|
+
}
|
166
|
+
if(self.$appdataHeat){
|
167
|
+
yield self.$appdataHeat.load()
|
168
|
+
}
|
169
|
+
} catch (e) {
|
170
|
+
console.log('热力系统登陆失败!')
|
171
|
+
}
|
172
|
+
}
|
173
|
+
yield self.$getConfig(self, 'Login')
|
174
|
+
console.log('登录配置', self.config)
|
175
|
+
if (self.config.isMac) {
|
176
|
+
// 获取该登录人分公司下的mac配置
|
177
|
+
let getMacs = yield self.$resetpost('rs/sql/equipmentQuery', {data: {condition: `f_filialeids like '%${self.$login.f.f_orgids}%'`}}, {
|
178
|
+
resolveMsg: null,
|
179
|
+
rejectMsg: null
|
180
|
+
}).catch(() => {
|
181
|
+
throw new Error('获取mac配置失败')
|
182
|
+
})
|
183
|
+
console.log('MAC地址信息', getMacs)
|
184
|
+
// 获取本地mac地址
|
185
|
+
let getLocalMac = yield self.$resetget('http://127.0.0.1:8003/loadmac', {
|
186
|
+
resolveMsg: null,
|
187
|
+
rejectMsg: null
|
188
|
+
}).catch(() => {
|
189
|
+
throw new Error('获取本地mac配置失败')
|
190
|
+
})
|
191
|
+
console.log('本地MAC地址信息', getLocalMac)
|
192
|
+
// 对Mac地址进行匹配
|
193
|
+
let macValidate = false
|
194
|
+
for (let i = 0; i < getLocalMac.data.mac.length; i++) {
|
195
|
+
for (let j = 0; j < getMacs.data.length; j++) {
|
196
|
+
if (getMacs.data[j].f_mac_number.toLocaleUpperCase() === getLocalMac.data.mac[i]) {
|
197
|
+
macValidate = true
|
198
|
+
}
|
199
|
+
}
|
200
|
+
}
|
201
|
+
if (!macValidate) {
|
202
|
+
throw new Error('Mac地址验证失败, 请联系管理员!!')
|
203
|
+
}
|
204
|
+
}
|
205
|
+
console.log(self.$login.depPrompt)
|
206
|
+
// 弱口令验证
|
207
|
+
//跳转过来的不进行验证
|
208
|
+
if ((!self.otherLogin) && self.config.weakPassword && !(/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)(?!.*(.)(\1)+)(?!.*(123|321|abc|cba))[a-zA-Z\d!@#$%^&*()_+-=<>?]{8,16}$/.test(self.model.password))) {
|
209
|
+
self.$showMessage('登录系统: 此账户的密码过于简单,请修改密码后重新登陆!!!', ['confirm']).then((res) => {
|
210
|
+
self.modifyPwShow = true
|
211
|
+
})
|
212
|
+
} else if ((!self.otherLogin) && self.$login.depPrompt) {
|
213
|
+
self.depPromptShow = true
|
214
|
+
if (self.$login.showDaiBan && self.$login.r.includes('展示预约信息')){
|
215
|
+
// 获取待办
|
216
|
+
self.getDaiBan()
|
217
|
+
}
|
218
|
+
if (self.$login.showDaiBan && self.$login.r.includes('登录预约信息')){
|
219
|
+
// 获取待办 在util下有个Daiban.jsond 文件 ,在里面进行配置,在功能权限界面增加登录预约信息
|
220
|
+
self.getDaiBanA()
|
221
|
+
}
|
222
|
+
} else {
|
223
|
+
self.$goto('home-page', {functions: self.$login.f,config: self.config})
|
224
|
+
if (self.$login) {
|
225
|
+
console.log('登录信息', self.$login.f)
|
226
|
+
global.login=self.$login.f
|
227
|
+
console.log('登录信息', global.login)
|
228
|
+
}
|
229
|
+
}
|
230
|
+
} catch (ret) {
|
231
|
+
console.error('登录失败', ret)
|
232
|
+
let msg
|
233
|
+
if (ret instanceof Error) {
|
234
|
+
msg = ret
|
235
|
+
}
|
236
|
+
if (ret.status === 0) {
|
237
|
+
msg = '服务连接错误,请确认服务状态'
|
238
|
+
} else if (ret.status === 401) {
|
239
|
+
msg = ret.data
|
240
|
+
} else if (ret.status === 710) {
|
241
|
+
msg = ret.data
|
242
|
+
} else if (ret.status === 555) {
|
243
|
+
msg = ret.data
|
244
|
+
}
|
245
|
+
self.createCode()
|
246
|
+
self.picLyanzhengma = ''
|
247
|
+
yield self.$showMessage(msg)
|
248
|
+
self.model.ename = ''
|
249
|
+
self.model.password = ''
|
250
|
+
self.login = false
|
251
|
+
$('form').fadeIn(500)
|
252
|
+
}
|
253
|
+
}
|
254
|
+
export default {
|
255
|
+
title: '登录',
|
256
|
+
async ready () {
|
257
|
+
this.titleShow = this.$appdata.getSingleValue('关于我们')
|
258
|
+
window.versionTime = window.versionTime ? window.versionTime : new Date().getTime()
|
259
|
+
this.vTime = this.format(new Date(window.versionTime));
|
260
|
+
try{
|
261
|
+
let http = new HttpResetClass()
|
262
|
+
let res = await http.load('POST', 'rs/sql/singleTable',
|
263
|
+
{data:{
|
264
|
+
tablename: 't_changedeclare',
|
265
|
+
condition: ` f_type ='变更通知' `
|
266
|
+
}
|
267
|
+
}, {resolveMsg: null, rejectMsg: null})
|
268
|
+
if(res.data.length>0){
|
269
|
+
console.log("---------------获取通知",res.data[0].f_change_message)
|
270
|
+
this.notice=res.data[0].f_change_message
|
271
|
+
}
|
272
|
+
}catch(e){}
|
273
|
+
|
274
|
+
this.loginother();
|
275
|
+
$('#login-button').click(function (event) {
|
276
|
+
event.preventDefault()
|
277
|
+
$('form').fadeOut(500)
|
278
|
+
})
|
279
|
+
if (window.location.search && window.location.search.indexOf('af_key') !== -1&& window.location.search.indexOf('af_n') !== -1) {
|
280
|
+
const subUrl = window.location.search.replace('?af_key=','').split('&af_n=')
|
281
|
+
console.log(subUrl)
|
282
|
+
this.model.ename = window.atob(subUrl[0])
|
283
|
+
this.model.password = window.atob(subUrl[1])
|
284
|
+
console.log('this.model.ename',this.model.ename)
|
285
|
+
this.otherLogin = true
|
286
|
+
this.confirm()
|
287
|
+
}else{
|
288
|
+
//跳转不需要验证码
|
289
|
+
this.createCode()
|
290
|
+
}
|
291
|
+
console.log(this.$login)
|
292
|
+
},
|
293
|
+
data () {
|
294
|
+
return {
|
295
|
+
vTime: '',
|
296
|
+
image:{
|
297
|
+
img1: '/images/newStyle/login-info.png',
|
298
|
+
img2: '/images/newStyle/login-con.png',
|
299
|
+
img3: '/images/newStyle/login-left.png',
|
300
|
+
img4: '/images/newStyle/login-user.png',
|
301
|
+
img5: '/images/newStyle/login-pwd.png',
|
302
|
+
img6: '/images/newStyle/login-check.png',
|
303
|
+
img7: '/images/newStyle/login-do.png',
|
304
|
+
},
|
305
|
+
config: {
|
306
|
+
isMac: false,
|
307
|
+
depPrompt: false,
|
308
|
+
weakPassword: false,
|
309
|
+
title: '燃气客服系统',
|
310
|
+
distanceLogin: false,
|
311
|
+
// 那些角色可以定时获取预约提示
|
312
|
+
isTip : false,
|
313
|
+
// 那些角色可以定时获取预约提示
|
314
|
+
msgRole : '预约处理人员',
|
315
|
+
// 定时获取提示间隔 单位:分钟
|
316
|
+
times: 25,
|
317
|
+
approve: false, // 是否获取审核提醒
|
318
|
+
approveTimes: 1 // 审核时间见间隔
|
319
|
+
},
|
320
|
+
titleShow: true, //标题显示
|
321
|
+
otherLogin:false,
|
322
|
+
login: false,
|
323
|
+
depPromptShow: false,
|
324
|
+
model: {},
|
325
|
+
show: false,
|
326
|
+
checkCode: '',
|
327
|
+
login_do:true,
|
328
|
+
picLyanzhengma: '',
|
329
|
+
// 修改密码弹框展示
|
330
|
+
modifyPwShow: false,
|
331
|
+
logoandroid:false,
|
332
|
+
showus:false,
|
333
|
+
notice:'',
|
334
|
+
loginotherflag :true,
|
335
|
+
// 报建待办
|
336
|
+
AppDaiBan: '',
|
337
|
+
//安检待办
|
338
|
+
safecheckDaiBan:[],
|
339
|
+
// 预约待处理
|
340
|
+
OrderDaiBan: ''
|
341
|
+
}
|
342
|
+
},
|
343
|
+
methods: {
|
344
|
+
//格式化时间
|
345
|
+
format(dat){
|
346
|
+
//获取年月日,时间
|
347
|
+
const year = dat.getFullYear();
|
348
|
+
const mon = (dat.getMonth()+1) < 10 ? "0"+(dat.getMonth()+1) : dat.getMonth()+1;
|
349
|
+
const data = dat.getDate() < 10 ? "0"+(dat.getDate()) : dat.getDate();
|
350
|
+
const hour = dat.getHours() < 10 ? "0"+(dat.getHours()) : dat.getHours();
|
351
|
+
const min = dat.getMinutes() < 10 ? "0"+(dat.getMinutes()) : dat.getMinutes();
|
352
|
+
const seon = dat.getSeconds() < 10 ? "0"+(dat.getSeconds()) : dat.getSeconds();
|
353
|
+
|
354
|
+
return year + "-" + mon + "-" + data + " " + hour + ":" + min + ":" + seon;
|
355
|
+
},
|
356
|
+
async getDaiBan(){
|
357
|
+
let http = new HttpResetClass()
|
358
|
+
let condition = ''
|
359
|
+
if(this.$login.f.deps!=='柠条塔'){
|
360
|
+
condition = ` (f_orderstate != '预约成功' and f_orderstate != '预约失败' ) or f_orderstate is null `
|
361
|
+
} else {
|
362
|
+
condition =` f_orderstate is null and (f_address in( select f_address from t_user_address where f_slice_area='柠条塔') or f_address like '%柠条塔%') `
|
363
|
+
}
|
364
|
+
await http.load('POST', '/rs/sql/singleTable', {data: {
|
365
|
+
tablename:'t_order_center',
|
366
|
+
condition:condition
|
367
|
+
}}, {
|
368
|
+
resolveMsg: null,
|
369
|
+
rejectMsg: null
|
370
|
+
}).then((res) => {
|
371
|
+
let OrderDaiBan = {}
|
372
|
+
res.data.forEach(item=>{
|
373
|
+
OrderDaiBan[item.f_ordertype] = OrderDaiBan[item.f_ordertype] || []
|
374
|
+
OrderDaiBan[item.f_ordertype].push(item)
|
375
|
+
})
|
376
|
+
this.OrderDaiBan = `您有${res.data.length}条需要处理的微信预约业务!`
|
377
|
+
if (res.data.length> 0){
|
378
|
+
this.OrderDaiBan += `其中 ${Object.keys(OrderDaiBan).map(key=>`${key}:${OrderDaiBan[key].length}条`).join(', ')}`
|
379
|
+
}
|
380
|
+
})
|
381
|
+
let data = {
|
382
|
+
condition: '1 = 1',
|
383
|
+
data: {
|
384
|
+
orgid: this.$login.f.orgid,
|
385
|
+
id: this.$login.f.id
|
386
|
+
}
|
387
|
+
}
|
388
|
+
await http.load('POST', '/rs/sql/checkuser', {data: data}, {
|
389
|
+
resolveMsg: null,
|
390
|
+
rejectMsg: null
|
391
|
+
}).then((res) => {
|
392
|
+
let AppDaiBan = {}
|
393
|
+
res.data.forEach(item=>{
|
394
|
+
AppDaiBan[item.defname] = AppDaiBan[item.defname] || []
|
395
|
+
AppDaiBan[item.defname].push(item)
|
396
|
+
})
|
397
|
+
this.AppDaiBan = `您有${res.data.length}条需要处理的报建待办业务!`
|
398
|
+
if (res.data.length> 0){
|
399
|
+
this.AppDaiBan += `其中 ${Object.keys(AppDaiBan).map(key=>`${key}:${AppDaiBan[key].length}条`).join(', ')}`
|
400
|
+
}
|
401
|
+
})
|
402
|
+
|
403
|
+
},
|
404
|
+
async getDaiBanA(){
|
405
|
+
// 是否全局开启待办通知
|
406
|
+
if (daibanJson.enable) {
|
407
|
+
console.log("当前获取到待办配置为" + JSON.stringify(daibanJson))
|
408
|
+
let http = new HttpResetClass()
|
409
|
+
let daibanArray = []
|
410
|
+
for (let daibanItem of daibanJson.daiban) {
|
411
|
+
console.log("开始处理待办任务:" + daibanItem.title + "当前任务状态:" + daibanItem.enable?"开启":"关闭" )
|
412
|
+
if (daibanItem.enable) { // 控制每一项通知是否开启
|
413
|
+
let postResult = ''; //提示信息为
|
414
|
+
await http.load("POST",daibanItem.url,{data:daibanItem.data},{ resolveMsg: null, rejectMsg: null})
|
415
|
+
.then((res)=>{
|
416
|
+
let responseData = res.data
|
417
|
+
for (let item of responseData) {
|
418
|
+
postResult += eval(daibanItem.text) + "\n"
|
419
|
+
}
|
420
|
+
postResult += '\t'
|
421
|
+
daibanArray.push({text:postResult,oldData:daibanItem})
|
422
|
+
})
|
423
|
+
}
|
424
|
+
}
|
425
|
+
console.log("安检数据为:"+JSON.stringify(daibanArray))
|
426
|
+
this.safecheckDaiBan = daibanArray
|
427
|
+
}else {
|
428
|
+
console.log("待办提醒全局关闭。")
|
429
|
+
}
|
430
|
+
|
431
|
+
|
432
|
+
|
433
|
+
|
434
|
+
},
|
435
|
+
|
436
|
+
async loginother(){
|
437
|
+
if (this.config.distanceLogin) {
|
438
|
+
if (this.$login && this.$login.getUrlParames('name') ) {
|
439
|
+
let ename = this.$login.getUrlParames('name');
|
440
|
+
let logininfo = await this.$resetpost('rs/logic/getLoginData',{data:{ename:ename}},{resolveMsg: null, rejectMsg: null});
|
441
|
+
if(logininfo.data){
|
442
|
+
if(logininfo.data.ename && logininfo.data.password){
|
443
|
+
this.model.ename = logininfo.data.ename
|
444
|
+
this.model.password =logininfo.data.password
|
445
|
+
let gen = saveGen(this)
|
446
|
+
return co(gen)
|
447
|
+
}
|
448
|
+
}
|
449
|
+
}
|
450
|
+
}
|
451
|
+
},
|
452
|
+
theme(){
|
453
|
+
// var elementList = document.querySelectorAll('body');
|
454
|
+
// console.log(elementList)
|
455
|
+
// document.querySelectorAll('body')[0].className='themeTwo'
|
456
|
+
// var elementList = document.querySelectorAll('body');
|
457
|
+
// console.log(elementList)
|
458
|
+
},
|
459
|
+
onReady () {
|
460
|
+
this.$emit('ready')
|
461
|
+
},
|
462
|
+
confirm (key) {
|
463
|
+
this.login_do=!this.login_do
|
464
|
+
// return
|
465
|
+
if (key == 'key') {
|
466
|
+
$('form').fadeOut(500)
|
467
|
+
}
|
468
|
+
this.login = true
|
469
|
+
// let gen = saveGen(this)
|
470
|
+
// return co(gen)
|
471
|
+
if((!this.otherLogin) && this.$login && this.$login.Verification){
|
472
|
+
console.log('跳转过来的不走验证')
|
473
|
+
if(this.picLyanzhengma == '') {
|
474
|
+
this.$showMessage("请输入验证码!").then(()=>{
|
475
|
+
this.login = false
|
476
|
+
$('form').fadeIn(500)
|
477
|
+
this.createCode()
|
478
|
+
})
|
479
|
+
}else if(this.picLyanzhengma.toUpperCase() != this.checkCode ) {
|
480
|
+
//若输入的验证码与产生的验证码不一致时
|
481
|
+
this.$showMessage("验证码不正确").then(()=>{
|
482
|
+
this.login = false
|
483
|
+
$('form').fadeIn(500)
|
484
|
+
this.createCode();//刷新验证码
|
485
|
+
this.picLyanzhengma = '';
|
486
|
+
})
|
487
|
+
}else {
|
488
|
+
this.login = true
|
489
|
+
let gen = saveGen(this)
|
490
|
+
return co(gen)
|
491
|
+
}
|
492
|
+
}else {
|
493
|
+
this.login = true
|
494
|
+
let gen = saveGen(this)
|
495
|
+
return co(gen)
|
496
|
+
}
|
497
|
+
},
|
498
|
+
createCode(){
|
499
|
+
let code = "";
|
500
|
+
let codeLength = 4;//验证码的长度
|
501
|
+
let random = new Array(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R',
|
502
|
+
'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z');//随机数
|
503
|
+
for (let i = 0; i < codeLength; i++) {
|
504
|
+
//循环操作
|
505
|
+
let index = Math.floor(Math.random() * 36);//取得随机数的索引(0~35)
|
506
|
+
code += random[index];//根据索引取得随机数加到code上
|
507
|
+
}
|
508
|
+
this.checkCode = code;//把code值赋给验证码
|
509
|
+
},
|
510
|
+
|
511
|
+
async depPromptConfirm () {
|
512
|
+
this.depPromptShow = false
|
513
|
+
return this.$goto('home-page', {functions: this.$login.f,config: this.config})
|
514
|
+
},
|
515
|
+
|
516
|
+
depPromptCancel () {
|
517
|
+
this.depPromptShow = false
|
518
|
+
this.createCode()
|
519
|
+
this.picLyanzhengma = ''
|
520
|
+
this.model.ename = ''
|
521
|
+
this.model.password = ''
|
522
|
+
this.login = false
|
523
|
+
$('form').fadeIn(500)
|
524
|
+
},
|
525
|
+
delCookie() {
|
526
|
+
let cookies = document.cookie.split(";");
|
527
|
+
console.log("点击触发了")
|
528
|
+
for (let i = 0; i < cookies.length; i++) {
|
529
|
+
let cookie = cookies[i];
|
530
|
+
let eqPos = cookie.indexOf("=");
|
531
|
+
let name = eqPos > -1 ? cookie.substr(0, eqPos) : cookie;
|
532
|
+
document.cookie =
|
533
|
+
name + "=;expires=Thu, 01 Jan 1970 00:00:00 GMT; path=/";
|
534
|
+
}
|
535
|
+
if (cookies.length > 0) {
|
536
|
+
for (let i = 0; i < cookies.length; i++) {
|
537
|
+
let cookie = cookies[i];
|
538
|
+
let eqPos = cookie.indexOf("=");
|
539
|
+
let name = eqPos > -1 ? cookie.substr(0, eqPos) : cookie;
|
540
|
+
let domain = location.host.substr(location.host.indexOf("."));
|
541
|
+
document.cookie =
|
542
|
+
name +
|
543
|
+
"=;expires=Thu, 01 Jan 1970 00:00:00 GMT; path=/; domain=" +
|
544
|
+
domain;
|
545
|
+
}
|
546
|
+
}
|
547
|
+
localStorage.clear()
|
548
|
+
sessionStorage.clear()
|
549
|
+
window.location.reload()
|
550
|
+
}
|
551
|
+
|
552
|
+
},
|
553
|
+
watch: {
|
554
|
+
'modifyPwShow' (val){
|
555
|
+
if (!val) {
|
556
|
+
window.location.reload()
|
557
|
+
}
|
558
|
+
}
|
559
|
+
}
|
560
|
+
}
|
561
|
+
</script>
|
562
|
+
|
563
|
+
<style>
|
564
|
+
.my_button_search{width: 100px; height: 25px;position: relative; padding-left:2px;top: 0px;line-height: 25px; background:rgba(0,0,0,0); border-radius: 4px; border:none; font-family: PingFang; font-size: 15px}
|
565
|
+
.my_button_search:hover img{ filter: opacity(0.8);}
|
566
|
+
</style>
|
@@ -22,10 +22,10 @@
|
|
22
22
|
'has-success': !$v.newpassword.required && !$v.newpassword.numbersAndLetter8to16&&!$v.newpassword.minlength && !$v.newpassword.chinesePassword}">
|
23
23
|
<label for="newpassword" class="col-sm-4 col-sm-offset-1 control-label">新的密码: </label>
|
24
24
|
<div class="col-sm-4">
|
25
|
-
<input type="password" v-model="deliver.newpassword" class="form-control" id="newpassword" v-validate:newpassword='{required:true, numbersAndLetter8to16: true, minlength:
|
25
|
+
<input type="password" v-model="deliver.newpassword" class="form-control" id="newpassword" v-validate:newpassword='{required:true, numbersAndLetter8to16: true, minlength: 8,chinesePassword: true}'>
|
26
26
|
<span class="glyphicon glyphicon-ok form-control-feedback" v-if="!$v.newpassword.required && !$v.newpassword.minlength && !($v.newpassword.numbersAndLetter8to16 && !($v.newpassword.required)) && !($v.newpassword.chinesePassword) "></span>
|
27
27
|
<span v-if="$v.newpassword.required">不能为空</span>
|
28
|
-
<span v-if="($v.newpassword.numbersAndLetter8to16||$v.newpassword.minlength) && !($v.newpassword.required&&$v.newpassword.minlength)">密码必须是8~16
|
28
|
+
<span v-if="($v.newpassword.numbersAndLetter8to16||$v.newpassword.minlength) && !($v.newpassword.required&&$v.newpassword.minlength)">密码必须是8~16位数字与大小字母外加特殊字符的组合,并且不能出现类似'123','abc'等连贯数字或者字母</span>
|
29
29
|
<span v-if="$v.newpassword.chinesePassword">密码不能包含中文</span>
|
30
30
|
</div>
|
31
31
|
</div>
|
@@ -11,5 +11,5 @@ Vue.validator('chinesePassword', function (val) {
|
|
11
11
|
});
|
12
12
|
// 潜能要求8~16位数字字母组合;
|
13
13
|
Vue.validator('numbersAndLetter8to16', function (val) {
|
14
|
-
return /^(
|
14
|
+
return /^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)(?!.*(.)(\1)+)(?!.*(123|321|abc|cba))[a-zA-Z\d!@#$%^&*()_+-=<>?]{8,16}$/.test(val)
|
15
15
|
});
|