Merge branch 'routing-filter'

This commit is contained in:
Benjamin Meichsner 2010-05-25 23:16:49 +02:00
commit 00d9f060cc
29 changed files with 282 additions and 260 deletions

View file

@ -4,7 +4,7 @@
Foodcoop
%ul
%li= link_to "Mitglieder", foodcoop_users_path
%li= link_to "Meine Aufgaben", :controller => "home", :action => "tasks"
%li= link_to "Meine Aufgaben", user_tasks_path
%li= link_to "Nachricht schreiben", :controller => "messages", :action => "new"
// Orders

View file

@ -21,11 +21,11 @@
- unless @unaccepted_tasks.empty?
%h3 Aufgaben übernehmen
Du bis für Aufgaben verantwortlich.
= link_to "Aufgaben übernehmen/ablehnen", my_tasks_path
= link_to "Aufgaben übernehmen/ablehnen", user_tasks_path
- unless @unassigned_tasks_number == 0
%h3 Offene Aufgaben
= "Es gibt #{@unassigned_tasks_number} #{link_to 'offene Aufgabe(n)', :controller => 'tasks'}"
%p{:style => "clear:both"}= link_to "Meine Aufgaben", my_tasks_path
%p{:style => "clear:both"}= link_to "Meine Aufgaben", user_tasks_path
- if @ordergroup
// Current orders

View file

