wbc
2 天以前 52dbfd767f2485a1d615c5d9db50d648a1d8214a
H5/Js/UserLogin.js
@@ -5,19 +5,25 @@
            isLoading: false,
            phone: '',
            passwd: '',
            rememberPwd: false,
            show: false,
            show2: false,
        }
    },
    mounted() {
        var that = this;
        if (typeof (Cookies.get('loginAccount')) == "undefined") { }
        if (typeof (Cookies.get('loginAccount')) == "undefined") {
        }
        else {
            that.phone = Cookies.get('loginAccount');
          //  that.passwd = Cookies.get('passwd');
            const rememberPwdStr = Cookies.get('rememberPwd');
            that.rememberPwd = rememberPwdStr ? JSON.parse(rememberPwdStr.toLowerCase()) : false;
            if (that.rememberPwd) {
                that.passwd = Cookies.get('passwd');
            }
        }
       // that.phone = "admin";
      //  that.passwd = "123456";
        //that.phone = "admin";
        //that.passwd = "123456";
    },
    methods: {
        onSubmit(name) {
@@ -25,7 +31,9 @@
            that._userLogin();
        },
        _userLogin() {
            var that = this;
            console.log(that.rememberPwd)
            that.isLoading = true;
            that.AxiosHttp("post", 'login/login', {
                userID: that.phone,
@@ -37,9 +45,19 @@
                        var _userGuid = json.data.tbBillList.guid;
                        var _userAccount = json.data.tbBillList.account;
                        var _userName = json.data.tbBillList.userName;
                        var _orgId = json.data.tbBillList.orgId;
                        var _orgNo = json.data.tbBillList.orgNo;
                        var _orgName = json.data.tbBillList.orgName;
                        Cookies.set('loginGuid', _userGuid);
                        Cookies.set('loginAccount', _userAccount);
                        Cookies.set('loginName', _userName);
                        Cookies.set('orgId', _orgId);
                        Cookies.set('orgNo', _orgNo);
                        Cookies.set('orgName', _orgName);
                        Cookies.set('passwd', that.passwd);
                        Cookies.set('rememberPwd', that.rememberPwd);
                        console.log(json.data.tbBillList);
                        console.log(Cookies);
                        window.location.href = ("/H5/Default.aspx?userGuid=" + _userGuid + "&userAccount=" + _userAccount);
                    }
                    else {