Page 1 of 1

inplace editing

Posted: 27 Jun 2014, 21:53
by apropos
Is inplace editing supported in Mobile? I cannot get the editor to trigger by clicking on the field display. Similar markup works with the normal renderer.

profile.xhtml:

Code: Select all

<ui:composition template="/WEB-INF/template/visitor/common.xhtml"
                xmlns="http://www.w3.org/1999/xhtml"
                xmlns:h="http://xmlns.jcp.org/jsf/html"
                xmlns:f="http://xmlns.jcp.org/jsf/core"
                xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
                xmlns:o="http://omnifaces.org/ui"
                xmlns:p="http://primefaces.org/ui"
                xmlns:pe="http://primefaces.org/ui/extensions"
                xmlns:pm="http://primefaces.org/mobile"
        >
    <ui:param name="mainActiveIndex" value="3"/>
    <ui:define name="content">
        <h:form id="profileEdit">
            <pm:field>
                <p:outputLabel for="name" value="#{ui.name}"/>
                <p:inplace id="nameInplace" editor="true">
                    <p:inputText id="name" value="#{profileEditor.name}" required="true"/>
                </p:inplace>
                <p:messages for="name" id="nameMessages"/>
            </pm:field>
 
         (...more fields..)

        </h:form>
    </ui:define>
</ui:composition>
common.xhtml template:

Code: Select all

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:f="http://xmlns.jcp.org/jsf/core"
      xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
      xmlns:p="http://primefaces.org/ui"
      xmlns:pm="http://primefaces.org/mobile"
        >

<f:view renderKitId="PRIMEFACES_MOBILE"/>

<h:head>
    <h:outputScript name="primefaces_ja.js"/>
    <ui:insert name="head"/>
</h:head>

<h:body>
    <pm:page>
        <pm:header>
            <p:tabMenu id="mainmenu" activeIndex="#{mainActiveIndex}">
                  (...navbar...)
            </p:tabMenu>
        </pm:header>

        <pm:content>
            <ui:insert name="content"/>

            <p:growl id="growl" autoupdate="true"/>
        </pm:content>

        <pm:footer />
    </pm:page>
</h:body>

</html>

Re: inplace editing

Posted: 11 Jul 2014, 10:54
by kukeltje
does it work without pm:field?

Re: inplace editing

Posted: 16 Jul 2014, 01:05
by apropos
I see no functional change taking out pm:field. Naturally, this makes the fields lay out differently, but the inplace fields are still acting like dead output text. If versions matter, this is PrimeFaces 5.0 running on WildFly 8.1.0.

Re: inplace editing

Posted: 14 Jun 2016, 16:20
by tetamusha
I'm on PrimeFaces 6.0 and this behavior still stands.