mirror of
https://github.com/TracksApp/tracks.git
synced 2025-12-16 15:20:13 +01:00
initial changes to add an option to select either context or project as grouping of todos on home or tag page
* new menu item in view menu * js to toggle view * store setting in cookie to keep de choice of view persistent * refactor index and tag page of todos to look more alike * refactor context and project partials to look more alike
This commit is contained in:
parent
55aa387ab9
commit
f22dfc1f9b
15 changed files with 160 additions and 84 deletions
|
|
@ -1,5 +1,19 @@
|
|||
module ProjectsHelper
|
||||
|
||||
def show_project_name(project)
|
||||
if source_view_is :project
|
||||
content_tag(:span, :id => "project_name"){project.name}
|
||||
else
|
||||
link_to_project( project )
|
||||
end
|
||||
end
|
||||
|
||||
def show_project_settings(project)
|
||||
content_tag(:div, :id => dom_id(project, "container"), :class=>"list") do
|
||||
render :partial => "projects/project_settings", :object => project
|
||||
end
|
||||
end
|
||||
|
||||
def project_next_prev
|
||||
html = ""
|
||||
html << link_to_project(@previous_project, "« #{@previous_project.shortened_name}".html_safe) if @previous_project
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue