Skip to content

Commit 4ed9a8e

Browse files
committed
Remove offers dashboard
1 parent 24bdac4 commit 4ed9a8e

File tree

4 files changed

+1
-76
lines changed

4 files changed

+1
-76
lines changed

app/controllers/offers_controller.rb

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,5 @@
1-
# Managems of offer-type posts
2-
#
31
class OffersController < PostsController
42
def model
53
Offer
64
end
7-
8-
def dashboard
9-
initial_scope =
10-
if current_organization
11-
current_organization.offers.active.of_active_members
12-
else
13-
Offer.all.active.of_active_members
14-
end
15-
@offers = Category.all.sort_by { |a| a.name.downcase }.
16-
each_with_object({}) do |category, offers|
17-
list = initial_scope.merge(category.posts).limit(5)
18-
offers[category] = list if list.present?
19-
end
20-
end
215
end

app/views/application/_navbar.html.erb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545
<div class="col-xs-12 col-sm-12 col-md-12 col-lg-12">
4646
<ul class="nav nav-pills actions-menu">
4747
<%= render 'application/menus/user_list_link' %>
48-
<%= render 'application/menus/offers_dashboard_link' %>
48+
<%= render 'application/menus/offers_list_link' %>
4949
<%= render 'application/menus/inquiries_list_link' %>
5050
<%= render 'application/menus/offers_by_tag_link' %>
5151
<% if current_user.manages?(@organization) %>

app/views/offers/dashboard.html.erb

Lines changed: 0 additions & 59 deletions
This file was deleted.

0 commit comments

Comments
 (0)