Merge branch 'develop'

This commit is contained in:
Anand Doshi 2015-09-24 17:31:12 +05:30
commit 52efde31e7
7 changed files with 42 additions and 52 deletions

View File

@ -1,2 +1,2 @@
from __future__ import unicode_literals from __future__ import unicode_literals
__version__ = '6.3.1' __version__ = '6.3.2'

View File

@ -580,7 +580,7 @@
"is_submittable": 0, "is_submittable": 0,
"issingle": 0, "issingle": 0,
"istable": 0, "istable": 0,
"modified": "2015-09-15 12:29:34.435839", "modified": "2015-09-24 07:59:06.502058",
"modified_by": "Administrator", "modified_by": "Administrator",
"module": "Accounts", "module": "Accounts",
"name": "Tax Rule", "name": "Tax Rule",
@ -601,7 +601,7 @@
"print": 1, "print": 1,
"read": 1, "read": 1,
"report": 1, "report": 1,
"role": "Administrator", "role": "Accounts Manager",
"set_user_permissions": 0, "set_user_permissions": 0,
"share": 1, "share": 1,
"submit": 0, "submit": 0,

View File

@ -13,16 +13,6 @@ class TestTaxRule(unittest.TestCase):
def setUp(self): def setUp(self):
frappe.db.sql("delete from `tabTax Rule` where use_for_shopping_cart <> 1") frappe.db.sql("delete from `tabTax Rule` where use_for_shopping_cart <> 1")
def test_customer_group(self):
tax_rule = make_tax_rule(customer= "_Test Customer", customer_group= "_Test Customer Group 1",
sales_tax_template = "_Test Sales Taxes and Charges Template")
self.assertRaises(IncorrectCustomerGroup, tax_rule.save)
def test_supplier_type(self):
tax_rule = make_tax_rule(tax_type= "Purchase", supplier= "_Test Supplier", supplier_type= "_Test Supplier Type 1",
purchase_tax_template = "_Test Purchase Taxes and Charges Template")
self.assertRaises(IncorrectSupplierType, tax_rule.save)
def test_conflict(self): def test_conflict(self):
tax_rule1 = make_tax_rule(customer= "_Test Customer", tax_rule1 = make_tax_rule(customer= "_Test Customer",
sales_tax_template = "_Test Sales Taxes and Charges Template", priority = 1) sales_tax_template = "_Test Sales Taxes and Charges Template", priority = 1)
@ -138,4 +128,3 @@ def make_tax_rule(**args):
tax_rule.insert() tax_rule.insert()
return tax_rule return tax_rule

View File

@ -29,7 +29,7 @@ blogs.
""" """
app_icon = "icon-th" app_icon = "icon-th"
app_color = "#e74c3c" app_color = "#e74c3c"
app_version = "6.3.1" app_version = "6.3.2"
github_link = "https://github.com/frappe/erpnext" github_link = "https://github.com/frappe/erpnext"
error_report_email = "support@erpnext.com" error_report_email = "support@erpnext.com"

View File

@ -2,6 +2,11 @@ from __future__ import unicode_literals
import frappe import frappe
def execute(): def execute():
# remove missing lead
for customer in frappe.db.sql_list("""select name from `tabCustomer`
where ifnull(lead_name, '')!='' and not exists (select name from `tabLead` where name=`tabCustomer`.lead_name)"""):
frappe.db.set_value("Customer", customer, "lead_name", None)
# remove missing default taxes # remove missing default taxes
for customer in frappe.db.sql_list("""select name from `tabCustomer` for customer in frappe.db.sql_list("""select name from `tabCustomer`
where ifnull(default_taxes_and_charges, '')!='' and not exists ( where ifnull(default_taxes_and_charges, '')!='' and not exists (
@ -18,8 +23,3 @@ def execute():
c = frappe.get_doc("Supplier", supplier) c = frappe.get_doc("Supplier", supplier)
c.default_taxes_and_charges = None c.default_taxes_and_charges = None
c.save() c.save()
# remove missing lead
for customer in frappe.db.sql_list("""select name from `tabCustomer`
where ifnull(lead_name, '')!='' and not exists (select name from `tabLead` where name=`tabCustomer`.lead_name)"""):
frappe.db.set_value("Customer", customer, "lead_name", None)

View File

@ -5,6 +5,7 @@ def execute():
frappe.reload_doc("accounts", "doctype", "shipping_rule_country") frappe.reload_doc("accounts", "doctype", "shipping_rule_country")
frappe.reload_doctype("Price List") frappe.reload_doctype("Price List")
frappe.reload_doctype("Shipping Rule") frappe.reload_doctype("Shipping Rule")
frappe.reload_doctype("Shopping Cart Settings")
# for price list # for price list
countries = frappe.db.sql_list("select name from tabCountry") countries = frappe.db.sql_list("select name from tabCountry")

View File

@ -1,6 +1,6 @@
from setuptools import setup, find_packages from setuptools import setup, find_packages
version = "6.3.1" version = "6.3.2"
with open("requirements.txt", "r") as f: with open("requirements.txt", "r") as f:
install_requires = f.readlines() install_requires = f.readlines()