i have list of objects services in thymeleaf context, , have following @ page: <select id="inputservice" name="idservice" size="1"> <option th:each="service : ${services}" th:text="${service.name}" th:value="${service.idservice}"/> </select> <p id="selectedservicelimits"></p> each object services contains fields minamount , maxamount . how can print p element these 2 fields of selected service in select javascript? , how can print these 2 fields of option selected when document ready? thanks! <script th:inline="javascript"> /*<![cdata[*/ function showlimits() { var services = /*[[${services}]]*/ null; var selectedindex = $("#inputservice option:selected").index(); var service = services[selectedindex]; $("#amountlimits").text("Ми...
Comments
Post a Comment