delete shop scope in model

This commit is contained in:
Zin Moe
2020-01-13 18:41:37 +06:30
parent a3edbb07fd
commit 270c2a821e
20 changed files with 25 additions and 29 deletions

View File

@@ -19,7 +19,7 @@ class Inventory::StockChecksController < BaseInventoryController
item_list = JSON.parse(params[:stock_item])
reason = params[:reason]
check = StockCheck.new
@check = check.create(current_user, reason, item_list,current_shop)
@check = check.create(current_user, reason, item_list)
end
def show
@@ -33,7 +33,7 @@ class Inventory::StockChecksController < BaseInventoryController
check = params[:data]
stockCheck = StockCheck.find_by_id(check)
stockCheck.stock_check_items.each do |item|
StockJournal.from_stock_check(item,current_shop)
StockJournal.from_stock_check(item)
end
end