fix: ensure important information loads for all events (guest + auth)

Changed getEventDetails to requiresAuth: false so guests can fetch
full event details without auth tokens. Added retry logic (2 attempts
with 1s delay) to _loadFullDetails for reliability on slow networks.
This ensures important_information, images, and other detail-only
fields are always fetched in the background after initial display.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-03-30 22:22:30 +05:30
parent 605c9277a5
commit e63e9daa0c
2 changed files with 19 additions and 14 deletions

View File

@@ -77,9 +77,9 @@ class EventsService {
return list;
}
/// Event details
/// Event details — requiresAuth: false so guests can fetch full details
Future<EventModel> getEventDetails(int eventId) async {
final res = await _api.post(ApiEndpoints.eventDetails, body: {'event_id': eventId}, requiresAuth: true);
final res = await _api.post(ApiEndpoints.eventDetails, body: {'event_id': eventId}, requiresAuth: false);
return EventModel.fromJson(Map<String, dynamic>.from(res));
}