replace @shop and shop_details with current_shop

This commit is contained in:
Zin Moe
2020-01-13 17:34:48 +06:30
parent f99defc459
commit a3edbb07fd
48 changed files with 72 additions and 72 deletions

View File

@@ -90,8 +90,8 @@ class Inventory::InventoryDefinitionsController < BaseInventoryController
format.json { head :no_content }
end
StockJournal.delete_stock_journal(inventory.item_code,@shop)
StockCheckItem.delete_stock_check_item(inventory.item_code,@shop)
StockJournal.delete_stock_journal(inventory.item_code,current_shop)
StockCheckItem.delete_stock_check_item(inventory.item_code,current_shop)
if !inventory.nil?
inventory.destroy
flash[:message] = 'Inventory was successfully destroyed.'