Fórum
Pass JsonArray on liferay rest webservices method
Brijesh Desai, modificado 7 Anos atrás.
Pass JsonArray on liferay rest webservices method
Junior Member Postagens: 55 Data de Entrada: 22/10/14 Postagens Recentes
Hello Team,
I need to pass JsonArray on liferay rest webservice serviceImpl method.
It gives following error,
Unable to convert to type: com.liferay.portal.kernel.json.JSONArray
I need to call webservice by Jquery ajax call.
Thanks in advance for expert help
Kind regards,
Brijesh
I need to pass JsonArray on liferay rest webservice serviceImpl method.
It gives following error,
Unable to convert to type: com.liferay.portal.kernel.json.JSONArray
I need to call webservice by Jquery ajax call.
Thanks in advance for expert help
Kind regards,
Brijesh
Brijesh Desai, modificado 7 Anos atrás.
RE: Pass JsonArray on liferay rest webservices method
Junior Member Postagens: 55 Data de Entrada: 22/10/14 Postagens Recentes
I am in certain need of this,
Any expert suggestion needed,
thanks in advance
Any expert suggestion needed,
thanks in advance
Brijesh Desai, modificado 6 Anos atrás.
RE: Pass JsonArray on liferay rest webservices method
Junior Member Postagens: 55 Data de Entrada: 22/10/14 Postagens Recentes
I couldn't get this within liferay service builder but managed with rest java web services project with jersey client jars
Brijesh Desai, modificado 6 Anos atrás.
RE: Pass JsonArray on liferay rest webservices method
Junior Member Postagens: 55 Data de Entrada: 22/10/14 Postagens Recentes
If anyone come across this scenario, following code may help,
@Path("/WebLrDocMetadata")
public class CustomMetaDataService {
FileNodeDao fileNodeDao = new FileNodeDao();
@POST
@Path("/metaDataProperties")
@Produces("application/json")
public List<FileNode> getMetaDataProperties(@Valid List<FileNode> reqFileNodeDaoList) {
System.out.println("users 1111111111122222222222223333333333333 ----- " + reqFileNodeDaoList.size());
List<FileNode> resFileNodeDaoList = fileNodeDao.getAllFileNodesData(reqFileNodeDaoList);
return resFileNodeDaoList;
}
}