mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-08 15:51:19 +00:00
refactor: revert indentation
This commit is contained in:
@@ -57,12 +57,12 @@ def make_sl_entries(sl_entries, allow_negative_stock=False, via_landed_cost_vouc
|
|||||||
"""Create SL entries from SL entry dicts
|
"""Create SL entries from SL entry dicts
|
||||||
|
|
||||||
args:
|
args:
|
||||||
- allow_negative_stock: disable negative stock valiations if true
|
- allow_negative_stock: disable negative stock valiations if true
|
||||||
- via_landed_cost_voucher: landed cost voucher cancels and reposts
|
- via_landed_cost_voucher: landed cost voucher cancels and reposts
|
||||||
entries of purchase document. This flag is used to identify if
|
entries of purchase document. This flag is used to identify if
|
||||||
cancellation and repost is happening via landed cost voucher, in
|
cancellation and repost is happening via landed cost voucher, in
|
||||||
such cases certain validations need to be ignored (like negative
|
such cases certain validations need to be ignored (like negative
|
||||||
stock)
|
stock)
|
||||||
"""
|
"""
|
||||||
from erpnext.controllers.stock_controller import future_sle_exists
|
from erpnext.controllers.stock_controller import future_sle_exists
|
||||||
|
|
||||||
@@ -527,12 +527,12 @@ class update_entries_after:
|
|||||||
|
|
||||||
:param args: args as dict
|
:param args: args as dict
|
||||||
|
|
||||||
args = {
|
args = {
|
||||||
"item_code": "ABC",
|
"item_code": "ABC",
|
||||||
"warehouse": "XYZ",
|
"warehouse": "XYZ",
|
||||||
"posting_date": "2012-12-12",
|
"posting_date": "2012-12-12",
|
||||||
"posting_time": "12:00"
|
"posting_time": "12:00"
|
||||||
}
|
}
|
||||||
"""
|
"""
|
||||||
|
|
||||||
def __init__(
|
def __init__(
|
||||||
@@ -603,15 +603,15 @@ class update_entries_after:
|
|||||||
:Data Structure:
|
:Data Structure:
|
||||||
|
|
||||||
self.data = {
|
self.data = {
|
||||||
warehouse1: {
|
warehouse1: {
|
||||||
'previus_sle': {},
|
'previus_sle': {},
|
||||||
'qty_after_transaction': 10,
|
'qty_after_transaction': 10,
|
||||||
'valuation_rate': 100,
|
'valuation_rate': 100,
|
||||||
'stock_value': 1000,
|
'stock_value': 1000,
|
||||||
'prev_stock_value': 1000,
|
'prev_stock_value': 1000,
|
||||||
'stock_queue': '[[10, 100]]',
|
'stock_queue': '[[10, 100]]',
|
||||||
'stock_value_difference': 1000
|
'stock_value_difference': 1000
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
"""
|
"""
|
||||||
@@ -1656,11 +1656,11 @@ def get_previous_sle(args, for_update=False, extra_cond=None):
|
|||||||
is called from various transaction like stock entry, reco etc
|
is called from various transaction like stock entry, reco etc
|
||||||
|
|
||||||
args = {
|
args = {
|
||||||
"item_code": "ABC" or ["ABC", "XYZ"],
|
"item_code": "ABC",
|
||||||
"warehouse": "XYZ" or ["XYZ", "ABC"],
|
"warehouse": "XYZ",
|
||||||
"posting_date": "2012-12-12",
|
"posting_date": "2012-12-12",
|
||||||
"posting_time": "12:00",
|
"posting_time": "12:00",
|
||||||
"sle": "name of reference Stock Ledger Entry"
|
"sle": "name of reference Stock Ledger Entry"
|
||||||
}
|
}
|
||||||
"""
|
"""
|
||||||
args["name"] = args.get("sle", None) or ""
|
args["name"] = args.get("sle", None) or ""
|
||||||
|
|||||||
Reference in New Issue
Block a user