0

我第一次进入页面时遇到错误。但是,如果我再次刷新页面,所需的消息工作正常,我将要求设置为af:inputText

修订:我设置 showRequired=" false true"

<af:inputText id="id" styleClass="input-medium" showRequired="true"
                required="true"
                requiredMessageDetail="You Must Insert ID"
                maximumLength="50" autoSubmit="true" simple="true"
                contentStyle="width:25%;"/>

我在Chrome中检查控制台出现如下错误:

Uncaught NotFoundError: An attempt was made to reference a Node in a context where it does not exist. message-11.1.1.5.0-1095.js:162
AdfDhtmlMessagesPeer._messageUpdate message-11.1.1.5.0-1095.js:162
AdfDhtmlMessagesPeer.MessageNotify message-11.1.1.5.0-1095.js:106
AdfRichUIPeer.messageNotify core-11.1.1.5.0-1095.js:15213
AdfDhtmlPage._notifyComponent boot-11.1.1.5.0-1095.js:10917
AdfDhtmlPage.addMessage boot-11.1.1.5.0-1095.js:10705
AdfUIEditableValue._addFacesMessage core-11.1.1.5.0-1095.js:5417
AdfUIEditableValue._addRequiredFacesMessage core-11.1.1.5.0-1095.js:5411
AdfUIEditableValue.ValidateValue core-11.1.1.5.0-1095.js:5370
AdfUIEditableValue.validate core-11.1.1.5.0-1095.js:5295
AdfDhtmlPage._processValidators boot-11.1.1.5.0-1095.js:7551
AdfDhtmlPage.queueEvent boot-11.1.1.5.0-1095.js:7379
AdfUIComponent.queueEvent core-11.1.1.5.0-1095.js:4265
AdfComponentEvent.queue boot-11.1.1.5.0-1095.js:2155
AdfDhtmlCommandLinkPeer.HandleComponentClick core-11.1.1.5.0-1095.js:18885
AdfRichUIPeer.DispatchComponentEvent core-11.1.1.5.0-1095.js:15124
AdfUIComponent._deliverEvent core-11.1.1.5.0-1095.js:4356
AdfUIComponent.broadcast core-11.1.1.5.0-1095.js:4282
AdfDhtmlPage._deliverQueuedEvents boot-11.1.1.5.0-1095.js:7622
AdfDhtmlPage._deliverAllQueuedEvents boot-11.1.1.5.0-1095.js:7604
AdfDhtmlPage._eventLoopDeliverEvents boot-11.1.1.5.0-1095.js:7595
AdfDhtmlPage._redistribute boot-11.1.1.5.0-1095.js:8591
(anonymous function)
4

2 回答 2

0

我对此错误的 回答是xmlns:f="java.sun.com/jsf/core",使用.<f:<af:table<f:facet

尝试删除<f:and xmlns:f="java.sun.com/jsf/core",然后它的工作。

于 2015-04-16T05:01:27.587 回答
0

刚试过这个,效果很好。

<af:form id="f1">
        <af:panelStretchLayout id="psl1">
            <f:facet name="center">
                <!-- id="af_one_column_stretched"   -->
                <af:panelGroupLayout layout="scroll" id="pgl1">
                    <af:inputText id="id" styleClass="input-medium" showRequired="false" required="true"
                                  requiredMessageDetail="You Must Insert ID" maximumLength="50" autoSubmit="true"
                                  simple="true" contentStyle="width:25%;" label="Input"/>
                    <af:commandButton text="Submit" id="cb1"/>
                </af:panelGroupLayout>
            </f:facet>
        </af:panelStretchLayout>
    </af:form>

也许您已将它插入到导致该行为的其他一些元素中。试试这个,然后你可能会找出真正的问题。董

于 2013-09-24T06:49:44.853 回答