diff --git a/frontend/app/components/wp-fast-table/wp-table-filters.ts b/frontend/app/components/wp-fast-table/wp-table-filters.ts index 55fb33252d..cff02d6dce 100644 --- a/frontend/app/components/wp-fast-table/wp-table-filters.ts +++ b/frontend/app/components/wp-fast-table/wp-table-filters.ts @@ -43,7 +43,15 @@ export class WorkPackageTableFilters extends WorkPackageTableBaseState any { - return (current:QueryFilterInstanceResource[]) => current.map((el:HalResource) => el.$plain()); + // TODO: this should be + // + // return (current:QueryFilterInstanceResource[]) => current.map((el:HalResource) => el.$plain()); + // + // instead. But for some reasons deeply burried probably within the + // HalResource, filters received from the server will not set the + // HalResource's source correctly when updating the values, operators ... + // Filters created in the frontend itself behave as expected. + return (current:QueryFilterInstanceResource[]) => current.map((el:HalResource) => _.cloneDeep(el)); } constructor(filters:QueryFilterInstanceResource[], schema:QuerySchemaResourceInterface) {