commission in sale edit

This commit is contained in:
Zin Lin Phyo
2017-08-25 13:44:22 +06:30
parent 283c59c5dc
commit b4eb27b8a9
16 changed files with 417 additions and 422 deletions

View File

@@ -1,12 +0,0 @@
class CreateProductCommissions < ActiveRecord::Migration[5.1]
def change
create_table :product_commissions do |t|
t.string :product_code
t.integer :commission_id
t.integer :qty
t.string :sale_id
t.string :sale_item_id
t.timestamps
end
end
end

View File

@@ -0,0 +1,16 @@
class CreateProductCommissions < ActiveRecord::Migration[5.1]
# rake db:migrate:down VERSION=20170823034141
def change
create_table :product_commissions do |t|
t.string :product_id
t.integer :commission_id
t.integer :commissioner_id
t.decimal :qty, :precision => 10, :scale => 2, :default => 0.00
t.string :sale_id
t.string :sale_item_id
t.decimal :price, :precision => 10, :scale => 2, :default => 0.00
t.decimal :amount, :precision => 10, :scale => 2, :default => 0.00
t.timestamps
end
end
end