How to change the success message in client script

Based on the option select by user the success message to be changed. How to do in client script.

Thankyou

frappe.web_form.on(‘what_are_you_creating_for’, (options, value) => {

frappe.web_form.after_save = () => {
console.log(“happy”,data)
if (value === “Research Survey”) {

// Here i want to set the success message based on the condition please help
console.log(‘its working’)
}

if(value === “Quiz”){
console.log(“its quiz”)
}
if(value === “Application Form”){
console.log(“its application form”)
}
}
});

{
“allow_comments”: 0,
“allow_delete”: 0,
“allow_edit”: 0,
“allow_incomplete”: 0,
“allow_multiple”: 0,
“allow_print”: 0,
“apply_document_permissions”: 0,
“breadcrumbs”: “”,
“button_label”: “Save”,
“client_script”: “frappe.web_form.on(‘what_are_you_creating_for’, (options, value) => {\nfrappe.web_form.after_save = () => {\n console.log("happy",data)\nif (value === "Research Survey") {\n console.log(‘its working’)\n }\n \nif(value === "Quiz"){\n console.log("its quiz")\n }\n if(value === "Application Form"){\n console.log("its application form")\n }\n \n}\n\n \n \n});\n\n\n\n\n”,
“creation”: “2023-03-31 13:02:33.649425”,
“doc_type”: “Turiya”,
“docstatus”: 0,
“doctype”: “Web Form”,
“idx”: 0,
“is_standard”: 1,
“list_columns”: [],
“login_required”: 0,
“max_attachment_size”: 0,
“modified”: “2023-03-31 15:49:57.773676”,
“modified_by”: “Administrator”,
“module”: “Turiyform”,
“name”: “turiyatreeform”,
“owner”: “Administrator”,
“published”: 1,
“route”: “turiyatreeform”,
“show_attachments”: 0,
“show_list”: 0,
“show_sidebar”: 0,
-------------------------->>>>>>>>>>.“success_message”: “”,<<<<<<<<<<<<------------------
“title”: “TuriyaTreeForm”,

}