用户密码支持自定义配置规则

This commit is contained in:
RuoYi
2020-08-03 11:40:51 +08:00
parent 3d2d88287a
commit 8bf5140a72
7 changed files with 58 additions and 5 deletions

View File

@ -221,7 +221,9 @@
});
function submitHandler() {
if ($.validate.form()) {
var chrtype = [[${@config.getKey('sys.account.chrtype')}]];
var password = $("#password").val();
if ($.validate.form() && checkpwd(chrtype, password)) {
var data = $("#form-user-add").serializeArray();
var status = $("input[id='status']").is(':checked') == true ? 0 : 1;
var roleIds = $.form.selectCheckeds("role");
@ -233,7 +235,7 @@
}
}
/*用户管理-新增-选择部门树*/
/* 用户管理-新增-选择部门树 */
function selectDeptTree() {
var treeId = $("#treeId").val();
var deptId = $.common.isEmpty(treeId) ? "100" : $("#treeId").val();

View File

@ -200,7 +200,7 @@
}
}
/*用户管理-修改-选择部门树*/
/* 用户管理-修改-选择部门树 */
function selectDeptTree() {
var deptId = $.common.isEmpty($("#treeId").val()) ? "100" : $("#treeId").val();
var url = ctx + "system/dept/selectDeptTree/" + deptId;

View File

@ -283,7 +283,9 @@
});
function submitChangPassword () {
if ($.validate.form("form-user-resetPwd")) {
var chrtype = [[${@config.getKey('sys.account.chrtype')}]];
var password = $("#newPassword").val();
if ($.validate.form("form-user-resetPwd") && checkpwd(chrtype, password)) {
$.operate.saveModal(ctx + "system/user/profile/resetPwd", $('#form-user-resetPwd').serialize());
}
}

View File

@ -82,7 +82,9 @@
});
function submitHandler() {
if ($.validate.form()) {
var chrtype = [[${@config.getKey('sys.account.chrtype')}]];
var password = $("#newPassword").val();
if ($.validate.form() && checkpwd(chrtype, password)) {
$.operate.save(ctx + "system/user/profile/resetPwd", $('#form-user-resetPwd').serialize());
}
}