links in studienansicht fixed
This commit is contained in:
@@ -40,17 +40,9 @@ class StudienController < ApplicationController
|
|||||||
{:hicon=>'icon-list', :text => I18n.t('modulgruppe.list'), :path=>modulgruppen_path}]
|
{:hicon=>'icon-list', :text => I18n.t('modulgruppe.list'), :path=>modulgruppen_path}]
|
||||||
case params[:ansicht]
|
case params[:ansicht]
|
||||||
when 'semesteransicht'
|
when 'semesteransicht'
|
||||||
@text = 'Zu Modulansicht wechseln'
|
|
||||||
@flip = 'modulgruppenansicht'
|
|
||||||
# render 'semesteransicht'
|
|
||||||
|
|
||||||
when 'infoansicht'
|
when 'infoansicht'
|
||||||
@text = 'Zu Modulansicht wechseln'
|
|
||||||
@flip = 'modulgruppenansicht'
|
|
||||||
|
|
||||||
else
|
else
|
||||||
@text = 'Zu Semesteransicht wechseln'
|
params[:ansicht]="modulgruppenansicht"
|
||||||
@flip = 'semesteransicht'
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@@ -4,21 +4,22 @@
|
|||||||
<h1><%= @studium.typ %> <%= @studium.name %> (<%= @studium.zahl %>)</h1>
|
<h1><%= @studium.typ %> <%= @studium.name %> (<%= @studium.zahl %>)</h1>
|
||||||
<p>
|
<p>
|
||||||
<div class="pull-right">
|
<div class="pull-right">
|
||||||
<%= link_to @text, studium_path(@studium, :ansicht=>@flip), :class=>"btn" %>
|
<%= link_to "Semesteransicht", studium_path(@studium, :ansicht=>"semesteransicht"), :class=>"btn" unless params[:ansicht]=='semesteransicht' %>
|
||||||
<%= link_to "Infoansicht", studium_path(@studium, :ansicht=>"infoansicht"), :class=>"btn" %>
|
<%= link_to "Modulgruppenansicht", studium_path(@studium, :ansicht=>"modulgruppenansicht"), :class=>"btn" unless params[:ansicht]=='modulgruppenansicht' %>
|
||||||
|
<%= link_to "Infoansicht", studium_path(@studium, :ansicht=>"infoansicht"), :class=>"btn" unless params[:ansicht]=='infoansicht' %>
|
||||||
</div>
|
</div>
|
||||||
</p>
|
</p>
|
||||||
<% if params[:ansicht]=='modulgruppenansicht' %>
|
<% if params[:ansicht]=='modulgruppenansicht' %>
|
||||||
<%= render partial: 'modulgruppenansicht' %>
|
<%= render partial: 'modulgruppenansicht' %>
|
||||||
<% else if params[:ansicht]=='infoansicht' %>
|
<% else if params[:ansicht]=='infoansicht' %>
|
||||||
<%= render partial: 'infoansicht' %>
|
<%= render partial: 'infoansicht' %>
|
||||||
<% else %>
|
<% else %>
|
||||||
<%= render partial: 'semesteransicht' %>
|
<%= render partial: 'semesteransicht' %>
|
||||||
|
|
||||||
|
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<%= render :partial=>'layouts/pretty_toolbar', :object=>@toolbar_modulgruppen %><br>
|
<%= render :partial=>'layouts/pretty_toolbar', :object=>@toolbar_modulgruppen %><br>
|
||||||
<%= render 'layouts/pretty_toolbar' %>
|
<%= render 'layouts/pretty_toolbar' %>
|
||||||
|
|||||||
Reference in New Issue
Block a user