Details
-
Bug
-
Status: Done
-
L3
-
Resolution: Fixed
-
6.20.0
-
SR4J Sprint 103
-
7.5
Description
Behaviour is unable to capture the latest Insight Multiple field value via JSD screen.
First Scenario - Insight Multiple field option is using old values
Steps to Reproduce
- Create two Insight Custom field
- Edit Insight field configuration and check the "Multiple" option
- Associate to a JSD screen.
- Create a Behaviour with the script below on the Insight field (multiple choice)
def fieldA = getFieldByName("Insight Object 1") def fieldB = getFieldByName("Insight Object 2") log.warn "field value: "+fieldA.getValue() def values = fieldA.getValue() if(fieldA.getValue() == "HR-1") { fieldB.setHidden(false) } else { fieldB.setHidden(true) }
- Next, go to the JSD screen and select first option (e.g HR-1)
- In the server logs returned a null value:
2021-03-01 08:27:29,665+0000 http-nio-8080-exec-39 WARN admin 507x36027x1 1mp60zg 172.17.0.1 /rest/scriptrunner/behaviours/latest/jsd/jsd/runvalidator.json [c.o.scriptrunner.runner.ScriptBindingsManager] field value: []
- Now, select another value on the field:
2021-03-01 08:28:53,614+0000 http-nio-8080-exec-22 WARN admin 508x36030x1 1mp60zg 172.17.0.1 /rest/scriptrunner/behaviours/latest/jsd/jsd/runvalidator.json [c.o.scriptrunner.runner.ScriptBindingsManager] field value: [HR-1]
Demo - Screen Recording 2021-03-01 at 4.36.17 PM.mp4
Second Scenario - search option returned a null value
Steps to Reproduce
- Search option (magnifying glass by the field) returned a null value from getValue() API.
- In the server log, its printed a null value:
2021-03-16 09:23:28,117+0000 http-nio-8080-exec-5 WARN admin 563x1781x1 ne6tmt 172.17.0.1 /rest/scriptrunner/behaviours/latest/jsd/jsd/runvalidator.json [c.o.scriptrunner.runner.ScriptBindingsManager] field value:
Demo - Screen Recording 2021-03-16 at 5.23.34 PM.mp4
Expected Behaviour
Behaviour getValue() API should be capturing the latest value after field value changed from Insight Multiple field option. Also, magnifying glass by the field is able to return a field value.
Actual Behaviour
Behaviour getValue() API is returning a null/old value and magnifying glass by the field returned a null value.
Additional Info
- Tested on JIRA 8.14.0 and Insight 8.7.4
- Behaviour getValue() API is working on Insight Select field option.
Attachments
Issue Links
- split to
-
SRJIRA-5428 Using Insight Object selector in JSD do not trigger a behaviour
-
- Done
-