diff --git a/apps/red-ui/src/app/app.module.ts b/apps/red-ui/src/app/app.module.ts
index b46078f62..b3f4625ce 100644
--- a/apps/red-ui/src/app/app.module.ts
+++ b/apps/red-ui/src/app/app.module.ts
@@ -98,10 +98,10 @@ import { HtmlDebugScreenComponent } from './screens/html-debug-screen/html-debug
import { ReportDownloadBtnComponent } from './components/buttons/report-download-btn/report-download-btn.component';
import { ProjectListingActionsComponent } from './screens/project-listing-screen/project-listing-actions/project-listing-actions.component';
import { HasScrollbarDirective } from './utils/has-scrollbar.directive';
-import { ProjectTemplatesListingScreenComponent } from './screens/admin/project-templates-listing-screen/project-templates-listing-screen.component';
-import { AddEditProjectTemplateDialogComponent } from './screens/admin/project-templates-listing-screen/add-edit-project-template-dialog/add-edit-project-template-dialog.component';
-import { ProjectTemplateActionsComponent } from './components/project-template-actions/project-template-actions.component';
-import { ProjectTemplateViewSwitchComponent } from './components/project-template-view-switch/project-template-view-switch.component';
+import { RuleSetsListingScreenComponent } from './screens/admin/rule-sets-listing-screen/rule-sets-listing-screen.component';
+import { AddEditRuleSetDialogComponent } from './screens/admin/rule-sets-listing-screen/add-edit-rule-set-dialog/add-edit-rule-set-dialog.component';
+import { RuleSetActionsComponent } from './components/rule-set-actions/rule-set-actions.component';
+import { RuleSetViewSwitchComponent } from './components/rule-set-view-switch/rule-set-view-switch.component';
import { MatSliderModule } from '@angular/material/slider';
import { PendingChangesGuard } from './utils/can-deactivate.guard';
@@ -178,14 +178,14 @@ const routes = [
children: [
{
path: '',
- component: ProjectTemplatesListingScreenComponent,
+ component: RuleSetsListingScreenComponent,
canActivate: [CompositeRouteGuard],
data: {
routeGuards: [AuthGuard, RedRoleGuard, AppStateGuard]
}
},
{
- path: ':templateId',
+ path: ':ruleSetId',
children: [
{
path: 'dictionaries',
@@ -313,8 +313,8 @@ const matImports = [
CircleButtonComponent,
ChevronButtonComponent,
DictionaryListingScreenComponent,
- ProjectTemplatesListingScreenComponent,
- AddEditProjectTemplateDialogComponent,
+ RuleSetsListingScreenComponent,
+ AddEditRuleSetDialogComponent,
SyncWidthDirective,
HasScrollbarDirective,
AddEditDictionaryDialogComponent,
@@ -329,8 +329,8 @@ const matImports = [
HtmlDebugScreenComponent,
ReportDownloadBtnComponent,
ProjectListingActionsComponent,
- ProjectTemplateActionsComponent,
- ProjectTemplateViewSwitchComponent
+ RuleSetActionsComponent,
+ RuleSetViewSwitchComponent
],
imports: [
BrowserModule,
diff --git a/apps/red-ui/src/app/components/admin-page-header/admin-breadcrumbs.component.html b/apps/red-ui/src/app/components/admin-page-header/admin-breadcrumbs.component.html
index 5549ff5ea..33266b062 100644
--- a/apps/red-ui/src/app/components/admin-page-header/admin-breadcrumbs.component.html
+++ b/apps/red-ui/src/app/components/admin-page-header/admin-breadcrumbs.component.html
@@ -5,7 +5,7 @@
[routerLinkActiveOptions]="{ exact: true }"
routerLinkActive="active"
translate="project-templates"
- *ngIf="root || !!projectTemplate"
+ *ngIf="root || !!ruleSet"
>
-
+
-
- {{ projectTemplate.name }}
+
+ {{ ruleSet.name }}
@@ -37,7 +37,7 @@
{{ dictionary.label }}
diff --git a/apps/red-ui/src/app/components/admin-page-header/admin-breadcrumbs.component.ts b/apps/red-ui/src/app/components/admin-page-header/admin-breadcrumbs.component.ts
index b4931d79d..d7b4e412c 100644
--- a/apps/red-ui/src/app/components/admin-page-header/admin-breadcrumbs.component.ts
+++ b/apps/red-ui/src/app/components/admin-page-header/admin-breadcrumbs.component.ts
@@ -1,7 +1,7 @@
import { Component, Input, OnInit } from '@angular/core';
import { ActivatedRoute } from '@angular/router';
-import { TypeValue } from '@redaction/red-ui-http';
-import { AppStateService, ProjectTemplate } from '../../state/app-state.service';
+import { RuleSetModel, TypeValue } from '@redaction/red-ui-http';
+import { AppStateService } from '../../state/app-state.service';
import { UserPreferenceService } from '../../common/service/user-preference.service';
import { PermissionsService } from '../../common/service/permissions.service';
@@ -12,7 +12,7 @@ import { PermissionsService } from '../../common/service/permissions.service';
})
export class AdminBreadcrumbsComponent implements OnInit {
public dictionary: TypeValue;
- public projectTemplate: ProjectTemplate;
+ public ruleSet: RuleSetModel;
@Input()
public root = false;
@@ -25,8 +25,8 @@ export class AdminBreadcrumbsComponent implements OnInit {
ngOnInit(): void {
this._activatedRoute.params.subscribe((params) => {
- if (params.templateId) {
- this.projectTemplate = this._appStateService.getProjectTemplateById(params.templateId);
+ if (params.ruleSetId) {
+ this.ruleSet = this._appStateService.getRuleSetById(params.ruleSetId);
}
if (params.type) {
this.dictionary = this._appStateService.getDictionaryTypeValue(params.type);
diff --git a/apps/red-ui/src/app/components/project-template-actions/project-template-actions.component.ts b/apps/red-ui/src/app/components/project-template-actions/project-template-actions.component.ts
deleted file mode 100644
index 7316bdd35..000000000
--- a/apps/red-ui/src/app/components/project-template-actions/project-template-actions.component.ts
+++ /dev/null
@@ -1,37 +0,0 @@
-import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';
-import { ProjectTemplate } from '../../state/app-state.service';
-import { DialogService } from '../../dialogs/dialog.service';
-import { PermissionsService } from '../../common/service/permissions.service';
-
-@Component({
- selector: 'redaction-project-template-actions',
- templateUrl: './project-template-actions.component.html',
- styleUrls: ['./project-template-actions.component.scss']
-})
-export class ProjectTemplateActionsComponent implements OnInit {
- @Input() template: ProjectTemplate;
- @Output() loadTemplatesData = new EventEmitter();
-
- constructor(private readonly _dialogService: DialogService, public readonly permissionsService: PermissionsService) {}
-
- ngOnInit(): void {}
-
- openAddEditTemplateDialog(template?: ProjectTemplate) {
- this._dialogService.openAddEditTemplateDialog(template, async (newTemplate) => {
- if (newTemplate) {
- this.loadTemplatesData.emit();
- }
- });
- }
-
- openEditTemplateDialog($event: any, pt: ProjectTemplate) {
- $event.stopPropagation();
- this.openAddEditTemplateDialog(pt);
- }
-
- openDeleteTemplateDialog($event: any, template: ProjectTemplate) {
- this._dialogService.openDeleteProjectTemplateDialog($event, template, async () => {
- this.loadTemplatesData.emit();
- });
- }
-}
diff --git a/apps/red-ui/src/app/components/project-template-actions/project-template-actions.component.html b/apps/red-ui/src/app/components/rule-set-actions/rule-set-actions.component.html
similarity index 79%
rename from apps/red-ui/src/app/components/project-template-actions/project-template-actions.component.html
rename to apps/red-ui/src/app/components/rule-set-actions/rule-set-actions.component.html
index 9b0edb1f4..04d19f2f8 100644
--- a/apps/red-ui/src/app/components/project-template-actions/project-template-actions.component.html
+++ b/apps/red-ui/src/app/components/rule-set-actions/rule-set-actions.component.html
@@ -1,6 +1,6 @@