Calendar: Fix group calendar could be missing events under some circumstances

Static account options added to CalendarOwner were blocking the group data needed, fixed by using sent options over account options
This commit is contained in:
nathan 2023-07-25 11:15:51 -06:00
parent b44ea1b2b0
commit e0d284d3ae
2 changed files with 2 additions and 2 deletions

View File

@ -53,7 +53,7 @@ export const Et2StaticSelectMixin = <T extends Constructor<Et2WidgetWithSelect>>
const options = super.select_options || []; const options = super.select_options || [];
// make sure result is unique // make sure result is unique
return [...new Map([...options, ...(this.static_options || [])].map(item => return [...new Map([...(this.static_options || []), ...options].map(item =>
[item.value, item])).values()]; [item.value, item])).values()];
} }

View File

@ -89,7 +89,7 @@ export class CalendarOwner extends Et2StaticSelectMixin(Et2Select)
{ {
for(var i = 0; i < this.value.length; i++) for(var i = 0; i < this.value.length; i++)
{ {
if(!this.menuItems.find(o => o.value == this.value[i])) if(!this.select_options.find(o => o.value == this.value[i]))
{ {
missing_labels.push(this.value[i]); missing_labels.push(this.value[i]);
} }