I really wanted this to be automated when a system user gets Assigned (from the left sidebar) to the opportunity though will it require lots of custom development?
create a server script for ToDo doctype on save method like below
if doc.reference_type == 'Opportunity':
quotation = frappe.get_doc(doc.reference_type, doc.reference_name)
if quotation.status == 'Open' or not quotation.status:
quotation.status = 'Assigned'
quotation.save()
the only issue is that after new Assign To created and the opportunity saved, the status field not auto refreshed( the server script is executed on backend, no way to auto refresh the form), you need to manually to refresh to see the changed status.
OMG, Perfect! Completely worked with only one bug being raised!
When you create a Quotation to the Opportunity, unless you Submit the quotation document, status of the Opportunity becomes null. Once the Quotation is submitted, then the status of the opportunity gets routed just fine.
But thank you so much! This is really good enough and is getting the job done. I do however, wish you’d test the script on your end and fix the small bug thank you!
Same scenario with Sales Order and Invoice. I created a work flow and ticked the checkbox “Don’t Override Status” so that the workflow state show as the status and will not be on a draft status only while the document is in the process of approval.
However, the other status like Overdue, Deliver & Bill, Closed and Paid are not shown on shown if the checkbox “Don’t Override Status” unless you uncheck it but the draft status is shown which lead on confusion.
Another scenario I read is, if these other status are not on the workflow, you cannot open the document unless you deactivate the workflow. But I haven’t tested that scenario.