生产管理系统 - 角色管理、员工管理主页面联调

This commit is contained in:
2025-11-04 17:01:42 +08:00
parent fffd37a0a9
commit 1058767515
13 changed files with 4426 additions and 1428 deletions

View File

@@ -103,12 +103,8 @@ export default function EmployeeManagementPage() {
} catch (error) {
console.error('Failed to load employees:', error);
toast.error('加载员工数据失败');
// 如果API失败使用localStorage中的数据
const data = localStorage.getItem('smart_agriculture_employees');
if (data) {
setEmployees(JSON.parse(data));
}
setEmployees([]);
} finally {
setLoading(false);
}