Show always poll officer menu to officers

Since the change on commit cbbe188d6 we added a Poll.current.any?
condition to show the officing link on admin menu to officers.

That condition doesn't have much sense since Poll results only can be
added after a poll has ended, and there may be only one active poll.
This commit is contained in:
decabeza
2022-10-25 15:25:57 +02:00
committed by Javi Martín
parent 2e9c4de061
commit 1ff2144830
3 changed files with 2 additions and 5 deletions

View File

@@ -18,7 +18,7 @@ class Layout::AdminLoginItemsComponent < ApplicationComponent
(moderation_link if user.administrator? || user.moderator?),
(valuation_link if feature?(:budgets) && (user.administrator? || user.valuator?)),
(management_link if user.administrator? || user.manager?),
(officing_link if user.poll_officer? && Poll.current.any?),
(officing_link if user.poll_officer?),
(sdg_management_link if feature?(:sdg) && (user.administrator? || user.sdg_manager?))
]
end