fix: Sider and Server side test
- args passed to wrong function - missing space around '='
This commit is contained in:
parent
8951a5c267
commit
24a35c69c0
@ -13,7 +13,7 @@ from erpnext.stock.doctype.serial_no.serial_no import get_serial_nos
|
||||
|
||||
Filters = frappe._dict
|
||||
|
||||
def execute(filters: Filters =None) -> Tuple:
|
||||
def execute(filters: Filters = None) -> Tuple:
|
||||
to_date = filters["to_date"]
|
||||
columns = get_columns(filters)
|
||||
|
||||
@ -216,7 +216,7 @@ def setup_ageing_columns(filters: Filters, range_columns: List):
|
||||
fieldname = 'range' + str(i+1)
|
||||
add_column(range_columns, label=f"Age ({label})",fieldname=fieldname)
|
||||
|
||||
def add_column(range_columns: List, label:str, fieldname: str, fieldtype: str ='Float', width: int =140):
|
||||
def add_column(range_columns: List, label:str, fieldname: str, fieldtype: str = 'Float', width: int = 140):
|
||||
range_columns.append(dict(
|
||||
label=label,
|
||||
fieldname=fieldname,
|
||||
@ -228,7 +228,7 @@ def add_column(range_columns: List, label:str, fieldname: str, fieldtype: str ='
|
||||
class FIFOSlots:
|
||||
"Returns FIFO computed slots of inwarded stock as per date."
|
||||
|
||||
def __init__(self, filters: Dict =None , sle: List =None):
|
||||
def __init__(self, filters: Dict = None , sle: List = None):
|
||||
self.item_details = {}
|
||||
self.transferred_item_details = {}
|
||||
self.serial_no_batch_purchase_details = {}
|
||||
@ -245,7 +245,7 @@ class FIFOSlots:
|
||||
consumed/updated and maintained via FIFO. **
|
||||
}
|
||||
"""
|
||||
if self.sle == None:
|
||||
if self.sle is None:
|
||||
self.sle = self.__get_stock_ledger_entries()
|
||||
|
||||
for d in self.sle:
|
||||
@ -358,7 +358,8 @@ class FIFOSlots:
|
||||
posting_date <= %(to_date)s and
|
||||
is_cancelled != 1
|
||||
{sle_conditions}
|
||||
order by posting_date, posting_time, sle.creation, actual_qty""" #nosec
|
||||
order by posting_date, posting_time, sle.creation, actual_qty
|
||||
""" #nosec
|
||||
.format(
|
||||
item_conditions=self.__get_item_conditions(),
|
||||
sle_conditions=self.__get_sle_conditions()
|
||||
|
@ -33,7 +33,7 @@ def execute(filters=None):
|
||||
|
||||
if filters.get('show_stock_ageing_data'):
|
||||
filters['show_warehouse_wise_stock'] = True
|
||||
item_wise_fifo_queue = FIFOSlots().generate(filters, sle)
|
||||
item_wise_fifo_queue = FIFOSlots(filters, sle).generate()
|
||||
|
||||
# if no stock ledger entry found return
|
||||
if not sle:
|
||||
|
@ -33,7 +33,7 @@ def execute(filters=None):
|
||||
item_map = get_item_details(items, sle, filters)
|
||||
iwb_map = get_item_warehouse_map(filters, sle)
|
||||
warehouse_list = get_warehouse_list(filters)
|
||||
item_ageing = FIFOSlots().generate(filters)
|
||||
item_ageing = FIFOSlots(filters).generate()
|
||||
data = []
|
||||
item_balance = {}
|
||||
item_value = {}
|
||||
|
Loading…
Reference in New Issue
Block a user