Refactor data source and configuration management
Abstracts column data source with interface Updates managers to use configuration-driven view and date Decouples datasource creation from individual managers Improves flexibility and dependency injection for calendar components
This commit is contained in:
parent
0f10d44037
commit
9d270217bd
6 changed files with 31 additions and 17 deletions
|
|
@ -1,4 +1,5 @@
|
|||
import { IResource } from './ResourceTypes';
|
||||
import { CalendarView } from './CalendarTypes';
|
||||
|
||||
/**
|
||||
* Column information container
|
||||
|
|
@ -26,4 +27,16 @@ export interface IColumnDataSource {
|
|||
* Get the type of columns this datasource provides
|
||||
*/
|
||||
getType(): 'date' | 'resource';
|
||||
|
||||
/**
|
||||
* Update the current date for column calculations
|
||||
* @param date - The new current date
|
||||
*/
|
||||
setCurrentDate(date: Date): void;
|
||||
|
||||
/**
|
||||
* Update the current view (day/week/month)
|
||||
* @param view - The new calendar view
|
||||
*/
|
||||
setCurrentView(view: CalendarView): void;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue