java - Properties inside an ArrayList inside a HashMap always null -


i'm trying save form data in hashmap value arraylist of objets (named filterform). when try submit form, in entrykey values of map table values map null.

this map, first initialize it:

the map initialized following, before processing data:

private map<string, list<filterform>> filtros = new linkedhashmap<string, list<filterform>>();  public customsearchform() {         this.filtros.put("datos_personales", new arraylist<filterform>());         this.filtros.put("datos_institucion", new arraylist<filterform>());  } 

then catch values thymeleaf form

<div class="col-md-2 col-xs-2">     <select th:id="'accion_'+${f.key}+'_'+${status.index}" onchange="cambiocombo(this);" th:if="${ff.tipocampo != 'booleano'}" class="form-control select2me" form="customsearch"         placeholder="acción"         th:field="*{filtros[__${f.key}__][__${status.index}__].accion}">         <option th:each="a : ${customsearch.acciones}" th:value="${a}"                 th:text="${a}"></option>     </select>  </div>  <div class="col-md-3 col-xs-3">     <input th:id="'valuefield_'+${f.key}+'_'+${status.index}" th:if="${ff.tipocampo == 'numero' or ff.tipocampo == 'texto' or ff.tipocampo == 'tabla'}" form="customsearch"         type="text" class="form-control" placeholder="valor"         th:field="*{filtros[__${f.key}__][__${status.index}__].value}" />    <div th:if="${ff.tipocampo == 'fecha'}" th:id="'datefield_'+${f.key}+'_'+${status.index}" class="date"         data-date-format="dd/mm/yyyy">         <input form="searchform"             class="form-control input-lg date" th:id="'valuefielddate_'+${f.key}+'_'+${status.index}"             th:field="*{filtros[__${f.key}__][__${status.index}__].value}"              th:name="'valuefield_'+${f.key}+'_'+${status.index}" type="text" placeholder="fecha" />     </div> 

f property came when loop hashmap , status variable when loop list inside map.


Comments

Popular posts from this blog

javascript - jQuery: Add class depending on URL in the best way -

caching - How to check if a url path exists in the service worker cache -

Redirect to a HTTPS version using .htaccess -