- {t("activities", { count: total })} -
- {activities.length === 0 ? ( -| {t("colWhen")} | -{t("colStaff")} | -{t("colAction")} | -{t("colDescription")} | -{t("colTarget")} | -{t("colIp")} | -
|---|---|---|---|---|---|
| - {fromDate(a.createdAt)} - | -- {t("staffWithId", { - id: Number(a.userId), - name: nameById.get(Number(a.userId)) ?? "unknown", - })} - | -- - {a.action} - - | -{a.description} | -- {a.targetType && a.targetId ? ( - - {a.targetType === "user" ? t("userPrefix") : ""}# - {String(a.targetId)} - - ) : ( - - — - - )} - | -- {a.ipAddress || "—"} - | -
- {t("pagination", { page, pages, total })} - {page < pages ? ( - <> - {" · "} - - {t("next")} → - - > - ) : null} -
- +- You can view settings but need edit permission to change them. -
+{t("viewOnly")}
)} ); diff --git a/src/app/admin/settings/page.tsx b/src/app/admin/settings/page.tsx index d311746b..b52bb35f 100644 --- a/src/app/admin/settings/page.tsx +++ b/src/app/admin/settings/page.tsx @@ -1,3 +1,4 @@ +import { getTranslations } from "next-intl/server"; import { redirect } from "next/navigation"; import { canAccess, getAdminContext, PERMS } from "@/lib/permissions"; import { prisma } from "@/lib/prisma"; @@ -18,6 +19,7 @@ export default async function AdminSettings() { PERMS.SETTINGS_EDIT, session.user.rank, ); + const t = await getTranslations("pages.admin.settings"); let settings: Awaited