Ship site UI checklist, move admin to /mstcontroller, and add safe taxonomy label migration.
Deploy edu.mstaut.ir / deploy (push) Has been cancelled
Deploy edu.mstaut.ir / deploy (push) Has been cancelled
Production already has migrations through 008; 009 only updates four seed labels by id. Faculty sync remains upsert-by-email/name and does not wipe curated data. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
3eea1c35a6
commit
2b0db26a93
171 files changed
+1477
-807
No files matched your search
@@ -50,31 +50,31 @@ const publicPages = [
|
||||
];
|
||||
|
||||
const adminPages = [
|
||||
{ id: "20-admin-login", url: "/admin/login", title: "ورود ادمین (/admin/login)", login: false },
|
||||
{ id: "21-admin-dashboard", url: "/admin", title: "داشبورد ادمین (/admin)", login: true },
|
||||
{ id: "22-admin-courses", url: "/admin/courses", title: "لیست دورهها (/admin/courses)", login: true },
|
||||
{ id: "20-admin-login", url: "/mstcontroller/login", title: "ورود ادمین (/mstcontroller/login)", login: false },
|
||||
{ id: "21-admin-dashboard", url: "/mstcontroller", title: "داشبورد ادمین (/mstcontroller)", login: true },
|
||||
{ id: "22-admin-courses", url: "/mstcontroller/courses", title: "لیست دورهها (/mstcontroller/courses)", login: true },
|
||||
{
|
||||
id: "23-admin-course-new",
|
||||
url: "/admin/courses/new",
|
||||
title: "ایجاد دوره — فیلد آپلود تصویر (/admin/courses/new)",
|
||||
url: "/mstcontroller/courses/new",
|
||||
title: "ایجاد دوره — فیلد آپلود تصویر (/mstcontroller/courses/new)",
|
||||
login: true,
|
||||
},
|
||||
{
|
||||
id: "24-admin-articles",
|
||||
url: "/admin/articles",
|
||||
title: "لیست مقالات (/admin/articles)",
|
||||
url: "/mstcontroller/articles",
|
||||
title: "لیست مقالات (/mstcontroller/articles)",
|
||||
login: true,
|
||||
},
|
||||
{
|
||||
id: "25-admin-articles-new",
|
||||
url: "/admin/articles/new",
|
||||
title: "ایجاد مقاله — فیلد آپلود (/admin/articles/new)",
|
||||
url: "/mstcontroller/articles/new",
|
||||
title: "ایجاد مقاله — فیلد آپلود (/mstcontroller/articles/new)",
|
||||
login: true,
|
||||
},
|
||||
{
|
||||
id: "26-admin-registrations",
|
||||
url: "/admin/registrations",
|
||||
title: "ثبتنامها (/admin/registrations)",
|
||||
url: "/mstcontroller/registrations",
|
||||
title: "ثبتنامها (/mstcontroller/registrations)",
|
||||
login: true,
|
||||
},
|
||||
];
|
||||
@@ -134,7 +134,7 @@ async function loginAdmin(page, context) {
|
||||
if (!res.ok()) {
|
||||
throw new Error(`admin login API ${res.status()}: ${await res.text()}`);
|
||||
}
|
||||
await page.goto(new URL("/admin", BASE).toString(), {
|
||||
await page.goto(new URL("/mstcontroller", BASE).toString(), {
|
||||
waitUntil: "domcontentloaded",
|
||||
timeout: 60000,
|
||||
});
|
||||
@@ -161,12 +161,12 @@ for (const item of adminPages) {
|
||||
if (item.login && !loggedIn) {
|
||||
try {
|
||||
const after = await loginAdmin(page, context);
|
||||
loggedIn = after.includes("/admin") && !after.includes("/login");
|
||||
loggedIn = after.includes("/mstcontroller") && !after.includes("/login");
|
||||
if (!loggedIn) {
|
||||
report.push({
|
||||
id: "login-blocker",
|
||||
title: "ورود ادمین",
|
||||
url: "/admin/login",
|
||||
url: "/mstcontroller/login",
|
||||
finalUrl: after,
|
||||
status: "blocked",
|
||||
note: "لاگین ادمین موفق نشد؛ صفحات محافظتشده اسکرین نشدند. احتمالاً cookie Secure روی http یا رمز اشتباه.",
|
||||
@@ -178,7 +178,7 @@ for (const item of adminPages) {
|
||||
report.push({
|
||||
id: "login-blocker",
|
||||
title: "ورود ادمین",
|
||||
url: "/admin/login",
|
||||
url: "/mstcontroller/login",
|
||||
finalUrl: "",
|
||||
status: "blocked",
|
||||
note: err instanceof Error ? err.message : String(err),
|
||||
|
||||
Reference in new issue
Block a user