Foros de discusión

how to check the organization name is already exists via api??

Eswaran R, modificado hace 9 años.

how to check the organization name is already exists via api??

Junior Member Mensajes: 82 Fecha de incorporación: 29/12/14 Mensajes recientes
Hi friend ,,

i am already get error for Screen name and Email id
// email check
String email="welcome@gmail.com";
long companyId=PortalUtil.getDefaultCompanyId();
User usersss= UserLocalServiceUtil.getUserByEmailAddress(companyId,email);

// screen name check
String screen="welcome";
long companyId=PortalUtil.getDefaultCompanyId();
User usersss= UserLocalServiceUtil.getUserByEmailAddress(companyId,screen);


my question how to check the organization name is already exists ????

thanks
Regards
Eswaran R
thumbnail
Pankaj Kathiriya, modificado hace 9 años.

RE: how to check the organization name is already exists via api??

Liferay Master Mensajes: 722 Fecha de incorporación: 5/08/10 Mensajes recientes
I am not sure what you are trying to achieve but, you can get Organization by its name using method below.

OrganizationLocalServiceUtil.getOrganization(long companyId, String name)
Eswaran R, modificado hace 9 años.

RE: how to check the organization name is already exists via api??

Junior Member Mensajes: 82 Fecha de incorporación: 29/12/14 Mensajes recientes
hi Pankaj Kathiriya,

first of all thanks for reply ..

i am check now ...

regards

Eswaran R