Field and Form Rules for Editor

Field and Form Rules for Editor

How can I fix either of the scripts below so they will set the editor field based on another field on form submit, this sounds pretty simple but it is not natively available in triggers or business rules because the Directly Reports-To field can be different with every ticket, but the only option I have is to set the "Editor" to a specific user which won't work since not ever new hire will report to the same supervisor to edit the ticket.

Scripts I have tried:

"Directly Reports-To" = WorkOrder_Fields_UDF_CHAR15

Script 1:
var name=jQuery("#editorField").val();
if($CS.isFormSubmit()) {
$CS.setValue("WorkOrder_Fields_UDF_CHAR15");


Script 2:
// Get the value from the Direct Reports-To field
var name = $CS.getValue("WorkOrder_Fields_UDF_CHAR15");
// set the value of the editor field
$CS.setValue("#editorField", name); 

Neither of these scripts updates the field when the form is submitted.

PGSQL
14.6 Build 14600

                New to ADSelfService Plus?