mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-19 21:19:19 +00:00
Merge branch 'version-13-beta-pre-release' into version-13-beta
This commit is contained in:
@@ -5,7 +5,7 @@ import frappe
|
|||||||
from erpnext.hooks import regional_overrides
|
from erpnext.hooks import regional_overrides
|
||||||
from frappe.utils import getdate
|
from frappe.utils import getdate
|
||||||
|
|
||||||
__version__ = '13.0.0-beta.8'
|
__version__ = '13.0.0-beta.9'
|
||||||
|
|
||||||
def get_default_company(user=None):
|
def get_default_company(user=None):
|
||||||
'''Get default company for user'''
|
'''Get default company for user'''
|
||||||
|
|||||||
@@ -88,7 +88,7 @@ def get_party_details(address_name):
|
|||||||
gstin = address.get('gstin')
|
gstin = address.get('gstin')
|
||||||
|
|
||||||
gstin_details = get_gstin_details(gstin)
|
gstin_details = get_gstin_details(gstin)
|
||||||
legal_name = gstin_details.get('LegalName')
|
legal_name = gstin_details.get('LegalName') or gstin_details.get('TradeName')
|
||||||
location = gstin_details.get('AddrLoc') or address.get('city')
|
location = gstin_details.get('AddrLoc') or address.get('city')
|
||||||
state_code = gstin_details.get('StateCode')
|
state_code = gstin_details.get('StateCode')
|
||||||
pincode = gstin_details.get('AddrPncd')
|
pincode = gstin_details.get('AddrPncd')
|
||||||
|
|||||||
@@ -512,7 +512,7 @@ class StockEntry(StockController):
|
|||||||
bom_items = self.get_bom_raw_materials(finished_item_qty)
|
bom_items = self.get_bom_raw_materials(finished_item_qty)
|
||||||
outgoing_items_cost = sum([flt(row.qty)*flt(row.rate) for row in bom_items.values()])
|
outgoing_items_cost = sum([flt(row.qty)*flt(row.rate) for row in bom_items.values()])
|
||||||
|
|
||||||
return flt(outgoing_items_cost - scrap_items_cost)
|
return flt((outgoing_items_cost - scrap_items_cost) / finished_item_qty)
|
||||||
|
|
||||||
def distribute_additional_costs(self):
|
def distribute_additional_costs(self):
|
||||||
# If no incoming items, set additional costs blank
|
# If no incoming items, set additional costs blank
|
||||||
|
|||||||
Reference in New Issue
Block a user