-- Ether 测试用户数据
-- 创建时间: 2026-02-14
-- 更新时间: 2026-03-19 (密码已更新为 BCrypt 格式)

-- 管理员用户
-- 用户名: admin
-- 密码: Admin@123
-- 用户ID: 0ee11cf0-c093-4226-8fc9-321d2d31aa11
INSERT INTO auth_user (id, username, password, salt, real_name, status)
VALUES ('0ee11cf0-c093-4226-8fc9-321d2d31aa11', 'admin', '$2a$10$2JRCyrbZANZdGD4sgplVjuIOPvK1P/Be1/4iwXwkUqpbEDo2AHcuC', 'admin', '系统管理员', 'ACTIVE')
ON CONFLICT (username) DO UPDATE SET 
  password = EXCLUDED.password,
  salt = EXCLUDED.salt,
  real_name = EXCLUDED.real_name;

-- 员工测试用户
-- 用户名: worker_user
-- 密码: Worker@123
-- 用户ID: 199883aa-38ab-4349-a894-9ea8af76845f
INSERT INTO auth_user (id, username, password, salt, real_name, phone, status)
VALUES ('199883aa-38ab-4349-a894-9ea8af76845f', 'worker_user', '$2a$10$3/dKkpbWb0z0YpcwGy.wdOMU.ks0C8lAkA7I3d5aUHqLGgtkDJtRW', 'WrkSlT01', '测试员工', '13800000001', 'ACTIVE')
ON CONFLICT (username) DO UPDATE SET 
  password = EXCLUDED.password,
  salt = EXCLUDED.salt,
  real_name = EXCLUDED.real_name,
  phone = EXCLUDED.phone;

-- 查询验证
SELECT id, username, real_name, status FROM auth_user WHERE username IN ('admin', 'worker_user');
