diff --git a/UI/Web/src/app/_services/action-factory.service.ts b/UI/Web/src/app/_services/action-factory.service.ts index 131e20cac..6d2f7053e 100644 --- a/UI/Web/src/app/_services/action-factory.service.ts +++ b/UI/Web/src/app/_services/action-factory.service.ts @@ -870,6 +870,14 @@ export class ActionFactoryService { ]; this.smartFilterActions = [ + { + action: Action.Edit, + title: 'rename', + description: 'rename-tooltip', + callback: this.dummyCallback, + requiresAdmin: false, + children: [], + }, { action: Action.Delete, title: 'delete', diff --git a/UI/Web/src/app/all-filters/all-filters.component.html b/UI/Web/src/app/all-filters/all-filters.component.html index 2f487574a..7b502232b 100644 --- a/UI/Web/src/app/all-filters/all-filters.component.html +++ b/UI/Web/src/app/all-filters/all-filters.component.html @@ -9,9 +9,7 @@ {{t('count', {count: filters.length | number})}} {{t('create')}} - - diff --git a/UI/Web/src/app/all-filters/all-filters.component.ts b/UI/Web/src/app/all-filters/all-filters.component.ts index e41b2a83e..40da8e10b 100644 --- a/UI/Web/src/app/all-filters/all-filters.component.ts +++ b/UI/Web/src/app/all-filters/all-filters.component.ts @@ -9,7 +9,7 @@ import {FilterService} from "../_services/filter.service"; import {Router} from "@angular/router"; import {Series} from "../_models/series"; import {JumpbarService} from "../_services/jumpbar.service"; -import {Action, ActionFactoryService, ActionItem} from "../_services/action-factory.service"; +import {ActionFactoryService} from "../_services/action-factory.service"; import {ActionService} from "../_services/action.service"; import {ManageSmartFiltersComponent} from "../sidenav/_components/manage-smart-filters/manage-smart-filters.component"; import {DecimalPipe} from "@angular/common"; @@ -29,7 +29,7 @@ export class AllFiltersComponent implements OnInit { private readonly actionFactory = inject(ActionFactoryService); private readonly actionService = inject(ActionService); - filterActions = this.actionFactory.getSmartFilterActions(this.handleAction.bind(this)); + jumpbarKeys: Array = []; filters: SmartFilter[] = []; isLoading = true; @@ -46,22 +46,4 @@ export class AllFiltersComponent implements OnInit { this.cdRef.markForCheck(); }); } - - async deleteFilter(filter: SmartFilter) { - await this.actionService.deleteFilter(filter.id, success => { - this.filters = this.filters.filter(f => f.id != filter.id); - this.jumpbarKeys = this.jumpbarService.getJumpKeys(this.filters, (s: Series) => s.name); - this.cdRef.markForCheck(); - }); - } - - async handleAction(action: ActionItem, filter: SmartFilter) { - switch (action.action) { - case(Action.Delete): - await this.deleteFilter(filter); - break; - default: - break; - } - } } diff --git a/UI/Web/src/app/carousel/_components/carousel-reel/carousel-reel.component.html b/UI/Web/src/app/carousel/_components/carousel-reel/carousel-reel.component.html index 157825782..85cd9bc8f 100644 --- a/UI/Web/src/app/carousel/_components/carousel-reel/carousel-reel.component.html +++ b/UI/Web/src/app/carousel/_components/carousel-reel/carousel-reel.component.html @@ -3,8 +3,11 @@ @if (alwaysShow || items && items.length > 0) {