Loading portal-gui/src/features/profile/profile.tsx +2 −14 Changes for portal-gui/src/features/profile/profile.tsx: 2 added lines, 14 removed lines. Original line number Diff line number Diff line import type { ReactNode } from 'react'; import { CheckIcon, ExternalLinkIcon } from 'lucide-react'; import { CheckIcon } from 'lucide-react'; import { PageContent } from '@/components/common/page-content'; import { PageHeader } from '@/components/common/page-header'; import { Badge } from '@/components/ui/badge'; import { Button } from '@/components/ui/button'; import { Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, } from '@/components/ui/card'; Loading Loading @@ -103,8 +101,7 @@ export function ProfilePage() { <CardHeader> <CardTitle>Account</CardTitle> <CardDescription> Your name, email and password are managed in your OpenOP account. Your account details. Ask an administrator to change them. </CardDescription> </CardHeader> Loading @@ -130,15 +127,6 @@ export function ProfilePage() { </Field> </dl> </CardContent> <CardFooter> <Button asChild variant="outline"> <a href={user.account_url} target="_blank" rel="noreferrer"> Manage account <ExternalLinkIcon /> </a> </Button> </CardFooter> </Card> <Card> Loading portal-gui/src/types/authentication.ts +0 −1 Changes for portal-gui/src/types/authentication.ts: 0 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -16,7 +16,6 @@ export type CurrentUser = { organization: string | null; // The token's API scopes (CAMARA), without the OpenID Connect ones. scopes: string[]; account_url: string; }; export type LogoutResponse = { Loading src/portal_service/api/auth/schemas.py +0 −2 Changes for src/portal_service/api/auth/schemas.py: 0 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -12,7 +12,6 @@ class CurrentUser(BaseModel): roles: list[str] = [] organization: str | None = None scopes: list[str] = [] account_url: str @classmethod def from_claims(cls, claims: TokenClaims) -> "CurrentUser": Loading @@ -24,7 +23,6 @@ class CurrentUser(BaseModel): roles=sorted(claims.roles), organization=claims.organization, scopes=sorted(claims.api_scopes), account_url=f"{claims.iss}/account", ) Loading tests/unit/test_me_route.py +0 −2 Changes for tests/unit/test_me_route.py: 0 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -15,7 +15,6 @@ from fastapi.testclient import TestClient from portal_service.api.dependencies import get_identity_provider, get_login_session_repo from portal_service.application.session_crypto import SessionCredentials, encrypt_tokens from portal_service.domain.models import LoginSession, SessionTokens from tests.conftest import ISSUER from tests.fakes import FakeIdentityProvider, FakeLoginSessionRepository SESSION_COOKIE = "oop_session" Loading Loading @@ -91,7 +90,6 @@ def test_answers_with_the_user_behind_the_cookie( "organization": "dev-org", # Only the API scopes, sorted; the OpenID Connect ones are left out. "scopes": ["location-retrieval:read", "qod-sessions-read"], "account_url": f"{ISSUER}/account", } Loading Loading
portal-gui/src/features/profile/profile.tsx +2 −14 Changes for portal-gui/src/features/profile/profile.tsx: 2 added lines, 14 removed lines. Original line number Diff line number Diff line import type { ReactNode } from 'react'; import { CheckIcon, ExternalLinkIcon } from 'lucide-react'; import { CheckIcon } from 'lucide-react'; import { PageContent } from '@/components/common/page-content'; import { PageHeader } from '@/components/common/page-header'; import { Badge } from '@/components/ui/badge'; import { Button } from '@/components/ui/button'; import { Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, } from '@/components/ui/card'; Loading Loading @@ -103,8 +101,7 @@ export function ProfilePage() { <CardHeader> <CardTitle>Account</CardTitle> <CardDescription> Your name, email and password are managed in your OpenOP account. Your account details. Ask an administrator to change them. </CardDescription> </CardHeader> Loading @@ -130,15 +127,6 @@ export function ProfilePage() { </Field> </dl> </CardContent> <CardFooter> <Button asChild variant="outline"> <a href={user.account_url} target="_blank" rel="noreferrer"> Manage account <ExternalLinkIcon /> </a> </Button> </CardFooter> </Card> <Card> Loading
portal-gui/src/types/authentication.ts +0 −1 Changes for portal-gui/src/types/authentication.ts: 0 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -16,7 +16,6 @@ export type CurrentUser = { organization: string | null; // The token's API scopes (CAMARA), without the OpenID Connect ones. scopes: string[]; account_url: string; }; export type LogoutResponse = { Loading
src/portal_service/api/auth/schemas.py +0 −2 Changes for src/portal_service/api/auth/schemas.py: 0 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -12,7 +12,6 @@ class CurrentUser(BaseModel): roles: list[str] = [] organization: str | None = None scopes: list[str] = [] account_url: str @classmethod def from_claims(cls, claims: TokenClaims) -> "CurrentUser": Loading @@ -24,7 +23,6 @@ class CurrentUser(BaseModel): roles=sorted(claims.roles), organization=claims.organization, scopes=sorted(claims.api_scopes), account_url=f"{claims.iss}/account", ) Loading
tests/unit/test_me_route.py +0 −2 Changes for tests/unit/test_me_route.py: 0 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -15,7 +15,6 @@ from fastapi.testclient import TestClient from portal_service.api.dependencies import get_identity_provider, get_login_session_repo from portal_service.application.session_crypto import SessionCredentials, encrypt_tokens from portal_service.domain.models import LoginSession, SessionTokens from tests.conftest import ISSUER from tests.fakes import FakeIdentityProvider, FakeLoginSessionRepository SESSION_COOKIE = "oop_session" Loading Loading @@ -91,7 +90,6 @@ def test_answers_with_the_user_behind_the_cookie( "organization": "dev-org", # Only the API scopes, sorted; the OpenID Connect ones are left out. "scopes": ["location-retrieval:read", "qod-sessions-read"], "account_url": f"{ISSUER}/account", } Loading