Commit 8caef1c0 authored by Florent POITTEVIN's avatar Florent POITTEVIN
Browse files

fix: 1319 1320 condition to display button on preservation space org unit

parent 9d93cb91
......@@ -55,7 +55,7 @@ export class PreservationSpaceHomeRoutable extends SharedAbstractPresentational
},
{
id: "NOTIFICATION_RECEIVED",
icon: "send",
icon: "mail",
titleToTranslate: TRANSLATE("preservationSpace.notificationInbox.home.title"),
suffixUrl: PreservationSpaceRoutesEnum.notificationInbox,
route: () => [...this.rootUrl, PreservationSpaceRoutesEnum.notificationInbox],
......@@ -63,7 +63,7 @@ export class PreservationSpaceHomeRoutable extends SharedAbstractPresentational
},
{
id: "NOTIFICATION_SENT",
icon: "mail",
icon: "send",
titleToTranslate: TRANSLATE("preservationSpace.notificationSent.home.title"),
suffixUrl: PreservationSpaceRoutesEnum.notificationSent,
route: () => [...this.rootUrl, PreservationSpaceRoutesEnum.notificationSent],
......
......@@ -40,7 +40,7 @@
</ng-template>
<ng-template #linkToDepositArchiveAndNotification>
<button *ngIf="readonly"
<button *ngIf="readonly && securityService.isRootOrAdmin() || securityService.isMemberOfOrgUnit(model.resId)"
dlcmAlternativeButton
solidifyShortCuts
(onEnter)="goToDeposit()"
......@@ -58,7 +58,7 @@
{{'organizationalUnit.form.link.seeArchives' | translate}}
</button>
<button *ngIf="readonly"
<button *ngIf="readonly && securityService.isRootOrAdmin() || securityService.isMemberOfOrgUnit(model.resId)"
dlcmAlternativeButton
solidifyShortCuts
(onEnter)="goToReceivedRequestNotification()"
......
......@@ -64,19 +64,19 @@ export class OrgunitListRoutable extends SharedAbstractListRoutable<Organization
logo: "description",
callback: model => this.goToDeposit(model),
placeholder: TRANSLATE("crud.list.action.goToDeposit"),
displayOnCondition: model => !this._securityService.isRootOrAdmin() && this._securityService.isMemberOfOrgUnit(model.resId),
displayOnCondition: model => this._securityService.isRootOrAdmin() || this._securityService.isMemberOfOrgUnit(model.resId),
},
{
logo: "email",
logo: "send",
callback: model => this.goToSentRequestNotification(model),
placeholder: TRANSLATE("crud.list.action.goToSentRequestNotification"),
displayOnCondition: model => this._securityService.isRootOrAdmin(),
displayOnCondition: model => true,
},
{
logo: "send",
logo: "email",
callback: model => this.goToReceivedRequestNotification(model),
placeholder: TRANSLATE("crud.list.action.goToReceivedRequestNotification"),
displayOnCondition: model => true,
displayOnCondition: model => this._securityService.isRootOrAdmin() || this._securityService.isMemberOfOrgUnit(model.resId),
},
{
logo: "account_circle",
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment