Merge pull request #13329 from shreyashah115/travis-fix

[Fix] Travis
This commit is contained in:
Achilles Rasquinha 2018-03-19 19:10:21 +05:30 committed by GitHub
commit 60da37b502
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 8 additions and 7 deletions

View File

@ -330,7 +330,7 @@ class SellingController(StockController):
self.make_sl_entries(sl_entries)
def set_po_nos(self):
if self.doctype in ("Delivery Note", "Sales Invoice"):
if self.doctype in ("Delivery Note", "Sales Invoice") and hasattr(self, "items"):
ref_fieldname = "against_sales_order" if self.doctype == "Delivery Note" else "sales_order"
sales_orders = list(set([d.get(ref_fieldname) for d in self.items if d.get(ref_fieldname)]))
if sales_orders:

View File

@ -245,5 +245,5 @@ def get_child_assessment_groups(assessment_group):
assessment_groups = [d.get("value") for d in get_children("Assessment Group",
assessment_group) if d.get("value") and not d.get("expandable")]
else:
assessment_groups = [args.assessment_group]
assessment_groups = [assessment_group]
return assessment_groups

View File

@ -1,8 +1,9 @@
import frappe
def execute():
frappe.db.sql("""
UPDATE `tabData Migration Connector`
SET hostname = 'https://hubmarket.org'
WHERE connector_name = 'Hub Connector'
""")
if frappe.db.table_exists("Data Migration Connector"):
frappe.db.sql("""
UPDATE `tabData Migration Connector`
SET hostname = 'https://hubmarket.org'
WHERE connector_name = 'Hub Connector'
""")