Skip to content

Commit

Permalink
Refactored structural elements from planning view into layout
Browse files Browse the repository at this point in the history
  • Loading branch information
arafatm committed Aug 3, 2010
1 parent e334972 commit 1153c6e
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 33 deletions.
11 changes: 10 additions & 1 deletion lib/views/layout.haml
@@ -1,4 +1,13 @@
%html
%head
%title= "Fable: Share a story"
= yield
%link{:href => "/main.css", :rel => "stylesheet", :type => "text/css"}
%body
%header= "Story Planner"
%nav
%ul
%li
%a{:href=>'/'} Story Planner
%section#main
= yield
%footer= "Fable"
50 changes: 18 additions & 32 deletions lib/views/planning.haml
@@ -1,32 +1,18 @@
!!! 5
%html
%head
%link{:href => "/main.css", :rel => "stylesheet", :type => "text/css"}
%title= "Story Planner"
%body
%header= "Story Planner"
%nav
%ul
%li
%a{:href=>'/'} Story Planner
%section#main
%table.map
%thead
%tr
%th
- @features.each do |feature|
%th.feature= feature.description
%tbody
- @releases.each do |release|
%tr
%th
= release.description
= release.date
- @features.each do |feature|
- stories = Story.all(:feature => feature, :release => release)
%td{:class => cycle('even', 'odd')}
%ul.stories
- stories.each do |story|
%li.story= "#{story.id}: #{story.description}"
%footer= "Fable"

%table.map
%thead
%tr
%th
- @features.each do |feature|
%th.feature= feature.description
%tbody
- @releases.each do |release|
%tr
%th
= release.description
= release.date
- @features.each do |feature|
- stories = Story.all(:feature => feature, :release => release)
%td{:class => cycle('even', 'odd')}
%ul.stories
- stories.each do |story|
%li.story= "#{story.id}: #{story.description}"

0 comments on commit 1153c6e

Please sign in to comment.