brotherton-erpnext/erpnext/projects/web_form/tasks/tasks.py

10 lines
384 B
Python
Raw Normal View History

2016-06-24 10:46:07 +00:00
from __future__ import unicode_literals
import frappe
def get_context(context):
2016-07-05 06:42:39 +00:00
if frappe.form_dict.project:
context.parents = [{'title': frappe.form_dict.project, 'route': '/projects?project='+ frappe.form_dict.project}]
elif context.doc and context.doc.get('project'):
context.parents = [{'title': context.doc.project, 'route': '/projects?project='+ context.doc.project}]