themengruppen verwaltung ergänzung

This commit is contained in:
Andreas Stephanides
2014-02-16 15:34:16 +01:00
parent 87d7cc247a
commit 82388150ff
9 changed files with 30 additions and 0 deletions

View File

@@ -0,0 +1,10 @@
<%= semantic_form_for [@thema,@attachment],:remote=>true do |f| %>
<%= f.inputs do %>
<%= f.input :name %>
<%= f.input :datei, :as => :file %>
<% end %>
<%= f.actions do %>
<%= f.action :submit, :as => :input %>
<% end %>
<% end %>

View File

@@ -0,0 +1,2 @@
$("#attachmentform").html("<%=escape_javascript( render :partial=>'attachments/rform' )%>")

View File

@@ -0,0 +1 @@
$("#attachmentform").html("<%=escape_javascript( render :partial=>'attachments/rform' )%>")

View File

@@ -0,0 +1 @@
$("#fragenform").html("<%=escape_javascript( render :partial=>'fragen/rform' )%>")

View File

@@ -0,0 +1,10 @@
<h2>FAQs:</h2>
<div id="fragen">
<%= render :partial=>'fragen/liste' %>
</div>
<% @frage=Frage.new; @frage.thema=@thema %>
<div id="fragenform">
<%= render :partial=>'fragen/rform' %>
</div>
<% @frage_elements = [{:icon=>:plus, :hicon=>'icon-plus', :text=>I18n.t('frage.add'), :path=>new_frage_path}] %>
<%= render :partial=>'layouts/pretty_toolbar', :object=>@frage_elements %>

View File

@@ -0,0 +1 @@
$("#themaview").html("<%= escape_javascript(raw("<h2>Bearbeiten</h2>")+render(:partial=>"themen/form") )%>");

View File

@@ -0,0 +1 @@
$("#themaview").html("<%=escape_javascript( render :partial=>'themen/fragen' )%>")

View File

@@ -0,0 +1,2 @@
alert('t');
$("#themaview").html("<%= escape_javascript(raw("<h2>Bearbeiten</h2>")+render(:partial=>"themen/small", :object=>@thema) )%>");

View File

@@ -0,0 +1,2 @@
alert("hallo Welt");
$("#themaview").html("<%=escape_javascript( render :action=>:edit, :layout=>false )%>");