diff --git a/apps/web/src/LogsViewer.tsx b/apps/web/src/LogsViewer.tsx index 7b7a519..4fe903d 100644 --- a/apps/web/src/LogsViewer.tsx +++ b/apps/web/src/LogsViewer.tsx @@ -94,7 +94,7 @@ export function LogsViewer() { } return ( -
{t("setup.intro")}
{err}
{t("shifts.none")}
{t("shifts.selectAShift")}
{t("common.loading")}
{t("shifts.noActivity")}
{t("shift.endConfirm")}
diff --git a/apps/web/src/TariffLab.tsx b/apps/web/src/TariffLab.tsx index 46807d7..73d4293 100644 --- a/apps/web/src/TariffLab.tsx +++ b/apps/web/src/TariffLab.tsx @@ -113,7 +113,7 @@ export function TariffLab() { const currency = result?.currency ?? state?.active?.currency ?? "ALL"; return ( - + {t("lab.title")} {t("lab.intro")} diff --git a/apps/web/src/UsersManager.tsx b/apps/web/src/UsersManager.tsx index 9f74ee2..b1cb4f5 100644 --- a/apps/web/src/UsersManager.tsx +++ b/apps/web/src/UsersManager.tsx @@ -41,7 +41,7 @@ export function UsersManager({ user }: { user: SessionUser | null }) { setError(e instanceof ApiError ? e.message : (e as Error).message); return ( - + {t("users.title")} {canCreate && roles.length > 0 && ( diff --git a/apps/web/src/lib/i18n/en.ts b/apps/web/src/lib/i18n/en.ts index 6c741f4..c78adcc 100644 --- a/apps/web/src/lib/i18n/en.ts +++ b/apps/web/src/lib/i18n/en.ts @@ -568,6 +568,7 @@ export const en: Catalog = { starting: "Starting…", endShift: "End shift", ending: "Ending…", + endConfirm: "End this shift? A signed Z-report is recorded and printed.", drawer: "Drawer:", openingFloatInherited: "(opening float inherited from the prior shift)", drawerCashAdmin: "Drawer cash (admin) — load or remove the float", @@ -640,6 +641,7 @@ export const en: Catalog = { preset_custom: "Custom", selectAShift: "Select a shift to see its activity log.", noActivity: "No activity in this shift.", + current: "current", drawerSection: "Drawer", openingFloat: "Opening float", cashTaken: "Cash taken", diff --git a/apps/web/src/lib/i18n/sq.ts b/apps/web/src/lib/i18n/sq.ts index 33e2539..7cfdead 100644 --- a/apps/web/src/lib/i18n/sq.ts +++ b/apps/web/src/lib/i18n/sq.ts @@ -580,6 +580,7 @@ export const sq = { starting: "Duke filluar…", endShift: "Mbyll turnin", ending: "Duke mbyllur…", + endConfirm: "Të mbyllet ky turn? Regjistrohet dhe printohet një Raport Z i nënshkruar.", drawer: "Arka:", openingFloatInherited: "(bilanci fillestar i trashëguar nga turni i mëparshëm)", drawerCashAdmin: "Para në arkë (admin) — shto ose hiq bilancin", @@ -653,6 +654,7 @@ export const sq = { preset_custom: "E zgjedhur", selectAShift: "Zgjidh një turn për të parë aktivitetin e tij.", noActivity: "Asnjë aktivitet në këtë turn.", + current: "aktual", // Expanded drawer detail. drawerSection: "Arka", openingFloat: "Bilanci fillestar", diff --git a/apps/web/src/router.tsx b/apps/web/src/router.tsx index 8346969..1c7cc54 100644 --- a/apps/web/src/router.tsx +++ b/apps/web/src/router.tsx @@ -24,7 +24,6 @@ import { TariffComposer } from "./TariffComposer.js"; import { TariffLab } from "./TariffLab.js"; import { SubscriptionManager } from "./SubscriptionManager.js"; import { SubscriptionPlansManager } from "./SubscriptionPlansManager.js"; -import { ShiftControl } from "./ShiftControl.js"; import { SiteSettings } from "./SiteSettings.js"; import { UsersManager } from "./UsersManager.js"; import { RolesManager } from "./RolesManager.js"; @@ -78,7 +77,7 @@ function SetupLayout() { const { t } = useTranslation(); const show = (perm: Permission) => can(user, perm); return ( - + {show("site:update") && } {show("tariff:read") && } @@ -344,18 +343,16 @@ const shiftRoute = createRoute({ path: "/shift", component: function ShiftRoute() { const { user } = rootRoute.useRouteContext(); - // Top: the shift CONTROL (open/close, drawer vouchers, X-report). The drawer-voucher - // form is operator-RAISED (shift:create); an admin authorizes with their password. - // Below: the shift LIST + per-shift activity log (scoped server-side by permission). + // The shift hub: list (current/open shift on top + history) + per-shift activity log. + // The CURRENT shift's pane carries the actions (open/close, drawer voucher, takings), + // each opening a modal. `canManage` = shift:create (start/end + raise vouchers); a + // voucher additionally needs an admin's password sign-off server-side. return ( - - - {can(user, "shift:read") && ( - - - - )} - + ); }, });
{t("lab.intro")}