@ -3,56 +3,56 @@
tabs = [
{ :name => "Start", :url => root_path, :active => ["index", "home"],
:subnav => [
{ :name => "Meine Aufgaben", :url => "/home/tasks" },
{ :name => "Meine Bestellgruppe", :url => "/home/ordergroup", :access_denied? => (!u.ordergroup)},
{ :name => "Mein Profil", :url => "/home/profile"}
{ :name => "Meine Aufgaben", :url => user_tasks_path },
{ :name => "Meine Bestellgruppe", :url => my_ordergroup_path, :access_denied? => (!u.ordergroup)},
{ :name => "Mein Profil", :url => my_profile_path}
]
},
{ :name => "Foodcoop", :url => "/tasks",
{ :name => "Foodcoop", :url => tasks_path,
:active => ["foodcoop", "tasks", "messages", "foodcoop/ordergroups", "foodcoop/workgroups", "foodcoop/users"],
:subnav => [
{ :name => "Mitglieder", :url => "/foodcoop/users"},
{ :name => "Abeitsgruppen", :url => "/foodcoop/workgroups"},
{ :name => "Bestellgruppen", :url => "/foodcoop/ordergroups"},
{ :name => "Nachrichten", :url => "/messages"},
{ :name => "Aufgaben", :url => "/tasks"}
{ :name => "Mitglieder", :url => foodcoop_users_path},
{ :name => "Abeitsgruppen", :url => foodcoop_workgroups_path},
{ :name => "Bestellgruppen", :url => foodcoop_ordergroups_path},
{ :name => "Nachrichten", :url => messages_path},
{ :name => "Aufgaben", :url => tasks_path}
]
},
{ :name => "Wiki", :url => "/wiki", :active => ["pages", "wiki"],
{ :name => "Wiki", :url => wiki_path, :active => ["pages", "wiki"],
:subnav => [
{ :name => "Startseite", :url => "/wiki" },
{ :name => "Alle Seiten", :url => "/pages/all" }
{ :name => "Startseite", :url => wiki_path },
{ :name => "Alle Seiten", :url => all_pages_path }
]
},
{ :name => "Bestellungen", :url => u.ordergroup ? "/ordering/" : "/orders",
{ :name => "Bestellungen", :url => u.ordergroup ? ordering_path : orders_path,
:active => ["orders", "ordering"],
:subnav => [
{ :name => "Bestellen!", :url => "/ordering" },
{ :name => "Meine Bestellungen", :url => "/ordering/myOrders" },
{ :name => "Bestellverwaltung", :url => "/orders", :access_denied? => (!u.role_orders?) }
{ :name => "Bestellen!", :url => ordering_path },
{ :name => "Meine Bestellungen", :url => my_orders_path },
{ :name => "Bestellverwaltung", :url => orders_path, :access_denied? => (!u.role_orders?) }
]
},
{ :name => "Artikel", :url => "/suppliers",
{ :name => "Artikel", :url => suppliers_path,
:active => ["articles", "suppliers", "deliveries", "article_categories", "stockit", "stock_takings"],
:access_denied? => (!u.role_article_meta? && !u.role_suppliers?),
:subnav => [
{ :name => "Artikel", :url => supplier_articles_path(Supplier.first) },
{ :name => "Lager", :url => "/stockit" },
{ :name => "Lager", :url => stock_articles_path },
{ :name => "Lieferantinnen", :url => suppliers_path, :access_denied? => (!u.role_suppliers?) },
{ :name => "Kategorien", :url => "/article_categories"}
{ :name => "Kategorien", :url => article_categories_path }
]
},
{ :name => "Finanzen", :url => "/finance",
{ :name => "Finanzen", :url => finance_root_path,
:active => ["finance/invoices", "finance/transactions", "finance/balancing"],
:access_denied? => (!u.role_finance?),
:subnav => [
{ :name => "Konten verwalten", :url => "/finance/transactions" },
{ :name => "Bestellungen abrechnen", :url => "/finance/balancing/list" },
{ :name => "Konten verwalten", :url => finance_transactions_path },
{ :name => "Bestellungen abrechnen", :url => finance_balancing_path },
{ :name => "Rechnungen", :url => finance_invoices_path }
]
},
{ :name => "Administration", :url => "/admin",
:active => ["admin", "admin/users", "admin/ordergroups", "admin/workgroups"],
{ :name => "Administration", :url => admin_root_path,
:active => ["admin/"],
:access_denied? => (!u.role_admin?),
:subnav => [
{ :name => "Benutzerinnen", :url => admin_users_path },
@ -77,4 +77,4 @@
</li>
<% end -%>
<% end -%>
</ul>
</ul>

View file

@ -15,7 +15,7 @@
#header
#logo
%a{:href => "/"}
- link_to root_path do
<span>food</span>soft
%span{:style => "color:white; font-size:45%; letter-spacing: -1px;"}= Foodsoft.config[:name]
#nav= render :partial => 'layouts/main_tabnav'

View file

@ -1,6 +1,6 @@
<%= yield %>
--
FoodSoft: <%= @foodsoftUrl %>
Foodcoop-Homepage: <%= Foodsoft.config[:base_url] %>
Hilfe/Help: <%= Foodsoft.config[:help_url] %>
FoodSoft: <%= url_for(:controller => "home", :action => "index", :only_path => false) %>
Foodcoop-Homepage: <%= Foodsoft.config[:homepage] %>
Hilfe/Help: <%= Foodsoft.config[:help_url] %>

View file

@ -15,4 +15,4 @@
= text_field 'login', 'email'
= submit_tag 'Neues Passwort anfordern'
|
= link_to 'Abbrechen', :action => 'login'
= link_to 'Abbrechen', login_path

View file

@ -13,4 +13,4 @@
= form.password_field :password_confirmation
= form.submit 'Speichern'
|
= link_to 'Abbrechen', :action => 'login'
= link_to 'Abbrechen', login_path

View file

@ -7,5 +7,5 @@ Sofern Du Dich noch nicht für diese Aufgabe eingetragen hast ist das jetzt die
<%= @task_url %>
--
Deine Aufgaben: <%= Foodsoft.config[:base_url] %>/home/tasks
Deine Aufgaben: <%= url_for(:controller => "home", :actions => "user") %>

View file

@ -9,6 +9,6 @@ Für Euch wurden die folgenden Artikel bestellt:
<% end -%>
Gesamtpreis: <%= @group_order.price %>
Bestellung online einsehen: <%= "#{Foodsoft.config[:base_url]}/ordering/my_order_result/#{@order.id}" %>
Bestellung online einsehen: <%= url_for(:controller => "ordering", :action => "my_order_result", :id => @order.id) %>
Viele Grüße von <%= Foodsoft.config[:name] %>

View file

@ -11,6 +11,6 @@ Aufgaben für die nächste Woche:
<% end -%>
<% end -%>
Meine Aufgaben: <%= Foodsoft.config[:base_url] %>/home/tasks
Meine Aufgaben: <%= url_for(:controller => "home", :actions => "user") %>
Viele Grüße von <%= Foodsoft.config[:name] %>

View file

@ -8,7 +8,7 @@
%li
Seiten
%ul
%li= link_to "Meine Aufgaben", my_tasks_path
%li= link_to "Meine Aufgaben", user_tasks_path
%li= link_to "Alle Aufgaben", :action => "index"
%li= link_to "Erledigt Aufgaben (Archiv)", :action => "archive"