Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

ScriptRunner Behaviours:I want the other fields to be editable after the Epic Link is empty

Zhaocheng Zhou August 1, 2022
def formField = getFieldById(getFieldChanged())
def epicLinkVl = formField.getFormValue()
def projectNameFl = getFieldByName("ProjectName")
if (epicLinkVl) {
projectNameFl.setReadOnly(true)
}
else {
projectNameFl.setReadOnly(false)
}
but,
else {
projectNameFl.setReadOnly(false)
}
Not work

2 answers

0 votes
Zhaocheng Zhou August 1, 2022

done myself, Thank you!

0 votes
Mohamed Benziane
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 1, 2022

Hi,

welcolme to the community

use this formField.getValue() instead of formField.getFormValue()

https://docs.adaptavist.com/sr4js/latest/features/behaviours/api-quick-reference

Suggest an answer

Log in or Sign up to answer