Hi Guys, I created the following rule:
import static com.atlassian.jira.issue.IssueFieldConstants.PRIORITY
import static com.atlassian.jira.issue.IssueFieldConstants.COMPONENTS
getFieldById(PRIORITY).setFormValue(3)
getFieldById(COMPONENTS).setFormValue(["Program"])
this rule is supposed to set the Components field a default value of "Program" and the Priority default to "Medium"
ALL this should happen BEFORE the creation of the issue, meaning, these values should be set when I click on the "Create" Button inside Jira.

I'm not sure if I selected the correct option of when the script will run, neither if the script is correct.
Can someone instruct me on how to make this work?