diff --git a/apps/judicial-system/backend/src/app/modules/defendant/guards/rolesRules.ts b/apps/judicial-system/backend/src/app/modules/defendant/guards/rolesRules.ts index 7a04aa32efff..94577db1a405 100644 --- a/apps/judicial-system/backend/src/app/modules/defendant/guards/rolesRules.ts +++ b/apps/judicial-system/backend/src/app/modules/defendant/guards/rolesRules.ts @@ -1,5 +1,6 @@ import { RolesRule, RulesType } from '@island.is/judicial-system/auth' import { UserRole } from '@island.is/judicial-system/types' + import { UpdateDefendantDto } from '../dto/updateDefendant.dto' const limitedAccessFields: (keyof UpdateDefendantDto)[] = ['punishmentType'] diff --git a/apps/judicial-system/backend/src/app/modules/defendant/limitedAccessDefendant.controller.ts b/apps/judicial-system/backend/src/app/modules/defendant/limitedAccessDefendant.controller.ts index 2cd5e184b9ce..72c928841396 100644 --- a/apps/judicial-system/backend/src/app/modules/defendant/limitedAccessDefendant.controller.ts +++ b/apps/judicial-system/backend/src/app/modules/defendant/limitedAccessDefendant.controller.ts @@ -1,29 +1,31 @@ import { - JwtAuthGuard, - RolesGuard, - RolesRules, - CurrentHttpUser, -} from '@island.is/judicial-system/auth' -import { ServiceRequirement, User } from '@island.is/judicial-system/types' -import { LOGGER_PROVIDER } from '@island.is/logging' -import { + Body, Controller, - UseGuards, Inject, - Patch, Param, - Body, + Patch, + UseGuards, } from '@nestjs/common' -import { ApiTags, ApiOkResponse } from '@nestjs/swagger' -import { prisonSystemStaffRule } from '../../guards' -import { CaseExistsGuard, CurrentCase, Case } from '../case' -import { DefendantService } from './defendant.service' +import { ApiOkResponse,ApiTags } from '@nestjs/swagger' + +import type { Logger } from '@island.is/logging' +import { LOGGER_PROVIDER } from '@island.is/logging' + +import { + CurrentHttpUser, + JwtAuthGuard, + RolesGuard, + RolesRules, +} from '@island.is/judicial-system/auth' +import { User } from '@island.is/judicial-system/types' + +import { Case,CaseExistsGuard, CurrentCase } from '../case' import { UpdateDefendantDto } from './dto/updateDefendant.dto' import { CurrentDefendant } from './guards/defendant.decorator' import { DefendantExistsGuard } from './guards/defendantExists.guard' -import { Defendant } from './models/defendant.model' -import type { Logger } from '@island.is/logging' import { prisonSystemStaffUpdateRule } from './guards/rolesRules' +import { Defendant } from './models/defendant.model' +import { DefendantService } from './defendant.service' interface LimitedAccessUpdateDefendant extends Pick {} diff --git a/apps/judicial-system/web/src/routes/Prison/IndictmentOverview/IndictmentOverview.strings.ts b/apps/judicial-system/web/src/routes/Prison/IndictmentOverview/IndictmentOverview.strings.ts index 063bc7ae7676..36e6d6b19fbd 100644 --- a/apps/judicial-system/web/src/routes/Prison/IndictmentOverview/IndictmentOverview.strings.ts +++ b/apps/judicial-system/web/src/routes/Prison/IndictmentOverview/IndictmentOverview.strings.ts @@ -48,8 +48,8 @@ export const strings = defineMessages({ defaultMessage: 'Sekt', description: 'Notaður sem texti í sekt valmöguleika í Refsitegund', }, - indictmentRulingDecisionfine: { - id: 'judicial.system.core:court.indictment_overview.punishmentType.indictmentRulingDecisionfine', + indictmentRulingDecisionFine: { + id: 'judicial.system.core:court.indictment_overview.punishmentType.indictmentRulingDecisionFine', defaultMessage: 'Viðurlagaákvörðun', description: 'Notaður sem texti í viðurlagaákvörðun í Refsitegund', }, diff --git a/apps/judicial-system/web/src/routes/Prison/IndictmentOverview/IndictmentOverview.tsx b/apps/judicial-system/web/src/routes/Prison/IndictmentOverview/IndictmentOverview.tsx index 33a43cc5bfd9..2eca57e7c2d9 100644 --- a/apps/judicial-system/web/src/routes/Prison/IndictmentOverview/IndictmentOverview.tsx +++ b/apps/judicial-system/web/src/routes/Prison/IndictmentOverview/IndictmentOverview.tsx @@ -4,6 +4,7 @@ import { useIntl } from 'react-intl' import { Box, RadioButton, Text } from '@island.is/island-ui/core' import * as constants from '@island.is/judicial-system/consts' import { formatDate } from '@island.is/judicial-system/formatters' +import { PunishmentType } from '@island.is/judicial-system/types' import { core } from '@island.is/judicial-system-web/messages' import { BlueBox, @@ -18,16 +19,13 @@ import { } from '@island.is/judicial-system-web/src/components' import { CaseFileCategory, - Defendant, } from '@island.is/judicial-system-web/src/graphql/schema' import { - useCase, useDefendants, useFileList, } from '@island.is/judicial-system-web/src/utils/hooks' import { strings } from './IndictmentOverview.strings' -import { PunishmentType } from '@island.is/judicial-system/types' const IndictmentOverview = () => { const { workingCase } = useContext(FormContext) @@ -166,7 +164,7 @@ const IndictmentOverview = () => { }} large backgroundColor="white" - label={formatMessage(strings.indictmentRulingDecisionfine)} + label={formatMessage(strings.indictmentRulingDecisionFine)} />