-
straighten
-
-
{{ 'ALARM.SET_DISTANCE' | translate }}
-
{{ 'ALARM.SET_DISTANCE_HINT' | translate }}
+
+
+
+
straighten
+
+
{{ 'ALARM.SET_DISTANCE' | translate }}
+
{{ 'ALARM.SET_DISTANCE_HINT' | translate }}
+
-
-
-
+
+
- @if (form.controls.distanceMode.value === 'distance') {
-
- {{ 'ALARM.DISTANCE_LABEL' | translate }}
-
- {{ 'ALARM.DISTANCE_SUFFIX' | translate }}
-
- }
+ @if (form.controls.distanceMode.value === 'distance') {
+
+ {{ 'ALARM.DISTANCE_LABEL' | translate }}
+
+ {{ 'ALARM.DISTANCE_SUFFIX' | translate }}
+
+ }
-
-
+
+
+ }
{{ 'ALARM.MESSAGE_SETTINGS' | translate }}
diff --git a/Applications/Pgan.PoracleWebNet.App/ClientApp/src/app/modules/lures/lure-edit-dialog.component.scss b/Applications/Pgan.PoracleWebNet.App/ClientApp/src/app/modules/lures/lure-edit-dialog.component.scss
index e6b51a65..5425acf8 100644
--- a/Applications/Pgan.PoracleWebNet.App/ClientApp/src/app/modules/lures/lure-edit-dialog.component.scss
+++ b/Applications/Pgan.PoracleWebNet.App/ClientApp/src/app/modules/lures/lure-edit-dialog.component.scss
@@ -56,3 +56,16 @@ mat-slide-toggle {
min-width: 0;
}
}
+
+.scope-current {
+ align-items: center;
+ display: flex;
+ flex-wrap: wrap;
+ gap: 0.5rem;
+ margin: 0 0 1rem;
+}
+
+.scope-hint {
+ color: var(--mat-sys-on-surface-variant, rgb(0 0 0 / 60%));
+ font-size: 0.75rem;
+}
diff --git a/Applications/Pgan.PoracleWebNet.App/ClientApp/src/app/modules/lures/lure-edit-dialog.component.ts b/Applications/Pgan.PoracleWebNet.App/ClientApp/src/app/modules/lures/lure-edit-dialog.component.ts
index b56d11ec..f03dde06 100644
--- a/Applications/Pgan.PoracleWebNet.App/ClientApp/src/app/modules/lures/lure-edit-dialog.component.ts
+++ b/Applications/Pgan.PoracleWebNet.App/ClientApp/src/app/modules/lures/lure-edit-dialog.component.ts
@@ -17,6 +17,7 @@ import { I18nService } from '../../core/services/i18n.service';
import { LureService } from '../../core/services/lure.service';
import { DeliveryPreviewComponent } from '../../shared/components/delivery-preview/delivery-preview.component';
import { TemplateSelectorComponent } from '../../shared/components/template-selector/template-selector.component';
+import { WhereChipComponent } from '../../shared/components/where-chip/where-chip.component';
import { AUTO_DELETE, compose, EDIT, isAutoDelete, isEdit, preserve } from '../../shared/utils/clean-flags';
@Component({
@@ -34,6 +35,7 @@ import { AUTO_DELETE, compose, EDIT, isAutoDelete, isEdit, preserve } from '../.
TranslatePipe,
TemplateSelectorComponent,
DeliveryPreviewComponent,
+ WhereChipComponent,
],
selector: 'app-lure-edit-dialog',
standalone: true,
@@ -81,6 +83,11 @@ export class LureEditDialogComponent {
}
}
+ /** True when the alarm is confined to areas, which the areas-or-distance control cannot express. */
+ isAreaScoped(): boolean {
+ return (this.data.overrideAreas?.length ?? 0) > 0;
+ }
+
onDistanceModeChange(): void {
if (this.form.controls.distanceMode.value === 'areas') this.form.controls.distanceKm.setValue(0);
else if (!this.form.controls.distanceKm.value) this.form.controls.distanceKm.setValue(1);
diff --git a/Applications/Pgan.PoracleWebNet.App/ClientApp/src/app/modules/lures/lure-list.component.html b/Applications/Pgan.PoracleWebNet.App/ClientApp/src/app/modules/lures/lure-list.component.html
index c574494f..4cd07fb8 100644
--- a/Applications/Pgan.PoracleWebNet.App/ClientApp/src/app/modules/lures/lure-list.component.html
+++ b/Applications/Pgan.PoracleWebNet.App/ClientApp/src/app/modules/lures/lure-list.component.html
@@ -78,11 +78,12 @@
{{ getLureName(lure.lureId) }} {{ 'LURES.LURE_SUFFIX' | translate }}