Fix a bug with active subcategory in admin

This commit is contained in:
Konstantinos Triantafyllou 2022-09-13 13:30:16 +03:00
parent 35e4563144
commit 4ed0890bb9
3 changed files with 9 additions and 25 deletions

@ -1 +1 @@
Subproject commit fa919431d3be63fb4045d47083b3ba7cd6414e03
Subproject commit 945cee4519a4f5b2c5e53dd5c069d4f038f987e6

View File

@ -875,34 +875,18 @@ export class IndicatorsComponent implements OnInit, OnDestroy, OnChanges, AfterV
this.notification.groups.push(Role.manager(value.type, value.alias))
});
this.notificationService.sendNotification(this.notification).subscribe(notification => {
UIkit.notification('A notification has been <b>sent</b> successfully', {
status: 'success',
timeout: 6000,
pos: 'bottom-right'
});
NotificationHandler.rise('A notification has been <b>sent</b> successfully');
}, error => {
UIkit.notification('An error has occurred. Please try again later', {
status: 'danger',
timeout: 6000,
pos: 'bottom-right'
});
NotificationHandler.rise('An error has occurred. Please try again later', 'danger');
});
});
}
this.editing = false;
this.importLoading = false;
UIkit.notification("Success! Indicated were imported", {
status: 'success',
timeout: 6000,
pos: 'bottom-right'
});
NotificationHandler.rise('Indicators have been <b>imported</b> successfully!');
}, error => {
this.chartIndicatorFb = null;
UIkit.notification(error.error.message, {
status: 'danger',
timeout: 6000,
pos: 'bottom-right'
});
NotificationHandler.rise(error.error.message, 'danger');
this.editing = false;
this.importLoading = false;
}));

View File

@ -25,7 +25,7 @@
class="uk-width-expand uk-text-truncate uk-margin-small-left">
{{topic.name}}
</span>
<span *ngIf="open" class="uk-invisible-hover uk-margin-xsmall-left" [class.uk-invisible-hover]="topicIndex !== i"
<span *ngIf="open" class="uk-margin-xsmall-left" [class.uk-invisible-hover]="topicIndex !== i"
(click)="$event.stopPropagation();$event.preventDefault()">
<a class="uk-link-reset uk-flex uk-flex-middle">
<icon [flex]="true" [name]="stakeholderUtils.visibilityIcon.get(topic.visibility)"
@ -155,7 +155,7 @@
<a (click)="chooseCategory(i)">
<span class="title"> {{category.name}}</span>
</a>
<span class="uk-invisible-hover uk-flex uk-flex-column uk-flex-center uk-margin-small-left"
<span class="uk-flex uk-flex-column uk-flex-center uk-margin-small-left"
[class.uk-invisible-hover]="categoryIndex !== i"
(click)="$event.stopPropagation();$event.preventDefault()">
<a class="uk-link-reset uk-flex uk-flex-middle">
@ -236,8 +236,8 @@
<a (click)="chooseSubcategory(i);$event.preventDefault()" class="uk-margin-small-left">
<span>{{subCategory.name}}</span>
</a>
<span class="uk-invisible-hover uk-flex uk-flex-column uk-flex-center uk-margin-small-left"
[class.uk-invisible-hover]="categoryIndex !== i"
<span class="uk-flex uk-flex-column uk-flex-center uk-margin-small-left"
[class.uk-invisible-hover]="subCategoryIndex !== i"
(click)="$event.stopPropagation();$event.preventDefault()">
<a class="uk-link-reset uk-flex uk-flex-middle">
<icon [flex]="true" [name]="stakeholderUtils.visibilityIcon.get(subCategory.visibility)"