Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VB-3521/VB-3557/VB-3559/VB-3558/VB-3560/Change additional support page - single text field #729

Merged
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion server/@types/bapv.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ export type VisitSessionData = {
originalVisitSlot?: VisitSlot
visitRestriction?: 'OPEN' | 'CLOSED'
visitors?: VisitorListItem[]
visitorSupport?: VisitorSupport[]
visitorSupport?: VisitorSupport
mainContact?: {
contact?: VisitorListItem
phoneNumber: string
Expand Down
2 changes: 0 additions & 2 deletions server/@types/express/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import { SupportType } from '../../data/orchestrationApiTypes'
import { VisitorListItem, VisitSessionData, Prison } from '../bapv'
import { UserDetails } from '../../services/userService'

Expand All @@ -9,7 +8,6 @@ declare module 'express-session' {
interface SessionData {
returnTo: string
nowInMinutes: number
availableSupportTypes: SupportType[]
visitorList: { visitors: VisitorListItem[] }
adultVisitors: { adults: VisitorListItem[] }
slotsList: VisitSlotList
Expand Down
75 changes: 14 additions & 61 deletions server/@types/orchestration-api.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -96,13 +96,6 @@ export interface paths {
*/
get: operations['getNotificationCount']
}
'/visit-support': {
/**
* Available Support
* @description Retrieve all available support types
*/
get: operations['getSupportTypes']
}
'/visit-sessions': {
/**
* Returns all visit sessions which are within the reservable time period - whether or not they are full
Expand Down Expand Up @@ -324,8 +317,7 @@ export interface components {
visitContact?: components['schemas']['ContactDto']
/** @description List of visitors associated with the visit */
visitors?: components['schemas']['VisitorDto'][]
/** @description List of additional support associated with the visit */
visitorSupport?: components['schemas']['VisitorSupportDto'][]
visitorSupport?: components['schemas']['VisitorSupportDto']
/**
* Format: date-time
* @description The visit created date and time
Expand Down Expand Up @@ -369,16 +361,11 @@ export interface components {
}
/** @description Visitor support */
VisitorSupportDto: {
/**
* @description Support type
* @example OTHER
*/
type: string
/**
* @description Support text description
* @example visually impaired assistance
*/
text?: string
description: string
}
BookingOrchestrationRequestDto: {
/**
Expand All @@ -394,6 +381,14 @@ export interface components {
| 'NOT_APPLICABLE'
| 'BY_PRISONER'
}
/** @description Visitor support */
ApplicationSupportDto: {
/**
* @description Support text description, if empty is given then existing support text will be removed
* @example visually impaired assistance
*/
description: string
}
ChangeApplicationDto: {
/**
* @description Visit Restriction
Expand All @@ -415,8 +410,7 @@ export interface components {
visitContact?: components['schemas']['ContactDto']
/** @description List of visitors associated with the visit */
visitors: components['schemas']['VisitorDto'][]
/** @description List of additional support associated with the visit */
visitorSupport?: components['schemas']['VisitorSupportDto'][]
visitorSupport?: components['schemas']['ApplicationSupportDto']
}
/** @description Visit */
ApplicationDto: {
Expand Down Expand Up @@ -467,8 +461,7 @@ export interface components {
visitContact?: components['schemas']['ContactDto']
/** @description List of visitors associated with the visit */
visitors: components['schemas']['VisitorDto'][]
/** @description List of additional support associated with the visit */
visitorSupport: components['schemas']['VisitorSupportDto'][]
visitorSupport?: components['schemas']['VisitorSupportDto']
/**
* Format: date-time
* @description The visit created date and time
Expand Down Expand Up @@ -516,8 +509,7 @@ export interface components {
visitContact?: components['schemas']['ContactDto']
/** @description List of visitors associated with the visit */
visitors: components['schemas']['VisitorDto'][]
/** @description List of additional support associated with the visit */
visitorSupport?: components['schemas']['VisitorSupportDto'][]
visitorSupport?: components['schemas']['ApplicationSupportDto']
}
DlqMessage: {
body: {
Expand Down Expand Up @@ -636,8 +628,8 @@ export interface components {
pageSize?: number
/** Format: int32 */
pageNumber?: number
paged?: boolean
unpaged?: boolean
paged?: boolean
}
SortObject: {
empty?: boolean
Expand Down Expand Up @@ -696,19 +688,6 @@ export interface components {
/** Format: int32 */
count: number
}
/** @description Support Type */
SupportTypeDto: {
/**
* @description Support type name
* @example MASK_EXEMPT
*/
type: string
/**
* @description Support description
* @example Face covering exemption
*/
description: string
}
/** @description Visit Session */
VisitSessionDto: {
/**
Expand Down Expand Up @@ -1749,32 +1728,6 @@ export interface operations {
}
}
}
/**
* Available Support
* @description Retrieve all available support types
*/
getSupportTypes: {
responses: {
/** @description Available Support information returned */
200: {
content: {
'*/*': components['schemas']['SupportTypeDto'][]
}
}
/** @description Incorrect request to Get Available Support */
400: {
content: {
'application/json': components['schemas']['ErrorResponse']
}
}
/** @description Unauthorized to access this endpoint */
401: {
content: {
'application/json': components['schemas']['ErrorResponse']
}
}
}
}
/**
* Returns all visit sessions which are within the reservable time period - whether or not they are full
* @description Retrieve all visits for a specified prisoner
Expand Down
83 changes: 66 additions & 17 deletions server/@types/prison-api.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1577,6 +1577,10 @@ export interface paths {
*/
get: operations['getPrisonerEducations']
}
'/api/court/{bookingId}/next-court-event': {
/** Returns the next court event details (if one exists) related to the passed in booking */
get: operations['getNextCourtEvent']
}
'/api/court-date-results/{offenderNo}': {
/**
* Returns details of all court dates and the result of each.
Expand Down Expand Up @@ -7312,10 +7316,10 @@ export interface components {
establishmentName: string
}
PageString: {
/** Format: int32 */
totalPages?: number
/** Format: int64 */
totalElements?: number
/** Format: int32 */
totalPages?: number
first?: boolean
last?: boolean
/** Format: int32 */
Expand All @@ -7337,8 +7341,8 @@ export interface components {
pageSize?: number
/** Format: int32 */
pageNumber?: number
paged?: boolean
unpaged?: boolean
paged?: boolean
}
SortObject: {
empty?: boolean
Expand Down Expand Up @@ -7559,10 +7563,10 @@ export interface components {
code?: string
}
PageCalculableSentenceEnvelope: {
/** Format: int32 */
totalPages?: number
/** Format: int64 */
totalElements?: number
/** Format: int32 */
totalPages?: number
first?: boolean
last?: boolean
/** Format: int32 */
Expand Down Expand Up @@ -9316,10 +9320,10 @@ export interface components {
additionalAnswers?: string[]
}
PageOffenceDto: {
/** Format: int32 */
totalPages?: number
/** Format: int64 */
totalElements?: number
/** Format: int32 */
totalPages?: number
first?: boolean
last?: boolean
/** Format: int32 */
Expand Down Expand Up @@ -10093,10 +10097,10 @@ export interface components {
numberOfMembers: number
}
PageEducation: {
/** Format: int32 */
totalPages?: number
/** Format: int64 */
totalElements?: number
/** Format: int32 */
totalPages?: number
first?: boolean
last?: boolean
/** Format: int32 */
Expand All @@ -10110,6 +10114,16 @@ export interface components {
pageable?: components['schemas']['PageableObject']
empty?: boolean
}
CourtEventDetails: {
/** Format: int64 */
eventId: number
/** @example 2021-07-05T10:35:17 */
startTime: string
courtLocation: string
courtEventType: string
comments?: string
caseReference?: string
}
/** @description A charge linked to a court date */
CourtDateCharge: {
/**
Expand Down Expand Up @@ -10309,10 +10323,10 @@ export interface components {
hasVisits: boolean
}
PageVisitWithVisitors: {
/** Format: int32 */
totalPages?: number
/** Format: int64 */
totalElements?: number
/** Format: int32 */
totalPages?: number
first?: boolean
last?: boolean
/** Format: int32 */
Expand Down Expand Up @@ -10679,10 +10693,10 @@ export interface components {
otherContacts: components['schemas']['Contact'][]
}
PageBedAssignment: {
/** Format: int32 */
totalPages?: number
/** Format: int64 */
totalElements?: number
/** Format: int32 */
totalPages?: number
first?: boolean
last?: boolean
/** Format: int32 */
Expand Down Expand Up @@ -10737,10 +10751,10 @@ export interface components {
currency: string
}
PageAlert: {
/** Format: int32 */
totalPages?: number
/** Format: int64 */
totalElements?: number
/** Format: int32 */
totalPages?: number
first?: boolean
last?: boolean
/** Format: int32 */
Expand All @@ -10755,10 +10769,10 @@ export interface components {
empty?: boolean
}
PagePrisonerBookingSummary: {
/** Format: int32 */
totalPages?: number
/** Format: int64 */
totalElements?: number
/** Format: int32 */
totalPages?: number
first?: boolean
last?: boolean
/** Format: int32 */
Expand Down Expand Up @@ -19972,6 +19986,41 @@ export interface operations {
}
}
}
/** Returns the next court event details (if one exists) related to the passed in booking */
getNextCourtEvent: {
parameters: {
path: {
/** @description The bookingId to check court events against */
bookingId: number
}
}
responses: {
/** @description OK */
200: {
content: {
'application/json': components['schemas']['CourtEventDetails']
}
}
/** @description Invalid request. */
400: {
content: {
'application/json': components['schemas']['ErrorResponse']
}
}
/** @description Requested resource not found. */
404: {
content: {
'application/json': components['schemas']['ErrorResponse']
}
}
/** @description Unrecoverable error occurred whilst processing request. */
500: {
content: {
'application/json': components['schemas']['ErrorResponse']
}
}
}
}
/**
* Returns details of all court dates and the result of each.
* @description <p>This endpoint uses the REPLICA database.</p>
Expand Down
Loading
Loading