It's all about the answers!

Ask a question

Can we validate date and show custom messages using java script?


Jazz Queries (111421) | asked Oct 11 '17, 9:07 a.m.

 Hi,


Can we validate date field in RTC and show custom message based through Java script. It is achievable using plugins but I was wondering if we can get it done through javascripts?

 

One answer



permanent link
Donald Nong (14.5k614) | answered Oct 11 '17, 11:02 p.m.

The Script-based Validator is supposed to support "any attribute type" so it could be your only choice if JavaScript is required.


Comments
Ralph Schoon commented Oct 12 '17, 4:18 a.m. | edited Oct 12 '17, 4:19 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

The JavaScript attribute customization ( https://jazz.net/library/article/1003 ) API basically only really supports text based items. String or enumerations https://jazz.net/wiki/bin/view/Main/AttributeCustomization#API_for_Javascript . Complex items are generally not claimed to be supported and you have mixed results if you try. E.g. for contributors. 


The JavaScript API however also allows the conversion of timestamps so you can use JavaScript against the text representation.  

Valication can show validation warnings or errors in the UI.

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.