king
2023-06-30 0519dcda8b6fb2914987f8d4d58e1d14bcf98dc3
src/views/login/index.jsx
@@ -1,5 +1,5 @@
import React, { Component } from 'react'
import { message, Modal, notification } from 'antd'
import { message, Modal } from 'antd'
import md5 from 'md5'
import moment from 'moment'
@@ -311,27 +311,6 @@
      }
    }
    if (sessionStorage.getItem('loginError')) {
      try {
        let res = JSON.parse(sessionStorage.getItem('loginError'))
        console.info(res.url)
        console.info(res.request)
        console.info(res.response)
        let result = JSON.parse(res.response)
        notification.warning({
          top: 92,
          message: result.message,
          duration: 5
        })
      } catch (e) {}
      setTimeout(() => {
        sessionStorage.removeItem('loginError')
      }, 2000)
    }
    const _addressUrl = _href + 'queryAddress'
    if (localStorage.getItem(_addressUrl) === 'true') {
@@ -509,7 +488,30 @@
            authError: res.message
          })
        }
      }, () => {
      }, (error) => {
        if (error && error.ErrCode === 'LoginError') {
          let param = {
            func: 's_visitor_login',
            timestamp: moment().format('YYYY-MM-DD HH:mm:ss'),
            SessionUid: _id,
            TypeCharOne: 'pc',
            appkey: '202004041613277377A6A2456D34A4948AE84'
          }
          param.LText = md5(window.btoa(_id + param.timestamp))
          param.secretkey = md5(param.LText + 'mingke' + param.timestamp)
          let params = {
            url: _rduri.replace('dostars', 'dologon'),
            method: 'post',
            data: JSON.stringify(param)
          }
          Api.directRequest(params)
          return
        }
        if (index === -1 || index > 10) {
          this.setState({
            auth: false,