Fórum

Web Form Bug

na na, modificado 15 Anos atrás.

Web Form Bug

Junior Member Postagens: 94 Data de Entrada: 29/04/08 Postagens Recentes
I use multiple paragraph type field to construct my liferay web form. When I sent the webform through email, the email content have all the those paragraph type field as null. How to hide the paragraph type field appear in email at all?
thumbnail
coffy_ sk, modificado 14 Anos atrás.

RE: Web Form Bug

Junior Member Postagens: 26 Data de Entrada: 05/06/09 Postagens Recentes
Hi,
you need to modify getMailBody() method of com.liferay.portlet.webform.action.ViewAction class (I use liferay 5.1.2)
You retrieve fieldType from portlet preferences. And then put simple condition before field is written to output


for (int i = 1; itr.hasNext(); i++) {
	...
	String fieldType = prefs.getValue("fieldType" + i, StringPool.BLANK);

	if ( ... && !fieldType.equals("paragraph") ) {
		...
		...
	}
}