P1 complete: real انطلق maps + Nabeh WhatsApp OTP + chat + ratings + cancel(both) + fraud detection
- maps: real map-saas route/geocode/reverse/places (x-api-key per country) + straight-line fallback - auth: Redis-backed OTP + Nabeh WhatsApp send (dev mode keeps fixed 1234 bypass) - chat: per-trip messages (participant-guarded) + socket broadcast - ratings: post-trip rating + driver avg recompute + no double-rate - cancel: from rider or driver + stage-based cancel fee + notify both - fraud: cancel-abuse (soft/hard block via Redis), arrived-far-from-pickup, completed-too-fast → fraud_flags - migration InitP1b (chat_messages, ratings, fraud_flags, trips.cancelled_by/cancel_fee) Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -48,6 +48,6 @@ export class TripsController {
|
||||
@Post(':id/cancel')
|
||||
cancel(@CurrentUser() user: AuthUser, @Param('id') id: string) {
|
||||
const actor = user.role === 'driver' ? 'driver' : 'rider';
|
||||
return this.trips.cancel(user.tenantId, id, actor);
|
||||
return this.trips.cancel(user.tenantId, id, actor, user.userId);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user