fix: ( permissions) accept payments:manage for luggage charges

This commit is contained in:
Abubeker Yasin
2026-09-05 09:23:22 +03:00
parent b899037151
commit 70b1f75158
3 changed files with 12 additions and 5 deletions

View File

@@ -22,7 +22,14 @@ import { PASSENGER_PERMS } from '../../seed/passenger-permissions.registry';
* included — could raise a charge.
*/
const CanCharge = () =>
PassengerStaff([PASSENGER_PERMS.excessBaggage.charge, PASSENGER_PERMS.bookings.manage, PASSENGER_PERMS.admin]);
PassengerStaff([
PASSENGER_PERMS.excessBaggage.charge,
// Same shape as the supplementary-charge guard in payments.controller.ts: both bill a
// passenger and send them a pay link, so whoever manages payments can do either.
PASSENGER_PERMS.payments.manage,
PASSENGER_PERMS.bookings.manage,
PASSENGER_PERMS.admin,
]);
class UpsertBaggageAllowanceDto {
@IsString() seatClassId: string;