added 'order' fields to sections, categories and sub_categories. - moved backoffice migrations to front-api
This commit is contained in:
16
front-api/db/migrate/20150314033113_create_suppliers.rb
Normal file
16
front-api/db/migrate/20150314033113_create_suppliers.rb
Normal file
@@ -0,0 +1,16 @@
|
||||
class CreateSuppliers < ActiveRecord::Migration
|
||||
def change
|
||||
create_table :suppliers do |t|
|
||||
t.string :name
|
||||
t.string :address
|
||||
t.string :postal_code
|
||||
t.string :town
|
||||
t.string :phone
|
||||
t.string :contact_person
|
||||
t.string :email
|
||||
t.text :note
|
||||
|
||||
t.timestamps null: false
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -0,0 +1,5 @@
|
||||
class AddSupplierToItem < ActiveRecord::Migration
|
||||
def change
|
||||
add_column :items, :supplier_id, :integer
|
||||
end
|
||||
end
|
||||
@@ -0,0 +1,5 @@
|
||||
class AddOrderToSections < ActiveRecord::Migration
|
||||
def change
|
||||
add_column :sections, :order, :integer
|
||||
end
|
||||
end
|
||||
@@ -0,0 +1,5 @@
|
||||
class AddOrderToCategories < ActiveRecord::Migration
|
||||
def change
|
||||
add_column :categories, :order, :integer
|
||||
end
|
||||
end
|
||||
@@ -0,0 +1,5 @@
|
||||
class AddOrderToSubcategories < ActiveRecord::Migration
|
||||
def change
|
||||
add_column :sub_categories, :order, :integer
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user