Auto Submit

dev_local_v9_beifangminzu
autosubmit 2 years ago
parent 50402f6b21
commit be86b4d707

@ -26,7 +26,7 @@
display: block !important;
}
</style><script>if(document.domain !== "www.educoder.net") document.title = '';</script>
<script src="/react/build/umi.cb54c35c.js"></script>
<script src="/react/build/umi.38e5ad8f.js"></script>
<script src="/react/build/js/public.js"></script>
</body>
</html>

@ -231,7 +231,7 @@ var LoginPopComponents = function LoginPopComponents(_ref) {
var onFinish = /*#__PURE__*/function () {
var _ref2 = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee() {
var _res2;
var res, iv, ciphertext, _res, _res3, from;
var res, newData, iv, ciphertext, _res, _res3, from;
return regeneratorRuntime_default()().wrap(function _callee$(_context) {
while (1) switch (_context.prev = _context.next) {
case 0:
@ -248,7 +248,7 @@ var LoginPopComponents = function LoginPopComponents(_ref) {
}, form.getFieldValue()));
case 5:
res = _context.sent;
_context.next = 20;
_context.next = 21;
break;
case 8:
if (!(accountInfo !== null && accountInfo !== void 0 && accountInfo.user_token)) {
@ -261,26 +261,27 @@ var LoginPopComponents = function LoginPopComponents(_ref) {
}, form.getFieldsValue()));
case 11:
res = _context.sent;
_context.next = 20;
_context.next = 21;
break;
case 14:
newData = JSON.parse(JSON.stringify(accountInfo || {}));
iv = _crypto_js_4_1_1_crypto_js_default().enc.Utf8.parse("5183666c72eec9e4");
ciphertext = _crypto_js_4_1_1_crypto_js_default().AES.encrypt(accountInfo.password || "", iv, {
ciphertext = _crypto_js_4_1_1_crypto_js_default().AES.encrypt(newData.password || "", iv, {
iv: iv,
mode: (_crypto_js_4_1_1_crypto_js_default()).mode.CBC
});
accountInfo.password = ciphertext.toString();
_context.next = 19;
return (0,service_user/* LoginIn */.Es)(objectSpread2_default()(objectSpread2_default()({}, accountInfo), form.getFieldValue()));
case 19:
res = _context.sent;
newData.password = ciphertext.toString();
_context.next = 20;
return (0,service_user/* LoginIn */.Es)(objectSpread2_default()(objectSpread2_default()({}, newData), form.getFieldValue()));
case 20:
res = _context.sent;
case 21:
if (!res.status) {
_context.next = 27;
_context.next = 28;
break;
}
if (!(res.status === -4)) {
_context.next = 25;
_context.next = 26;
break;
}
dispatch({
@ -298,10 +299,10 @@ var LoginPopComponents = function LoginPopComponents(_ref) {
}
});
return _context.abrupt("return");
case 25:
case 26:
setErrorValue((_res = res) === null || _res === void 0 ? void 0 : _res.message);
return _context.abrupt("return");
case 27:
case 28:
setOpenModal(false);
if ((_res2 = res) !== null && _res2 !== void 0 && _res2.show) {
localStorage.setItem('extension-modal', 'exist');
@ -310,35 +311,35 @@ var LoginPopComponents = function LoginPopComponents(_ref) {
localStorage.removeItem('extension-modal');
}
if (!(location.pathname === '/user/login' || location.pathname === '/login')) {
_context.next = 44;
_context.next = 45;
break;
}
from = searchParams.get("form") || searchParams.get("back_url");
if (!from) {
_context.next = 35;
_context.next = 36;
break;
}
window.location.href = decodeURIComponent(from);
_context.next = 42;
_context.next = 43;
break;
case 35:
case 36:
if (!(!password.test(accountInfo.password) && !(accountInfo !== null && accountInfo !== void 0 && accountInfo.code))) {
_context.next = 40;
_context.next = 41;
break;
}
message/* default */.ZP.info('系统检测您的密码强度过低,请及时修改');
window.location.href = '/account/secure';
_context.next = 42;
_context.next = 43;
break;
case 40:
case 41:
window.location.href = "/";
return _context.abrupt("return");
case 42:
_context.next = 52;
case 43:
_context.next = 53;
break;
case 44:
case 45:
if (!(!password.test(accountInfo.password) && !(accountInfo !== null && accountInfo !== void 0 && accountInfo.code))) {
_context.next = 50;
_context.next = 51;
break;
}
message/* default */.ZP.info('系统检测您的密码强度过低,请及时修改');
@ -349,14 +350,14 @@ var LoginPopComponents = function LoginPopComponents(_ref) {
showPopLogin: false
}
});
_context.next = 52;
_context.next = 53;
break;
case 50:
case 51:
window.location.reload();
return _context.abrupt("return");
case 52:
form.resetFields();
case 53:
form.resetFields();
case 54:
case "end":
return _context.stop();
}

File diff suppressed because one or more lines are too long
Loading…
Cancel
Save