mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-20 05:16:07 +00:00
Merge branch 'feature/agenda-new-api-peter' into feature/agenda-new-api-eudes
This commit is contained in:
@@ -634,7 +634,7 @@ export class AgendaPage implements OnInit {
|
|||||||
this.rangeEndDate = endTime
|
this.rangeEndDate = endTime
|
||||||
|
|
||||||
this.showLoader = true;
|
this.showLoader = true;
|
||||||
const selectedCalendarIds = this.getSelectedAgendaCalendars();
|
const selectedCalendarIds = this.removeDuplicatesByOwnerUserId(this.getSelectedAgendaCalendars());
|
||||||
this.listToPresent = this.CalendarStore.getEventsByCalendarIds(selectedCalendarIds)
|
this.listToPresent = this.CalendarStore.getEventsByCalendarIds(selectedCalendarIds)
|
||||||
// this.calendar.currentDate.setDate(1);
|
// this.calendar.currentDate.setDate(1);
|
||||||
|
|
||||||
@@ -647,9 +647,14 @@ export class AgendaPage implements OnInit {
|
|||||||
|
|
||||||
|
|
||||||
let load = 0;
|
let load = 0;
|
||||||
for (const selectedCalendar of this.removeDuplicatesByOwnerUserId(selectedCalendarIds)) {
|
for (const selectedCalendar of selectedCalendarIds) {
|
||||||
|
|
||||||
const response = await this.AgendaDataRepositoryService.EventList({userId: selectedCalendar.OwnerUserId, calendarOwnerName: selectedCalendar['FullName'] })
|
const response = await this.AgendaDataRepositoryService.EventList({
|
||||||
|
userId: selectedCalendar.OwnerUserId,
|
||||||
|
calendarOwnerName: selectedCalendar['FullName'],
|
||||||
|
endDate: endTime.toISOString(),
|
||||||
|
startDate: startTime.toISOString()
|
||||||
|
})
|
||||||
|
|
||||||
if(response.isOk()) {
|
if(response.isOk()) {
|
||||||
let label;
|
let label;
|
||||||
@@ -668,11 +673,11 @@ export class AgendaPage implements OnInit {
|
|||||||
this.CalendarStore.pushEvent(eventsList, label, selectedCalendar.OwnerUserId);
|
this.CalendarStore.pushEvent(eventsList, label, selectedCalendar.OwnerUserId);
|
||||||
|
|
||||||
this.listToPresent = this.CalendarStore.getEventsByCalendarIds(selectedCalendarIds)
|
this.listToPresent = this.CalendarStore.getEventsByCalendarIds(selectedCalendarIds)
|
||||||
// console.log('this.listToPresent', this.listToPresent)
|
|
||||||
this.showTimelinePR = true;
|
this.showTimelinePR = true;
|
||||||
|
|
||||||
load++
|
load++
|
||||||
if (load == selectedCalendarIds.length) {
|
if (load ==(selectedCalendarIds).length) {
|
||||||
this.showLoader = false;
|
this.showLoader = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -681,7 +686,7 @@ export class AgendaPage implements OnInit {
|
|||||||
this.updateEventListBox()
|
this.updateEventListBox()
|
||||||
} else {
|
} else {
|
||||||
load++
|
load++
|
||||||
if (load == selectedCalendarIds.length) {
|
if (load == (selectedCalendarIds).length) {
|
||||||
this.showLoader = false;
|
this.showLoader = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -769,8 +774,9 @@ export class AgendaPage implements OnInit {
|
|||||||
updateEventListBox() {
|
updateEventListBox() {
|
||||||
|
|
||||||
const selectedCalendarIds = this.getSelectedAgendaCalendars();
|
const selectedCalendarIds = this.getSelectedAgendaCalendars();
|
||||||
this.listToPresent = this.CalendarStore.getEventsByCalendarIds(selectedCalendarIds)
|
this.listToPresent = this.removeDuplicatesByOwnerUserId(this.CalendarStore.getEventsByCalendarIds(selectedCalendarIds))
|
||||||
|
|
||||||
|
console.log('this.listToPresent', JSON.stringify(this.listToPresent) )
|
||||||
const year = this.listBoxService.list(this.listToPresent, 'md', this.rangeStartDate, this.rangeEndDate, { segment: this.segment, selectedDate: this.eventSelectedDate })
|
const year = this.listBoxService.list(this.listToPresent, 'md', this.rangeStartDate, this.rangeEndDate, { segment: this.segment, selectedDate: this.eventSelectedDate })
|
||||||
this.TimelineMDList = year
|
this.TimelineMDList = year
|
||||||
|
|
||||||
|
|||||||
@@ -71,6 +71,8 @@ export class CalendarService {
|
|||||||
}
|
}
|
||||||
return true
|
return true
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
pushEvent(eventsList: EventList, profile: 'pr' | 'md', CalendarId: string) {
|
pushEvent(eventsList: EventList, profile: 'pr' | 'md', CalendarId: string) {
|
||||||
|
|||||||
Reference in New Issue
Block a user