Fixed sidebar rendering, was not working on some pages after rails 2.2 upgrade

Signed-off-by: Reinier Balt <lrbalt@gmail.com>
This commit is contained in:
Vitalie Lazu 2009-01-17 17:40:37 +08:00 committed by Reinier Balt
parent 01a011ee06
commit 496741c972
5 changed files with 24 additions and 24 deletions

View file

@ -8,5 +8,5 @@
<div id="input_box">
<%= render :partial => "shared/add_new_item_form" %>
<%= render :template => "sidebar/sidebar" %>
</div><!-- End of input box -->
<%= render :file => "sidebar/sidebar.html.erb" %>
</div><!-- End of input box -->

View file

@ -57,18 +57,18 @@
<li>
<%= rss_formatted_link({:controller => 'todos', :action => 'index', :tag => 'starred'}) %>
<%= text_formatted_link({:controller => 'todos', :action => 'index', :tag => 'starred'}) %>
All starred, active actions
All starred, active actions
</li>
<li>
<%= text_formatted_link({:controller => 'projects', :action => 'index', :projects_and_actions => true}) %>
Active projects with their actions
Active projects with their actions
</li>
<li><h4>Feeds for incomplete actions in a specific context:</h4>
<% if @active_contexts.empty? && @hidden_contexts.empty? -%>
<ul><li>There need to be at least one context before you can request a feed</li></ul>
<% else -%>
<ul>
<li>Step 1 - Choose the context you want a feed of:
<li>Step 1 - Choose the context you want a feed of:
<select name="feed-contexts" id="feed-contexts">
<%= options_from_collection_for_select(@active_contexts, "id", "name", @active_contexts.first.id) unless @active_projects.empty?-%>
<%= options_from_collection_for_select(@hidden_contexts, "id", "name") -%>
@ -78,7 +78,7 @@
:url => { :controller => "feedlist", :action => "get_feeds_for_context" },
:before => "$('feeds-for-context').startWaiting()",
:complete => "$('feeds-for-context').stopWaiting()"
-%>
-%>
</li>
<li>Step 2 - Select the feed for this context
<div id="feedicons-context">
@ -95,7 +95,7 @@
<ul><li>There need to be at least one project before you can request a feed</li></ul>
<% else -%>
<ul>
<li>Step 1 - Choose the project you want a feed of:
<li>Step 1 - Choose the project you want a feed of:
<select name="feed-projects" id="feed-projects">
<%= options_from_collection_for_select(@active_projects, "id", "name", @active_projects.first.id) unless @active_projects.empty?-%>
<%= options_from_collection_for_select(@hidden_projects, "id", "name") -%>
@ -106,7 +106,7 @@
:url => { :controller => "feedlist", :action => "get_feeds_for_project" },
:before => "$('feeds-for-project').startWaiting()",
:complete => "$('feeds-for-project').stopWaiting()"
-%>
-%>
</li>
<li>Step 2 - Select the feed for this project
<div id="feedicons-project">
@ -123,7 +123,7 @@
</div><!-- End of display_box -->
<div id="input_box">
<%= render :template => "sidebar/sidebar" %>
<%= render :file => "sidebar/sidebar.html.erb" %>
</div><!-- End of input box -->
<script type="text/javascript">

View file

@ -14,7 +14,7 @@
<div class="add_note_link"><%= link_to_function( "Add a note", "Element.toggle('new-note'); Form.focusFirstElement('form-new-note');", :id=>"add_note_href") %></div>
<h2>Notes</h2>
<div id="empty-n" style="display:<%= @project.notes.empty? ? 'block' : 'none'%>;">
<%= render :partial => "shared/empty",
<%= render :partial => "shared/empty",
:locals => { :message => "Currently there are no notes attached to this project"} %>
</div>
<%= render :partial => "notes/notes_summary", :collection => @project.notes %>
@ -56,7 +56,7 @@
<div id="default_context">
<h2>Default Context</h2>
<div>
<% form_remote_tag( :url => project_path(@project), :method => :put,
<% form_remote_tag( :url => project_path(@project), :method => :put,
:html=> { :id => 'set-default-context-action',
:name => 'default_context',
:class => 'inline-form' }) do -%>
@ -74,5 +74,5 @@
<div id="input_box">
<%= render :partial => "shared/add_new_item_form" %>
<%= render :template => "sidebar/sidebar" %>
<%= render :file => "sidebar/sidebar.html.erb" %>
</div><!-- End of input box -->

View file

@ -1,15 +1,15 @@
<div id="display_box">
<div id="tickler-empty-nd" style="display:<%= (@count == 0) ? 'block' : 'none'%>;">
<div class="message"><p>Currently there are no deferred actions.</p></div>
</div>
<%= render :partial => "contexts/context", :collection => @contexts,
<%= render :partial => "contexts/context", :collection => @contexts,
:locals => { :collapsible => true } %>
</div><!-- End of display_box -->
<div id="input_box">
<%= render :partial => "shared/add_new_item_form" %>
<%= render :template => "sidebar/sidebar" %>
</div><!-- End of input box -->
<%= render :file => "sidebar/sidebar.html.erb" %>
</div><!-- End of input box -->

View file

@ -3,25 +3,25 @@
<h2>No actions found</h2>
<div class="message"><p>Currently there are no incomplete actions with the tag '<%= @tag_name %>'</p></div>
</div>
<%= render :partial => "contexts/context", :collection => @contexts_to_show,
<%= render :partial => "contexts/context", :collection => @contexts_to_show,
:locals => { :collapsible => true } %>
<% unless @deferred.nil? -%>
<%= render :partial => "todos/deferred", :locals => { :deferred => @deferred, :collapsible => true, :append_descriptor => "tagged with &lsquo;#{@tag_name}&rsquo;" } %>
<% end -%>
<% unless @hidden_todos.nil? -%>
<%= render :partial => "todos/hidden", :locals => { :hidden => @hidden_todos, :collapsible => true, :append_descriptor => "tagged with &lsquo;#{@tag_name}&rsquo;" } %>
<% end -%>
<% unless @done.nil? -%>
<%= render :partial => "todos/completed",
<%= render :partial => "todos/completed",
:locals => { :done => @done, :collapsible => true, :append_descriptor => "tagged with &lsquo;#{@tag_name}&rsquo;" } %>
<% end -%>
</div><!-- End of display_box -->
<div id="input_box">
<%= render :partial => "shared/add_new_item_form" %>
<%= render :template => "sidebar/sidebar" %>
</div><!-- End of input box -->
<%= render :file => "sidebar/sidebar.html.erb" %>
</div><!-- End of input box -->