Kanchan Chauhan | b3fe6a4 | 2016-03-16 18:01:22 +0530 | [diff] [blame] | 1 | import frappe |
| 2 | |
Kanchan Chauhan | b3fe6a4 | 2016-03-16 18:01:22 +0530 | [diff] [blame] | 3 | |
| 4 | def get_context(context): |
| 5 | context.no_cache = 1 |
| 6 | |
| 7 | task = frappe.get_doc('Task', frappe.form_dict.task) |
Ankush Menat | 4551d7d | 2021-08-19 13:41:10 +0530 | [diff] [blame] | 8 | |
Kanchan Chauhan | b3fe6a4 | 2016-03-16 18:01:22 +0530 | [diff] [blame] | 9 | context.comments = frappe.get_all('Communication', filters={'reference_name': task.name, 'comment_type': 'comment'}, |
| 10 | fields=['subject', 'sender_full_name', 'communication_date']) |
Ankush Menat | 4551d7d | 2021-08-19 13:41:10 +0530 | [diff] [blame] | 11 | |
| 12 | context.doc = task |