Show multiple text box dynamically based on value entered
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-29-2018 12:08 AM
Hi,
I need to create textboxes(input fields) based on the value entered on another text box.
For eg, if the value entered is 5, i need to create 5 text boxes to accept 5 inputs.
Is this possible to implement?
Thanks.
- Labels:
-
Scripting and Coding

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-31-2018 07:01 AM
I see,
well, I would try this approach:
As you will show an UI Macro (+ UI Page eventually, depending on the approach) you can use in the Angular (if you embed it in the Jelly) or Jelly Javascript that will create a new element on the fly, depending on some conditioning (in your case what the user chose). Afterwards, you can use this data to populate a supporting table, where these values will be set so you can use them later in your REQ/INC/whatever. Newer approach, which sadly I havent the chance to test yet, is to put a JSON type field in the corresponding REQ/INC/whatever rec . This way you can have kind of more robust and easy way to show your user input values, as you cannot just so easy create and delete fields from an incident table for example - this would be total madness 🙂
So to use one of the above approaches, you still need to create a custom formatter for the corresponding table, which calls extra UI Page/Macro. There you can easily show whatever needed as you can parse either the JSON field or the data from the supporting table. This is although big customisation in my opinion and if you have this as requirement, then the guys doing the business/service processes got very confused. Its not usual to not know what you should ask - especially if you as service management operations. Its like having your own shop, but you dont know what you are selling because you expect your customers to tell you 🙂
I am very sure there is an easier way to achieve this process. Let me know if i can help in this (although i would help and with the above but its an overkill to me)
Cheers,
Joro