Refactoring of articles and article_categories. articles are now a nested resource of supplier.

This commit is contained in:
Benjamin Meichsner 2009-01-16 16:19:26 +01:00
parent b38025869a
commit 936e6ef69a
36 changed files with 597 additions and 589 deletions

View file

@ -23,11 +23,11 @@
{ :name => "Manage orders", :url => "/orders", :access? => (u.role_orders?) }
]
},
{ :name => "Articles", :url => "/articles", :active => ["articles", "suppliers", "deliveries"],
{ :name => "Articles", :url => "/suppliers", :active => ["articles", "suppliers", "deliveries", "article_categories"],
:access? => (u.role_article_meta? || u.role_suppliers?),
:subnav => [
{ :name => "Show articles", :url => "/articles/list" },
{ :name => "Categories", :url => "/articles" },
{ :name => "Show articles", :url => "/suppliers" },
{ :name => "Categories", :url => "/suppliers" },
{ :name => "Suppliers", :url => suppliers_path, :access? => (u.role_suppliers?) }
]
},

View file

@ -0,0 +1,17 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="content-type" content="text/html;charset=UTF-8" />
<title>ArticleCategories: <%= controller.action_name %></title>
<%= stylesheet_link_tag 'scaffold' %>
</head>
<body>
<p style="color: green"><%= flash[:notice] %></p>
<%= yield %>
</body>
</html>