sheno
#1
IN Task page
there is assigned to click on the left hand of the page
by click it then we can assign that task to specific user .
- i need to add a custom field in the task page and lets called it
Assigned To as a read only type
- i want when i click on the left assigned to so
it will effect on the costume field and type the name of the one who assigned to .
Thx a lot for your help .
Hi @sheno,
You can achieve the 2nd step by using the hooks, add the after_insert
hook for ToDo
doctype.
then in your hook method add the code to set the value to Assigned To field in task.
Please refer the following code
if self.reference_type == "Task" and self.reference_name:
frappe.db.set_value("Task", self.reference_name, "assigned_to", self.owner)
Thanks, Makarand
1 Like
sheno
#5
thx a lot for replay
actually i dont know hook
where is it located to add this command in it
@sheno,
Please refer the developer manual for hooks documentations.
Thanks, Makarand
1 Like