Merge branch 'develop' into dialog-cleanup
This commit is contained in:
commit
fd2b7d3c1d
@ -733,3 +733,4 @@ erpnext.patches.v13_0.print_uom_after_quantity_patch
|
||||
erpnext.patches.v13_0.set_payment_channel_in_payment_gateway_account
|
||||
erpnext.patches.v13_0.create_healthcare_custom_fields_in_stock_entry_detail
|
||||
erpnext.patches.v13_0.update_reason_for_resignation_in_employee
|
||||
execute:frappe.delete_doc("Report", "Quoted Item Comparison")
|
@ -288,7 +288,6 @@ def update_included_uom_in_report(columns, result, include_uom, conversion_facto
|
||||
return
|
||||
|
||||
convertible_cols = {}
|
||||
|
||||
is_dict_obj = False
|
||||
if isinstance(result[0], dict):
|
||||
is_dict_obj = True
|
||||
@ -310,13 +309,13 @@ def update_included_uom_in_report(columns, result, include_uom, conversion_facto
|
||||
for row_idx, row in enumerate(result):
|
||||
data = row.items() if is_dict_obj else enumerate(row)
|
||||
for key, value in data:
|
||||
if not key in convertible_columns or not conversion_factors[row_idx]:
|
||||
if key not in convertible_columns or not conversion_factors[row_idx-1]:
|
||||
continue
|
||||
|
||||
if convertible_columns.get(key) == 'rate':
|
||||
new_value = flt(value) * conversion_factors[row_idx]
|
||||
new_value = flt(value) * conversion_factors[row_idx-1]
|
||||
else:
|
||||
new_value = flt(value) / conversion_factors[row_idx]
|
||||
new_value = flt(value) / conversion_factors[row_idx-1]
|
||||
|
||||
if not is_dict_obj:
|
||||
row.insert(key+1, new_value)
|
||||
|
Loading…
Reference in New Issue
Block a user