diff options
author | Sebastian <sebasjm@gmail.com> | 2024-04-03 15:31:28 -0300 |
---|---|---|
committer | Sebastian <sebasjm@gmail.com> | 2024-04-03 15:31:28 -0300 |
commit | c7e68c254aa93778b8201227d6db1ac57e081e81 (patch) | |
tree | b5d34651a8d17180826dcd4f09bb808f2f080b21 /packages/merchant-backoffice-ui/src/paths/instance/templates | |
parent | 4bf1ab8ba924b2a0fc4813814bdeeb66a2928382 (diff) | |
download | wallet-core-c7e68c254aa93778b8201227d6db1ac57e081e81.tar.xz |
wip #8655: unauthorized not documented
Diffstat (limited to 'packages/merchant-backoffice-ui/src/paths/instance/templates')
4 files changed, 20 insertions, 4 deletions
diff --git a/packages/merchant-backoffice-ui/src/paths/instance/templates/list/index.tsx b/packages/merchant-backoffice-ui/src/paths/instance/templates/list/index.tsx index 5a8be71b0..23bc95943 100644 --- a/packages/merchant-backoffice-ui/src/paths/instance/templates/list/index.tsx +++ b/packages/merchant-backoffice-ui/src/paths/instance/templates/list/index.tsx @@ -38,6 +38,7 @@ import { import { Notification } from "../../../../utils/types.js"; import { NotFoundPageOrAdminCreate } from "../../../notfound/index.js"; import { ListPage } from "./ListPage.js"; +import { LoginPage } from "../../../login/index.js"; interface Props { onCreate: () => void; @@ -69,8 +70,11 @@ export default function ListTemplates({ case HttpStatusCode.NotFound: { return <NotFoundPageOrAdminCreate /> } + case HttpStatusCode.Unauthorized: { + return <LoginPage /> + } default: { - assertUnreachable(result.case) + assertUnreachable(result) } } } diff --git a/packages/merchant-backoffice-ui/src/paths/instance/templates/qr/index.tsx b/packages/merchant-backoffice-ui/src/paths/instance/templates/qr/index.tsx index 3464fb04e..ed809c7b3 100644 --- a/packages/merchant-backoffice-ui/src/paths/instance/templates/qr/index.tsx +++ b/packages/merchant-backoffice-ui/src/paths/instance/templates/qr/index.tsx @@ -28,6 +28,7 @@ import { } from "../../../../hooks/templates.js"; import { NotFoundPageOrAdminCreate } from "../../../notfound/index.js"; import { QrPage } from "./QrPage.js"; +import { LoginPage } from "../../../login/index.js"; export type Entity = TalerMerchantApi.TransferInformation; interface Props { @@ -49,8 +50,11 @@ export default function TemplateQrPage({ case HttpStatusCode.NotFound: { return <NotFoundPageOrAdminCreate /> } + case HttpStatusCode.Unauthorized: { + return <LoginPage /> + } default: { - assertUnreachable(result.case) + assertUnreachable(result) } } } diff --git a/packages/merchant-backoffice-ui/src/paths/instance/templates/update/index.tsx b/packages/merchant-backoffice-ui/src/paths/instance/templates/update/index.tsx index 1ff4b56cf..5fc8bee93 100644 --- a/packages/merchant-backoffice-ui/src/paths/instance/templates/update/index.tsx +++ b/packages/merchant-backoffice-ui/src/paths/instance/templates/update/index.tsx @@ -36,6 +36,7 @@ import { import { Notification } from "../../../../utils/types.js"; import { NotFoundPageOrAdminCreate } from "../../../notfound/index.js"; import { UpdatePage } from "./UpdatePage.js"; +import { LoginPage } from "../../../login/index.js"; export type Entity = TalerMerchantApi.TemplatePatchDetails & WithId; @@ -65,8 +66,11 @@ export default function UpdateTemplate({ case HttpStatusCode.NotFound: { return <NotFoundPageOrAdminCreate /> } + case HttpStatusCode.Unauthorized: { + return <LoginPage /> + } default: { - assertUnreachable(result.case) + assertUnreachable(result) } } } diff --git a/packages/merchant-backoffice-ui/src/paths/instance/templates/use/index.tsx b/packages/merchant-backoffice-ui/src/paths/instance/templates/use/index.tsx index 0073ca574..d631cef96 100644 --- a/packages/merchant-backoffice-ui/src/paths/instance/templates/use/index.tsx +++ b/packages/merchant-backoffice-ui/src/paths/instance/templates/use/index.tsx @@ -35,6 +35,7 @@ import { import { Notification } from "../../../../utils/types.js"; import { NotFoundPageOrAdminCreate } from "../../../notfound/index.js"; import { UsePage } from "./UsePage.js"; +import { LoginPage } from "../../../login/index.js"; export type Entity = TalerMerchantApi.TransferInformation; interface Props { @@ -62,8 +63,11 @@ export default function TemplateUsePage({ case HttpStatusCode.NotFound: { return <NotFoundPageOrAdminCreate /> } + case HttpStatusCode.Unauthorized: { + return <LoginPage /> + } default: { - assertUnreachable(result.case) + assertUnreachable(result) } } } |