How can I use custom javascript in Spring Roo generated pages? -


I am working on a spring roo project and in case of being able to customize the web page, Has hit.

The main thing I want to do is to be able to dynamically hide some fields because the customer is filling out web forms. I have a drop down list that has been powered by enumeration, which has 4 options and the fifth is the "other" option. If the user selects "other" then I have to show a text box so that the user selects his own Could.

I was talking to someone and he said, "It really depends on the UI you have chosen. In the case of MVC scaffold you can use JavaScript to run these relations. ". I'm actually using MVC scaffolding so I think I have to use javascript. I really do not know much javascript but the problem is that I do not even know where the javascript code will go during my project files and then of course there is another problem that Javascript is used to dynamically hide the field in Spring How to do.

Thanks

itemprop = "text">

Spring MVC scaffolding by default Dojo as your Javascript framework uses it.

When you attach events to DOM elements, you can use the standard dojo function. To include your own custom JavaScript methods within the generated . Jspx page, just enter & lt; Script / & gt; tag.

In addition, you can integrate the other existing Javascript frameworks of JQuery. At the moment you can manually add jQuery, but it can possibly be expected in future Spring Cry version.

You can now be safe with dojo.

Comments

Popular posts from this blog

mysql - BLOB/TEXT column 'value' used in key specification without a key length -

javascript - What is an alternative to using getElementByClass for hiding multiple elements? -

c - Selecting a file randomly from a file system -