Merge pull request #13332 from achillesrasquinha/fixes
Check Set Sales Target Item exists in User Slides
This commit is contained in:
commit
b714643ca2
@ -12,7 +12,10 @@ def get_slide_settings():
|
|||||||
currency = defaults.get("currency") or ''
|
currency = defaults.get("currency") or ''
|
||||||
|
|
||||||
doc = frappe.get_doc("Setup Progress")
|
doc = frappe.get_doc("Setup Progress")
|
||||||
item = [d for d in doc.get("actions") if d.action_name == "Set Sales Target"][0]
|
item = [d for d in doc.get("actions") if d.action_name == "Set Sales Target"]
|
||||||
|
|
||||||
|
if len(item):
|
||||||
|
item = item[0]
|
||||||
if not item.action_document:
|
if not item.action_document:
|
||||||
item.action_document = company
|
item.action_document = company
|
||||||
doc.save()
|
doc.save()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user