Merge branch 'develop'
This commit is contained in:
commit
b02788b915
@ -1 +1 @@
|
||||
__version__ = '4.15.3'
|
||||
__version__ = '4.15.4'
|
||||
|
@ -492,7 +492,7 @@ erpnext.POS = Class.extend({
|
||||
});
|
||||
|
||||
me.refresh_delete_btn();
|
||||
if(me.frm.doc[this.party]) {
|
||||
if(me.frm.doc[this.party.toLowerCase()]) {
|
||||
this.barcode.$input.focus();
|
||||
} else {
|
||||
this.party_field.$input.focus();
|
||||
|
@ -119,6 +119,10 @@ class AccountsController(TransactionBase):
|
||||
item.get(fieldname) is None and value is not None:
|
||||
item.set(fieldname, value)
|
||||
|
||||
if fieldname == "cost_center" and item.meta.get_field("cost_center") \
|
||||
and not item.get("cost_center") and value is not None:
|
||||
item.set(fieldname, value)
|
||||
|
||||
if ret.get("pricing_rule"):
|
||||
for field in ["base_price_list_rate", "price_list_rate",
|
||||
"discount_percentage", "base_rate", "rate"]:
|
||||
|
@ -4,7 +4,7 @@ app_publisher = "Web Notes Technologies Pvt. Ltd. and Contributors"
|
||||
app_description = "Open Source Enterprise Resource Planning for Small and Midsized Organizations"
|
||||
app_icon = "icon-th"
|
||||
app_color = "#e74c3c"
|
||||
app_version = "4.15.3"
|
||||
app_version = "4.15.4"
|
||||
|
||||
error_report_email = "support@erpnext.com"
|
||||
|
||||
|
@ -57,6 +57,9 @@ class BOM(Document):
|
||||
last_purchase_rate, is_manufactured_item
|
||||
from `tabItem` where name=%s""", item_code, as_dict = 1)
|
||||
|
||||
if not item:
|
||||
frappe.throw(_("Item: {0} does not exist in the system").format(item_code))
|
||||
|
||||
return item
|
||||
|
||||
def validate_rm_item(self, item):
|
||||
|
@ -108,6 +108,7 @@ erpnext.StockAnalytics = erpnext.StockGridReport.extend({
|
||||
// otherwise, only reset values
|
||||
$.each(this.data, function(i, d) {
|
||||
me.reset_item_values(d);
|
||||
d["closing_qty_value"] = 0;
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -403,10 +403,14 @@ erpnext.TransactionController = erpnext.stock.StockController.extend({
|
||||
|
||||
_set_values_for_item_list: function(children) {
|
||||
var me = this;
|
||||
var price_list_rate_changed = false;
|
||||
$.each(children, function(i, d) {
|
||||
var existing_pricing_rule = frappe.model.get_value(d.doctype, d.name, "pricing_rule");
|
||||
$.each(d, function(k, v) {
|
||||
if (["doctype", "name"].indexOf(k)===-1) {
|
||||
if(k=="price_list_rate") {
|
||||
if(flt(v) != flt(d.price_list_rate)) price_list_rate_changed = true;
|
||||
}
|
||||
frappe.model.set_value(d.doctype, d.name, k, v);
|
||||
}
|
||||
});
|
||||
@ -414,6 +418,8 @@ erpnext.TransactionController = erpnext.stock.StockController.extend({
|
||||
if(!me.frm.doc.ignore_pricing_rule && existing_pricing_rule && !d.pricing_rule) {
|
||||
me.apply_price_list(frappe.get_doc(d.doctype, d.name));
|
||||
}
|
||||
|
||||
if(!price_list_rate_changed) me.calculate_taxes_and_totals();
|
||||
});
|
||||
},
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user