Functional tests now work properly, bearing in mind whether a user is logged in or...
[depot.git] / app / views / products / index.html.erb
index 3e068e6697479b9aa50cf8223096c4bb23567a05..ca7fb6a809cd53c83ec2491a40f59f13fcb21e19 100644 (file)
@@ -1,4 +1,4 @@
-<div id="product-list">
+<div id="pretty-list">
   <h1>Listing products</h1>
 
   <table>
           <% else %>
             <dd class="unavailable">Available from <%= product.date_available %></dd>
           <% end %>
+          <% if not product.date_available_until.nil? %> 
+            <% if product.date_available_until.future? %>
+              <dd>Available until <%= product.date_available_until %></dd>
+            <% else %>
+              <dd class="unavailable">Unavailable since <%= product.date_available_until %></dd>
+            <% end %>
+          <% end %>
         </dl>
       </td>