Foros de discusión

liferay-ui:input-editor - No required message shown for input-editor

Éric Barboza, modificado hace 9 años.

liferay-ui:input-editor - No required message shown for input-editor

New Member Mensajes: 11 Fecha de incorporación: 28/10/13 Mensajes recientes
Hi guys,

I am trying to use input-editor tag inside a xhtml page and validate some required fields in this page when my form is submitted. There are two input fields and one liferay-ui:input-editor on this page.

The problem that I'm facing is that when I use the required attritbute for the input-editor field and a user tries to submit the form without filling this field, no error message is displayed specifying that this is a madatory field. I would like to mention that it works fine when used with a <h:inputText /> field.

Here is how I used the ckeditor in my xhtml file:


<div id="mydiv">
	<h:message for="inputEditor"></h:message>
	<liferay-ui:input-editor id="inputEditor" value="#{myBean.contentBody}" />
</div>


Environment info:
portal-service:jar:6.2.1
liferay-faces-bridge-impl:jar:3.2.4-ga5
liferay-faces-util:jar:3.2.4-ga5
liferay-faces-bridge-api:jar:3.2.4-ga5
liferay-faces-alloy:jar:3.2.4-ga5

I would like to know if I am using something in a wrong way or if there is any opened issue related to this.

Let me know if I should provide further info.

Thanks in advance.
thumbnail
Neil Griffin, modificado hace 9 años.

RE: liferay-ui:input-editor - No required message shown for input-editor

Liferay Legend Mensajes: 2655 Fecha de incorporación: 27/07/05 Mensajes recientes
Hi Eric,

The JSF version of liferay-ui:input-editor is a Facelet composite component which is basically the reason why h:message is not working the way you would expect. In the forthcoming version of Liferay Faces, we have a new portal:inputRichText component that is a Java-based UIComponent that will indeed work the way you expect.

But for now, you can specify <liferay-ui:input-editor inlineMessage="true" required="true" /> in order to get the behavior you want.

Kind Regards,

Neil
Éric Barboza, modificado hace 9 años.

RE: liferay-ui:input-editor - No required message shown for input-editor

New Member Mensajes: 11 Fecha de incorporación: 28/10/13 Mensajes recientes
Hi Neil,

Here you are again, helping me. I would like to say that my code worked very well using the inlineMessage attribute.

Thank you very much for your quick response. I tought I was going to have the chance to meet you at Liferay Symposium Brazil.
thumbnail
Neil Griffin, modificado hace 9 años.

RE: liferay-ui:input-editor - No required message shown for input-editor

Liferay Legend Mensajes: 2655 Fecha de incorporación: 27/07/05 Mensajes recientes
Hi Éric,

I am glad to hear that the inlineMessage attribute worked for you. emoticon

It would have been nice to meet you at the Liferay Symposium in Brazil, but I only attended the North American and Europe Symposiums this year.

Kind Regards,

Neil