Blazor Scheduler Example - Fare Calendar
| ||||||||||||||||||||||||||||||||||||||||||
|
This demo illustrates how to customize the scheduler to showcase it as an Airfare calendar depicting the lowest available price on each day of a month for a specific route, such as between Barcelona and Los Angeles.
In this demo, Scheduler initially displays the fare of the airline service which offers the lowest price on each day by comparing between the 3 available airlines. Here, the 3 airline services act as the Scheduler resources. The appointment collection has been dynamically generated for a month (for all 3 resources) within the GenerateEvents method and then filtered externally based on the ascending Fare value within the FilterByFare method. Since each day of the Scheduler needs to display only a single appointment showing the fare value, it has been queried to take only the first 30 values from the sorted list and assigned to the Scheduler DataSource. The filtering process is carried in the OnInitialized method, and therefore, the dataSource of Scheduler is assigned within this method.
Scheduler has been rendered in read-only mode, and therefore no editing actions are allowed. To customize the look of the appointments that display the fare value, the EventTemplate option within the ScheduleView tag is used. Also, the tooltip has been enabled with the TooltipTemplate option to display the flight details in a customized style.