diff --git a/app/controllers/welcome_controller.rb b/app/controllers/welcome_controller.rb index af71f7f552580aa6fdeb448b195a38a796f30a5b..ff6597b91f18eccd4015ee14220eee7cdd352350 100644 --- a/app/controllers/welcome_controller.rb +++ b/app/controllers/welcome_controller.rb @@ -1,15 +1,7 @@ class WelcomeController < ApplicationController def index - @carousel = [] - @general = [] - mainPage = main_page_repository.all.first - - @carousel = carousel_repository.all - - @general = mainPage["highlights"].take(3).collect do |id| - learning_object_repository.find(id) - end + @carousel = carousel_repository.all || [] @highlights = learning_object_repository.all_by_score_from_offset_to_limit 0, 6 end diff --git a/app/views/welcome/index.html.erb b/app/views/welcome/index.html.erb index 5eceb4e726c8fff7258f0965369359eb9f799188..160f1c29e2939063facc0af330136d906a32a326 100644 --- a/app/views/welcome/index.html.erb +++ b/app/views/welcome/index.html.erb @@ -27,7 +27,6 @@ <div class="container"> <div class="carousel-caption"> <h1><%= link_to highlight.title, highlight.url, style: 'color: white;' %></h1> - </div> </div> </div> @@ -36,14 +35,6 @@ </div> <% end %> </div> - <div class="row mainpage-highlights"> - <% if @general.present? %> - <ul class="list-unstyled"> - <h2>Destaques</h2> - <%= render @general, orientation: 'horizontal' %> - <% end %> - </ul> - </div> </div> <% if !user_signed_in? %> <div class="registration-banner col-md-3 col-md-offset-1 hidden-xs hidden-sm">