created items and configured back office ui a bit

This commit is contained in:
Senad Uka
2015-01-18 10:24:15 +01:00
parent 6d1ac88a7f
commit d09bc71aae
32 changed files with 368 additions and 7 deletions

View File

@@ -1,4 +0,0 @@
class Category < ActiveRecord::Base
has_many :sub_categories
belongs_to :section
end

4
app/models/category.rb Normal file
View File

@@ -0,0 +1,4 @@
class Category < ActiveRecord::Base
has_many :sub_categories
belongs_to :section
end

4
app/models/item.rb Normal file
View File

@@ -0,0 +1,4 @@
class Item < ActiveRecord::Base
belongs_to :unit
has_many :multi_media_descriptions
end

3
app/models/media_type.rb Normal file
View File

@@ -0,0 +1,3 @@
class MediaType < ActiveRecord::Base
has_many :multi_media_descriptions
end

View File

@@ -0,0 +1,5 @@
class MultiMediaDescription < ActiveRecord::Base
belongs_to :item
belongs_to :media_type
end

View File

@@ -1,3 +1,3 @@
class Section < ActiveRecord::Base
has_many :categories
has_many :categories
end

2
app/models/unit.rb Normal file
View File

@@ -0,0 +1,2 @@
class Unit < ActiveRecord::Base
end