A1-A7 收口OA统一审批中心与企微基础设施路线

这个提交包含在:
2026-05-09 15:28:39 +08:00
父节点 37c717110b
当前提交 8110e7df9c
共修改 10 个文件,包含 103 行新增和 32 行删除
+4 -4
查看文件
@@ -1,6 +1,6 @@
export const MAIN_NAV_ORDER = ["/portal", "/team", "/leave-requests", "/reimbursements", "/assets", "/weekly-reports", "/todos", "/announcements", "/projects"];
export const MAIN_NAV_ORDER = ["/portal", "/workflow/tasks", "/team", "/leave-requests", "/reimbursements", "/assets", "/weekly-reports", "/todos", "/announcements", "/projects"];
export const ADMIN_NAV_ORDER = ["/system/workspace", "/people", "/organization", "/system/workflow-definitions", "/system/settings", "/system/feature-flags", "/audit-logs"];
export const BACKUP_NAV_ORDER = ["/attendance", "/workflow/tasks", "/contracts-registry", "/purchase-requests", "/travel-requests", "/budgets", "/payment-batches", "/ap-operations", "/invoice-pool", "/inventory-checks", "/system/cutover", "/system/integrations/erp", "/dashboard", "/settings/profile"];
export const BACKUP_NAV_ORDER = ["/attendance", "/contracts-registry", "/purchase-requests", "/travel-requests", "/budgets", "/payment-batches", "/ap-operations", "/invoice-pool", "/inventory-checks", "/system/cutover", "/system/integrations/erp", "/dashboard", "/settings/profile"];
const PAGE_TITLES: Array<{ path: string; title: string; group: string }> = [
{ path: "/portal", title: "工作台", group: "工作台" },
@@ -22,8 +22,8 @@ const PAGE_TITLES: Array<{ path: string; title: string; group: string }> = [
{ path: "/reimbursements", title: "报销", group: "主导航" },
{ path: "/leave-requests", title: "请假", group: "主导航" },
{ path: "/assets", title: "资产", group: "主导航" },
{ path: "/workflow/tasks/", title: "审批详情", group: "备用模块" },
{ path: "/workflow/tasks", title: "审批待办", group: "备用模块" },
{ path: "/workflow/tasks/", title: "审批详情", group: "主导航" },
{ path: "/workflow/tasks", title: "审批待办", group: "主导航" },
{ path: "/mobile/assets/scan", title: "移动资产扫描", group: "移动工作台" },
{ path: "/mobile/approvals", title: "移动审批", group: "移动工作台" },
{ path: "/mobile/capture", title: "移动拍照上传", group: "移动工作台" },
@@ -19,10 +19,24 @@ async function login(page: Page, user: E2EUser) {
await page.goto("/login");
const credentialForm = page.locator("#login-identifier, input[autocomplete='username'], input[placeholder*='邮箱']").first();
const accountLoginButton = page.getByRole("button", { name: "使用账号密码登录" });
const credentialFormVisible = await credentialForm.isVisible({ timeout: 1_000 }).catch(() => false);
const accountLoginVisible = await accountLoginButton.isVisible().catch(() => false);
if (!credentialFormVisible && accountLoginVisible) {
await accountLoginButton.click({ timeout: 5_000 });
for (let attempt = 0; attempt < 3; attempt += 1) {
const credentialFormVisible = await credentialForm.isVisible({ timeout: 1_000 }).catch(() => false);
if (credentialFormVisible) {
break;
}
const accountLoginVisible = await accountLoginButton.isVisible({ timeout: 3_000 }).catch(() => false);
if (!accountLoginVisible) {
break;
}
try {
await accountLoginButton.click({ timeout: 5_000 });
} catch (error) {
if (attempt >= 2) {
throw error;
}
}
}
const identifierByTestId = page.getByTestId("login-identifier");