We have a requirement to add some functionality implementation on change of one date picker custom field value and we need to achieve this through java script.
We have tried adding event listener to both the elements(both textbox and calendar icon) but it is not working. what is the event listener should be used and on which element to be used?
Hi @Sandesh TM
adding a simple change event lisneter on an input field would be something like the below code in javascript
AJS.$(function () {
AJS.$('#customfield_XXXXX').on('change', function () {
// what will you do when you got the change
console.log('Date changed:', AJS.$(this).val());
});
});
I don't know what have you tried and what error you've got. The more you clarify, the more we can help
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.