forked from bofh/fetsite
is updated button für themen
This commit is contained in:
@@ -92,7 +92,13 @@ class ThemenController < ApplicationController
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
def fragen
|
def is_updated
|
||||||
|
@thema = Thema.find(params[:id])
|
||||||
|
@thema.translation.touch
|
||||||
|
|
||||||
|
redirect_to @thema
|
||||||
|
end
|
||||||
|
def fragen
|
||||||
@thema = Thema.find(params[:id])
|
@thema = Thema.find(params[:id])
|
||||||
@fragen=@thema.fragen
|
@fragen=@thema.fragen
|
||||||
respond_to do |format|
|
respond_to do |format|
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
<h2><%= small.title %> <%= link_to fa_icon("pencil"), verwalten_thema_path(small) if can? :edit, small %></h2>
|
<h2><%= small.title %> <%= link_to fa_icon("pencil"), verwalten_thema_path(small) if can? :edit, small %></h2>
|
||||||
</a>
|
</a>
|
||||||
<% if small.is_outdated? %>
|
<% if small.is_outdated? %>
|
||||||
<div class="sticker sticker-red"> <%= I18n.t("thema.outdated") %> </div>
|
<div class="sticker sticker-red"> <%= I18n.t("thema.outdated") %> <%= link_to"Als aktuell markieren",is_updated_thema_path(small), :class=>:btn %></div>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if small.isdraft %>
|
<% if small.isdraft %>
|
||||||
<div class="sticker sticker-yellow"><%= I18n.t("thema.isdraft") %> </div>
|
<div class="sticker sticker-yellow"><%= I18n.t("thema.isdraft") %> </div>
|
||||||
|
|||||||
@@ -155,6 +155,7 @@ Fetsite::Application.routes.draw do
|
|||||||
get :fragen
|
get :fragen
|
||||||
get :verwalten
|
get :verwalten
|
||||||
get :sanitize
|
get :sanitize
|
||||||
|
get :is_updated
|
||||||
end
|
end
|
||||||
resources :attachments
|
resources :attachments
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user