zmdms-webui 2.8.3 → 2.8.5
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.
|
@@ -8,7 +8,7 @@ import Input from '../input/input.js';
|
|
|
8
8
|
import ButtonCom from '../button/button.js';
|
|
9
9
|
import ModalComponent from '../modal/modal.js';
|
|
10
10
|
|
|
11
|
-
var countDownMaxTime =
|
|
11
|
+
var countDownMaxTime = 60;
|
|
12
12
|
var ForgetPassword = function (_a) {
|
|
13
13
|
var checkUserPhone = _a.checkUserPhone, sendCode = _a.sendCode, submitRequest = _a.submitRequest, open = _a.open, setOpen = _a.setOpen;
|
|
14
14
|
var form = MemoForm.useForm()[0];
|
|
@@ -36,7 +36,8 @@ var ForgetPassword = function (_a) {
|
|
|
36
36
|
checkUserPhone({
|
|
37
37
|
account: account,
|
|
38
38
|
phone: phone,
|
|
39
|
-
})
|
|
39
|
+
})
|
|
40
|
+
.then(function () {
|
|
40
41
|
// 发送验证码
|
|
41
42
|
sendCode({
|
|
42
43
|
phone: phone,
|
|
@@ -61,6 +62,11 @@ var ForgetPassword = function (_a) {
|
|
|
61
62
|
}, (countDown - 1) * 1000);
|
|
62
63
|
myMessage.warning(((_b = (_a = err === null || err === void 0 ? void 0 : err.response) === null || _a === void 0 ? void 0 : _a.data) === null || _b === void 0 ? void 0 : _b.msg) || "验证码发送失败!");
|
|
63
64
|
});
|
|
65
|
+
})
|
|
66
|
+
.catch(function () {
|
|
67
|
+
setTimeout(function () {
|
|
68
|
+
resolve(1);
|
|
69
|
+
}, (countDown - 1) * 1000);
|
|
64
70
|
});
|
|
65
71
|
});
|
|
66
72
|
}, [form, checkUserPhone, setCountDown, countDown, sendCode]);
|
|
@@ -95,12 +101,11 @@ var ForgetPassword = function (_a) {
|
|
|
95
101
|
label: "短信验证码",
|
|
96
102
|
width: "halfAll",
|
|
97
103
|
rules: [{ required: true, message: "请输入短信验证码" }],
|
|
98
|
-
nextNode: (jsxs(ButtonCom, __assign({ style: {
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
}, type: "primary", onClick: onSendCode }, { children: ["\u53D1\u9001\u9A8C\u8BC1\u7801", countDown < countDownMaxTime ? "(".concat(countDown, "s)") : ""] }))),
|
|
104
|
+
nextNode: (jsxs(ButtonCom, __assign({ type: "primary", style: {
|
|
105
|
+
marginLeft: "10px",
|
|
106
|
+
}, onClick: onSendCode }, { children: ["\u53D1\u9001\u9A8C\u8BC1\u7801", countDown < countDownMaxTime ? "(".concat(countDown, "s)") : ""] }))),
|
|
102
107
|
render: function (itemProps) {
|
|
103
|
-
return jsx(Input, { placeholder: "\u8BF7\u8F93\u5165\u77ED\u4FE1\u9A8C\u8BC1\u7801" });
|
|
108
|
+
return jsx(Input, { autoComplete: "off", placeholder: "\u8BF7\u8F93\u5165\u77ED\u4FE1\u9A8C\u8BC1\u7801" });
|
|
104
109
|
},
|
|
105
110
|
},
|
|
106
111
|
{
|
|
@@ -132,7 +137,7 @@ var ForgetPassword = function (_a) {
|
|
|
132
137
|
color: "#794808",
|
|
133
138
|
} }, { children: "\u5BC6\u7801\u5FC5\u987B\u5305\u542B\u5927\u5C0F\u5199\u5B57\u6BCD\u3001\u6570\u5B57\u3001\u7279\u6B8A\u5B57\u7B26\u4E14\u6700\u5C0F\u957F\u5EA6\u4E3A8\uFF0C\u4E14\u4E0D\u80FD\u51FA\u73B0\u8FDE\u7EED\u6570\u5B57\u6216\u5B57\u7B26\uFF0C\u4E0D\u80FD\u51FA\u73B0\u76F8\u540C\u5B57\u7B26\uFF0C\u4E14\u7981\u6B62\u4F7F\u7528\u7528\u6237\u8D26\u53F7\u4F5C\u4E3A\u5BC6\u7801" }))),
|
|
134
139
|
render: function (itemProps) {
|
|
135
|
-
return jsx(Input.Password, { placeholder: "\u8BF7\u8F93\u5165\u65B0\u5BC6\u7801" });
|
|
140
|
+
return (jsx(Input.Password, { autoComplete: "off", placeholder: "\u8BF7\u8F93\u5165\u65B0\u5BC6\u7801" }));
|
|
136
141
|
},
|
|
137
142
|
},
|
|
138
143
|
{
|
|
@@ -154,7 +159,7 @@ var ForgetPassword = function (_a) {
|
|
|
154
159
|
},
|
|
155
160
|
],
|
|
156
161
|
render: function (itemProps) {
|
|
157
|
-
return jsx(Input.Password, { placeholder: "\u786E\u8BA4\u65B0\u5BC6\u7801" });
|
|
162
|
+
return jsx(Input.Password, { autoComplete: "off", placeholder: "\u786E\u8BA4\u65B0\u5BC6\u7801" });
|
|
158
163
|
},
|
|
159
164
|
},
|
|
160
165
|
];
|