diff --git a/app/controllers/home_controller.rb b/app/controllers/home_controller.rb index 20a9a49..dedb4e7 100755 --- a/app/controllers/home_controller.rb +++ b/app/controllers/home_controller.rb @@ -8,6 +8,7 @@ class HomeController < ApplicationController else @starttopic=@themen = nil end + @stickythemen = Thema.where(:sticky_startpage=>true) end def dev diff --git a/app/models/thema.rb b/app/models/thema.rb index f9d506f..2149dcd 100644 --- a/app/models/thema.rb +++ b/app/models/thema.rb @@ -13,7 +13,7 @@ require 'uri' class Thema < ActiveRecord::Base include Rails.application.routes.url_helpers - attr_accessible :text, :title, :themengruppe_id,:isdraft, :hidelink, :hideattachment + attr_accessible :text, :title, :themengruppe_id,:isdraft, :hidelink, :hideattachment, :sticky_startpage,:sticky_intern has_many :fragen has_many :attachments belongs_to :themengruppe, :foreign_key => "themengruppe_id" diff --git a/app/views/themen/_form.html.erb b/app/views/themen/_form.html.erb index 4995656..3ee1ba9 100644 --- a/app/views/themen/_form.html.erb +++ b/app/views/themen/_form.html.erb @@ -21,6 +21,8 @@