Complete refactoring of orders-workflow.

OrderResult tables are removed. Data consistency is now possible through new article.price-history (ArticlePrice).
Balancing-workflow needs to be updated.
This commit is contained in:
Benjamin Meichsner 2009-01-29 01:57:51 +01:00
parent 80287aeea4
commit 9eb2125f15
98 changed files with 1121 additions and 1717 deletions

View file

@ -10,8 +10,8 @@
<td><%= @article.unit_quantity -%></td>
<td class="currency">
<acronym title="zuletzt geändert: <%= format_date(@article.updated_at) -%>
| Brutto: <%= number_to_currency(@article.gross_price) -%>">
<%= number_to_currency(@article.net_price) -%>
| Brutto: <%= number_to_currency(@article.fc_price) -%>">
<%= number_to_currency(@article.price) -%>
</acronym>
</td>
<td><%= number_to_percentage(@article.tax) if @article.tax != 0 -%></td>

View file

@ -31,7 +31,7 @@
%th Pfand
%tbody
%tr
%td= form.text_field :net_price, :size => 5
%td= form.text_field :price, :size => 5
%td= form.text_field :unit_quantity, :size => 5
%td= form.text_field :order_number, :size => 10
%td= form.text_field :tax, :size => 5

View file

@ -44,7 +44,7 @@
<%= form.text_field 'name', :size => 0 -%>
</td>
<td><%= form.text_field 'unit', :size => 5 -%></td>
<td><%= form.text_field 'net_price', :size => 4 -%></td>
<td><%= form.text_field 'price', :size => 4 -%></td>
<td><%= form.text_field 'unit_quantity', :size => 4 -%></td>
<td><%= form.text_field 'order_number', :size => 6 -%></td>
<td><%= form.text_field 'note', :size => 15 -%></td>

View file

@ -28,7 +28,7 @@
%td= form.text_field 'manufacturer', :size => 6
%td= form.text_field 'origin', :size => 6
%td= form.text_field 'unit', :size => 5
%td= form.text_field 'net_price', :size => 4
%td= form.text_field 'price', :size => 4
%td= form.text_field 'tax', :size => 4
%td= form.text_field 'deposit', :size => 4
%td= form.text_field 'unit_quantity', :size => 4

View file

@ -46,7 +46,7 @@
%td= article.origin
%td= article.unit
%td= article.unit_quantity
%td= article.net_price
%td= article.price
%td= article.tax
%td= article.deposit
%td= article.article_category.name if article.article_category
@ -60,7 +60,7 @@
%td{:style => highlight_new(unequal_attributes, :origin)}= form.text_field 'origin', :size => 5
%td{:style => highlight_new(unequal_attributes, :unit)}= form.text_field 'unit', :size => 5
%td{:style => highlight_new(unequal_attributes, :unit_quantity)}= form.text_field 'unit_quantity', :size => 5
%td{:style => highlight_new(unequal_attributes, :net_price)}= form.text_field 'net_price', :size => 5
%td{:style => highlight_new(unequal_attributes, :price)}= form.text_field 'price', :size => 5
%td{:style => highlight_new(unequal_attributes, :tax)}= form.text_field 'tax', :size => 4
%td{:style => highlight_new(unequal_attributes, :deposit)}= form.text_field 'deposit', :size => 4
%td= select 'article[]', 'article_category_id', ArticleCategory.find(:all).collect {|a| [ a.name, a.id ] }, { :include_blank => true }