Hi,
I followed the documentation for Issue Collector and I was able to create a webpage with a button that can now show a Dialog to open a ticket in a specific JIRA project. I am even able to provide Default values for some fields by adding this code:
// ==== default field values ====
fieldValues : {
summary : 'This is the default summary value'
}
And it is pretty sweet.
However I would like to upgrade this feature and to be able to pass values instead of only defining defaults one with "fieldValues".
In a way, this is what I am trying to do:
// ==== we add the code below to set the field values ====
"fieldValues": {
summary : $('#summary').val(),
description : $('#description').val()
}
<body>
<input id="summary" name="summary" type="text" value="" />
<input id="description" name="description" type="text" value="" />
</body>
This is a simplified version of my code, but I think it should shows what I am trying to do.
The problem is that the code $('#summary').val() is not called when we click on the button and trigger the function showCollectorDialog();. So the values I am trying to get from the inputs are never gathered back to the Dialog.
I am at lost to try and find a way to solve this.
Any help is appreciated.
Thank you