As you can see beneath I use a template where I put a dynamic accordionPanel into. Within the tab is a inplace editor.
The problem is that i can adjust the input of the inplace editor but when i click "Save" nothing happens.
Code: Select all
...
<ui:define name="content">
<h:form>
<p:accordionPanel value="#{onkostenController.onkostenByGebruiker}" var="onkost" multiple="true">
<p:tab title="#{onkost.omschrijving}">
<h:panelGrid columns="2" columnClasses="column" cellpadding="5">
<h:outputText value="Omschrijving : " />
<p:inplace editor="true">
<p:inputText value="#{onkost.omschrijving}" required="true" label="text"/>
</p:inplace>
...
Code: Select all
...
public List<Onkosten> getOnkostenByGebruiker() {
FacesContext context = FacesContext.getCurrentInstance();
String gebruikersnaam = (String) context.getExternalContext().getRemoteUser();
this.gebruiker = gegevensService.opvragenGebruiker(gebruikersnaam);
return onkostenService.alleOnkostenGebruiker(gebruiker);
}
...
Code: Select all
...
public List<Onkosten> alleOnkostenGebruiker(Gebruiker gebruiker) {
EntityManager em = emf.createEntityManager();
Query query = em.createQuery("select o from Onkosten o where o.gebruiker = :gebruiker");
query.setParameter("gebruiker", gebruiker);
return query.getResultList();
}
...
Code: Select all
...
private String omschrijving;
...
public String getOmschrijving() {
return omschrijving;
}
public void setOmschrijving(String omschrijving) {
this.omschrijving = omschrijving;
}
...
Thanks in advance.