This commit is contained in:
wangziqi
2026-01-07 16:18:56 +08:00
parent 7c4be0b7b4
commit ea9c94dfeb
13 changed files with 2243 additions and 148 deletions

View File

@@ -185,7 +185,7 @@ const Utils = {
if (this.confirm('确定要退出登录吗?')) {
localStorage.removeItem(STORAGE.TOKEN);
localStorage.removeItem(STORAGE.USER);
window.location.href = 'login.html';
window.location.href = '/login.html';
}
},
@@ -238,9 +238,9 @@ const Utils = {
// 获取角色文本
getRoleText(role) {
const roles = {
admin: '<span class="badge bg-danger">管理员</span>',
staff: '<span class="badge bg-success">工作人员</span>',
customer: '<span class="badge bg-info">客户</span>'
admin: '管理员',
staff: '工作人员',
customer: '客户'
};
return roles[role] || role;
},