mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-20 05:16:07 +00:00
change agenda
This commit is contained in:
@@ -62,6 +62,16 @@ export class CalendarService {
|
||||
})
|
||||
}
|
||||
|
||||
removeRangeForCalendar(rangeStartDate, rangeEndDate, profile, calendarId) {
|
||||
this._eventSource = this._eventSource.filter((e)=> {
|
||||
if(new Date(rangeStartDate).getTime() <= new Date(e.startTime).getTime() &&
|
||||
new Date(rangeEndDate).getTime() >= new Date(e.endTime).getTime() && e.CalendarId == calendarId) {
|
||||
return false
|
||||
}
|
||||
return true
|
||||
})
|
||||
}
|
||||
|
||||
pushEvent(eventsList: EventList[], profile: 'pr' | 'md') {
|
||||
|
||||
let news = []
|
||||
@@ -95,6 +105,18 @@ export class CalendarService {
|
||||
}, 10)
|
||||
}
|
||||
|
||||
getEventsByCalendarIds(ids:any[]): EventListStore[] {
|
||||
|
||||
let result = [];
|
||||
for (const calendar of ids) {
|
||||
const events = this._eventSource.filter(e => e.CalendarId == calendar.calendarId)
|
||||
result = result.concat(events)
|
||||
}
|
||||
|
||||
return result
|
||||
|
||||
}
|
||||
|
||||
|
||||
delete() {
|
||||
this._eventSource = []
|
||||
|
||||
Reference in New Issue
Block a user