mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-04 05:58:27 +00:00
Merge branch 'master' of github.com:webnotes/erpnext into wsgi
Conflicts: accounts/doctype/purchase_invoice/purchase_invoice.py accounts/doctype/sales_invoice/sales_invoice.txt selling/doctype/lead/lead.txt selling/doctype/opportunity/opportunity.txt stock/doctype/warehouse/warehouse.py
This commit is contained in:
@@ -6,6 +6,7 @@ import webnotes
|
||||
|
||||
def execute():
|
||||
webnotes.reload_doc("selling", "doctype", "shopping_cart_price_list")
|
||||
webnotes.reload_doc("setup", "doctype", "item_price")
|
||||
|
||||
for t in [
|
||||
("Supplier Quotation", "price_list_name", "buying_price_list"),
|
||||
|
||||
0
patches/october_2013/__init__.py
Normal file
0
patches/october_2013/__init__.py
Normal file
13
patches/october_2013/fix_is_cancelled_in_sle.py
Normal file
13
patches/october_2013/fix_is_cancelled_in_sle.py
Normal file
@@ -0,0 +1,13 @@
|
||||
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd.
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
import webnotes
|
||||
|
||||
def execute():
|
||||
webnotes.conn.sql("""update `tabStock Ledger Entry` set is_cancelled = 'No'
|
||||
where ifnull(is_cancelled, '') = ''""")
|
||||
|
||||
webnotes.conn.sql("""update tabBin b set b.stock_uom =
|
||||
(select i.stock_uom from tabItem i where i.name = b.item_code)
|
||||
where b.creation>='2013-09-01'""")
|
||||
@@ -218,4 +218,6 @@ patch_list = [
|
||||
"execute:webnotes.bean('Style Settings').save() #2013-09-19",
|
||||
"execute:webnotes.conn.set_value('Accounts Settings', None, 'frozen_accounts_modifier', 'Accounts Manager') # 2013-09-24",
|
||||
"patches.september_2013.p04_unsubmit_serial_nos",
|
||||
"patches.september_2013.p05_fix_customer_in_pos",
|
||||
"patches.october_2013.fix_is_cancelled_in_sle",
|
||||
]
|
||||
22
patches/september_2013/p05_fix_customer_in_pos.py
Normal file
22
patches/september_2013/p05_fix_customer_in_pos.py
Normal file
@@ -0,0 +1,22 @@
|
||||
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd.
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
import webnotes
|
||||
def execute():
|
||||
si_list = webnotes.conn.sql("""select name, debit_to from `tabSales Invoice`
|
||||
where ifnull(is_pos, 1)=1 and docstatus=1 and modified > '2013-09-03'""", as_dict=1)
|
||||
|
||||
for si in si_list:
|
||||
if not webnotes.conn.get_value("GL Entry", {"voucher_type": "Sales Invoice",
|
||||
"voucher_no": si.name, "account": si.debit_to}):
|
||||
debit_to = webnotes.conn.sql("""select account from `tabGL Entry` gle
|
||||
where voucher_type='Sales Invoice' and voucher_no=%s
|
||||
and (select master_type from tabAccount where name=gle.account)='Customer'
|
||||
""", si.name)
|
||||
if debit_to:
|
||||
si_bean = webnotes.bean("Sales Invoice", si.name)
|
||||
si_bean.doc.debit_to = debit_to[0][0]
|
||||
si_bean.doc.customer = None
|
||||
si_bean.run_method("set_customer_defaults")
|
||||
si_bean.update_after_submit()
|
||||
Reference in New Issue
Block a user