Skip to content

Commit

Permalink
feat(admin): rework the conditions in LayoutNotice to hide notice fro…
Browse files Browse the repository at this point in the history
…m admins and certification authorities

(cherry picked from commit 3fa779c)
  • Loading branch information
ThomasDos committed Aug 30, 2024
1 parent 74c9651 commit a329d07
Showing 1 changed file with 6 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,16 +38,17 @@ export const LayoutNotice = () => {

const canSeeAAPNotVisibleInSearchResultNotice =
authenticated &&
!isAdmin &&
!isGestionnaireMaisonMereAAP &&
isOrganism &&
!isGestionnaireMaisonMereAAP &&
!isVisibleInSearchResults;

const canSeeNoticeAlertFundingLimit = isFeaturNoticeAlertFundingLimitActive;
const canSeeNoticeAlertFundingLimit =
isFeaturNoticeAlertFundingLimitActive && isOrganism;

const canSeeNoticeAapSettings = pathname === "/agencies-settings/";
const canSeeNoticeAapSettings =
pathname === "/agencies-settings/" && isOrganism;

if (isLoading) {
if (isLoading || isAdmin) {
return null;
}

Expand Down

0 comments on commit a329d07

Please sign in to comment.