final db structure

This commit is contained in:
Min Zeya Phyo
2017-04-04 00:15:41 +06:30
parent 95454b4f0f
commit 2c1ac3191c
28 changed files with 209 additions and 3 deletions

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

@@ -0,0 +1,2 @@
class Lookup < ApplicationRecord
end

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

@@ -0,0 +1,4 @@
class Sale < ApplicationRecord
belongs_to :cashier
belongs_to :customer
end

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

@@ -0,0 +1,2 @@
class SaleAudit < ApplicationRecord
end

View File

@@ -0,0 +1,3 @@
class SaleDiscount < ApplicationRecord
belongs_to :sale
end

View File

@@ -0,0 +1,3 @@
class SaleDiscountItem < ApplicationRecord
belongs_to :sale
end

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

@@ -0,0 +1,3 @@
class SaleItem < ApplicationRecord
belongs_to :sale
end

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

@@ -0,0 +1,4 @@
class SaleOrder < ApplicationRecord
belongs_to :sale
belongs_to :order
end

View File

@@ -0,0 +1,3 @@
class SalePayment < ApplicationRecord
belongs_to :sale
end

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

@@ -0,0 +1,3 @@
class SaleTax < ApplicationRecord
belongs_to :sale
end