Skip to content

Commit

Permalink
show places, styles ranked in home
Browse files Browse the repository at this point in the history
  • Loading branch information
fwolfst committed Oct 9, 2020
1 parent 29dc498 commit 7da4748
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion app/controllers/pages_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
class PagesController < ApplicationController
def home
@styles = Style.active.rank(:row_order)
@places = Place.active.all
@places = Place.active.rank(:row_order)
end

def privacy
Expand Down
2 changes: 1 addition & 1 deletion app/views/pages/home/_courses.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
= t('home.courses.styles')
.columns.is-multiline.is-vcentered.is-centered.is-variable.is-8
-# TODO extract to controller
- Style.which_has_courses.each do |style|
- @styles.which_has_courses.each do |style|
.column.is-3.style-column{id: dom_id(style)}
= admin_edit_button edit_admin_style_path(style)
.box.pt-0.px-0
Expand Down
2 changes: 1 addition & 1 deletion app/views/pages/home/_videos.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
-#= admin_edit_button edit_admin_style_path(style)
#video-styles.mt-6.pt-6
- @styles.active.which_has_videos.each do |style|
- @styles.which_has_videos.each do |style|
%div.pb-4{id: dom_id(style)}
= render partial: 'pages/course_video_row', locals: { style: style }
- if @styles.empty?
Expand Down

0 comments on commit 7da4748

Please sign in to comment.