How to allow a customer to set his priority level in the ticket?

Hi, I wanted to allow the customer to set his priority level when raising a ticket instead of the agents. So, I added a new custom field to the ticket template with a drop-down box to select the priority and it works. But after the ticket is created it still has it set to the default medium priority level for the agent.

How can I pull this value to be set from the customer-chosen priority instead of the default priority? However, the ticket interface, shows the customer’s preference in the right column, allowing the agent to know what priority level the customer has chosen.

I want this to be set automatically by the customer rather than the agent. How can I achieve this?

You have two different fields, the default priority field and your new customer-set priority field. If you want the default priority field to automatically update to match the customer set priority field, you could create a server script that triggers on document save:

https://docs.erpnext.com/docs/v13/user/manual/en/customize-erpnext/server-script