Skip to content

Commit

Permalink
remove unused code from civicrm layouts
Browse files Browse the repository at this point in the history
  • Loading branch information
ElviaBth committed Aug 28, 2024
1 parent 5cbff68 commit ede8c50
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 30 deletions.
25 changes: 0 additions & 25 deletions app/views/layouts/decidim/admin/civicrm.html.erb
Original file line number Diff line number Diff line change
@@ -1,30 +1,5 @@
<% add_secondary_root_menu(:admin_civicrm_menu) %>

<% content_for :secondary_nav do %>
<div class="secondary-nav">
<div class="secondary-nav__title">
<%= t ".title" %>
</div>
<ul>
<li <% if is_active_link?(decidim_civicrm_admin.info_index_path) %> class="is-active" <% end %>>
<%= link_to t("menu.info", scope: "decidim.civicrm.admin"), decidim_civicrm_admin.info_index_path %>
</li>
<li <% if is_active_link?(decidim_civicrm_admin.groups_path) %> class="is-active" <% end %>>
<%= link_to t("menu.groups", scope: "decidim.civicrm.admin"), decidim_civicrm_admin.groups_path %>
</li>
<li <% if is_active_link?(decidim_civicrm_admin.membership_types_path) %> class="is-active" <% end %>>
<%= link_to t("menu.membership_types", scope: "decidim.civicrm.admin"), decidim_civicrm_admin.membership_types_path %>
</li>
<li <% if is_active_link?(decidim_civicrm_admin.meetings_path) %> class="is-active" <% end %>>
<%= link_to t("menu.meetings", scope: "decidim.civicrm.admin"), decidim_civicrm_admin.meetings_path %>
</li>
<li <% if is_active_link?(decidim_civicrm_admin.meeting_registrations_path) %> class="is-active" <% end %>>
<%= link_to t("menu.meeting_registrations", scope: "decidim.civicrm.admin"), decidim_civicrm_admin.meeting_registrations_path %>
</li>
</ul>
</div>
<% end %>

<%= render "layouts/decidim/admin/application" do %>
<%= yield %>
<% end %>
5 changes: 0 additions & 5 deletions lib/decidim/civicrm/menu.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,31 +9,26 @@ def self.register_admin_civicrm_menu!
I18n.t("menu.info", scope: "decidim.civicrm.admin"),
decidim_civicrm_admin.info_index_path,
icon_name: "",
if: allowed_to?(:index, :civicrm),
active: is_active_link?(decidim_civicrm_admin.info_index_path)
menu.add_item :groups,
I18n.t("menu.groups", scope: "decidim.civicrm.admin"),
decidim_civicrm_admin.groups_path,
icon_name: "",
if: allowed_to?(:index, :civicrm),
active: is_active_link?(decidim_civicrm_admin.groups_path)
menu.add_item :membership_types,
I18n.t("menu.membership_types", scope: "decidim.civicrm.admin"),
decidim_civicrm_admin.membership_types_path,
icon_name: "",
if: allowed_to?(:index, :civicrm),
active: is_active_link?(decidim_civicrm_admin.membership_types_path)
menu.add_item :meetings,
I18n.t("menu.meetings", scope: "decidim.civicrm.admin"),
decidim_civicrm_admin.meetings_path,
icon_name: "",
if: allowed_to?(:index, :civicrm),
active: is_active_link?(decidim_civicrm_admin.meetings_path)
menu.add_item :meeting_registrations,
I18n.t("menu.meeting_registrations", scope: "decidim.civicrm.admin"),
decidim_civicrm_admin.meeting_registrations_path,
icon_name: "",
if: allowed_to?(:index, :civicrm),
active: is_active_link?(decidim_civicrm_admin.meeting_registrations_path)
end
end
Expand Down

0 comments on commit ede8c50

Please sign in to comment.