Ich habe ein <form:textarea>
Element. Ich würde es mit Daten prefill wie aus dem modelAttributes
Prefill-Formular: Textarea Feder mvc
Hier ist mein Code:
java:
ArrayList<Bloc> lblocs= new ArrayList<>();
lblocs = blocDao.getListBlocs();
modelMap.addAttributes("listeBlocs", lblocs);
jsp:
<form:form method="post" modelAttribute="listeBlocs">
<c:forEach var="bloc" items="${listeBlocs}" varStatus="status">
<form:textarea path="bloc_contenu" name="BContenu_textarea"
value="" />
</c:forEach>
</form:form>
bloc_contenu soll ein String-Attribut sein, ein Bloc-Objekt. Wenn lade ich die Seite, die ich die folgende Fehlermeldung erhalten:
Invalid property 'bloc_contenu' of bean class [java.util.ArrayList]: Bean property 'bloc_contenu' is not readable or has an invalid getter method
Irgendwelche Vorschläge?
sollten Sie die Eigenschaft bloc_contenu auf dem BefehlBean dieses Formulars haben. –