end
end
+ def css_classes
+ [
+ completed? ? 'version-completed' : 'version-incompleted',
+ "version-#{status}"
+ ].join(' ')
+ end
+
def self.fields_for_order_statement(table=nil)
table ||= table_name
["(CASE WHEN #{table}.effective_date IS NULL THEN 1 ELSE 0 END)", "#{table}.effective_date", "#{table}.name", "#{table}.id"]
<% else %>
<div id="roadmap">
<% @versions.each do |version| %>
- <article class="version-article <%= version.completed? ? 'version-completed' : 'version-incompleted' %>">
+ <article class="version-article <%= version.css_classes %>">
<header>
<h3 class="version"><%= link_to_version version, :name => version_anchor(version) %></h3>
</header>
<h2><%= @version.name %></h2>
-<div id="roadmap">
+<div id="roadmap" class="<%= @version.css_classes %>">
<%= render :partial => 'versions/overview', :locals => {:version => @version} %>
<%= render(:partial => "wiki/content", :locals => {:content => @version.wiki_page.content}) if @version.wiki_page %>