feat: add is_featured/is_top_event fields and API endpoints
- Event model: added is_featured, is_top_event BooleanFields - Migration 0007 applied to DB - EventForm: checkboxes for both new fields - EventAdmin: list_display, list_editable, list_filter for both flags - FeaturedEventsAPI: POST /api/events/featured-events/ -> is_featured=True events - TopEventsAPI: POST /api/events/top-events/ -> is_top_event=True events
This commit is contained in:
@@ -21,4 +21,6 @@ urlpatterns += [
|
||||
path('events/events-by-category/', EventsByCategoryAPI.as_view(), name='api_events_by_category'),
|
||||
path('events/events-by-month-year/', EventsByMonthYearAPI.as_view(), name='events_by_month_year'),
|
||||
path('events/events-by-date/', EventsByDateAPI.as_view(), name='events_by_date'),
|
||||
path('events/featured-events/', FeaturedEventsAPI.as_view(), name='featured_events'),
|
||||
path('events/top-events/', TopEventsAPI.as_view(), name='top_events'),
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user