Introduced StockTaking. TODO: Dry up the stockit/stock_takings/deliveries controllers/views!

This commit is contained in:
Benjamin Meichsner 2009-02-12 18:32:20 +01:00
parent 2bb4cdb9d6
commit 951d19db6a
30 changed files with 436 additions and 55 deletions

View file

@ -144,10 +144,17 @@ class RoadToVersionThree < ActiveRecord::Migration
# t.datetime :created_at
# end
# == User
# Ativate all Users for notification on upcoming tasks
User.all.each { |u| u.settings['notify.upcoming_tasks'] = 1 }
# == StockTaking
create_table :stock_takings do |t|
t.date :date
t.text :note
t.datetime :created_at
end
add_column :stock_changes, :stock_taking_id, :integer
# # == User
# # Ativate all Users for notification on upcoming tasks
# User.all.each { |u| u.settings['notify.upcoming_tasks'] = 1 }
end
def self.down

View file

@ -9,7 +9,7 @@
#
# It's strongly recommended to check this file into your version control system.
ActiveRecord::Schema.define(:version => 20090120184410) do
ActiveRecord::Schema.define(:version => 20090119155930) do
create_table "article_categories", :force => true do |t|
t.string "name", :default => "", :null => false
@ -218,6 +218,13 @@ ActiveRecord::Schema.define(:version => 20090120184410) do
t.datetime "created_at"
end
create_table "stock_takings", :force => true do |t|
t.date "date"
t.text "note"
t.integer "created_by"
t.datetime "created_at"
end
create_table "suppliers", :force => true do |t|
t.string "name", :default => "", :null => false
t.string "address", :default => "", :null => false