feat(admin): items_base browser and AdminPageShell on core pages
Co-authored-by: Cursor <[email protected]>
This commit is contained in:
1 parent
7138ae4445
commit
98613af875
42 files changed
+2196
-698
No files matched your search
@@ -0,0 +1,115 @@
|
||||
"use server";
|
||||
|
||||
import { revalidatePath } from "next/cache";
|
||||
import { z } from "zod";
|
||||
import { Prisma } from "@/generated/prisma/client";
|
||||
import { PERMS } from "@/lib/permissions";
|
||||
import { prisma } from "@/lib/prisma";
|
||||
import { adminAction } from "@/lib/safe-action";
|
||||
import { ActionError, actionOk } from "@/lib/safe-action-shared";
|
||||
import { rcon } from "@/lib/services/rcon";
|
||||
import { logStaffActivity } from "@/lib/services/staff-activity";
|
||||
|
||||
const ITEMS_BASE_FIELDS = [
|
||||
"publicName",
|
||||
"itemName",
|
||||
"type",
|
||||
"spriteId",
|
||||
"width",
|
||||
"length",
|
||||
"stackHeight",
|
||||
"allowStack",
|
||||
"allowSit",
|
||||
"allowLay",
|
||||
"allowWalk",
|
||||
"allowGift",
|
||||
"allowTrade",
|
||||
"allowRecycle",
|
||||
"allowMarketplaceSell",
|
||||
"allowInventoryStack",
|
||||
"interactionType",
|
||||
"interactionModesCount",
|
||||
"vendingIds",
|
||||
"multiheight",
|
||||
"customparams",
|
||||
"effectIdMale",
|
||||
"effectIdFemale",
|
||||
"clothingOnWalk",
|
||||
] as const;
|
||||
|
||||
const updateSchema = z.object({
|
||||
id: z.coerce.number().int().positive(),
|
||||
fields: z.record(z.string(), z.unknown()),
|
||||
});
|
||||
|
||||
function pickAllowed(
|
||||
fields: Record<string, unknown>,
|
||||
allowed: readonly string[],
|
||||
): Record<string, unknown> {
|
||||
const out: Record<string, unknown> = {};
|
||||
for (const key of allowed) {
|
||||
if (Object.hasOwn(fields, key) && fields[key] !== undefined) {
|
||||
out[key] = fields[key];
|
||||
}
|
||||
}
|
||||
return out;
|
||||
}
|
||||
|
||||
export const updateItemsBase = adminAction(
|
||||
{ permission: PERMS.CATALOG_EDIT, schema: updateSchema },
|
||||
async (ctx) => {
|
||||
const { id, fields } = ctx.data;
|
||||
const safe = pickAllowed(fields, ITEMS_BASE_FIELDS);
|
||||
if (Object.keys(safe).length === 0) {
|
||||
throw new ActionError("No valid fields to update");
|
||||
}
|
||||
|
||||
const existing = await prisma.itemsBase.findUnique({
|
||||
where: { id },
|
||||
select: { id: true },
|
||||
});
|
||||
if (!existing) throw new ActionError("Item not found");
|
||||
|
||||
// Coerce common numeric / decimal fields from form strings.
|
||||
const data: Record<string, unknown> = { ...safe };
|
||||
for (const key of [
|
||||
"spriteId",
|
||||
"width",
|
||||
"length",
|
||||
"allowStack",
|
||||
"allowSit",
|
||||
"allowLay",
|
||||
"allowWalk",
|
||||
"allowGift",
|
||||
"allowTrade",
|
||||
"allowRecycle",
|
||||
"allowMarketplaceSell",
|
||||
"allowInventoryStack",
|
||||
"interactionModesCount",
|
||||
"effectIdMale",
|
||||
"effectIdFemale",
|
||||
]) {
|
||||
if (data[key] !== undefined) data[key] = Number(data[key]);
|
||||
}
|
||||
if (data.stackHeight !== undefined) {
|
||||
data.stackHeight = new Prisma.Decimal(String(data.stackHeight));
|
||||
}
|
||||
|
||||
await prisma.itemsBase.update({
|
||||
where: { id },
|
||||
data: data as Prisma.ItemsBaseUpdateInput,
|
||||
});
|
||||
await rcon.updateCatalog().catch(() => false);
|
||||
await logStaffActivity({
|
||||
staffId: Number(ctx.session.user.id),
|
||||
action: "items_base_update",
|
||||
description: `Updated items_base #${id}`,
|
||||
targetType: "items_base",
|
||||
targetId: id,
|
||||
});
|
||||
revalidatePath("/admin/items");
|
||||
revalidatePath(`/admin/items/${id}`);
|
||||
revalidatePath("/admin/catalog");
|
||||
return actionOk({ id });
|
||||
},
|
||||
);
|
||||
@@ -1,6 +1,8 @@
|
||||
import { Newspaper } from "lucide-react";
|
||||
import Link from "next/link";
|
||||
import { redirect } from "next/navigation";
|
||||
import { getTranslations } from "next-intl/server";
|
||||
import { AdminPageShell } from "@/components/admin/admin-page-shell";
|
||||
import { ArticleCard } from "@/components/admin/article-card";
|
||||
import { StatusCard } from "@/components/admin/dashboard";
|
||||
import { Button } from "@/components/ui/button";
|
||||
@@ -56,17 +58,18 @@ export default async function AdminArticles({
|
||||
: "—";
|
||||
|
||||
return (
|
||||
<main>
|
||||
<div className="flex justify-end mb-6">
|
||||
<AdminPageShell
|
||||
icon={Newspaper}
|
||||
title={t("title")}
|
||||
subtitle={t("subtitle")}
|
||||
actions={
|
||||
<Button variant="default" asChild>
|
||||
<Link href="/admin/articles/new">{t("newArticle")}</Link>
|
||||
</Button>
|
||||
</div>
|
||||
|
||||
}
|
||||
>
|
||||
{error ? (
|
||||
<p className="text-xs text-[var(--admin-error)] dark:text-[var(--admin-error)] mb-4">
|
||||
Error: {error}
|
||||
</p>
|
||||
<p className="text-xs text-[var(--admin-error)] mb-4">Error: {error}</p>
|
||||
) : null}
|
||||
|
||||
<div className="grid grid-cols-[repeat(auto-fit,minmax(180px,1fr))] gap-3.5 mb-6">
|
||||
@@ -83,7 +86,7 @@ export default async function AdminArticles({
|
||||
/>
|
||||
</div>
|
||||
|
||||
<section className="mt-6">
|
||||
<section className="mt-2">
|
||||
<h2 className="admin-section-title">{t("recentArticles")}</h2>
|
||||
{articles.length === 0 ? (
|
||||
<div className="admin-empty">{t("noArticles")}</div>
|
||||
@@ -102,6 +105,6 @@ export default async function AdminArticles({
|
||||
</div>
|
||||
)}
|
||||
</section>
|
||||
</main>
|
||||
</AdminPageShell>
|
||||
);
|
||||
}
|
||||
@@ -1,4 +1,7 @@
|
||||
import { Store } from "lucide-react";
|
||||
import { redirect } from "next/navigation";
|
||||
import { getTranslations } from "next-intl/server";
|
||||
import { AdminPageShell } from "@/components/admin/admin-page-shell";
|
||||
import { CatalogTree } from "@/components/admin/catalog-tree";
|
||||
import { Prisma } from "@/generated/prisma/client";
|
||||
import { calcPagination, parseListParams } from "@/lib/admin-helpers";
|
||||
@@ -23,6 +26,7 @@ export default async function CatalogPagesPage({
|
||||
}
|
||||
|
||||
const canEdit = canAccess(permissions, PERMS.CATALOG_EDIT, session.user.rank);
|
||||
const t = await getTranslations("pages.admin.catalog");
|
||||
|
||||
const params = await searchParams;
|
||||
const sp = new URLSearchParams(params);
|
||||
@@ -200,50 +204,52 @@ export default async function CatalogPagesPage({
|
||||
}
|
||||
|
||||
return (
|
||||
<div className="space-y-6">
|
||||
<div className="flex items-center justify-between">
|
||||
<p className="text-muted-foreground">
|
||||
{totalBcPages} BC pages ({enabledBcPages} enabled) ·{" "}
|
||||
{totalBcItems} items
|
||||
</p>
|
||||
<div className="flex items-center gap-2">
|
||||
<CatalogViewToggle currentView={viewMode} catalogType="bc" />
|
||||
{canEdit && (
|
||||
<CatalogManagerDialog
|
||||
catalogType="bc"
|
||||
canEdit={canEdit}
|
||||
totals={{
|
||||
totalPages: totalBcPages,
|
||||
enabledPages: enabledBcPages,
|
||||
totalItems: totalBcItems,
|
||||
}}
|
||||
initialRoots={bcRootPages.map((p) => ({
|
||||
id: p.id,
|
||||
caption: p.caption,
|
||||
iconImage: p.iconImage,
|
||||
enabled: p.enabled,
|
||||
orderNum: 0,
|
||||
}))}
|
||||
/>
|
||||
)}
|
||||
{canEdit && (
|
||||
<CatalogActions
|
||||
catalogType="bc"
|
||||
initialParentId={sp.get("newPageParent")}
|
||||
/>
|
||||
)}
|
||||
<AdminPageShell icon={Store} title={t("title")} subtitle={t("subtitle")}>
|
||||
<div className="space-y-6">
|
||||
<div className="flex items-center justify-between">
|
||||
<p className="text-muted-foreground">
|
||||
{totalBcPages} BC pages ({enabledBcPages} enabled) ·{" "}
|
||||
{totalBcItems} items
|
||||
</p>
|
||||
<div className="flex items-center gap-2">
|
||||
<CatalogViewToggle currentView={viewMode} catalogType="bc" />
|
||||
{canEdit && (
|
||||
<CatalogManagerDialog
|
||||
catalogType="bc"
|
||||
canEdit={canEdit}
|
||||
totals={{
|
||||
totalPages: totalBcPages,
|
||||
enabledPages: enabledBcPages,
|
||||
totalItems: totalBcItems,
|
||||
}}
|
||||
initialRoots={bcRootPages.map((p) => ({
|
||||
id: p.id,
|
||||
caption: p.caption,
|
||||
iconImage: p.iconImage,
|
||||
enabled: p.enabled,
|
||||
orderNum: 0,
|
||||
}))}
|
||||
/>
|
||||
)}
|
||||
{canEdit && (
|
||||
<CatalogActions
|
||||
catalogType="bc"
|
||||
initialParentId={sp.get("newPageParent")}
|
||||
/>
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
{viewMode === "tree" ? (
|
||||
<CatalogTree rootPages={bcRootPages} catalogType="bc" />
|
||||
) : (
|
||||
<CatalogTable
|
||||
data={{ rows: bcRows, ...bcPagination }}
|
||||
canEdit={canEdit}
|
||||
catalogType="bc"
|
||||
/>
|
||||
)}
|
||||
</div>
|
||||
{viewMode === "tree" ? (
|
||||
<CatalogTree rootPages={bcRootPages} catalogType="bc" />
|
||||
) : (
|
||||
<CatalogTable
|
||||
data={{ rows: bcRows, ...bcPagination }}
|
||||
canEdit={canEdit}
|
||||
catalogType="bc"
|
||||
/>
|
||||
)}
|
||||
</div>
|
||||
</AdminPageShell>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -396,43 +402,45 @@ export default async function CatalogPagesPage({
|
||||
}
|
||||
|
||||
return (
|
||||
<div className="space-y-6">
|
||||
<div className="flex items-center justify-between">
|
||||
<p className="text-muted-foreground">
|
||||
{totalPages} pages ({enabledPages} enabled) · {totalItems}{" "}
|
||||
items
|
||||
</p>
|
||||
<div className="flex items-center gap-2">
|
||||
<CatalogViewToggle currentView={viewMode} catalogType="normal" />
|
||||
{canEdit && (
|
||||
<CatalogManagerDialog
|
||||
catalogType="normal"
|
||||
canEdit={canEdit}
|
||||
totals={{
|
||||
totalPages,
|
||||
enabledPages,
|
||||
totalItems,
|
||||
}}
|
||||
initialRoots={rootPages.map((p) => ({
|
||||
id: p.id,
|
||||
caption: p.caption,
|
||||
iconImage: p.iconImage,
|
||||
enabled: p.enabled,
|
||||
orderNum: 0,
|
||||
}))}
|
||||
/>
|
||||
)}
|
||||
{canEdit && (
|
||||
<CatalogActions initialParentId={sp.get("newPageParent")} />
|
||||
)}
|
||||
<AdminPageShell icon={Store} title={t("title")} subtitle={t("subtitle")}>
|
||||
<div className="space-y-6">
|
||||
<div className="flex items-center justify-between">
|
||||
<p className="text-muted-foreground">
|
||||
{totalPages} pages ({enabledPages} enabled) · {totalItems}{" "}
|
||||
items
|
||||
</p>
|
||||
<div className="flex items-center gap-2">
|
||||
<CatalogViewToggle currentView={viewMode} catalogType="normal" />
|
||||
{canEdit && (
|
||||
<CatalogManagerDialog
|
||||
catalogType="normal"
|
||||
canEdit={canEdit}
|
||||
totals={{
|
||||
totalPages,
|
||||
enabledPages,
|
||||
totalItems,
|
||||
}}
|
||||
initialRoots={rootPages.map((p) => ({
|
||||
id: p.id,
|
||||
caption: p.caption,
|
||||
iconImage: p.iconImage,
|
||||
enabled: p.enabled,
|
||||
orderNum: 0,
|
||||
}))}
|
||||
/>
|
||||
)}
|
||||
{canEdit && (
|
||||
<CatalogActions initialParentId={sp.get("newPageParent")} />
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{viewMode === "tree" ? (
|
||||
<CatalogTree rootPages={rootPages} catalogType="normal" />
|
||||
) : (
|
||||
<CatalogTable data={{ rows, ...pagination }} canEdit={canEdit} />
|
||||
)}
|
||||
</div>
|
||||
{viewMode === "tree" ? (
|
||||
<CatalogTree rootPages={rootPages} catalogType="normal" />
|
||||
) : (
|
||||
<CatalogTable data={{ rows, ...pagination }} canEdit={canEdit} />
|
||||
)}
|
||||
</div>
|
||||
</AdminPageShell>
|
||||
);
|
||||
}
|
||||
@@ -1,6 +1,8 @@
|
||||
import os from "node:os";
|
||||
import { Terminal } from "lucide-react";
|
||||
import { redirect } from "next/navigation";
|
||||
import { getTranslations } from "next-intl/server";
|
||||
import { AdminPageShell } from "@/components/admin/admin-page-shell";
|
||||
import {
|
||||
DiagnosticRow,
|
||||
InfoItem,
|
||||
@@ -87,205 +89,219 @@ export default async function CommandoCentrum() {
|
||||
const rconSet = !!process.env.RCON_HOST;
|
||||
|
||||
return (
|
||||
<main>
|
||||
{/* ── Live status ────────────────────────────────────────── */}
|
||||
<div
|
||||
className="grid grid-cols-[repeat(auto-fit,minmax(180px,1fr))] gap-3.5 mb-6"
|
||||
style={{ marginTop: "1.1rem" }}
|
||||
>
|
||||
<StatusCard
|
||||
label={t("playersOnline")}
|
||||
value={onlineCount}
|
||||
hint={
|
||||
totalUsers >= 0
|
||||
? t("totalAccounts", { count: totalUsers })
|
||||
: t("dbUnavailable")
|
||||
}
|
||||
state="neutral"
|
||||
icon="👤"
|
||||
/>
|
||||
<StatusCard
|
||||
label={t("emulator")}
|
||||
value={emulatorOnline ? t("online") : t("offline")}
|
||||
hint={emulatorOnline ? t("rconReachable") : t("rconNotResponding")}
|
||||
state={emulatorOnline ? "ok" : "danger"}
|
||||
icon="🎮"
|
||||
/>
|
||||
<StatusCard
|
||||
label={t("database")}
|
||||
value={dbOk ? t("connected") : t("down")}
|
||||
hint={dbOk ? t("queriesResponding") : t("cannotReachDb")}
|
||||
state={dbOk ? "ok" : "danger"}
|
||||
icon="🗄️"
|
||||
/>
|
||||
<StatusCard
|
||||
label={t("emulatorErrors")}
|
||||
value={errors.length}
|
||||
hint={t("last50Logged")}
|
||||
state={errors.length === 0 ? "ok" : "warn"}
|
||||
icon="⚠️"
|
||||
/>
|
||||
</div>
|
||||
<AdminPageShell icon={Terminal} title={t("title")} subtitle={t("subtitle")}>
|
||||
<main>
|
||||
{/* ── Live status ────────────────────────────────────────── */}
|
||||
<div
|
||||
className="grid grid-cols-[repeat(auto-fit,minmax(180px,1fr))] gap-3.5 mb-6"
|
||||
style={{ marginTop: "1.1rem" }}
|
||||
>
|
||||
<StatusCard
|
||||
label={t("playersOnline")}
|
||||
value={onlineCount}
|
||||
hint={
|
||||
totalUsers >= 0
|
||||
? t("totalAccounts", { count: totalUsers })
|
||||
: t("dbUnavailable")
|
||||
}
|
||||
state="neutral"
|
||||
icon="👤"
|
||||
/>
|
||||
<StatusCard
|
||||
label={t("emulator")}
|
||||
value={emulatorOnline ? t("online") : t("offline")}
|
||||
hint={emulatorOnline ? t("rconReachable") : t("rconNotResponding")}
|
||||
state={emulatorOnline ? "ok" : "danger"}
|
||||
icon="🎮"
|
||||
/>
|
||||
<StatusCard
|
||||
label={t("database")}
|
||||
value={dbOk ? t("connected") : t("down")}
|
||||
hint={dbOk ? t("queriesResponding") : t("cannotReachDb")}
|
||||
state={dbOk ? "ok" : "danger"}
|
||||
icon="🗄️"
|
||||
/>
|
||||
<StatusCard
|
||||
label={t("emulatorErrors")}
|
||||
value={errors.length}
|
||||
hint={t("last50Logged")}
|
||||
state={errors.length === 0 ? "ok" : "warn"}
|
||||
icon="⚠️"
|
||||
/>
|
||||
</div>
|
||||
|
||||
{/* ── Online users widget ───────────────────────────────── */}
|
||||
<section id="online" className="admin-card mb-6 scroll-mt-4">
|
||||
<h2 className="admin-section-title">{t("onlineUsers")}</h2>
|
||||
<OnlineUsersWidget users={onlineUsers} isLoading={false} />
|
||||
</section>
|
||||
|
||||
{/* ── Server info + diagnostics ──────────────────────────── */}
|
||||
<div className="grid grid-cols-1 gap-4 md:grid-cols-2">
|
||||
<section className="admin-card p-5">
|
||||
<h2 className="admin-section-title">{t("serverInfo")}</h2>
|
||||
<div className="grid grid-cols-[repeat(auto-fit,minmax(150px,1fr))] gap-2.5">
|
||||
<InfoItem label={t("node")} value={process.version} />
|
||||
<InfoItem
|
||||
label={t("platform")}
|
||||
value={`${process.platform} ${process.arch}`}
|
||||
/>
|
||||
<InfoItem label={t("appUptime")} value={uptime(process.uptime())} />
|
||||
<InfoItem
|
||||
label={t("heapUsed")}
|
||||
value={mb(process.memoryUsage().heapUsed)}
|
||||
/>
|
||||
<InfoItem label={t("rss")} value={mb(process.memoryUsage().rss)} />
|
||||
<InfoItem label={t("hostUptime")} value={uptime(os.uptime())} />
|
||||
<InfoItem
|
||||
label={t("load1m")}
|
||||
value={os.loadavg()[0]?.toFixed(2) ?? "—"}
|
||||
/>
|
||||
<InfoItem label={t("cpus")} value={os.cpus().length} />
|
||||
</div>
|
||||
{/* ── Online users widget ───────────────────────────────── */}
|
||||
<section id="online" className="admin-card mb-6 scroll-mt-4">
|
||||
<h2 className="admin-section-title">{t("onlineUsers")}</h2>
|
||||
<OnlineUsersWidget users={onlineUsers} isLoading={false} />
|
||||
</section>
|
||||
|
||||
<section className="admin-card p-5">
|
||||
<h2 className="admin-section-title">{t("systemDiagnostics")}</h2>
|
||||
<div className="flex flex-col">
|
||||
<DiagnosticRow
|
||||
label={t("database")}
|
||||
detail={dbOk ? t("connectionHealthy") : t("unreachable")}
|
||||
state={dbOk ? "ok" : "danger"}
|
||||
/>
|
||||
<DiagnosticRow
|
||||
label={t("emulatorRcon")}
|
||||
detail={emulatorOnline ? t("respondingToPing") : t("noResponse")}
|
||||
state={emulatorOnline ? "ok" : "warn"}
|
||||
/>
|
||||
<DiagnosticRow
|
||||
label={t("rconConfig")}
|
||||
detail={rconSet ? t("rconHostSet") : t("rconHostNotConfigured")}
|
||||
state={rconSet ? "ok" : "warn"}
|
||||
/>
|
||||
<DiagnosticRow
|
||||
label={t("twoFaEncryptionKey")}
|
||||
detail={appKeySet ? t("appKeyConfigured") : t("appKeyMissing")}
|
||||
state={appKeySet ? "ok" : "warn"}
|
||||
/>
|
||||
<DiagnosticRow
|
||||
label={t("emailSmtp")}
|
||||
detail={smtpSet ? t("smtpHostSet") : t("notConfigured")}
|
||||
state={smtpSet ? "ok" : "warn"}
|
||||
/>
|
||||
<DiagnosticRow
|
||||
label={t("maintenanceMode")}
|
||||
detail={maintenance ? t("siteIsInMaintenance") : t("siteIsLive")}
|
||||
state={maintenance ? "warn" : "ok"}
|
||||
/>
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
{/* ── Server info + diagnostics ──────────────────────────── */}
|
||||
<div className="grid grid-cols-1 gap-4 md:grid-cols-2">
|
||||
<section className="admin-card p-5">
|
||||
<h2 className="admin-section-title">{t("serverInfo")}</h2>
|
||||
<div className="grid grid-cols-[repeat(auto-fit,minmax(150px,1fr))] gap-2.5">
|
||||
<InfoItem label={t("node")} value={process.version} />
|
||||
<InfoItem
|
||||
label={t("platform")}
|
||||
value={`${process.platform} ${process.arch}`}
|
||||
/>
|
||||
<InfoItem
|
||||
label={t("appUptime")}
|
||||
value={uptime(process.uptime())}
|
||||
/>
|
||||
<InfoItem
|
||||
label={t("heapUsed")}
|
||||
value={mb(process.memoryUsage().heapUsed)}
|
||||
/>
|
||||
<InfoItem
|
||||
label={t("rss")}
|
||||
value={mb(process.memoryUsage().rss)}
|
||||
/>
|
||||
<InfoItem label={t("hostUptime")} value={uptime(os.uptime())} />
|
||||
<InfoItem
|
||||
label={t("load1m")}
|
||||
value={os.loadavg()[0]?.toFixed(2) ?? "—"}
|
||||
/>
|
||||
<InfoItem label={t("cpus")} value={os.cpus().length} />
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<CommandocentrumControls />
|
||||
<section className="admin-card p-5">
|
||||
<h2 className="admin-section-title">{t("systemDiagnostics")}</h2>
|
||||
<div className="flex flex-col">
|
||||
<DiagnosticRow
|
||||
label={t("database")}
|
||||
detail={dbOk ? t("connectionHealthy") : t("unreachable")}
|
||||
state={dbOk ? "ok" : "danger"}
|
||||
/>
|
||||
<DiagnosticRow
|
||||
label={t("emulatorRcon")}
|
||||
detail={
|
||||
emulatorOnline ? t("respondingToPing") : t("noResponse")
|
||||
}
|
||||
state={emulatorOnline ? "ok" : "warn"}
|
||||
/>
|
||||
<DiagnosticRow
|
||||
label={t("rconConfig")}
|
||||
detail={rconSet ? t("rconHostSet") : t("rconHostNotConfigured")}
|
||||
state={rconSet ? "ok" : "warn"}
|
||||
/>
|
||||
<DiagnosticRow
|
||||
label={t("twoFaEncryptionKey")}
|
||||
detail={appKeySet ? t("appKeyConfigured") : t("appKeyMissing")}
|
||||
state={appKeySet ? "ok" : "warn"}
|
||||
/>
|
||||
<DiagnosticRow
|
||||
label={t("emailSmtp")}
|
||||
detail={smtpSet ? t("smtpHostSet") : t("notConfigured")}
|
||||
state={smtpSet ? "ok" : "warn"}
|
||||
/>
|
||||
<DiagnosticRow
|
||||
label={t("maintenanceMode")}
|
||||
detail={
|
||||
maintenance ? t("siteIsInMaintenance") : t("siteIsLive")
|
||||
}
|
||||
state={maintenance ? "warn" : "ok"}
|
||||
/>
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
|
||||
{/* ── Staff activity ─────────────────────────────────────── */}
|
||||
<section className="mt-6">
|
||||
<h2 className="admin-section-title">{t("recentStaffActivity")}</h2>
|
||||
{activity.length === 0 ? (
|
||||
<div className="admin-empty">{t("noStaffActivity")}</div>
|
||||
) : (
|
||||
<div className="admin-card overflow-x-auto">
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{t("colWhen")}</th>
|
||||
<th>{t("colStaff")}</th>
|
||||
<th>{t("colAction")}</th>
|
||||
<th>{t("colDescription")}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{activity.map((a) => (
|
||||
<tr key={String(a.id)}>
|
||||
<td className="text-sm theme-text-muted dark:theme-text-muted whitespace-nowrap">
|
||||
{formatDate(a.createdAt, "datetime-seconds")}
|
||||
</td>
|
||||
<td>{nameById.get(Number(a.userId)) ?? `#${a.userId}`}</td>
|
||||
<td>
|
||||
<span className="inline-block text-[0.6rem] font-bold px-2 py-0.5 rounded-full bg-[var(--admin-accent)]/18 text-[var(--admin-text)]">
|
||||
{a.action}
|
||||
</span>
|
||||
</td>
|
||||
<td className="text-sm theme-text-muted dark:theme-text-muted">
|
||||
{a.description}
|
||||
</td>
|
||||
<CommandocentrumControls />
|
||||
|
||||
{/* ── Staff activity ─────────────────────────────────────── */}
|
||||
<section className="mt-6">
|
||||
<h2 className="admin-section-title">{t("recentStaffActivity")}</h2>
|
||||
{activity.length === 0 ? (
|
||||
<div className="admin-empty">{t("noStaffActivity")}</div>
|
||||
) : (
|
||||
<div className="admin-card overflow-x-auto">
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{t("colWhen")}</th>
|
||||
<th>{t("colStaff")}</th>
|
||||
<th>{t("colAction")}</th>
|
||||
<th>{t("colDescription")}</th>
|
||||
</tr>
|
||||
))}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
)}
|
||||
</section>
|
||||
|
||||
{/* ── Emulator errors ────────────────────────────────────── */}
|
||||
<section className="mt-6">
|
||||
<h2 className="admin-section-title">{t("recentEmulatorErrors")}</h2>
|
||||
{errors.length === 0 ? (
|
||||
<div className="admin-empty">{t("noEmulatorErrors")}</div>
|
||||
) : (
|
||||
<div className="admin-card overflow-x-auto">
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{t("colWhen")}</th>
|
||||
<th>{t("colType")}</th>
|
||||
<th>{t("colVersion")}</th>
|
||||
<th>{t("colStacktrace")}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{errors.map((e) => {
|
||||
const trace = decodeStacktrace(e.stacktrace);
|
||||
const snippet = trace
|
||||
? trace.split("\n").slice(0, 20).join("\n") +
|
||||
(trace.split("\n").length > 20
|
||||
? `\n… ${t("truncated")}`
|
||||
: "")
|
||||
: t("empty");
|
||||
return (
|
||||
<tr key={e.id}>
|
||||
</thead>
|
||||
<tbody>
|
||||
{activity.map((a) => (
|
||||
<tr key={String(a.id)}>
|
||||
<td className="text-sm theme-text-muted dark:theme-text-muted whitespace-nowrap">
|
||||
{formatDate(
|
||||
e.timestamp ? new Date(e.timestamp * 1000) : null,
|
||||
"datetime-seconds",
|
||||
)}
|
||||
</td>
|
||||
<td>{e.type}</td>
|
||||
<td className="text-sm theme-text-muted dark:theme-text-muted whitespace-nowrap">
|
||||
{e.version}
|
||||
{formatDate(a.createdAt, "datetime-seconds")}
|
||||
</td>
|
||||
<td>
|
||||
<pre className="text-xs p-2 bg-[var(--admin-canvas)] text-[var(--color-text-readable)] rounded overflow-auto max-h-[160px]">
|
||||
{snippet}
|
||||
</pre>
|
||||
{nameById.get(Number(a.userId)) ?? `#${a.userId}`}
|
||||
</td>
|
||||
<td>
|
||||
<span className="inline-block text-[0.6rem] font-bold px-2 py-0.5 rounded-full bg-[var(--admin-accent)]/18 text-[var(--admin-text)]">
|
||||
{a.action}
|
||||
</span>
|
||||
</td>
|
||||
<td className="text-sm theme-text-muted dark:theme-text-muted">
|
||||
{a.description}
|
||||
</td>
|
||||
</tr>
|
||||
);
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
)}
|
||||
</section>
|
||||
</main>
|
||||
))}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
)}
|
||||
</section>
|
||||
|
||||
{/* ── Emulator errors ────────────────────────────────────── */}
|
||||
<section className="mt-6">
|
||||
<h2 className="admin-section-title">{t("recentEmulatorErrors")}</h2>
|
||||
{errors.length === 0 ? (
|
||||
<div className="admin-empty">{t("noEmulatorErrors")}</div>
|
||||
) : (
|
||||
<div className="admin-card overflow-x-auto">
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{t("colWhen")}</th>
|
||||
<th>{t("colType")}</th>
|
||||
<th>{t("colVersion")}</th>
|
||||
<th>{t("colStacktrace")}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{errors.map((e) => {
|
||||
const trace = decodeStacktrace(e.stacktrace);
|
||||
const snippet = trace
|
||||
? trace.split("\n").slice(0, 20).join("\n") +
|
||||
(trace.split("\n").length > 20
|
||||
? `\n… ${t("truncated")}`
|
||||
: "")
|
||||
: t("empty");
|
||||
return (
|
||||
<tr key={e.id}>
|
||||
<td className="text-sm theme-text-muted dark:theme-text-muted whitespace-nowrap">
|
||||
{formatDate(
|
||||
e.timestamp ? new Date(e.timestamp * 1000) : null,
|
||||
"datetime-seconds",
|
||||
)}
|
||||
</td>
|
||||
<td>{e.type}</td>
|
||||
<td className="text-sm theme-text-muted dark:theme-text-muted whitespace-nowrap">
|
||||
{e.version}
|
||||
</td>
|
||||
<td>
|
||||
<pre className="text-xs p-2 bg-[var(--admin-canvas)] text-[var(--color-text-readable)] rounded overflow-auto max-h-[160px]">
|
||||
{snippet}
|
||||
</pre>
|
||||
</td>
|
||||
</tr>
|
||||
);
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
)}
|
||||
</section>
|
||||
</main>
|
||||
</AdminPageShell>
|
||||
);
|
||||
}
|
||||
+101
-97
@@ -1,6 +1,8 @@
|
||||
import { Shield } from "lucide-react";
|
||||
import Link from "next/link";
|
||||
import { redirect } from "next/navigation";
|
||||
import { getTranslations } from "next-intl/server";
|
||||
import { AdminPageShell } from "@/components/admin/admin-page-shell";
|
||||
import { AdminSimplePager } from "@/components/admin/admin-simple-pager";
|
||||
import { StatusCard } from "@/components/admin/dashboard";
|
||||
import { Button } from "@/components/ui/button";
|
||||
@@ -104,103 +106,105 @@ export default async function AdminGuildsPage({
|
||||
);
|
||||
|
||||
return (
|
||||
<main>
|
||||
{loadError ? (
|
||||
<div className="mb-4 rounded-lg bg-[var(--admin-error-subtle)] p-3 text-xs text-[var(--admin-error)]">
|
||||
{t("loadError")}
|
||||
</div>
|
||||
) : null}
|
||||
|
||||
<form className="mb-4 flex gap-2" method="get">
|
||||
<input
|
||||
type="search"
|
||||
name="search"
|
||||
defaultValue={q}
|
||||
placeholder={t("searchPlaceholder")}
|
||||
className="admin-input flex-1"
|
||||
/>
|
||||
<Button type="submit" variant="default" size="sm">
|
||||
{t("search")}
|
||||
</Button>
|
||||
</form>
|
||||
|
||||
<div className="grid grid-cols-[repeat(auto-fit,minmax(180px,1fr))] gap-3.5 mb-6">
|
||||
<StatusCard label={t("totalGuilds")} value={total} icon="🛡️" />
|
||||
</div>
|
||||
|
||||
<section>
|
||||
<h2 className="admin-section-title">
|
||||
{t("title")} ({total})
|
||||
</h2>
|
||||
{rows.length === 0 ? (
|
||||
<div className="admin-empty">{t("empty")}</div>
|
||||
) : (
|
||||
<div className="admin-card overflow-x-auto" style={{ padding: 0 }}>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{t("colId")}</th>
|
||||
<th>{t("colBadge")}</th>
|
||||
<th>{t("colName")}</th>
|
||||
<th>{t("colOwner")}</th>
|
||||
<th>{t("colMembers")}</th>
|
||||
<th>{t("colCreated")}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{rows.map((g) => (
|
||||
<tr key={g.id}>
|
||||
<td className="muted">{g.id}</td>
|
||||
<td>
|
||||
{g.badge ? (
|
||||
// eslint-disable-next-line @next/next/no-img-element
|
||||
<img
|
||||
src={`https://habbo-stories-content.s3.amazonaws.com/badge-part-images/${g.badge}.gif`}
|
||||
alt=""
|
||||
width={40}
|
||||
height={40}
|
||||
className="h-10 w-10 object-contain"
|
||||
/>
|
||||
) : (
|
||||
<span className="muted">—</span>
|
||||
)}
|
||||
</td>
|
||||
<td>
|
||||
<Link
|
||||
href={`/admin/guilds/${g.id}`}
|
||||
className="font-medium hover:underline"
|
||||
>
|
||||
{g.name || `#${g.id}`}
|
||||
</Link>
|
||||
{g.description ? (
|
||||
<div className="muted text-xs line-clamp-1 max-w-xs">
|
||||
{g.description}
|
||||
</div>
|
||||
) : null}
|
||||
</td>
|
||||
<td>
|
||||
<Link href={`/admin/users/show/${g.userId}`}>
|
||||
{ownerById.get(g.userId) ?? `#${g.userId}`}
|
||||
</Link>
|
||||
</td>
|
||||
<td>{membersByGuild.get(g.id) ?? 0}</td>
|
||||
<td className="muted">
|
||||
{formatDate(new Date(g.dateCreated * 1000), "date")}
|
||||
</td>
|
||||
</tr>
|
||||
))}
|
||||
</tbody>
|
||||
</table>
|
||||
<AdminPageShell icon={Shield} title={t("title")} subtitle={t("subtitle")}>
|
||||
<main>
|
||||
{loadError ? (
|
||||
<div className="mb-4 rounded-lg bg-[var(--admin-error-subtle)] p-3 text-xs text-[var(--admin-error)]">
|
||||
{t("loadError")}
|
||||
</div>
|
||||
)}
|
||||
<AdminSimplePager
|
||||
page={pagination.page}
|
||||
lastPage={pagination.lastPage}
|
||||
total={total}
|
||||
basePath="/admin/guilds"
|
||||
params={q ? { search: q } : undefined}
|
||||
/>
|
||||
</section>
|
||||
</main>
|
||||
) : null}
|
||||
|
||||
<form className="mb-4 flex gap-2" method="get">
|
||||
<input
|
||||
type="search"
|
||||
name="search"
|
||||
defaultValue={q}
|
||||
placeholder={t("searchPlaceholder")}
|
||||
className="admin-input flex-1"
|
||||
/>
|
||||
<Button type="submit" variant="default" size="sm">
|
||||
{t("search")}
|
||||
</Button>
|
||||
</form>
|
||||
|
||||
<div className="grid grid-cols-[repeat(auto-fit,minmax(180px,1fr))] gap-3.5 mb-6">
|
||||
<StatusCard label={t("totalGuilds")} value={total} icon="🛡️" />
|
||||
</div>
|
||||
|
||||
<section>
|
||||
<h2 className="admin-section-title">
|
||||
{t("listHeading", { count: total })}
|
||||
</h2>
|
||||
{rows.length === 0 ? (
|
||||
<div className="admin-empty">{t("empty")}</div>
|
||||
) : (
|
||||
<div className="admin-card overflow-x-auto" style={{ padding: 0 }}>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{t("colId")}</th>
|
||||
<th>{t("colBadge")}</th>
|
||||
<th>{t("colName")}</th>
|
||||
<th>{t("colOwner")}</th>
|
||||
<th>{t("colMembers")}</th>
|
||||
<th>{t("colCreated")}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{rows.map((g) => (
|
||||
<tr key={g.id}>
|
||||
<td className="muted">{g.id}</td>
|
||||
<td>
|
||||
{g.badge ? (
|
||||
// eslint-disable-next-line @next/next/no-img-element
|
||||
<img
|
||||
src={`https://habbo-stories-content.s3.amazonaws.com/badge-part-images/${g.badge}.gif`}
|
||||
alt=""
|
||||
width={40}
|
||||
height={40}
|
||||
className="h-10 w-10 object-contain"
|
||||
/>
|
||||
) : (
|
||||
<span className="muted">—</span>
|
||||
)}
|
||||
</td>
|
||||
<td>
|
||||
<Link
|
||||
href={`/admin/guilds/${g.id}`}
|
||||
className="font-medium hover:underline"
|
||||
>
|
||||
{g.name || `#${g.id}`}
|
||||
</Link>
|
||||
{g.description ? (
|
||||
<div className="muted text-xs line-clamp-1 max-w-xs">
|
||||
{g.description}
|
||||
</div>
|
||||
) : null}
|
||||
</td>
|
||||
<td>
|
||||
<Link href={`/admin/users/show/${g.userId}`}>
|
||||
{ownerById.get(g.userId) ?? `#${g.userId}`}
|
||||
</Link>
|
||||
</td>
|
||||
<td>{membersByGuild.get(g.id) ?? 0}</td>
|
||||
<td className="muted">
|
||||
{formatDate(new Date(g.dateCreated * 1000), "date")}
|
||||
</td>
|
||||
</tr>
|
||||
))}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
)}
|
||||
<AdminSimplePager
|
||||
page={pagination.page}
|
||||
lastPage={pagination.lastPage}
|
||||
total={total}
|
||||
basePath="/admin/guilds"
|
||||
params={q ? { search: q } : undefined}
|
||||
/>
|
||||
</section>
|
||||
</main>
|
||||
</AdminPageShell>
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,273 @@
|
||||
"use client";
|
||||
|
||||
import Link from "next/link";
|
||||
import { useRouter } from "next/navigation";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { useState } from "react";
|
||||
import { updateItemsBase } from "@/actions/items-base";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";
|
||||
import { Input } from "@/components/ui/input";
|
||||
import { Label } from "@/components/ui/label";
|
||||
import { useServerAction } from "@/hooks/use-server-action";
|
||||
|
||||
export type ItemsBaseEditValues = {
|
||||
id: number;
|
||||
spriteId: number;
|
||||
publicName: string;
|
||||
itemName: string;
|
||||
type: string;
|
||||
width: number;
|
||||
length: number;
|
||||
stackHeight: string;
|
||||
allowStack: number;
|
||||
allowSit: number;
|
||||
allowLay: number;
|
||||
allowWalk: number;
|
||||
allowGift: number;
|
||||
allowTrade: number;
|
||||
allowRecycle: number;
|
||||
allowMarketplaceSell: number;
|
||||
allowInventoryStack: number;
|
||||
interactionType: string;
|
||||
interactionModesCount: number;
|
||||
vendingIds: string;
|
||||
multiheight: string;
|
||||
customparams: string;
|
||||
};
|
||||
|
||||
const ALLOW_FLAGS: Array<{ key: keyof ItemsBaseEditValues; label: string }> = [
|
||||
{ key: "allowStack", label: "Stack" },
|
||||
{ key: "allowSit", label: "Sit" },
|
||||
{ key: "allowLay", label: "Lay" },
|
||||
{ key: "allowWalk", label: "Walk" },
|
||||
{ key: "allowGift", label: "Gift" },
|
||||
{ key: "allowTrade", label: "Trade" },
|
||||
{ key: "allowRecycle", label: "Recycle" },
|
||||
{ key: "allowMarketplaceSell", label: "Marketplace" },
|
||||
{ key: "allowInventoryStack", label: "Inv. stack" },
|
||||
];
|
||||
|
||||
export function ItemsBaseEditForm({
|
||||
initial,
|
||||
canEdit,
|
||||
}: {
|
||||
initial: ItemsBaseEditValues;
|
||||
canEdit: boolean;
|
||||
}) {
|
||||
const t = useTranslations("pages.admin.items");
|
||||
const router = useRouter();
|
||||
const { run, isPending } = useServerAction();
|
||||
const [form, setForm] = useState(initial);
|
||||
|
||||
function setField<K extends keyof ItemsBaseEditValues>(
|
||||
key: K,
|
||||
value: ItemsBaseEditValues[K],
|
||||
) {
|
||||
setForm((prev) => ({ ...prev, [key]: value }));
|
||||
}
|
||||
|
||||
function handleSave() {
|
||||
if (!canEdit || isPending) return;
|
||||
const { id, ...fields } = form;
|
||||
run(() => updateItemsBase({ id, fields }), {
|
||||
successMessage: t("saved"),
|
||||
onSuccess: () => router.refresh(),
|
||||
});
|
||||
}
|
||||
|
||||
return (
|
||||
<div className="space-y-6">
|
||||
<div className="flex flex-wrap items-center justify-between gap-3">
|
||||
<div>
|
||||
<p className="text-sm text-muted-foreground m-0 font-mono">
|
||||
#{form.id}
|
||||
</p>
|
||||
<h2 className="text-xl font-bold m-0">
|
||||
{form.publicName || form.itemName || t("untitled")}
|
||||
</h2>
|
||||
</div>
|
||||
<div className="flex gap-2">
|
||||
<Button variant="outline" asChild>
|
||||
<Link href="/admin/items">{t("back")}</Link>
|
||||
</Button>
|
||||
{canEdit ? (
|
||||
<Button onClick={handleSave} disabled={isPending}>
|
||||
{t("save")}
|
||||
</Button>
|
||||
) : null}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className="grid gap-4 md:grid-cols-2">
|
||||
<Card>
|
||||
<CardHeader className="pb-2">
|
||||
<CardTitle className="text-sm">{t("sectionIdentity")}</CardTitle>
|
||||
</CardHeader>
|
||||
<CardContent className="space-y-3">
|
||||
<div>
|
||||
<Label htmlFor="publicName">{t("publicName")}</Label>
|
||||
<Input
|
||||
id="publicName"
|
||||
value={form.publicName}
|
||||
disabled={!canEdit}
|
||||
onChange={(e) => setField("publicName", e.target.value)}
|
||||
/>
|
||||
</div>
|
||||
<div>
|
||||
<Label htmlFor="itemName">{t("itemName")}</Label>
|
||||
<Input
|
||||
id="itemName"
|
||||
value={form.itemName}
|
||||
disabled={!canEdit}
|
||||
className="font-mono"
|
||||
onChange={(e) => setField("itemName", e.target.value)}
|
||||
/>
|
||||
</div>
|
||||
<div className="grid grid-cols-2 gap-3">
|
||||
<div>
|
||||
<Label htmlFor="type">{t("type")}</Label>
|
||||
<Input
|
||||
id="type"
|
||||
value={form.type}
|
||||
disabled={!canEdit}
|
||||
maxLength={3}
|
||||
onChange={(e) => setField("type", e.target.value)}
|
||||
/>
|
||||
</div>
|
||||
<div>
|
||||
<Label htmlFor="spriteId">{t("spriteId")}</Label>
|
||||
<Input
|
||||
id="spriteId"
|
||||
type="number"
|
||||
value={form.spriteId}
|
||||
disabled={!canEdit}
|
||||
onChange={(e) => setField("spriteId", Number(e.target.value))}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</CardContent>
|
||||
</Card>
|
||||
|
||||
<Card>
|
||||
<CardHeader className="pb-2">
|
||||
<CardTitle className="text-sm">{t("sectionDims")}</CardTitle>
|
||||
</CardHeader>
|
||||
<CardContent className="space-y-3">
|
||||
<div className="grid grid-cols-3 gap-3">
|
||||
<div>
|
||||
<Label htmlFor="width">{t("width")}</Label>
|
||||
<Input
|
||||
id="width"
|
||||
type="number"
|
||||
value={form.width}
|
||||
disabled={!canEdit}
|
||||
onChange={(e) => setField("width", Number(e.target.value))}
|
||||
/>
|
||||
</div>
|
||||
<div>
|
||||
<Label htmlFor="length">{t("length")}</Label>
|
||||
<Input
|
||||
id="length"
|
||||
type="number"
|
||||
value={form.length}
|
||||
disabled={!canEdit}
|
||||
onChange={(e) => setField("length", Number(e.target.value))}
|
||||
/>
|
||||
</div>
|
||||
<div>
|
||||
<Label htmlFor="stackHeight">{t("stackHeight")}</Label>
|
||||
<Input
|
||||
id="stackHeight"
|
||||
value={form.stackHeight}
|
||||
disabled={!canEdit}
|
||||
onChange={(e) => setField("stackHeight", e.target.value)}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<Label htmlFor="interactionType">{t("interactionType")}</Label>
|
||||
<Input
|
||||
id="interactionType"
|
||||
value={form.interactionType}
|
||||
disabled={!canEdit}
|
||||
onChange={(e) => setField("interactionType", e.target.value)}
|
||||
/>
|
||||
</div>
|
||||
<div>
|
||||
<Label htmlFor="interactionModesCount">
|
||||
{t("interactionModes")}
|
||||
</Label>
|
||||
<Input
|
||||
id="interactionModesCount"
|
||||
type="number"
|
||||
value={form.interactionModesCount}
|
||||
disabled={!canEdit}
|
||||
onChange={(e) =>
|
||||
setField("interactionModesCount", Number(e.target.value))
|
||||
}
|
||||
/>
|
||||
</div>
|
||||
</CardContent>
|
||||
</Card>
|
||||
|
||||
<Card>
|
||||
<CardHeader className="pb-2">
|
||||
<CardTitle className="text-sm">{t("sectionFlags")}</CardTitle>
|
||||
</CardHeader>
|
||||
<CardContent className="grid grid-cols-2 gap-2 sm:grid-cols-3">
|
||||
{ALLOW_FLAGS.map(({ key, label }) => (
|
||||
<label
|
||||
key={key}
|
||||
className="flex items-center gap-2 text-sm rounded-md border px-2 py-1.5"
|
||||
>
|
||||
<input
|
||||
type="checkbox"
|
||||
checked={Number(form[key]) === 1}
|
||||
disabled={!canEdit}
|
||||
onChange={(e) => setField(key, e.target.checked ? 1 : 0)}
|
||||
/>
|
||||
{label}
|
||||
</label>
|
||||
))}
|
||||
</CardContent>
|
||||
</Card>
|
||||
|
||||
<Card>
|
||||
<CardHeader className="pb-2">
|
||||
<CardTitle className="text-sm">{t("sectionExtra")}</CardTitle>
|
||||
</CardHeader>
|
||||
<CardContent className="space-y-3">
|
||||
<div>
|
||||
<Label htmlFor="vendingIds">{t("vendingIds")}</Label>
|
||||
<Input
|
||||
id="vendingIds"
|
||||
value={form.vendingIds}
|
||||
disabled={!canEdit}
|
||||
onChange={(e) => setField("vendingIds", e.target.value)}
|
||||
/>
|
||||
</div>
|
||||
<div>
|
||||
<Label htmlFor="multiheight">{t("multiheight")}</Label>
|
||||
<Input
|
||||
id="multiheight"
|
||||
value={form.multiheight}
|
||||
disabled={!canEdit}
|
||||
onChange={(e) => setField("multiheight", e.target.value)}
|
||||
/>
|
||||
</div>
|
||||
<div>
|
||||
<Label htmlFor="customparams">{t("customparams")}</Label>
|
||||
<Input
|
||||
id="customparams"
|
||||
value={form.customparams}
|
||||
disabled={!canEdit}
|
||||
onChange={(e) => setField("customparams", e.target.value)}
|
||||
/>
|
||||
</div>
|
||||
</CardContent>
|
||||
</Card>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,66 @@
|
||||
import { Package } from "lucide-react";
|
||||
import { notFound, redirect } from "next/navigation";
|
||||
import { getTranslations } from "next-intl/server";
|
||||
import { AdminPageShell } from "@/components/admin/admin-page-shell";
|
||||
import { canAccess, getAdminContext, PERMS } from "@/lib/permissions";
|
||||
import { prisma } from "@/lib/prisma";
|
||||
import { ItemsBaseEditForm } from "./items-base-edit-form";
|
||||
|
||||
export const dynamic = "force-dynamic";
|
||||
|
||||
export default async function ItemsBaseDetailPage({
|
||||
params,
|
||||
}: {
|
||||
params: Promise<{ id: string }>;
|
||||
}) {
|
||||
const { session, permissions } = await getAdminContext();
|
||||
if (!canAccess(permissions, PERMS.CATALOG_VIEW, session.user.rank)) {
|
||||
redirect("/admin");
|
||||
}
|
||||
|
||||
const t = await getTranslations("pages.admin.items");
|
||||
const { id: rawId } = await params;
|
||||
const id = Number(rawId);
|
||||
if (!Number.isFinite(id) || id <= 0) notFound();
|
||||
|
||||
const item = await prisma.itemsBase.findUnique({ where: { id } });
|
||||
if (!item) notFound();
|
||||
|
||||
const canEdit = canAccess(permissions, PERMS.CATALOG_EDIT, session.user.rank);
|
||||
|
||||
return (
|
||||
<AdminPageShell
|
||||
icon={Package}
|
||||
title={t("editTitle", { name: item.publicName || item.itemName })}
|
||||
subtitle={t("editSubtitle", { id: item.id })}
|
||||
>
|
||||
<ItemsBaseEditForm
|
||||
canEdit={canEdit}
|
||||
initial={{
|
||||
id: item.id,
|
||||
spriteId: item.spriteId,
|
||||
publicName: item.publicName,
|
||||
itemName: item.itemName,
|
||||
type: item.type,
|
||||
width: item.width,
|
||||
length: item.length,
|
||||
stackHeight: String(item.stackHeight),
|
||||
allowStack: item.allowStack,
|
||||
allowSit: item.allowSit,
|
||||
allowLay: item.allowLay,
|
||||
allowWalk: item.allowWalk,
|
||||
allowGift: item.allowGift,
|
||||
allowTrade: item.allowTrade,
|
||||
allowRecycle: item.allowRecycle,
|
||||
allowMarketplaceSell: item.allowMarketplaceSell,
|
||||
allowInventoryStack: item.allowInventoryStack,
|
||||
interactionType: item.interactionType,
|
||||
interactionModesCount: item.interactionModesCount,
|
||||
vendingIds: item.vendingIds,
|
||||
multiheight: item.multiheight,
|
||||
customparams: item.customparams,
|
||||
}}
|
||||
/>
|
||||
</AdminPageShell>
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,118 @@
|
||||
"use client";
|
||||
|
||||
import { Eye, Package, Pencil } from "lucide-react";
|
||||
import Link from "next/link";
|
||||
import { DataTable } from "@/components/admin/data-table";
|
||||
import { Badge } from "@/components/ui/badge";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import type { DataTableColumn, PaginatedResult } from "@/types/common";
|
||||
|
||||
export interface ItemsBaseRow {
|
||||
id: number;
|
||||
spriteId: number;
|
||||
publicName: string;
|
||||
itemName: string;
|
||||
type: string;
|
||||
interactionType: string;
|
||||
width: number;
|
||||
length: number;
|
||||
}
|
||||
|
||||
function getColumns(canEdit: boolean): DataTableColumn<ItemsBaseRow>[] {
|
||||
return [
|
||||
{ key: "id", label: "ID", sortable: true },
|
||||
{
|
||||
key: "publicName",
|
||||
label: "Name",
|
||||
sortable: true,
|
||||
render: (_, row) => (
|
||||
<Link
|
||||
href={`/admin/items/${row.id}`}
|
||||
className="hover:opacity-80 flex items-center gap-2 min-w-0"
|
||||
>
|
||||
<Package className="h-4 w-4 shrink-0 text-muted-foreground" />
|
||||
<div className="min-w-0">
|
||||
<span className="font-medium block truncate">
|
||||
{row.publicName || "—"}
|
||||
</span>
|
||||
<span className="text-xs text-muted-foreground font-mono truncate block">
|
||||
{row.itemName}
|
||||
</span>
|
||||
</div>
|
||||
</Link>
|
||||
),
|
||||
},
|
||||
{
|
||||
key: "spriteId",
|
||||
label: "Sprite",
|
||||
sortable: true,
|
||||
render: (v) => <span className="tabular-nums text-sm">{String(v)}</span>,
|
||||
},
|
||||
{
|
||||
key: "type",
|
||||
label: "Type",
|
||||
sortable: true,
|
||||
filterKey: "filter_type",
|
||||
filterOptions: [
|
||||
{ label: "Floor (s)", value: "s" },
|
||||
{ label: "Wall (i)", value: "i" },
|
||||
{ label: "Effect (e)", value: "e" },
|
||||
{ label: "Badge (b)", value: "b" },
|
||||
{ label: "Robot (r)", value: "r" },
|
||||
],
|
||||
render: (v) => <Badge variant="outline">{String(v)}</Badge>,
|
||||
},
|
||||
{
|
||||
key: "interactionType",
|
||||
label: "Interaction",
|
||||
sortable: true,
|
||||
render: (v) => (
|
||||
<span className="text-xs font-mono text-muted-foreground">
|
||||
{String(v || "default")}
|
||||
</span>
|
||||
),
|
||||
},
|
||||
{
|
||||
key: "width",
|
||||
label: "Size",
|
||||
render: (_, row) => (
|
||||
<span className="tabular-nums text-sm">
|
||||
{row.width}×{row.length}
|
||||
</span>
|
||||
),
|
||||
},
|
||||
{
|
||||
key: "actions",
|
||||
label: "",
|
||||
render: (_, row) => (
|
||||
<div className="flex gap-1 justify-end">
|
||||
<Button variant="ghost" size="icon" asChild>
|
||||
<Link href={`/admin/items/${row.id}`} aria-label="View">
|
||||
{canEdit ? (
|
||||
<Pencil className="h-4 w-4" />
|
||||
) : (
|
||||
<Eye className="h-4 w-4" />
|
||||
)}
|
||||
</Link>
|
||||
</Button>
|
||||
</div>
|
||||
),
|
||||
},
|
||||
];
|
||||
}
|
||||
|
||||
export function ItemsTable({
|
||||
data,
|
||||
canEdit,
|
||||
}: {
|
||||
data: PaginatedResult<ItemsBaseRow>;
|
||||
canEdit: boolean;
|
||||
}) {
|
||||
return (
|
||||
<DataTable
|
||||
columns={getColumns(canEdit)}
|
||||
data={data}
|
||||
searchPlaceholder="Search name, classname or ID…"
|
||||
/>
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,73 @@
|
||||
import { Package } from "lucide-react";
|
||||
import { getTranslations } from "next-intl/server";
|
||||
import { AdminPageShell } from "@/components/admin/admin-page-shell";
|
||||
import { fetchAdminList } from "@/lib/admin-list";
|
||||
import { canAccess, PERMS } from "@/lib/permissions";
|
||||
import { type ItemsBaseRow, ItemsTable } from "./items-table";
|
||||
|
||||
export default async function ItemsBasePage({
|
||||
params: paramsPromise,
|
||||
searchParams,
|
||||
}: {
|
||||
params: Promise<{ locale: string }>;
|
||||
searchParams: Promise<Record<string, string>>;
|
||||
}) {
|
||||
const result = await fetchAdminList<ItemsBaseRow>(
|
||||
{
|
||||
permission: PERMS.CATALOG_VIEW,
|
||||
model: "itemsBase",
|
||||
searchFields: ["itemName", "publicName"],
|
||||
defaultSort: { id: "desc" },
|
||||
select: {
|
||||
id: true,
|
||||
spriteId: true,
|
||||
publicName: true,
|
||||
itemName: true,
|
||||
type: true,
|
||||
interactionType: true,
|
||||
width: true,
|
||||
length: true,
|
||||
},
|
||||
filterMap: {
|
||||
filter_type: (v) => ({ type: v }),
|
||||
},
|
||||
mapRow: (r) => ({
|
||||
id: r.id as number,
|
||||
spriteId: r.spriteId as number,
|
||||
publicName: (r.publicName as string) || "",
|
||||
itemName: (r.itemName as string) || "",
|
||||
type: (r.type as string) || "s",
|
||||
interactionType: (r.interactionType as string) || "default",
|
||||
width: r.width as number,
|
||||
length: r.length as number,
|
||||
}),
|
||||
},
|
||||
paramsPromise,
|
||||
searchParams,
|
||||
);
|
||||
|
||||
const t = await getTranslations("pages.admin.items");
|
||||
const canEdit = canAccess(
|
||||
result.permissions,
|
||||
PERMS.CATALOG_EDIT,
|
||||
result.rank,
|
||||
);
|
||||
|
||||
return (
|
||||
<AdminPageShell icon={Package} title={t("title")} subtitle={t("subtitle")}>
|
||||
<p className="text-muted-foreground m-0">
|
||||
{t("total", { count: result.total })}
|
||||
</p>
|
||||
<ItemsTable
|
||||
data={{
|
||||
rows: result.rows,
|
||||
total: result.total,
|
||||
page: result.page,
|
||||
perPage: result.perPage,
|
||||
lastPage: result.lastPage,
|
||||
}}
|
||||
canEdit={canEdit}
|
||||
/>
|
||||
</AdminPageShell>
|
||||
);
|
||||
}
|
||||
+32
-24
@@ -1,5 +1,7 @@
|
||||
import { ClipboardList } from "lucide-react";
|
||||
import { redirect } from "next/navigation";
|
||||
import { getTranslations } from "next-intl/server";
|
||||
import { AdminPageShell } from "@/components/admin/admin-page-shell";
|
||||
import { StatusCard } from "@/components/admin/dashboard";
|
||||
import { buildStaffActivityWhere } from "@/lib/admin/log-filters";
|
||||
import { calcPagination, parseListParams } from "@/lib/admin-helpers";
|
||||
@@ -97,31 +99,37 @@ export default async function AdminStaffActivities({
|
||||
}));
|
||||
|
||||
return (
|
||||
<div className="space-y-6">
|
||||
<div className="grid grid-cols-[repeat(auto-fit,minmax(180px,1fr))] gap-3.5">
|
||||
<StatusCard label={t("totalActivities")} value={total} icon="📋" />
|
||||
<StatusCard
|
||||
label={t("onThisPage")}
|
||||
value={activities.length}
|
||||
icon="📄"
|
||||
/>
|
||||
<StatusCard
|
||||
label={t("recent")}
|
||||
value={recentCount}
|
||||
state={recentCount > 0 ? "ok" : "neutral"}
|
||||
icon="🟢"
|
||||
<AdminPageShell
|
||||
icon={ClipboardList}
|
||||
title={t("title")}
|
||||
subtitle={t("subtitle")}
|
||||
>
|
||||
<div className="space-y-6">
|
||||
<div className="grid grid-cols-[repeat(auto-fit,minmax(180px,1fr))] gap-3.5">
|
||||
<StatusCard label={t("totalActivities")} value={total} icon="📋" />
|
||||
<StatusCard
|
||||
label={t("onThisPage")}
|
||||
value={activities.length}
|
||||
icon="📄"
|
||||
/>
|
||||
<StatusCard
|
||||
label={t("recent")}
|
||||
value={recentCount}
|
||||
state={recentCount > 0 ? "ok" : "neutral"}
|
||||
icon="🟢"
|
||||
/>
|
||||
</div>
|
||||
|
||||
<StaffActivitiesTable
|
||||
data={{
|
||||
rows,
|
||||
total,
|
||||
page: pagination.page,
|
||||
perPage: pagination.perPage,
|
||||
lastPage: pagination.lastPage,
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
|
||||
<StaffActivitiesTable
|
||||
data={{
|
||||
rows,
|
||||
total,
|
||||
page: pagination.page,
|
||||
perPage: pagination.perPage,
|
||||
lastPage: pagination.lastPage,
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
</AdminPageShell>
|
||||
);
|
||||
}
|
||||
@@ -1,7 +1,9 @@
|
||||
import { Store } from "lucide-react";
|
||||
import Link from "next/link";
|
||||
import { redirect } from "next/navigation";
|
||||
import { getTranslations } from "next-intl/server";
|
||||
import { cancelMarketplaceListing } from "@/actions/admin-marketplace";
|
||||
import { AdminPageShell } from "@/components/admin/admin-page-shell";
|
||||
import { AdminSimplePager } from "@/components/admin/admin-simple-pager";
|
||||
import { StatusCard } from "@/components/admin/dashboard";
|
||||
import { Button } from "@/components/ui/button";
|
||||
@@ -69,109 +71,115 @@ export default async function AdminMarketplacePage({
|
||||
const usernameById = new Map(users.map((u) => [u.id, u.username]));
|
||||
|
||||
return (
|
||||
<main>
|
||||
{loadError ? (
|
||||
<div className="mb-4 rounded-lg bg-[var(--admin-error-subtle)] p-3 text-xs text-[var(--admin-error)]">
|
||||
{t("loadError")}
|
||||
<AdminPageShell icon={Store} title={t("title")} subtitle={t("subtitle")}>
|
||||
<main>
|
||||
{loadError ? (
|
||||
<div className="mb-4 rounded-lg bg-[var(--admin-error-subtle)] p-3 text-xs text-[var(--admin-error)]">
|
||||
{t("loadError")}
|
||||
</div>
|
||||
) : null}
|
||||
|
||||
<div className="mb-4 flex flex-wrap gap-2">
|
||||
<Button
|
||||
variant={filter === "active" ? "default" : "ghost"}
|
||||
size="sm"
|
||||
asChild
|
||||
>
|
||||
<Link href="/admin/marketplace?filter=active">
|
||||
{t("filterActive")}
|
||||
</Link>
|
||||
</Button>
|
||||
<Button
|
||||
variant={filter === "sold" ? "default" : "ghost"}
|
||||
size="sm"
|
||||
asChild
|
||||
>
|
||||
<Link href="/admin/marketplace?filter=sold">{t("filterSold")}</Link>
|
||||
</Button>
|
||||
</div>
|
||||
) : null}
|
||||
|
||||
<div className="mb-4 flex flex-wrap gap-2">
|
||||
<Button
|
||||
variant={filter === "active" ? "default" : "ghost"}
|
||||
size="sm"
|
||||
asChild
|
||||
>
|
||||
<Link href="/admin/marketplace?filter=active">
|
||||
{t("filterActive")}
|
||||
</Link>
|
||||
</Button>
|
||||
<Button
|
||||
variant={filter === "sold" ? "default" : "ghost"}
|
||||
size="sm"
|
||||
asChild
|
||||
>
|
||||
<Link href="/admin/marketplace?filter=sold">{t("filterSold")}</Link>
|
||||
</Button>
|
||||
</div>
|
||||
<div className="grid grid-cols-[repeat(auto-fit,minmax(180px,1fr))] gap-3.5 mb-6">
|
||||
<StatusCard
|
||||
label={t("activeListings")}
|
||||
value={activeCount}
|
||||
icon="🏪"
|
||||
/>
|
||||
<StatusCard label={t("soldListings")} value={soldCount} icon="✅" />
|
||||
</div>
|
||||
|
||||
<div className="grid grid-cols-[repeat(auto-fit,minmax(180px,1fr))] gap-3.5 mb-6">
|
||||
<StatusCard label={t("activeListings")} value={activeCount} icon="🏪" />
|
||||
<StatusCard label={t("soldListings")} value={soldCount} icon="✅" />
|
||||
</div>
|
||||
|
||||
<section>
|
||||
<h2 className="admin-section-title">
|
||||
{filter === "sold" ? t("soldListings") : t("activeListings")} ({total}
|
||||
)
|
||||
</h2>
|
||||
{rows.length === 0 ? (
|
||||
<div className="admin-empty">{t("empty")}</div>
|
||||
) : (
|
||||
<div className="admin-card overflow-x-auto" style={{ padding: 0 }}>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{t("colId")}</th>
|
||||
<th>{t("colItem")}</th>
|
||||
<th>{t("colSeller")}</th>
|
||||
<th>{t("colPrice")}</th>
|
||||
<th>{t("colListed")}</th>
|
||||
{filter === "sold" ? <th>{t("colSold")}</th> : null}
|
||||
{canEdit && filter === "active" ? (
|
||||
<th>{t("colActions")}</th>
|
||||
) : null}
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{rows.map((row) => (
|
||||
<tr key={row.id}>
|
||||
<td className="muted">{row.id}</td>
|
||||
<td>
|
||||
<code>{row.itemId}</code>
|
||||
</td>
|
||||
<td>
|
||||
<Link href={`/admin/users/show/${row.userId}`}>
|
||||
{usernameById.get(row.userId) ?? `#${row.userId}`}
|
||||
</Link>
|
||||
</td>
|
||||
<td>{row.price}</td>
|
||||
<td className="muted">
|
||||
{formatDate(new Date(row.timestamp * 1000))}
|
||||
</td>
|
||||
{filter === "sold" ? (
|
||||
<td className="muted">
|
||||
{formatDate(
|
||||
row.soldTimestamp
|
||||
? new Date(row.soldTimestamp * 1000)
|
||||
: null,
|
||||
)}
|
||||
</td>
|
||||
) : null}
|
||||
<section>
|
||||
<h2 className="admin-section-title">
|
||||
{filter === "sold" ? t("soldListings") : t("activeListings")} (
|
||||
{total})
|
||||
</h2>
|
||||
{rows.length === 0 ? (
|
||||
<div className="admin-empty">{t("empty")}</div>
|
||||
) : (
|
||||
<div className="admin-card overflow-x-auto" style={{ padding: 0 }}>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{t("colId")}</th>
|
||||
<th>{t("colItem")}</th>
|
||||
<th>{t("colSeller")}</th>
|
||||
<th>{t("colPrice")}</th>
|
||||
<th>{t("colListed")}</th>
|
||||
{filter === "sold" ? <th>{t("colSold")}</th> : null}
|
||||
{canEdit && filter === "active" ? (
|
||||
<td>
|
||||
<form action={cancelMarketplaceListing}>
|
||||
<input type="hidden" name="id" value={row.id} />
|
||||
<Button type="submit" variant="ghost" size="sm">
|
||||
{t("cancel")}
|
||||
</Button>
|
||||
</form>
|
||||
</td>
|
||||
<th>{t("colActions")}</th>
|
||||
) : null}
|
||||
</tr>
|
||||
))}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
)}
|
||||
<AdminSimplePager
|
||||
page={pagination.page}
|
||||
lastPage={pagination.lastPage}
|
||||
total={total}
|
||||
basePath="/admin/marketplace"
|
||||
params={filter === "sold" ? { filter: "sold" } : undefined}
|
||||
/>
|
||||
</section>
|
||||
</main>
|
||||
</thead>
|
||||
<tbody>
|
||||
{rows.map((row) => (
|
||||
<tr key={row.id}>
|
||||
<td className="muted">{row.id}</td>
|
||||
<td>
|
||||
<code>{row.itemId}</code>
|
||||
</td>
|
||||
<td>
|
||||
<Link href={`/admin/users/show/${row.userId}`}>
|
||||
{usernameById.get(row.userId) ?? `#${row.userId}`}
|
||||
</Link>
|
||||
</td>
|
||||
<td>{row.price}</td>
|
||||
<td className="muted">
|
||||
{formatDate(new Date(row.timestamp * 1000))}
|
||||
</td>
|
||||
{filter === "sold" ? (
|
||||
<td className="muted">
|
||||
{formatDate(
|
||||
row.soldTimestamp
|
||||
? new Date(row.soldTimestamp * 1000)
|
||||
: null,
|
||||
)}
|
||||
</td>
|
||||
) : null}
|
||||
{canEdit && filter === "active" ? (
|
||||
<td>
|
||||
<form action={cancelMarketplaceListing}>
|
||||
<input type="hidden" name="id" value={row.id} />
|
||||
<Button type="submit" variant="ghost" size="sm">
|
||||
{t("cancel")}
|
||||
</Button>
|
||||
</form>
|
||||
</td>
|
||||
) : null}
|
||||
</tr>
|
||||
))}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
)}
|
||||
<AdminSimplePager
|
||||
page={pagination.page}
|
||||
lastPage={pagination.lastPage}
|
||||
total={total}
|
||||
basePath="/admin/marketplace"
|
||||
params={filter === "sold" ? { filter: "sold" } : undefined}
|
||||
/>
|
||||
</section>
|
||||
</main>
|
||||
</AdminPageShell>
|
||||
);
|
||||
}
|
||||
@@ -1,3 +1,6 @@
|
||||
import { Wifi } from "lucide-react";
|
||||
import { getTranslations } from "next-intl/server";
|
||||
import { AdminPageShell } from "@/components/admin/admin-page-shell";
|
||||
import { fetchAdminList } from "@/lib/admin-list";
|
||||
import { PERMS } from "@/lib/permissions";
|
||||
import { OnlineTable } from "./online-table";
|
||||
@@ -27,10 +30,12 @@ export default async function OnlineUsersPage({
|
||||
searchParams,
|
||||
);
|
||||
|
||||
const t = await getTranslations("pages.admin.online");
|
||||
|
||||
return (
|
||||
<div className="space-y-6">
|
||||
<p className="text-muted-foreground">
|
||||
Currently online users ({result.total} connected)
|
||||
<AdminPageShell icon={Wifi} title={t("title")} subtitle={t("subtitle")}>
|
||||
<p className="text-muted-foreground m-0">
|
||||
{t("connected", { count: result.total })}
|
||||
</p>
|
||||
|
||||
<OnlineTable
|
||||
@@ -42,6 +47,6 @@ export default async function OnlineUsersPage({
|
||||
lastPage: result.lastPage,
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
</AdminPageShell>
|
||||
);
|
||||
}
|
||||
@@ -1,3 +1,6 @@
|
||||
import { DoorOpen } from "lucide-react";
|
||||
import { getTranslations } from "next-intl/server";
|
||||
import { AdminPageShell } from "@/components/admin/admin-page-shell";
|
||||
import { fetchAdminList } from "@/lib/admin-list";
|
||||
import { canAccess, PERMS } from "@/lib/permissions";
|
||||
import { RoomsTable } from "./rooms-table";
|
||||
@@ -44,11 +47,12 @@ export default async function RoomsPage({
|
||||
searchParams,
|
||||
);
|
||||
|
||||
const t = await getTranslations("pages.admin.rooms");
|
||||
const canEdit = canAccess(result.permissions, PERMS.ROOMS_EDIT, result.rank);
|
||||
|
||||
return (
|
||||
<div className="space-y-6">
|
||||
<p className="text-muted-foreground">
|
||||
<AdminPageShell icon={DoorOpen} title={t("title")} subtitle={t("subtitle")}>
|
||||
<p className="text-muted-foreground m-0">
|
||||
{result.total.toLocaleString()} rooms total
|
||||
</p>
|
||||
|
||||
@@ -62,6 +66,6 @@ export default async function RoomsPage({
|
||||
}}
|
||||
canEdit={canEdit}
|
||||
/>
|
||||
</div>
|
||||
</AdminPageShell>
|
||||
);
|
||||
}
|
||||
@@ -1,5 +1,7 @@
|
||||
import { Settings } from "lucide-react";
|
||||
import { redirect } from "next/navigation";
|
||||
import { getTranslations } from "next-intl/server";
|
||||
import { AdminPageShell } from "@/components/admin/admin-page-shell";
|
||||
import { canAccess, getAdminContext, PERMS } from "@/lib/permissions";
|
||||
import { prisma } from "@/lib/prisma";
|
||||
import { AdvancedSettingsPanel } from "./advanced-settings-panel";
|
||||
@@ -41,29 +43,31 @@ export default async function AdminSettings() {
|
||||
const documented = settings.filter((s) => !!s.comment).length;
|
||||
|
||||
return (
|
||||
<div className="space-y-8">
|
||||
<div className="admin-stat-row">
|
||||
<span className="admin-stat-chip">
|
||||
{t("keysInDatabase", { count: settings.length })}
|
||||
</span>
|
||||
<span className="admin-stat-chip">
|
||||
{t("managedInForm", { count: MANAGED_SETTING_KEYS.length })}
|
||||
</span>
|
||||
<span className="admin-stat-chip">
|
||||
{t("documented", { count: documented })}
|
||||
</span>
|
||||
<AdminPageShell icon={Settings} title={t("title")} subtitle={t("subtitle")}>
|
||||
<div className="space-y-8">
|
||||
<div className="admin-stat-row">
|
||||
<span className="admin-stat-chip">
|
||||
{t("keysInDatabase", { count: settings.length })}
|
||||
</span>
|
||||
<span className="admin-stat-chip">
|
||||
{t("managedInForm", { count: MANAGED_SETTING_KEYS.length })}
|
||||
</span>
|
||||
<span className="admin-stat-chip">
|
||||
{t("documented", { count: documented })}
|
||||
</span>
|
||||
</div>
|
||||
|
||||
<CmsSettingsForm values={values} canEdit={canEdit} />
|
||||
|
||||
<AdvancedSettingsPanel
|
||||
settings={settings.map((s) => ({
|
||||
key: s.key,
|
||||
value: s.value,
|
||||
comment: s.comment,
|
||||
}))}
|
||||
canEdit={canEdit}
|
||||
/>
|
||||
</div>
|
||||
|
||||
<CmsSettingsForm values={values} canEdit={canEdit} />
|
||||
|
||||
<AdvancedSettingsPanel
|
||||
settings={settings.map((s) => ({
|
||||
key: s.key,
|
||||
value: s.value,
|
||||
comment: s.comment,
|
||||
}))}
|
||||
canEdit={canEdit}
|
||||
/>
|
||||
</div>
|
||||
</AdminPageShell>
|
||||
);
|
||||
}
|
||||
+135
-123
@@ -1,6 +1,8 @@
|
||||
import { ShoppingCart } from "lucide-react";
|
||||
import Link from "next/link";
|
||||
import { redirect } from "next/navigation";
|
||||
import { getTranslations } from "next-intl/server";
|
||||
import { AdminPageShell } from "@/components/admin/admin-page-shell";
|
||||
import { AdminSimplePager } from "@/components/admin/admin-simple-pager";
|
||||
import { StatusCard } from "@/components/admin/dashboard";
|
||||
import { CurrencyIcon } from "@/components/shared/currency-icon";
|
||||
@@ -111,142 +113,152 @@ export default async function AdminShop({
|
||||
).length;
|
||||
|
||||
return (
|
||||
<main>
|
||||
{loadError ? (
|
||||
<div className="mb-4 rounded-lg bg-[var(--admin-error-subtle)] p-3 text-xs text-[var(--admin-error)]">
|
||||
Could not load some shop data (database unavailable).
|
||||
</div>
|
||||
) : null}
|
||||
<div className="flex items-center justify-end gap-4">
|
||||
<AdminPageShell
|
||||
icon={ShoppingCart}
|
||||
title={t("title")}
|
||||
subtitle={t("subtitle")}
|
||||
actions={
|
||||
<Button variant="default" asChild>
|
||||
<Link href="/admin/shop/new">{t("newPackage")}</Link>
|
||||
</Button>
|
||||
</div>
|
||||
}
|
||||
>
|
||||
<main>
|
||||
{loadError ? (
|
||||
<div className="mb-4 rounded-lg bg-[var(--admin-error-subtle)] p-3 text-xs text-[var(--admin-error)]">
|
||||
Could not load some shop data (database unavailable).
|
||||
</div>
|
||||
) : null}
|
||||
|
||||
<div className="grid grid-cols-[repeat(auto-fit,minmax(180px,1fr))] gap-3.5 mb-6">
|
||||
<StatusCard label={t("packages")} value={packageTotal} icon="🛍️" />
|
||||
<StatusCard label={t("recentOrders")} value={orders.length} icon="🧾" />
|
||||
<StatusCard
|
||||
label={t("paidOrders")}
|
||||
value={paidOrders}
|
||||
state={paidOrders > 0 ? "ok" : "neutral"}
|
||||
icon="💳"
|
||||
/>
|
||||
</div>
|
||||
<div className="grid grid-cols-[repeat(auto-fit,minmax(180px,1fr))] gap-3.5 mb-6">
|
||||
<StatusCard label={t("packages")} value={packageTotal} icon="🛍️" />
|
||||
<StatusCard
|
||||
label={t("recentOrders")}
|
||||
value={orders.length}
|
||||
icon="🧾"
|
||||
/>
|
||||
<StatusCard
|
||||
label={t("paidOrders")}
|
||||
value={paidOrders}
|
||||
state={paidOrders > 0 ? "ok" : "neutral"}
|
||||
icon="💳"
|
||||
/>
|
||||
</div>
|
||||
|
||||
<section className="mt-6">
|
||||
<h2 className="admin-section-title">
|
||||
{t("packagesTotal", { count: packageTotal })}
|
||||
</h2>
|
||||
{packages.length === 0 ? (
|
||||
<div className="admin-empty">{t("noPackages")}</div>
|
||||
) : (
|
||||
<div className="admin-card overflow-x-auto" style={{ padding: 0 }}>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>#</th>
|
||||
<th>{t("colName")}</th>
|
||||
<th>{t("colPrice")}</th>
|
||||
<th>{t("colCredits")}</th>
|
||||
<th>{t("colDuckets")}</th>
|
||||
<th>{t("colDiamonds")}</th>
|
||||
<th>{t("colRank")}</th>
|
||||
<th>{t("colPosition")}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{packages.map((p) => (
|
||||
<tr key={String(p.id)}>
|
||||
<td className="muted">{String(p.id)}</td>
|
||||
<td>
|
||||
<Link href={`/admin/shop/${p.id}`}>{p.name}</Link>
|
||||
</td>
|
||||
<td>{p.costs}</td>
|
||||
<td>
|
||||
<CurrencyCell kind="credits" value={p.credits} />
|
||||
</td>
|
||||
<td>
|
||||
<CurrencyCell kind="duckets" value={p.duckets} />
|
||||
</td>
|
||||
<td>
|
||||
<CurrencyCell kind="diamonds" value={p.diamonds} />
|
||||
</td>
|
||||
<td className="muted">{p.giveRank ?? "—"}</td>
|
||||
<td className="muted">{p.position}</td>
|
||||
<section className="mt-6">
|
||||
<h2 className="admin-section-title">
|
||||
{t("packagesTotal", { count: packageTotal })}
|
||||
</h2>
|
||||
{packages.length === 0 ? (
|
||||
<div className="admin-empty">{t("noPackages")}</div>
|
||||
) : (
|
||||
<div className="admin-card overflow-x-auto" style={{ padding: 0 }}>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>#</th>
|
||||
<th>{t("colName")}</th>
|
||||
<th>{t("colPrice")}</th>
|
||||
<th>{t("colCredits")}</th>
|
||||
<th>{t("colDuckets")}</th>
|
||||
<th>{t("colDiamonds")}</th>
|
||||
<th>{t("colRank")}</th>
|
||||
<th>{t("colPosition")}</th>
|
||||
</tr>
|
||||
))}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
)}
|
||||
<AdminSimplePager
|
||||
page={pkgPagination.page}
|
||||
lastPage={pkgPagination.lastPage}
|
||||
total={packageTotal}
|
||||
basePath="/admin/shop"
|
||||
/>
|
||||
</section>
|
||||
|
||||
<section className="mt-6">
|
||||
<h2 className="admin-section-title">
|
||||
{t("recentOrders")} ({orders.length})
|
||||
</h2>
|
||||
<p className="muted -mt-1 mb-3 text-sm">{t("ordersHint")}</p>
|
||||
{orders.length === 0 ? (
|
||||
<div className="admin-empty">{t("noOrders")}</div>
|
||||
) : (
|
||||
<div className="admin-card overflow-x-auto" style={{ padding: 0 }}>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{t("colTransaction")}</th>
|
||||
<th>{t("colUser")}</th>
|
||||
<th>{t("colDescription")}</th>
|
||||
<th>{t("colAmount")}</th>
|
||||
<th>{t("colStatus")}</th>
|
||||
<th>{t("colDate")}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{orders.map((o) => {
|
||||
const state = statusState(o.status);
|
||||
return (
|
||||
<tr key={String(o.id)}>
|
||||
</thead>
|
||||
<tbody>
|
||||
{packages.map((p) => (
|
||||
<tr key={String(p.id)}>
|
||||
<td className="muted">{String(p.id)}</td>
|
||||
<td>
|
||||
<code>{o.transactionId}</code>
|
||||
<Link href={`/admin/shop/${p.id}`}>{p.name}</Link>
|
||||
</td>
|
||||
<td className="muted">
|
||||
<Link href={`/admin/users/${o.userId}`}>
|
||||
#{o.userId}
|
||||
</Link>
|
||||
</td>
|
||||
<td className="muted">{o.description ?? "—"}</td>
|
||||
<td>{p.costs}</td>
|
||||
<td>
|
||||
{o.amount} {o.currency}
|
||||
<CurrencyCell kind="credits" value={p.credits} />
|
||||
</td>
|
||||
<td>
|
||||
{o.status ? (
|
||||
<span
|
||||
className={`inline-block text-[0.72rem] font-bold px-2 py-0.5 rounded-full ${state === "ok" ? "bg-[var(--admin-success-subtle)] text-[var(--admin-text)]" : state === "danger" ? "bg-[var(--admin-error-subtle)] text-[var(--admin-text)]" : "bg-[var(--admin-accent)]/18 text-[var(--admin-text)]"}`}
|
||||
>
|
||||
{o.status}
|
||||
</span>
|
||||
) : (
|
||||
<span className="muted">—</span>
|
||||
)}
|
||||
<CurrencyCell kind="duckets" value={p.duckets} />
|
||||
</td>
|
||||
<td className="muted">
|
||||
{formatDate(o.createdAt, "date")}
|
||||
<td>
|
||||
<CurrencyCell kind="diamonds" value={p.diamonds} />
|
||||
</td>
|
||||
<td className="muted">{p.giveRank ?? "—"}</td>
|
||||
<td className="muted">{p.position}</td>
|
||||
</tr>
|
||||
);
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
)}
|
||||
</section>
|
||||
</main>
|
||||
))}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
)}
|
||||
<AdminSimplePager
|
||||
page={pkgPagination.page}
|
||||
lastPage={pkgPagination.lastPage}
|
||||
total={packageTotal}
|
||||
basePath="/admin/shop"
|
||||
/>
|
||||
</section>
|
||||
|
||||
<section className="mt-6">
|
||||
<h2 className="admin-section-title">
|
||||
{t("recentOrders")} ({orders.length})
|
||||
</h2>
|
||||
<p className="muted -mt-1 mb-3 text-sm">{t("ordersHint")}</p>
|
||||
{orders.length === 0 ? (
|
||||
<div className="admin-empty">{t("noOrders")}</div>
|
||||
) : (
|
||||
<div className="admin-card overflow-x-auto" style={{ padding: 0 }}>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{t("colTransaction")}</th>
|
||||
<th>{t("colUser")}</th>
|
||||
<th>{t("colDescription")}</th>
|
||||
<th>{t("colAmount")}</th>
|
||||
<th>{t("colStatus")}</th>
|
||||
<th>{t("colDate")}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{orders.map((o) => {
|
||||
const state = statusState(o.status);
|
||||
return (
|
||||
<tr key={String(o.id)}>
|
||||
<td>
|
||||
<code>{o.transactionId}</code>
|
||||
</td>
|
||||
<td className="muted">
|
||||
<Link href={`/admin/users/${o.userId}`}>
|
||||
#{o.userId}
|
||||
</Link>
|
||||
</td>
|
||||
<td className="muted">{o.description ?? "—"}</td>
|
||||
<td>
|
||||
{o.amount} {o.currency}
|
||||
</td>
|
||||
<td>
|
||||
{o.status ? (
|
||||
<span
|
||||
className={`inline-block text-[0.72rem] font-bold px-2 py-0.5 rounded-full ${state === "ok" ? "bg-[var(--admin-success-subtle)] text-[var(--admin-text)]" : state === "danger" ? "bg-[var(--admin-error-subtle)] text-[var(--admin-text)]" : "bg-[var(--admin-accent)]/18 text-[var(--admin-text)]"}`}
|
||||
>
|
||||
{o.status}
|
||||
</span>
|
||||
) : (
|
||||
<span className="muted">—</span>
|
||||
)}
|
||||
</td>
|
||||
<td className="muted">
|
||||
{formatDate(o.createdAt, "date")}
|
||||
</td>
|
||||
</tr>
|
||||
);
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
)}
|
||||
</section>
|
||||
</main>
|
||||
</AdminPageShell>
|
||||
);
|
||||
}
|
||||
@@ -1,4 +1,7 @@
|
||||
import { Filter } from "lucide-react";
|
||||
import { redirect } from "next/navigation";
|
||||
import { getTranslations } from "next-intl/server";
|
||||
import { AdminPageShell } from "@/components/admin/admin-page-shell";
|
||||
import { canAccess, getAdminContext, PERMS } from "@/lib/permissions";
|
||||
import { prisma } from "@/lib/prisma";
|
||||
import { WordFilterClient } from "./wordfilter-client";
|
||||
@@ -9,6 +12,7 @@ export default async function AdminWordFilter() {
|
||||
redirect("/admin");
|
||||
}
|
||||
|
||||
const t = await getTranslations("pages.admin.wordfilter");
|
||||
const canEdit = canAccess(
|
||||
permissions,
|
||||
PERMS.WORDFILTER_EDIT,
|
||||
@@ -27,5 +31,9 @@ export default async function AdminWordFilter() {
|
||||
words = [];
|
||||
}
|
||||
|
||||
return <WordFilterClient words={words} canEdit={canEdit} />;
|
||||
return (
|
||||
<AdminPageShell icon={Filter} title={t("title")} subtitle={t("subtitle")}>
|
||||
<WordFilterClient words={words} canEdit={canEdit} />
|
||||
</AdminPageShell>
|
||||
);
|
||||
}
|
||||
+11
-7
@@ -102,14 +102,18 @@ export async function fetchAdminList<TRow = PrismaModel>(
|
||||
const { search, page, sort, order } = parsed;
|
||||
|
||||
// Build WHERE clause
|
||||
const searchWhere =
|
||||
const searchOr =
|
||||
search && config.searchFields.length > 0
|
||||
? {
|
||||
OR: config.searchFields.map((field) =>
|
||||
buildFieldCondition(field, search),
|
||||
),
|
||||
}
|
||||
: {};
|
||||
? config.searchFields.map((field) => buildFieldCondition(field, search))
|
||||
: [];
|
||||
// Exact numeric id match (furni / rooms / items lookup by id).
|
||||
if (search && /^\d+$/.test(search)) {
|
||||
const asId = Number(search);
|
||||
if (Number.isFinite(asId) && asId > 0) {
|
||||
searchOr.push({ id: asId });
|
||||
}
|
||||
}
|
||||
const searchWhere = searchOr.length > 0 ? { OR: searchOr } : {};
|
||||
|
||||
// Apply URL filter_* params via filterMap
|
||||
const filterWhere: Record<string, unknown> = {};
|
||||
|
||||
@@ -435,6 +435,13 @@ export const ADMIN_NAV_GROUPS: AdminNavGroup[] = [
|
||||
permission: PERMS.CATALOG_VIEW,
|
||||
matchPrefixes: ["/admin/catalog"],
|
||||
},
|
||||
{
|
||||
href: "/admin/items",
|
||||
labelKey: "itemsBase",
|
||||
icon: Package,
|
||||
permission: PERMS.CATALOG_VIEW,
|
||||
matchPrefixes: ["/admin/items"],
|
||||
},
|
||||
{
|
||||
href: "/admin/rare-values",
|
||||
labelKey: "rareValues",
|
||||
|
||||
@@ -40,6 +40,8 @@ const ROUTES: Array<[string, string]> = [
|
||||
["housekeeping", "PERMS.SETTINGS_VIEW"],
|
||||
["logs", "PERMS.LOGS_VIEW"],
|
||||
["catalog", "PERMS.CATALOG_VIEW"],
|
||||
["items", "PERMS.CATALOG_VIEW"],
|
||||
["items/[id]", "PERMS.CATALOG_VIEW"],
|
||||
["rooms/edit/[id]", "PERMS.ROOMS_EDIT"],
|
||||
];
|
||||
|
||||
@@ -64,6 +66,7 @@ const ACTION_GATES: Array<[string, string]> = [
|
||||
["admin-shop.ts", "PERMS.SHOP_EDIT"],
|
||||
["admin-radio-autodj.ts", "PERMS.RADIO_EDIT"],
|
||||
["catalog.ts", "PERMS.CATALOG_EDIT"],
|
||||
["items-base.ts", "PERMS.CATALOG_EDIT"],
|
||||
["rooms.ts", "PERMS.ROOMS_EDIT"],
|
||||
["admin-vpn.ts", "PERMS.SETTINGS_EDIT"],
|
||||
["admin-ads.ts", "PERMS.PAGES_EDIT"],
|
||||
|
||||
@@ -82,4 +82,15 @@ describe("staff smoke contract", () => {
|
||||
expect(readFileSync(path, "utf8"), path).toContain("TicketQueueBanner");
|
||||
}
|
||||
});
|
||||
|
||||
it("ships items_base browser", () => {
|
||||
expect(existsSync("src/app/admin/items/page.tsx")).toBe(true);
|
||||
expect(existsSync("src/app/admin/items/[id]/page.tsx")).toBe(true);
|
||||
expect(readFileSync("src/actions/items-base.ts", "utf8")).toContain(
|
||||
"updateItemsBase",
|
||||
);
|
||||
expect(readFileSync("src/lib/admin-nav.ts", "utf8")).toContain(
|
||||
"/admin/items",
|
||||
);
|
||||
});
|
||||
});
|
||||
+36
-2
@@ -909,7 +909,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Табло за управление",
|
||||
@@ -2865,7 +2866,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
+36
-2
@@ -909,7 +909,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Dashboard",
|
||||
@@ -2865,7 +2866,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
+36
-2
@@ -909,7 +909,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Dashboard",
|
||||
@@ -2865,7 +2866,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
+36
-2
@@ -879,7 +879,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Dashboard",
|
||||
@@ -2835,7 +2836,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"radioRequests": {
|
||||
|
||||
+36
-2
@@ -909,7 +909,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Ταμπλό",
|
||||
@@ -2865,7 +2866,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
@@ -1004,6 +1004,7 @@
|
||||
"hubCatalog": "Catalog & rares",
|
||||
"hubShop": "Shop & payments",
|
||||
"catalog": "Catalog",
|
||||
"itemsBase": "Items base",
|
||||
"shop": "Shop",
|
||||
"marketplace": "Marketplace",
|
||||
"transactions": "Transactions",
|
||||
@@ -1662,6 +1663,38 @@
|
||||
"cancel": "Cancel"
|
||||
}
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"catalog": {
|
||||
"title": "Catalog",
|
||||
"subtitle": "Browse and manage catalog pages and items",
|
||||
@@ -1805,6 +1838,7 @@
|
||||
"title": "Guilds",
|
||||
"subtitle": "Hotel groups and membership",
|
||||
"totalGuilds": "Guilds",
|
||||
"listHeading": "Guilds ({count})",
|
||||
"searchPlaceholder": "Search by name, description or ID…",
|
||||
"search": "Search",
|
||||
"empty": "No guilds found.",
|
||||
|
||||
+36
-2
@@ -879,7 +879,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Panel",
|
||||
@@ -2835,7 +2836,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"radioRequests": {
|
||||
|
||||
+36
-2
@@ -879,7 +879,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Tableau de bord",
|
||||
@@ -2835,7 +2836,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"radioRequests": {
|
||||
|
||||
+36
-2
@@ -909,7 +909,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Nadzorna ploča",
|
||||
@@ -2865,7 +2866,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
+36
-2
@@ -909,7 +909,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Irányítópult",
|
||||
@@ -2865,7 +2866,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
+36
-2
@@ -1032,7 +1032,8 @@
|
||||
"commandLog": "Log comandi",
|
||||
"tradeLog": "Log trade",
|
||||
"tools": "Strumenti",
|
||||
"guilds": "Gruppi"
|
||||
"guilds": "Gruppi",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Dashboard",
|
||||
@@ -1799,7 +1800,8 @@
|
||||
"noMembers": "Nessun membro.",
|
||||
"back": "Torna ai gruppi",
|
||||
"viewPublic": "Apri pagina pubblica",
|
||||
"disband": "Sciogli gruppo"
|
||||
"disband": "Sciogli gruppo",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"transactions": {
|
||||
"title": "Transazioni",
|
||||
@@ -2989,6 +2991,38 @@
|
||||
"less": "Meno",
|
||||
"more": "Più"
|
||||
}
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"radioRequests": {
|
||||
|
||||
+36
-2
@@ -1062,7 +1062,8 @@
|
||||
"chatLog": "Chatlog",
|
||||
"commandLog": "Commandolog",
|
||||
"tradeLog": "Tradelog",
|
||||
"tools": "Tools"
|
||||
"tools": "Tools",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Dashboard",
|
||||
@@ -1751,7 +1752,8 @@
|
||||
"noMembers": "Geen leden.",
|
||||
"back": "Terug naar gildes",
|
||||
"viewPublic": "Openbare pagina",
|
||||
"disband": "Gilde ontbinden"
|
||||
"disband": "Gilde ontbinden",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"transactions": {
|
||||
"title": "Transacties",
|
||||
@@ -3017,6 +3019,38 @@
|
||||
"less": "Minder",
|
||||
"more": "Meer"
|
||||
}
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"mod": {
|
||||
|
||||
+36
-2
@@ -909,7 +909,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Dashbord",
|
||||
@@ -2865,7 +2866,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
+36
-2
@@ -909,7 +909,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Pulpit nawigacyjny",
|
||||
@@ -2865,7 +2866,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
+36
-2
@@ -909,7 +909,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Painel",
|
||||
@@ -2865,7 +2866,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
+36
-2
@@ -909,7 +909,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Tabloul de bord",
|
||||
@@ -2865,7 +2866,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
+36
-2
@@ -907,7 +907,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Панель управления",
|
||||
@@ -2863,7 +2864,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
+36
-2
@@ -909,7 +909,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Dashboard",
|
||||
@@ -2865,7 +2866,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
+36
-2
@@ -909,7 +909,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Дасхбоард",
|
||||
@@ -2865,7 +2866,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
+36
-2
@@ -909,7 +909,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Instrumentbräda",
|
||||
@@ -2865,7 +2866,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
+36
-2
@@ -909,7 +909,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Kontrol Paneli",
|
||||
@@ -2865,7 +2866,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
+36
-2
@@ -909,7 +909,8 @@
|
||||
"commandLog": "Command log",
|
||||
"tradeLog": "Trade log",
|
||||
"tools": "Tools",
|
||||
"guilds": "Guilds"
|
||||
"guilds": "Guilds",
|
||||
"itemsBase": "Items base"
|
||||
},
|
||||
"dashboard": {
|
||||
"title": "Приладова панель",
|
||||
@@ -2865,7 +2866,40 @@
|
||||
"noMembers": "No members.",
|
||||
"back": "Back to guilds",
|
||||
"viewPublic": "Open public page",
|
||||
"disband": "Disband guild"
|
||||
"disband": "Disband guild",
|
||||
"listHeading": "Guilds ({count})"
|
||||
},
|
||||
"items": {
|
||||
"title": "Items base",
|
||||
"subtitle": "Browse and edit furni definitions in items_base (standalone from catalog pages)",
|
||||
"total": "{count, plural, one {# item} other {# items}}",
|
||||
"editTitle": "Edit {name}",
|
||||
"editSubtitle": "items_base #{id}",
|
||||
"back": "Back to list",
|
||||
"save": "Save",
|
||||
"saved": "Item saved",
|
||||
"untitled": "Untitled item",
|
||||
"sectionIdentity": "Identity",
|
||||
"sectionDims": "Dimensions & interaction",
|
||||
"sectionFlags": "Allow flags",
|
||||
"sectionExtra": "Extra",
|
||||
"publicName": "Public name",
|
||||
"itemName": "Classname",
|
||||
"type": "Type",
|
||||
"spriteId": "Sprite ID",
|
||||
"width": "Width",
|
||||
"length": "Length",
|
||||
"stackHeight": "Stack height",
|
||||
"interactionType": "Interaction",
|
||||
"interactionModes": "Modes",
|
||||
"vendingIds": "Vending IDs",
|
||||
"multiheight": "Multiheight",
|
||||
"customparams": "Custom params"
|
||||
},
|
||||
"online": {
|
||||
"title": "Online users",
|
||||
"subtitle": "Players currently connected",
|
||||
"connected": "{count, plural, one {# player connected} other {# players connected}}"
|
||||
}
|
||||
},
|
||||
"error": {
|
||||
|
||||
Reference in new issue
Block a user