system-clients 3.2.1-5 → 3.2.1-8

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": "system-clients",
3
- "version": "3.2.1-5",
3
+ "version": "3.2.1-8",
4
4
  "description": "系统基础框架",
5
5
  "main": "src/index.js",
6
6
  "directories": {
@@ -122,19 +122,27 @@
122
122
 
123
123
  let saveGen = function *(self) {
124
124
  try {
125
- yield self.$login.login(self.model.ename, self.model.password)
126
- yield self.$appdata.load()
125
+ if(self.$login){
126
+ yield self.$login.login(self.model.ename, self.model.password)
127
+ }
128
+ if(self.$appdata){
129
+ yield self.$appdata.load()
127
130
 
131
+ }
128
132
  if (Vue.$heatCompatibility) {
129
133
  try {
130
- yield self.$loginHeat.login(self.model.ename, self.model.password)
131
- yield self.$appdataHeat.load()
134
+ if(self.$loginHeat){
135
+ yield self.$loginHeat.login(self.model.ename, self.model.password)
136
+ }
137
+ if(self.$appdataHeat){
138
+ yield self.$appdataHeat.load()
139
+ }
132
140
  } catch (e) {
133
141
  console.log('热力系统登陆失败!')
134
142
  }
135
143
  }
136
-
137
- yield self.$getConfig(self, 'Login')
144
+ //吴小平
145
+ // yield self.$getConfig(self, 'Login')
138
146
  console.log('登录配置', self.config)
139
147
  if (self.config.isMac) {
140
148
  // 获取该登录人分公司下的mac配置
@@ -167,14 +175,18 @@
167
175
  }
168
176
  }
169
177
  // 弱口令验证
170
- if (self.config.weakPassword && !(/^(?:(?=.*[a-zA-Z])(?=.*[0-9])(?=.*[^A-Za-z0-9])).*$/.test(self.model.password))) {
178
+ //跳转过来的不进行验证
179
+ if ((!self.otherLogin) && self.config.weakPassword && !(/^(?:(?=.*[a-zA-Z])(?=.*[0-9])(?=.*[^A-Za-z0-9])).*$/.test(self.model.password))) {
171
180
  self.$showMessage('登录系统: 此账户的密码过于简单,请修改密码后重新登陆!!!', ['confirm']).then((res) => {
172
181
  self.modifyPwShow = true
173
182
  })
174
- } else if (self.config.depPrompt) {
183
+ } else if ((!self.otherLogin) && self.config.depPrompt) {
175
184
  self.depPromptShow = true
176
185
  } else {
177
186
  self.$goto('home-page', {functions: self.$login.f})
187
+ if(this.otherLogin){
188
+ window.location.search=""
189
+ }
178
190
  if (self.$login) {
179
191
  console.log('登录信息', self.$login.f)
180
192
  global.login=self.$login.f
@@ -225,15 +237,18 @@
225
237
  $('#login-button').click(function (event) {
226
238
  event.preventDefault()
227
239
  $('form').fadeOut(500)
228
- }),
229
- this.createCode()
240
+ })
230
241
  if (window.location.search && window.location.search.indexOf('af_key') !== -1&& window.location.search.indexOf('af_n') !== -1) {
231
242
  const subUrl = window.location.search.replace('?af_key=','').split('&af_n=')
232
243
  console.log(subUrl)
233
244
  this.model.ename = window.atob(subUrl[0])
234
245
  this.model.password = window.atob(subUrl[1])
235
246
  console.log('this.model.ename',this.model.ename)
247
+ this.otherLogin = true
236
248
  this.confirm()
249
+ }else{
250
+ //跳转不需要验证码
251
+ this.createCode()
237
252
  }
238
253
  },
239
254
  data () {
@@ -254,6 +269,7 @@
254
269
  title: '燃气客服系统',
255
270
  distanceLogin: false
256
271
  },
272
+ otherLogin:false,
257
273
  login: false,
258
274
  depPromptShow: false,
259
275
  model: {},
@@ -305,7 +321,8 @@
305
321
  this.login = true
306
322
  // let gen = saveGen(this)
307
323
  // return co(gen)
308
- if(this.$login.Verification){
324
+ if((!this.otherLogin) && this.$login && this.$login.Verification){
325
+ console.log('跳转过来的不走验证')
309
326
  if(this.picLyanzhengma == '') {
310
327
  this.$showMessage("请输入验证码!").then(()=>{
311
328
  this.login = false