From b9f708663cb46091ad5974f34a381f0674d770a3 Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Mon, 31 Oct 2016 16:52:17 +0530 Subject: [PATCH 1/5] Update item.py --- erpnext/stock/doctype/item/item.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/stock/doctype/item/item.py b/erpnext/stock/doctype/item/item.py index e9d4cb3fef..ced6a6431f 100644 --- a/erpnext/stock/doctype/item/item.py +++ b/erpnext/stock/doctype/item/item.py @@ -567,7 +567,7 @@ class Item(WebsiteGenerator): existing_allow_negative_stock = frappe.db.get_value("Stock Settings", None, "allow_negative_stock") frappe.db.set_value("Stock Settings", None, "allow_negative_stock", 1) - for warehouse in frappe.db.sql("select name from `tabWarehouse` where is_group = 0"): + for warehouse in frappe.db.sql("select warehouse from `tabBin` where item_code=%s", new_name): repost_stock(new_name, warehouse[0]) frappe.db.set_value("Stock Settings", None, "allow_negative_stock", existing_allow_negative_stock) From c61892501c7cf9dadcf9959b9e36701ac7b10444 Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Tue, 1 Nov 2016 11:45:09 +0530 Subject: [PATCH 2/5] [fix] Report GLE for Purchase Invoice with Update Stock option --- erpnext/patches.txt | 2 +- .../{v7_1 => v7_0}/repost_gle_for_pi_with_update_stock.py | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) rename erpnext/patches/{v7_1 => v7_0}/repost_gle_for_pi_with_update_stock.py (74%) diff --git a/erpnext/patches.txt b/erpnext/patches.txt index d694ef4e8e..0c75d1553e 100644 --- a/erpnext/patches.txt +++ b/erpnext/patches.txt @@ -342,4 +342,4 @@ erpnext.patches.v7_0.repost_bin_qty_and_item_projected_qty erpnext.patches.v7_1.set_prefered_contact_email execute:frappe.db.sql("update `tabSingles` set value = 1 where field = 'unlink_payment_on_cancellation_of_invoice' and doctype = 'Accounts Settings'") execute:frappe.db.sql("update `tabStock Entry` set total_amount = null where purpose in('Repack', 'Manufacture')") -erpnext.patches.v7_1.repost_gle_for_pi_with_update_stock \ No newline at end of file +erpnext.patches.v7_0.repost_gle_for_pi_with_update_stock #2016-11-01 \ No newline at end of file diff --git a/erpnext/patches/v7_1/repost_gle_for_pi_with_update_stock.py b/erpnext/patches/v7_0/repost_gle_for_pi_with_update_stock.py similarity index 74% rename from erpnext/patches/v7_1/repost_gle_for_pi_with_update_stock.py rename to erpnext/patches/v7_0/repost_gle_for_pi_with_update_stock.py index 2355d539ae..2883a8adc3 100644 --- a/erpnext/patches/v7_1/repost_gle_for_pi_with_update_stock.py +++ b/erpnext/patches/v7_0/repost_gle_for_pi_with_update_stock.py @@ -11,6 +11,10 @@ def execute(): for pi in frappe.db.sql("""select name from `tabPurchase Invoice` where update_stock=1 and docstatus=1 order by posting_date asc""", as_dict=1): + + frappe.db.sql("""delete from `tabGL Entry` + where voucher_type = 'Purchase Invoice' and voucher_no = %s""", pi.name) + pi_doc = frappe.get_doc("Purchase Invoice", pi.name) - pi_doc.make_gl_entries() + pi_doc.make_gl_entries(repost_future_gle=False) frappe.db.commit() \ No newline at end of file From 22161566ed17b2a8a07b827838d25b432a6aa898 Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Tue, 1 Nov 2016 12:36:03 +0530 Subject: [PATCH 3/5] Update index.md --- erpnext/docs/user/videos/index.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/docs/user/videos/index.md b/erpnext/docs/user/videos/index.md index 071dedbd03..9a82db5ee0 100644 --- a/erpnext/docs/user/videos/index.md +++ b/erpnext/docs/user/videos/index.md @@ -18,7 +18,7 @@ ---

- Conference Vidoes + Conference Videos

From 53bb687009d8bc3ccd2b02c291cf6d6dc263e1ec Mon Sep 17 00:00:00 2001 From: Rohit Waghchaure Date: Tue, 1 Nov 2016 13:21:43 +0530 Subject: [PATCH 4/5] hotfix issues --- erpnext/accounts/doctype/journal_entry/journal_entry.py | 3 ++- erpnext/accounts/page/pos/pos.js | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/erpnext/accounts/doctype/journal_entry/journal_entry.py b/erpnext/accounts/doctype/journal_entry/journal_entry.py index 083ba6ff61..145ed81564 100644 --- a/erpnext/accounts/doctype/journal_entry/journal_entry.py +++ b/erpnext/accounts/doctype/journal_entry/journal_entry.py @@ -763,7 +763,8 @@ def get_party_account_and_balance(company, party_type, party): return { "account": account, "balance": account_balance, - "party_balance": party_balance + "party_balance": party_balance, + "account_currency": frappe.db.get_value("Account", account, "account_currency") } @frappe.whitelist() diff --git a/erpnext/accounts/page/pos/pos.js b/erpnext/accounts/page/pos/pos.js index f43a43602b..4c13fe3720 100644 --- a/erpnext/accounts/page/pos/pos.js +++ b/erpnext/accounts/page/pos/pos.js @@ -392,7 +392,7 @@ erpnext.pos.PointOfSale = erpnext.taxes_and_totals.extend({ if(index < 30){ $(frappe.render_template("pos_item", { item_code: obj.name, - item_price: format_currency(obj.price_list_rate, obj.currency), + item_price: format_currency(obj.price_list_rate, me.frm.doc.currency), item_name: obj.name===obj.item_name ? "" : obj.item_name, item_image: obj.image ? "url('" + obj.image + "')" : null, color: frappe.get_palette(obj.item_name), From c538a55a5aa6737c1d3b99555c42b26fb4d5b8a1 Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Tue, 1 Nov 2016 15:35:53 +0600 Subject: [PATCH 5/5] bumped to version 7.1.4 --- erpnext/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/__init__.py b/erpnext/__init__.py index 4c87187bc4..58b7955490 100644 --- a/erpnext/__init__.py +++ b/erpnext/__init__.py @@ -2,7 +2,7 @@ from __future__ import unicode_literals import frappe -__version__ = '7.1.3' +__version__ = '7.1.4' def get_default_company(user=None): '''Get default company for user'''