commit
8c7b4549ed
@ -61,3 +61,4 @@ erpnext.patches.v4_0.update_custom_print_formats_for_renamed_fields
|
|||||||
erpnext.patches.v4_0.update_other_charges_in_custom_purchase_print_formats
|
erpnext.patches.v4_0.update_other_charges_in_custom_purchase_print_formats
|
||||||
erpnext.patches.v4_0.create_price_list_if_missing
|
erpnext.patches.v4_0.create_price_list_if_missing
|
||||||
execute:frappe.db.sql("update `tabItem` set end_of_life=null where end_of_life='0000-00-00'") #2014-06-16
|
execute:frappe.db.sql("update `tabItem` set end_of_life=null where end_of_life='0000-00-00'") #2014-06-16
|
||||||
|
erpnext.patches.v4_0.update_users_report_view_settings
|
||||||
|
|||||||
12
erpnext/patches/v4_0/update_users_report_view_settings.py
Normal file
12
erpnext/patches/v4_0/update_users_report_view_settings.py
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
|
||||||
|
# License: GNU General Public License v3. See license.txt
|
||||||
|
|
||||||
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
|
from frappe.model import update_users_report_view_settings
|
||||||
|
from erpnext.patches.v4_0.fields_to_be_renamed import rename_map
|
||||||
|
|
||||||
|
def execute():
|
||||||
|
for dt, field_list in rename_map.items():
|
||||||
|
for field in field_list:
|
||||||
|
update_users_report_view_settings(dt, field[0], field[1])
|
||||||
@ -102,7 +102,6 @@ class SalesOrder(SellingController):
|
|||||||
self.validate_warehouse()
|
self.validate_warehouse()
|
||||||
|
|
||||||
from erpnext.stock.doctype.packed_item.packed_item import make_packing_list
|
from erpnext.stock.doctype.packed_item.packed_item import make_packing_list
|
||||||
|
|
||||||
make_packing_list(self,'sales_order_details')
|
make_packing_list(self,'sales_order_details')
|
||||||
|
|
||||||
self.validate_with_previous_doc()
|
self.validate_with_previous_doc()
|
||||||
|
|||||||
@ -3,15 +3,15 @@
|
|||||||
|
|
||||||
$.extend(cur_frm.cscript, {
|
$.extend(cur_frm.cscript, {
|
||||||
message: function () {
|
message: function () {
|
||||||
var total_words = this.frm.doc.message.length;
|
var total_characters = this.frm.doc.message.length;
|
||||||
var total_msg = 1;
|
var total_msg = 1;
|
||||||
|
|
||||||
if (total_words > 160) {
|
if (total_characters > 160) {
|
||||||
total_msg = cint(total_words / 160);
|
total_msg = cint(total_characters / 160);
|
||||||
total_msg = (total_words % 160 == 0 ? total_msg : total_msg + 1);
|
total_msg = (total_characters % 160 == 0 ? total_msg : total_msg + 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
this.frm.set_value("total_words", total_words);
|
this.frm.set_value("total_characters", total_characters);
|
||||||
this.frm.set_value("total_messages", this.frm.doc.message ? total_msg : 0);
|
this.frm.set_value("total_messages", this.frm.doc.message ? total_msg : 0);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@ -82,7 +82,7 @@
|
|||||||
"reqd": 1
|
"reqd": 1
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"fieldname": "total_words",
|
"fieldname": "total_characters",
|
||||||
"fieldtype": "Int",
|
"fieldtype": "Int",
|
||||||
"label": "Total Characters",
|
"label": "Total Characters",
|
||||||
"permlevel": 0,
|
"permlevel": 0,
|
||||||
@ -109,7 +109,7 @@
|
|||||||
"idx": 1,
|
"idx": 1,
|
||||||
"in_create": 0,
|
"in_create": 0,
|
||||||
"issingle": 1,
|
"issingle": 1,
|
||||||
"modified": "2014-05-09 02:17:41.375945",
|
"modified": "2014-06-18 08:59:51.755566",
|
||||||
"modified_by": "Administrator",
|
"modified_by": "Administrator",
|
||||||
"module": "Selling",
|
"module": "Selling",
|
||||||
"name": "SMS Center",
|
"name": "SMS Center",
|
||||||
|
|||||||
@ -61,6 +61,9 @@ def update_packing_list_item(obj, packing_item_code, qty, warehouse, line, packi
|
|||||||
|
|
||||||
def make_packing_list(obj, item_table_fieldname):
|
def make_packing_list(obj, item_table_fieldname):
|
||||||
"""make packing list for sales bom item"""
|
"""make packing list for sales bom item"""
|
||||||
|
|
||||||
|
if obj._action == "update_after_submit": return
|
||||||
|
|
||||||
packing_list_idx = 0
|
packing_list_idx = 0
|
||||||
parent_items = []
|
parent_items = []
|
||||||
for d in obj.get(item_table_fieldname):
|
for d in obj.get(item_table_fieldname):
|
||||||
@ -92,4 +95,3 @@ def cleanup_packing_list(obj, parent_items):
|
|||||||
for d in packing_details:
|
for d in packing_details:
|
||||||
if d not in delete_list:
|
if d not in delete_list:
|
||||||
obj.append("packing_details", d)
|
obj.append("packing_details", d)
|
||||||
|
|
||||||
@ -221,7 +221,7 @@ class StockEntry(StockController):
|
|||||||
if not d.bom_no:
|
if not d.bom_no:
|
||||||
if not flt(d.incoming_rate) or d.s_warehouse or self.purpose == "Sales Return":
|
if not flt(d.incoming_rate) or d.s_warehouse or self.purpose == "Sales Return":
|
||||||
incoming_rate = self.get_incoming_rate(args)
|
incoming_rate = self.get_incoming_rate(args)
|
||||||
if incoming_rate:
|
if flt(incoming_rate) > 0:
|
||||||
d.incoming_rate = incoming_rate
|
d.incoming_rate = incoming_rate
|
||||||
|
|
||||||
d.amount = flt(d.transfer_qty) * flt(d.incoming_rate)
|
d.amount = flt(d.transfer_qty) * flt(d.incoming_rate)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user