mirror of
https://gitee.com/log4j/pig-ui.git
synced 2024-12-23 05:40:20 +08:00
🐛 Fixing a bug. 用户管理用户名校验
This commit is contained in:
parent
a50bdb7688
commit
764c499ad1
@ -96,7 +96,7 @@ export const registerUser = (userInfo: object) => {
|
||||
};
|
||||
|
||||
export function validateUsername(rule: any, value: any, callback: any, isEdit: boolean) {
|
||||
const flag = new RegExp(/^([a-z\u4e00-\u9fa5\d]+?)$/).test(value);
|
||||
const flag = new RegExp(/^([a-z\d]+?)$/).test(value);
|
||||
if (!flag) {
|
||||
callback(new Error('用户名支持小写英文、数字、中文'));
|
||||
}
|
||||
|
@ -171,7 +171,7 @@ const onSubmit = () => {
|
||||
const getTenantData = (id: string) => {
|
||||
// 获取部门数据
|
||||
getObj(id).then((res: any) => {
|
||||
Object.assign(form, res.data[0]);
|
||||
Object.assign(form, res.data);
|
||||
});
|
||||
};
|
||||
|
||||
|
@ -86,7 +86,7 @@
|
||||
:title="$t('appuser.importUserTip')"
|
||||
@refreshDataList="getDataList"
|
||||
ref="excelUploadRef"
|
||||
temp-url="/admin/sys-file/local/file/user.xlsx"
|
||||
temp-url="/admin/sys-file/local/file/appuser.xlsx"
|
||||
url="/admin/appuser/import"
|
||||
/>
|
||||
</div>
|
||||
|
Loading…
Reference in New Issue
Block a user