Fórum

Web Form Sender

Dimas Purdinanto, modificado 8 Anos atrás.

Web Form Sender

Junior Member Postagens: 29 Data de Entrada: 11/08/15 Postagens Recentes
Hi all,

I'm using Web Form to collect suggestions / complains from my team. But there's no telling who the real sender, since field to input names is a only free text.
Is it possible to grep the real sender, their email or names? I've set the portlet so the Web Form only visible to registered user (need to login)

Thank you
thumbnail
Amos Fong, modificado 8 Anos atrás.

RE: Web Form Sender

Liferay Legend Postagens: 2047 Data de Entrada: 07/10/08 Postagens Recentes
It doesn't look like the OOTB web form portlet can do this. You'll need to customize it to get what you want.
Dimas Purdinanto, modificado 8 Anos atrás.

RE: Web Form Sender

Junior Member Postagens: 29 Data de Entrada: 11/08/15 Postagens Recentes
Hi Amos,

On Github i see there's a project (sourcecode) for web-form portlet
https://github.com/liferay/liferay-plugins/tree/6.2.x/portlets/web-form-portlet

And i tried to modify web-form portlet using that code, but on the first deployment it said that some classes are missing
java.lang.ClassNotFoundException: com.liferay.webform.portlet.WebFormPortlet

So i added OOTB web-form classes, and deployment went smoothly

Is it a correct way? But somehow my mofication doesn't affect the outcome. I even deleted some lines on WebFormPortlet.java, the portlet still running well

Could you tell me how to modify the portlet?
thumbnail
Samuel Kong, modificado 8 Anos atrás.

RE: Web Form Sender

Liferay Legend Postagens: 1902 Data de Entrada: 10/03/08 Postagens Recentes
Don't try to modify the code directly. Instead, take a look a the documentation on Creating Plugins to Extend Plugins
Dimas Purdinanto, modificado 8 Anos atrás.

RE: Web Form Sender

Junior Member Postagens: 29 Data de Entrada: 11/08/15 Postagens Recentes
Well noted,

Do you happened to have web form war file for liferay ce 6.2?
I've grab it from here, i'm not sure if it is the correct one:
https://github.com/PolitAktiv/releases/blob/master/liferay/marketplace/6.2/web-form-portlet-6.2.0.3-ce-ga1-20140120092742162.war
Dimas Purdinanto, modificado 8 Anos atrás.

RE: Web Form Sender

Junior Member Postagens: 29 Data de Entrada: 11/08/15 Postagens Recentes
Hi Samuel,

Could you help to elaborate what's need to be done in point. 5

Thank you
thumbnail
Samuel Kong, modificado 8 Anos atrás.

RE: Web Form Sender

Liferay Legend Postagens: 1902 Data de Entrada: 10/03/08 Postagens Recentes
Dimas Purdinanto:
Could you help to elaborate what's need to be done in point. 5


What don't you understand?
Dimas Purdinanto, modificado 8 Anos atrás.

RE: Web Form Sender

Junior Member Postagens: 29 Data de Entrada: 11/08/15 Postagens Recentes
Samuel Kong:
Dimas Purdinanto:
Could you help to elaborate what's need to be done in point. 5


What don't you understand?


This part
Copy any files from the original plugin that you’re overwriting to your new plugin (using the same folder structure)


And when i tried to run the Ant target merge, here's the result

BUILD FAILED
C:\Users\xxx\liferay-plugins-sdk-6.2\build-common-plugin.xml:684: The following error occurred while executing this line:
C:\Users\xxx\liferay-plugins-sdk-6.2\build-common.xml:2080: src 'C:\Users\xxx\liferay-plugins-sdk-6.2\portlets\extended-webform-portlet\${set-build-xml-var.return}' doesn't exist.


I'm using eclipse by the way, please see attached file for the project structure
Phan Toan, modificado 6 Anos atrás.

RE: Web Form Sender

New Member Postagens: 2 Data de Entrada: 05/04/17 Postagens Recentes
This part
Copy any files from the original plugin that you’re overwriting to your new plugin (using the same folder structure)


And when i tried to run the Ant target merge, here's the result

BUILD FAILED
C:\Users\xxx\liferay-plugins-sdk-6.2\build-common-plugin.xml:684: The following error occurred while executing this line:
C:\Users\xxx\liferay-plugins-sdk-6.2\build-common.xml:2080: src 'C:\Users\xxx\liferay-plugins-sdk-6.2\portlets\extended-webform-portlet\${set-build-xml-var.return}' doesn't exist.



I solved this problem
i change

<property name="original.war.file" value="notifications-portlet-6.2.0.8.war" />

to single line:

<property name="original.war.file" value="notifications-portlet-6.2.0.8.war" />

and it worked.
thumbnail
Samuel Kong, modificado 8 Anos atrás.

RE: Web Form Sender

Liferay Legend Postagens: 1902 Data de Entrada: 10/03/08 Postagens Recentes
Dimas Purdinanto:
Well noted,

Do you happened to have web form war file for liferay ce 6.2?
I've grab it from here, i'm not sure if it is the correct one:
https://github.com/PolitAktiv/releases/blob/master/liferay/marketplace/6.2/web-form-portlet-6.2.0.3-ce-ga1-20140120092742162.war


The Web Form app (all all other apps/plugins) can be obtained from the Liferay Marketplace.

I have no idea if that WAR is good or not and If you're not sure, you shouldn't use it either. Bad things happen when you download files from random places.