diff --git a/app/assets/stylesheets/application.css.scss b/app/assets/stylesheets/application.css.scss index 73a6def..25ee93f 100755 --- a/app/assets/stylesheets/application.css.scss +++ b/app/assets/stylesheets/application.css.scss @@ -78,7 +78,7 @@ div.header { .navbar .nav li { - min-width:60%; + min-width:100%; } .navbar .nav .divider { border-style: solid; diff --git a/app/controllers/config_controller.rb b/app/controllers/config_controller.rb index 2c13eb3..2192afb 100755 --- a/app/controllers/config_controller.rb +++ b/app/controllers/config_controller.rb @@ -2,12 +2,5 @@ class ConfigController < ApplicationController def index end - def get_git_update - g = Git.open(".") - flash[:notice] ="Test" - flash[:notice] =g.remote("fetsite").fetch - redirect_to config_url - - end end diff --git a/app/models/calendar.rb b/app/models/calendar.rb index 9f2826e..2d817cb 100644 --- a/app/models/calendar.rb +++ b/app/models/calendar.rb @@ -14,6 +14,7 @@ class Calendar < ActiveRecord::Base attr_accessible :name, :public, :picture has_and_belongs_to_many :calentries mount_uploader :picture, PictureUploader + belongs_to :rubrik resourcify scope :public, -> { where(:public => :true) } end diff --git a/app/models/rubrik.rb b/app/models/rubrik.rb index 6087ef8..a74198b 100755 --- a/app/models/rubrik.rb +++ b/app/models/rubrik.rb @@ -15,12 +15,13 @@ class Rubrik < ActiveRecord::Base has_many :neuigkeiten, :class_name => "Neuigkeit" has_many :calentries, :through => :neuigkeiten, :as=>:object resourcify -def moderator - u=User.with_role(:newsmoderator).first - if !u.nil? - u.id - end -end + has_one :calendar + def moderator + u=User.with_role(:newsmoderator).first + if !u.nil? + u.id + end + end end diff --git a/app/views/fetprofiles/index.html.erb b/app/views/fetprofiles/index.html.erb index f6889e8..861cb3e 100644 --- a/app/views/fetprofiles/index.html.erb +++ b/app/views/fetprofiles/index.html.erb @@ -1,36 +1,29 @@ -
<%= fetprofile.fetmail %>
-<%= fetprofile.desc %>
- -<%= fetprofile.fetmail %>
+<%= fetprofile.desc %>
+<%= notice %>
- <%= @fetprofile.fetmailalias %> -
-- <%= @fetprofile.desc %> -
-- <%= "Aktiv".html_safe if @fetprofile.active %> -
-<%= link_to 'Destroy', @fetprofile, method: :delete, data: { confirm: 'Are you sure?' } %>
-+ <%= @fetprofile.fetmailalias %> +
++ <%= @fetprofile.desc %> +
++ <%= ""+I18n.t('fetprofiles.active')+"".html_safe if @fetprofile.active %> +
+<%= link_to 'Destroy', @fetprofile, method: :delete, data: { confirm: 'Are you sure?' } %>
+<%= notice %>
<%= notice %>
-- <%= @gremium.desc %> -
-
- <%= m.fetprofile.name %>
<%= render(m) %>
-
+ <%= @gremium.desc %> +
+
+ <%= m.fetprofile.name %>
+ <%= render(m) %>
+
| Title | -Text | -Datum | -- | - | - |
|---|---|---|---|---|---|
| <%= neuigkeit.title %> | -<%= neuigkeit.text %> | -<%= neuigkeit.datum %> | -<%= link_to 'Show', neuigkeit %> | -<%= link_to 'Edit', edit_neuigkeit_path(neuigkeit) %> | -<%= link_to 'Destroy', neuigkeit, method: :delete, data: { confirm: 'Are you sure?' } %> | -
<%= notice %>
-<%= notice %>
- <%= @neuigkeit.author.email.to_s unless @neuigkeit.try(:author).try(:email).to_s %> - <%= "am " + I18n.l(@neuigkeit.try(:datum).try(:to_date)) unless @neuigkeit.try(:datum).try(:to_date).nil? %> -
<%= link_to image_tag(@neuigkeit.picture.big_thumb.url),@neuigkeit.picture.url %>
+
<%= link_to image_tag(@neuigkeit.picture.big_thumb.url),@neuigkeit.picture.url %>
<%= notice %>
-- <%= @rubrik.desc %>
-Moderatoren: -<% @moderatoren.each do |m|%> -<%= m.email%>, -<% end%> - -