public async Task <IActionResult> GetNotifications(int id, bool showArchived, bool showNonArchived, bool sortByNew) { var specification = new CourseNotificationsSpecification(id, showArchived, showNonArchived); var result = await _queryBus.ExecuteAsync(new CourseNotificationsQuery(specification) { SortByNew = sortByNew }); return(Ok(result)); }
public CourseNotificationsQuery(CourseNotificationsSpecification specification) { Specification = specification; }