Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Deleted user
0 / 0 points
Next:
badges earned

Your Points Tracker
Challenges
Leaderboard
  • Global
  • Feed

Badge for your thoughts?

You're enrolled in our new beta rewards program. Join our group to get the inside scoop and share your feedback.

Join group
Recognition
Give the gift of kudos
You have 0 kudos available to give
Who do you want to recognize?
Why do you want to recognize them?
Kudos
Great job appreciating your peers!
Check back soon to give more kudos.

Past Kudos Given
No kudos given
You haven't given any kudos yet. Share the love above and you'll see it here.

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

behaviour convertToSingleSelect (JQL query) get selected value?

I am using the convertToSingleSelect in a behaviour as an Issue picker but need to retrieve the selected value for use in a second behaviour.

I cannot find any information on how to retrieve the value selected. formField.value is null..?

I would be grateful for any help or where to find the documentation on behaviours.

1 answer

0 votes
Tarun Sapra Community Leader Apr 15, 2019

Hello @markbutterfield 

If there is a behaviour mapped to the second field then in that behaviour if you use the code

getFieldByName("My Custom Field") 

Then you should be able to get the value of the of field with value coming from convertToSingleSelect . Hence I feel for the first field you should have one behaviour mapping and on behaviour mapping for the second field and then it should work.

The exact setup is as follows. 

Behaviour 1 : CF1 (convertToSingleSelect as issue picker)

Behaviour 2: CF2 (convertToSingleSelect as issue picker) : I need selected value from CF1 for query.

All attempts in the second behaviour to retrieve the selected value from CF1 return null. (getFieldByName("CF1").value is null) I cannot figure out how the selected value in CF1 is stored/retrieved.

OK, problem is that both are running as Initilaiser...helps when one reads through all the docs..

To do this, we don’t use an initialiser - instead we add an on change server-side script that will convert TextFieldA to a single-select issue picker - the JQL query will be formed from the value of the ProjectPicker field.

Tarun Sapra Community Leader Apr 15, 2019

Hello @markbutterfield 

You don't need to use initializer, instead as I mentioned before please have separate mapping for both fields and that should do the trick. If it works, and you feel my answer has helped you then please accept/upvote the answer. thanks.

Hello @markbutterfield  and @Tarun Sapra ,

I need to implement something like this:

I want to create a select list field for a particular project with options which appear on screen as:

<value of a custom field(any other custom field) of an issue><sapce><Value of summary field of the same issue>

 and the no. of options should be same as the no. of issues in that particular project.

Could you please help.

Thanks and Regards,

Swapnil Srivastav.

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Marketplace Apps & Integrations

☕️ Monday coffee with Jexo: Weekly Atlassian news roundup | 21st June 2021

Hi community 👋, as every Monday we're bringing you a quick update on what happened in the Atlassian ecosystem last week. There were a few interesting events like for example the announcement of th...

47 views 0 6
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you