inplace editing

UI Components for JSF
Post Reply
apropos
Posts: 2
Joined: 27 Jun 2014, 21:38

27 Jun 2014, 21:53

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>

kukeltje
Expert Member
Posts: 9605
Joined: 17 Jun 2010, 13:34
Location: Netherlands

11 Jul 2014, 10:54

does it work without pm:field?

apropos
Posts: 2
Joined: 27 Jun 2014, 21:38

16 Jul 2014, 01:05

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.

tetamusha
Posts: 8
Joined: 17 Mar 2016, 06:16

14 Jun 2016, 16:20

I'm on PrimeFaces 6.0 and this behavior still stands.

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 25 guests