Removed gettext and simplified_localization-plugin. L18n is now the appropriate module.

Upgraded to rails 2.2.2 and replaced complex foodsoft.rb-loader with simple
initializers/load_app_config.rb. Multiple foodcoops option is temporarly deactivated.
This commit is contained in:
Benjamin Meichsner 2009-01-06 15:45:19 +01:00
parent 5b9a7e05df
commit 9f8d0d28ac
121 changed files with 1197 additions and 15237 deletions

View file

@ -30,7 +30,7 @@
%td=h user.last_name
%td=h user.email
%td=h roles.join(', ')
%td=h FoodSoft::format_date_time(user.last_login)
%td=h format_date_time(user.last_login)
%td
= link_to(image_tag('b_edit.png', :size => "16x16", :border => "0", :alt => 'Benutzer_in bearbeiten', :title => 'Benutzer_in bearbeiten'), :action => 'editUser', :id => user)
= link_to(image_tag('b_drop.png', :size => "16x16", :border => "0", :alt => 'Benutzer_in löschen', :title => 'Benutzer_in löschen'), |

View file

@ -56,5 +56,5 @@
%td{:colspan => "4"}
%b
%abbr{:title => "= Gruppenbeträge - Rechnung ohne Pfand"} Differenz mit Aufschlag
= "(#{number_to_percentage(FoodSoft.getPriceMarkup)}):"
= "(#{number_to_percentage(APP_CONFIG[:price_markup])}):"
%span#fcProfit= number_to_currency(@order.fcProfit)

View file

@ -17,7 +17,7 @@
#logo
%a{:href => "/"}
<span>food</span>soft
%span{:style => "color:white; font-size:45%; letter-spacing: -1px;"}= FoodSoft::getFoodcoopName
%span{:style => "color:white; font-size:45%; letter-spacing: -1px;"}= APP_CONFIG[:name]
#nav= render :partial => 'shared/nav'
#main

View file

@ -12,4 +12,4 @@
= yield
#meta
Foodcoop
= link_to_if FoodSoft::getFoodcoopUrl, FoodSoft::getFoodcoopName, FoodSoft::getFoodcoopUrl
= link_to_if APP_CONFIG[:base_url], APP_CONFIG[:name], APP_CONFIG[:base_url]

View file

@ -1,9 +1,9 @@
Hallo <%= user.nick %>!
Der Kontostand deiner Bestellgruppe <%= group.name %> ist durch eine Buchung am <%= transaction.created_on.strftime('%d.%m.%Y um %H:%M') %> ins Minus gerutscht: <%= FoodSoft::format_currency(group.account_balance) %>
Der Kontostand deiner Bestellgruppe <%= group.name %> ist durch eine Buchung am <%= transaction.created_on.strftime('%d.%m.%Y um %H:%M') %> ins Minus gerutscht: <%= group.account_balance %>
Es wurden <%= FoodSoft::format_currency(transaction.amount) %> für "<%= transaction.note %>" abgebucht, die Buchung wurde von <%= transaction.user.nick %> erstellt.
Es wurden <%= transaction.amount %> für "<%= transaction.note %>" abgebucht, die Buchung wurde von <%= transaction.user.nick %> erstellt.
Bitte zahlt so bald wie möglich wieder Geld ein, um das Gruppenkonto auszugleichen.
Viele Grüße von <%= FoodSoft::getFoodcoopName %>
Viele Grüße von <%= APP_CONFIG[:name] %>

View file

@ -5,10 +5,10 @@ Die Bestellung "<%= order.name %>" wurde am <%= order.ends.strftime('%d.%m.%Y um
Für deine Bestellgruppe <%= group.name %> wurden die folgenden Artikel bestellt:
<% for result in results
article = result.order_article_result -%>
<%= article.name %>: <%= result.quantity %> x <%= article.unit %> = <%= FoodSoft::format_currency(result.quantity * article.gross_price) %>
<%= article.name %>: <%= result.quantity %> x <%= article.unit %> = <%= result.quantity * article.gross_price %>
<% end -%>
Gesamtpreis: <%= FoodSoft::format_currency(total) %>
Gesamtpreis: <%= total %>
Bestellung online einsehen: <%= ApplicationController.current.url_for(:controller => 'ordering', :action => 'my_order_result', :id => order.id) %>
Viele Grüße von <%= FoodSoft::getFoodcoopName %>
Viele Grüße von <%= APP_CONFIG[:name] %>

View file

@ -125,7 +125,7 @@
<%= button_to_function('-', "decreaseTolerance(#{i})") %>
<% end -%>
</td>
<td id="td_price_<%= i %>" style="text-align:right; padding-right:10px; width:4em"><span id="price_<%= i %>_display"><%= number_to_currency(article_total, :unit => "") %></span> <%= FoodSoft::getCurrencyUnit %></td>
<td id="td_price_<%= i %>" style="text-align:right; padding-right:10px; width:4em"><span id="price_<%= i %>_display"><%= number_to_currency(article_total, :unit => "") %></span> <%= l18n.number.currency.format.unit %></td>
</tr>
<% unless order_article.article.note.empty? -%>
<tr id="note_<%= i %>" class="note" style="display:none">
@ -139,7 +139,7 @@
<tfoot>
<tr>
<td colspan="6"></td>
<td colspan="3" class="currency"><%=_ "Total amount" %>: <span id="total_price"><%= total %></span> <%= FoodSoft::getCurrencyUnit %></td>
<td colspan="3" class="currency"><%=_ "Total amount" %>: <span id="total_price"><%= total %></span> <%= l18n.number.currency.format.unit %></td>
</tr>
<tr>
<td colspan="6"></td>
@ -147,7 +147,7 @@
</tr>
<tr>
<td colspan="6"></td>
<td colspan="3" class="currency"><%=_ "New account balance"%>: <strong><span id="new_balance"><%= @order_group.account_balance - total %></span> <%= FoodSoft::getCurrencyUnit %></strong></td>
<td colspan="3" class="currency"><%=_ "New account balance"%>: <strong><span id="new_balance"><%= @order_group.account_balance - total %></span> <%= l18n.number.currency.format.unit %></strong></td>
</tr>
<tr>
<td style="text-align:left;"><%= link_to_top %></td>
@ -171,7 +171,7 @@
setGroupBalance(<%= @availableFunds %>);
// localization
setDecimalSeparator("<%= FoodSoft::getDecimalSeparator %>");
setDecimalSeparator("<%= l18n.number.currency.format.separator %>");
// initialize javascript
updateBalance();

View file

@ -20,7 +20,7 @@
@ends = @order.ends.strftime('%d.%m.%Y').to_s
@title = replace_UTF8(@order.name.to_s) + " | beendet am " + @ends
pdf.SetAuthor(FoodSoft.getFoodcoopName)
pdf.SetAuthor(APP_CONFIG[:name])
pdf.SetTitle(replace_UTF8("Artikelsortierung für #{@order.name}, #{format_date(@order.ends)}"))
pdf.AliasNbPages()
pdf.AddPage()

View file

@ -11,7 +11,7 @@
@order_articles = @order.order_article_results
pdf.SetAuthor(replace_UTF8(FoodSoft.getFoodcoopName))
pdf.SetAuthor(replace_UTF8(APP_CONFIG[:name]))
pdf.SetTitle(replace_UTF8("BestellFAX für #{@order.supplier.name}"))
pdf.AliasNbPages()
pdf.AddPage()
@ -19,15 +19,15 @@
#the main informations
pdf.SetY(15)
pdf.SetFont('Arial','',10)
pdf.Cell(0,5,replace_UTF8(FoodSoft.getFoodcoopName),0,0,'R')
pdf.Cell(0,5,replace_UTF8(APP_CONFIG[:name]),0,0,'R')
pdf.Ln()
pdf.Cell(0,5,replace_UTF8(FoodSoft.getFoodcoopContact[:street]),0,0,'R')
pdf.Cell(0,5,replace_UTF8(APP_CONFIG[:contact].symbolize_keys[:street]),0,0,'R')
pdf.Ln()
pdf.Cell(0,5,FoodSoft.getFoodcoopContact[:zip_code] + " " + replace_UTF8(FoodSoft.getFoodcoopContact[:city]),0,0,'R')
pdf.Cell(0,5,APP_CONFIG[:contact].symbolize_keys[:zip_code] + " " + replace_UTF8(APP_CONFIG[:contact].symbolize_keys[:city]),0,0,'R')
pdf.Ln()
pdf.Cell(0,5,replace_UTF8(FoodSoft.getFoodcoopName[:phone]),0,0,'R')
pdf.Cell(0,5,replace_UTF8(APP_CONFIG[:name][:phone]),0,0,'R')
pdf.Ln()
pdf.Cell(0,5,replace_UTF8(FoodSoft.getFoodcoopName[:email]),0,0,'R')
pdf.Cell(0,5,replace_UTF8(APP_CONFIG[:name][:email]),0,0,'R')
pdf.Ln()
pdf.Cell(0,5,Date.today.strftime('%d.%m.%Y').to_s,0,0,'R')
pdf.Ln()

View file

@ -19,7 +19,7 @@
@ends = @order.ends.strftime('%d.%m.%Y').to_s
@title = replace_UTF8(@order.name.to_s) + " | beendet am " + @ends
pdf.SetAuthor(FoodSoft.getFoodcoopName)
pdf.SetAuthor(APP_CONFIG[:name])
pdf.SetTitle(replace_UTF8("GruppenSortierung für #{@order.name}, #{format_date(@order.ends)}"))
pdf.SetFillColor(235)
pdf.AliasNbPages()

View file

@ -18,7 +18,7 @@
MAX_ARTICLES_PER_PAGE = 15 #how many articles shoud written on a page
pdf=PDF.new
pdf.SetAuthor(FoodSoft.getFoodcoopName)
pdf.SetAuthor(APP_CONFIG[:name])
@starts = @order.starts.strftime('%d.%m.%Y').to_s
@ends = @order.ends.strftime('%d.%m.%Y').to_s
@title = replace_UTF8(@order.name.to_s) + " | beendet am " + @ends

View file

@ -2,7 +2,7 @@
%li
= image_tag 'b_user.png' , :size => '7x10', :border => 0, :alt => _("User")
= link_to h(@current_user.nick), { :controller => 'index', :action => 'myProfile' }, { :title => _("User Settings") }
- if FoodSoft::getFoodcoopUrl
%li= link_to FoodSoft::getFoodcoopName, FoodSoft::getFoodcoopUrl, { :title => _("Go to your FoodCoop-Hompage") }
- if APP_CONFIG[:base_url]
%li= link_to APP_CONFIG[:name], APP_CONFIG[:base_url], { :title => _("Go to your FoodCoop-Hompage") }
%li= link_to _("Help"), 'http://dev.foodcoops.net/wiki/FoodsoftDoku'
%li= link_to _("Logout"), :controller => '/login', :action => 'logout'

View file

@ -1,4 +1,4 @@
--
FoodSoft: <%= @foodsoftUrl %>
Foodcoop-Homepage: <%= FoodSoft::getFoodcoopUrl %>
Hilfe/Help: <%= FoodSoft::getHelp %>
Foodcoop-Homepage: <%= APP_CONFIG[:base_url] %>
Hilfe/Help: <%= APP_CONFIG[:help_url] %>