Merge pull request #1009 from Tria-plc/main

Main
This commit is contained in:
Abubeker Yasin
2026-07-29 17:05:55 +03:00
committed by GitHub
2 changed files with 9 additions and 9 deletions

View File

@@ -56,7 +56,7 @@ export class TicketsController {
}
@Get()
@PassengerStaff(PASSENGER_PERMS.tickets.generate)
@PassengerStaff(PASSENGER_PERMS.tickets.view)
@ApiBearerAuth('IAM-auth')
@ApiOperation({ summary: 'List all tickets with optional filters' })
@ApiQuery({ name: 'search', required: false })
@@ -99,7 +99,7 @@ export class TicketsController {
}
@Get('by-order/:merchantOrderId')
@PassengerStaff(PASSENGER_PERMS.tickets.generate)
@PassengerStaff(PASSENGER_PERMS.tickets.view)
@ApiBearerAuth('IAM-auth')
@ApiOperation({
summary: 'Get ticket by merchant order ID',
@@ -117,7 +117,7 @@ export class TicketsController {
}
@Post('scan-board/:qrCodeOrRef')
@PassengerStaff(PASSENGER_PERMS.tickets.generate)
@PassengerStaff(PASSENGER_PERMS.tickets.manage)
@ApiBearerAuth('IAM-auth')
@ApiOperation({
summary: 'Scan QR code or booking ref and automatically board ticket',
@@ -142,7 +142,7 @@ export class TicketsController {
}
@Post(':bookingRef/validate')
@PassengerStaff(PASSENGER_PERMS.tickets.generate)
@PassengerStaff(PASSENGER_PERMS.tickets.manage)
@ApiBearerAuth('IAM-auth')
@ApiOperation({
summary: 'Validate ticket at gate with audit logging',
@@ -173,7 +173,7 @@ export class TicketsController {
}
@Get(':ticketId/validation-logs')
@PassengerStaff(PASSENGER_PERMS.tickets.generate)
@PassengerStaff(PASSENGER_PERMS.tickets.view)
@ApiBearerAuth('IAM-auth')
@ApiOperation({ summary: 'Get validation logs for ticket' })
getValidationLogs(@Param('ticketId') ticketId: string) {
@@ -181,7 +181,7 @@ export class TicketsController {
}
@Get('offline/export')
@PassengerStaff(PASSENGER_PERMS.tickets.generate)
@PassengerStaff(PASSENGER_PERMS.tickets.view)
@ApiBearerAuth('IAM-auth')
@ApiOperation({ summary: 'Export tickets for offline validation' })
exportOfflineData(@Query('scheduleId') scheduleId: string) {
@@ -189,7 +189,7 @@ export class TicketsController {
}
@Post('validate/offline')
@PassengerStaff(PASSENGER_PERMS.tickets.generate)
@PassengerStaff(PASSENGER_PERMS.tickets.manage)
@ApiBearerAuth('IAM-auth')
@ApiOperation({
summary: 'Batch import offline validations',
@@ -232,7 +232,7 @@ export class TicketsController {
}
@Patch(':id/restore')
@PassengerStaff(PASSENGER_PERMS.tickets.generate)
@PassengerStaff(PASSENGER_PERMS.tickets.manage)
@ApiBearerAuth('IAM-auth')
@ApiOperation({ summary: 'Restore a cancelled ticket by resetting its status to ACTIVE' })
restore(@Param('id') id: string) {

View File

@@ -64,7 +64,7 @@ const navigationSections: { title: string; items: NavItem[] }[] = [
{ name: 'Bookings', href: '/bookings', icon: Ticket, permission: PERMS.bookings.view },
{ name: 'Passengers', href: '/passengers', icon: Users, permission: PERMS.passengers.view },
{ name: 'Tickets', href: '/tickets', icon: FileText, permission: PERMS.tickets.view },
{ name: 'Boarding', href: '/boarding', icon: LogIn, permission: PERMS.tickets.view },
{ name: 'Boarding', href: '/boarding', icon: LogIn, permission: PERMS.tickets.manage },
{ name: 'Luggage', href: '/excess-baggage', icon: Banknote, permission: PERMS.bookings.view },
{ name: 'Discrepancy', href: '/discrepancy', icon: Layers, permission: PERMS.seats.manage },
]