Foren

Home » Liferay Portal » English » 3. Development

Kombinierte Ansicht Flache Ansicht Baumansicht
Threads [ Zurück | Nächste ]
toggle
service builder sasmita swain 24. September 2012 23:05
RE: service builder Vishal Panchal 24. September 2012 23:15
RE: service builder Mazhar Alam 25. September 2012 00:03
RE: service builder sasmita swain 25. September 2012 01:54
RE: service builder Mazhar Alam 25. September 2012 02:07
RE: service builder sasmita swain 25. September 2012 02:18
RE: service builder sasmita swain 25. September 2012 02:22
RE: service builder Mazhar Alam 25. September 2012 02:29
RE: service builder sasmita swain 25. September 2012 02:39
RE: service builder Vishal Panchal 25. September 2012 02:45
RE: service builder sasmita swain 25. September 2012 02:56
RE: service builder sasmita swain 25. September 2012 02:58
RE: service builder Vishal Panchal 25. September 2012 03:05
RE: service builder sasmita swain 25. September 2012 03:24
RE: service builder Vishal Panchal 25. September 2012 04:43
RE: service builder sasmita swain 25. September 2012 20:54
RE: service builder Vishal Panchal 25. September 2012 22:00
RE: service builder sasmita swain 25. September 2012 22:43
RE: service builder sasmita swain 25. September 2012 23:11
RE: service builder Vishal Panchal 25. September 2012 23:15
RE: service builder sasmita swain 25. September 2012 23:26
RE: service builder Vishal Panchal 25. September 2012 23:29
RE: service builder sasmita swain 26. September 2012 00:08
RE: service builder Vishal Panchal 26. September 2012 00:56
RE: service builder sasmita swain 26. September 2012 01:45
RE: service builder sasmita swain 26. September 2012 02:36
RE: service builder sasmita swain 26. September 2012 02:37
RE: service builder Vishal Panchal 26. September 2012 03:42
RE: service builder sasmita swain 26. September 2012 04:02
RE: service builder Vishal Panchal 26. September 2012 04:12
RE: service builder sasmita swain 26. September 2012 04:24
RE: service builder Harish Kumar 26. September 2012 04:51
RE: service builder sasmita swain 26. September 2012 20:45
RE: service builder sasmita swain 26. September 2012 21:09
RE: service builder Vishal Panchal 26. September 2012 21:32
RE: service builder sasmita swain 26. September 2012 21:42
RE: service builder sasmita swain 26. September 2012 22:00
RE: service builder sasmita swain 26. September 2012 22:17
RE: service builder Chandrasekhar Kothuri 3. Oktober 2012 04:40
RE: service builder Vishal Panchal 25. September 2012 02:17
sasmita swain
service builder
24. September 2012 23:05
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

hi

i am using liferay 6.1..i have created own custom table using service builer.but i want to add extra column like user id given by liferay..how to add liferay existing column in custom table?

please give some suggestion

Thanks in advance
Sasmita
Vishal Panchal
RE: service builder
24. September 2012 23:15
Antwort

Vishal Panchal

Rang: Expert

Nachrichten: 279

Eintrittsdatum: 20. Mai 2012

Neue Beiträge

sasmita swain:
hi

i am using liferay 6.1..i have created own custom table using service builer.but i want to add extra column like user id given by liferay..how to add liferay existing column in custom table?

please give some suggestion

Thanks in advance
Sasmita


Hi sasmita ,

You can simply add one more field in your custom table.
Now , when you try to insert data in your table you can get current userId from themeDisplay.getUserId();
Is that your solution.?

Thanks & Regards,
Vishal R. Panchal
Mazhar Alam
RE: service builder
25. September 2012 00:03
Antwort

Mazhar Alam

Rang: Regular Member

Nachrichten: 201

Eintrittsdatum: 25. November 2011

Neue Beiträge

Agreed with Vishal's solution.
sasmita swain
RE: service builder
25. September 2012 01:54
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

thanks for your reply

where should i write themedisplay.getUserId();?
can i create userid extra column direct from table?
Mazhar Alam
RE: service builder
25. September 2012 02:07
Antwort

Mazhar Alam

Rang: Regular Member

Nachrichten: 201

Eintrittsdatum: 25. November 2011

Neue Beiträge

You have to create userId field within your service.xml and when you build service a column userId will be added to your table..
Then when you try to insert various values into your table at that time use themedisplay.getUserId() and set its value in the respective userId field.
Vishal Panchal
RE: service builder
25. September 2012 02:17
Antwort

Vishal Panchal

Rang: Expert

Nachrichten: 279

Eintrittsdatum: 20. Mai 2012

Neue Beiträge

sasmita swain:
thanks for your reply

where should i write themedisplay.getUserId();?
can i create userid extra column direct from table?



Hi sasmita swain,

As per Mazhar Alam,
you can add one more property in your service.xml
e.g. <column name="userId" type="long"/>
Now when you will insert some value in your custom table at that time you will need too provide userId value as you providing values to other fields.
so this time you need to use themeDisplay.getUserId() .

Thanks & Regards,
Vishal R. Panchal
sasmita swain
RE: service builder
25. September 2012 02:18
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

long userId = themeDisplay.getUserId();
i am using above code.but it is not comming. userid is not inserting. from user table what liferay has given
sasmita swain
RE: service builder
25. September 2012 02:22
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

sasmita swain:
long userId = themeDisplay.getUserId();
i am using above code.but it is not comming. userid is not inserting. from user table what liferay has given
Anhänge: emp1-portlet.rar (126,2k)
Mazhar Alam
RE: service builder
25. September 2012 02:29
Antwort

Mazhar Alam

Rang: Regular Member

Nachrichten: 201

Eintrittsdatum: 25. November 2011

Neue Beiträge

/*to get userId*/

ThemeDisplay themeDisplay = (ThemeDisplay)actionRequest.getAttribute(WebKeys.THEME_DISPLAY);
long userid= themeDisplay.getUserId();

/*to insert*/

Use the impl class -
like-

Yourentityimpl impl = new Yourentityimpl();
impl.setUserId(userid);


Thats it!!!!!
sasmita swain
RE: service builder
25. September 2012 02:39
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

thanks

i got that user id..but i want custom user id means when a user login ,that user id go to user database.that user id i want to fetch in my custom table.by default 10196 userid is comming for test@liferay.com..
Vishal Panchal
RE: service builder
25. September 2012 02:45
Antwort

Vishal Panchal

Rang: Expert

Nachrichten: 279

Eintrittsdatum: 20. Mai 2012

Neue Beiträge

sasmita swain:
thanks

i got that user id..but i want custom user id means when a user login ,that user id go to user database.that user id i want to fetch in my custom table.by default 10196 userid is comming for test@liferay.com..


By Using themeDisplay.getUserId(); you will get the userId of a User who is currently logged In.

Thanks & Regards,
Vishal R. Panchal
sasmita swain
RE: service builder
25. September 2012 02:56
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

ya i have used that one..but it is comming default userid
sasmita swain
RE: service builder
25. September 2012 02:58
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

here my attached file
Anhänge: emp1-portlet.rar (126,2k)
Vishal Panchal
RE: service builder
25. September 2012 03:05
Antwort

Vishal Panchal

Rang: Expert

Nachrichten: 279

Eintrittsdatum: 20. Mai 2012

Neue Beiträge

sasmita swain:
ya i have used that one..but it is comming default userid


Are you inserting by login as test@liferay.com..?
If yes than create new user and than try to insert again you will have different userId as same as newly created user's Id.


Thanks & Regards,
Vishal R. Panchal
sasmita swain
RE: service builder
25. September 2012 03:24
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

thanks

i got userid..anather thing is i want to retrieve empname,emp salary based on userid..e.g-userid=16727,emp name=sasmita.emp sal=20000.i want to retreive these in my form

can you tell me how to do?
Vishal Panchal
RE: service builder
25. September 2012 04:43
Antwort

Vishal Panchal

Rang: Expert

Nachrichten: 279

Eintrittsdatum: 20. Mai 2012

Neue Beiträge

sasmita swain:
thanks

i got userid..anather thing is i want to retrieve empname,emp salary based on userid..e.g-userid=16727,emp name=sasmita.emp sal=20000.i want to retreive these in my form

can you tell me how to do?


All You have to do is make finder in service.xml for the column userId.


Thanks & Regards,
Vishal R. Panchal
sasmita swain
RE: service builder
25. September 2012 20:54
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

hi
i have done same way.ut it is not retrieving.can u give me codes?
Vishal Panchal
RE: service builder
25. September 2012 22:00
Antwort

Vishal Panchal

Rang: Expert

Nachrichten: 279

Eintrittsdatum: 20. Mai 2012

Neue Beiträge

sasmita swain:
hi
i have done same way.ut it is not retrieving.can u give me codes?


Hi sasmita swain , as per your code in your service.xml you have already added finder method for the column empName

same way you have to add finder on column as below
<finder name="UserId" return-type="Collection">
<finder-column name="userId" />
</finder>

Than build service.

Next Go to *LocalServiceimpl.java add your finder code
public List<Employee> findByUserId(long userId) throws SystemException
{
List<Employee> empObj=employeePersistence.findByUserId(userId);

return empObj;
}

Now again build service again.
So you have findByUserId method accessible through EmployeeLocalServiceUtil.findByUserId(userId)



Thanks & Regards,
Vishal R. Panchal
sasmita swain
RE: service builder
25. September 2012 22:43
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

hi vishal
i have done same way but it is not comming.can you check my code.check my attached file.

Thanks
Anhänge: kusum-portlet.rar (116,0k)
sasmita swain
RE: service builder
25. September 2012 23:11
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

hi vishal
after build impl class,findByUserId accessible through universityLocalServiceUtil.

<%List<University> uni=UniversityLocalServiceUtil.findByUserId(10196);%>
<aui:input type="text" label="Name" name="nm" value=<%=uni.get(index);%>"/> but uni.getuniversityName() is not comming
Vishal Panchal
RE: service builder
25. September 2012 23:15
Antwort

Vishal Panchal

Rang: Expert

Nachrichten: 279

Eintrittsdatum: 20. Mai 2012

Neue Beiträge

sasmita swain:
hi vishal
after build impl class,findByUserId accessible through universityLocalServiceUtil.

<%List<University> uni=UniversityLocalServiceUtil.findByUserId(10196);%>
<aui:input type="text" label="Name" name="nm" value=<%=uni.get(index);%>"/> but uni.getuniversityName() is not comming


Hi, Try this

<%List<University> uni=UniversityLocalServiceUtil.findByUserId(10196);%>
<aui:input type="text" label="Name" name="nm" value=<%=uni.get(0).getuniversityName();%>"/>


Thanks& Regards,
Vishal R. Panchal
sasmita swain
RE: service builder
25. September 2012 23:26
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

thanks vishal

i got it.but why it is inserting multiple times in database?
2.i want to keep session of userid.,i have given handcoding userid

Thanks
Vishal Panchal
RE: service builder
25. September 2012 23:29
Antwort

Vishal Panchal

Rang: Expert

Nachrichten: 279

Eintrittsdatum: 20. Mai 2012

Neue Beiträge

sasmita swain:
thanks vishal

i got it.but why it is inserting multiple times in database?
2.i want to keep session of userid.,i have given handcoding userid

Thanks


Hi ,sasmita

<%
ThemeDisplay themeDisplay = (ThemeDisplay)actionRequest.getAttribute(WebKeys.THEME_DISPLAY);
List<University> uni=UniversityLocalServiceUtil.findByUserId(themeDisplay.getUserId());
%>
<aui:input type="text" label="Name" name="nm" value=<%=uni.get(0).getuniversityName();%>"/>

By doing this you need not to hard-code userid everytime.!

Thanks & Regards,
Vishal R. Panchal
sasmita swain
RE: service builder
26. September 2012 00:08
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

hi
after adding this following errors are comming
06:59:46,877 ERROR [PortletRequestDispatcherImpl:108] org.apache.jasper.JasperException: An exception occurred processing JSP page /html/celos/view.jsp at line 32

29: <aui:fieldset>
30:
31:
32: <% ThemeDisplay themeDisplay = (ThemeDisplay)actionRequest.getAttribute(WebKeys.THEME_DISPLAY);
33: List<University> uni=UniversityLocalServiceUtil.findByUserId(themeDisplay.getUserId());
34: %>
35: <aui:input type="text" label="Name" name="nm" value="<%=uni.get(0).getUniName()%>"/>


Stacktrace:
org.apache.jasper.JasperException: An exception occurred processing JSP page /html/celos/view.jsp at line 32

29: <aui:fieldset>
30:
31:
32: <% ThemeDisplay themeDisplay = (ThemeDisplay)actionRequest.getAttribute(WebKeys.THEME_DISPLAY);
33: List<University> uni=UniversityLocalServiceUtil.findByUserId(themeDisplay.getUserId());
34: %>
35: <aui:input type="text" label="Name" name="nm" value="<%=uni.get(0).getUniName()%>"/>


Stacktrace:
at org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:568)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:470)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:72)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:113)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.doFilter(InvokerFilter.java:70)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:684)
at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:593)
at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:530)
at com.liferay.portlet.PortletRequestDispatcherImpl.dispatch(PortletRequestDispatcherImpl.java:316)
at com.liferay.portlet.PortletRequestDispatcherImpl.include(PortletRequestDispatcherImpl.java:105)
at com.liferay.util.bridges.mvc.MVCPortlet.include(MVCPortlet.java:366)
at com.liferay.util.bridges.mvc.MVCPortlet.include(MVCPortlet.java:382)
at com.liferay.util.bridges.mvc.MVCPortlet.doView(MVCPortlet.java:145)
at com.liferay.portal.kernel.portlet.LiferayPortlet.doDispatch(LiferayPortlet.java:211)
at com.liferay.util.bridges.mvc.MVCPortlet.doDispatch(MVCPortlet.java:318)
at javax.portlet.GenericPortlet.render(GenericPortlet.java:233)
at com.liferay.portlet.FilterChainImpl.doFilter(FilterChainImpl.java:100)
at com.liferay.portal.kernel.portlet.PortletFilterUtil.doFilter(PortletFilterUtil.java:64)
at com.liferay.portal.kernel.servlet.PortletServlet.service(PortletServlet.java:93)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:72)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.doFilter(InvokerFilter.java:70)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:684)
at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:593)
at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:530)
at com.liferay.portlet.InvokerPortletImpl.invoke(InvokerPortletImpl.java:637)
at com.liferay.portlet.InvokerPortletImpl.invokeRender(InvokerPortletImpl.java:722)
at com.liferay.portlet.InvokerPortletImpl.render(InvokerPortletImpl.java:426)
at org.apache.jsp.html.portal.render_005fportlet_jsp._jspService(render_005fportlet_jsp.java:1215)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:72)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.doFilter(InvokerFilter.java:70)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:684)
at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:593)
at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:530)
at com.liferay.portal.util.PortalImpl.renderPortlet(PortalImpl.java:4735)
at com.liferay.portal.util.PortalUtil.renderPortlet(PortalUtil.java:1455)
at com.liferay.portlet.layoutconfiguration.util.RuntimePortletImpl.processPortlet(RuntimePortletImpl.java:213)
at com.liferay.portlet.layoutconfiguration.util.RuntimePortletImpl.processPortlet(RuntimePortletImpl.java:148)
at com.liferay.portlet.layoutconfiguration.util.RuntimePortletImpl.processTemplate(RuntimePortletImpl.java:309)
at com.liferay.portlet.layoutconfiguration.util.RuntimePortletImpl.processTemplate(RuntimePortletImpl.java:234)
at com.liferay.portlet.layoutconfiguration.util.RuntimePortletUtil.processTemplate(RuntimePortletUtil.java:106)
at org.apache.jsp.html.portal.layout.view.portlet_jsp._jspService(portlet_jsp.java:512)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:72)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.doFilter(InvokerFilter.java:70)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:684)
at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:593)
at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:530)
at com.liferay.portal.action.LayoutAction.includeLayoutContent(LayoutAction.java:412)
at com.liferay.portal.action.LayoutAction.processLayout(LayoutAction.java:680)
at com.liferay.portal.action.LayoutAction.execute(LayoutAction.java:244)
at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431)
at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)
at com.liferay.portal.struts.PortalRequestProcessor.process(PortalRequestProcessor.java:174)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:432)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:641)
at com.liferay.portal.servlet.MainServlet.callParentService(MainServlet.java:533)
at com.liferay.portal.servlet.MainServlet.service(MainServlet.java:510)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:72)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:113)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:113)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:113)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.secure.SecureFilter.processFilter(SecureFilter.java:201)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.autologin.AutoLoginFilter.processFilter(AutoLoginFilter.java:240)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.doFilter(InvokerFilter.java:70)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:684)
at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:471)
at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:402)
at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:329)
at com.liferay.portal.servlet.FriendlyURLServlet.service(FriendlyURLServlet.java:135)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:72)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.strip.StripFilter.processFilter(StripFilter.java:304)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:113)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.gzip.GZipFilter.processFilter(GZipFilter.java:123)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.secure.SecureFilter.processFilter(SecureFilter.java:201)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.i18n.I18nFilter.processFilter(I18nFilter.java:241)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.etag.ETagFilter.processFilter(ETagFilter.java:55)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.autologin.AutoLoginFilter.processFilter(AutoLoginFilter.java:240)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.sso.ntlm.NtlmPostFilter.processFilter(NtlmPostFilter.java:83)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.sharepoint.SharepointFilter.processFilter(SharepointFilter.java:80)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.virtualhost.VirtualHostFilter.processFilter(VirtualHostFilter.java:208)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDirectCallFilter(InvokerFilterChain.java:184)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:92)
at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:738)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDirectCallFilter(InvokerFilterChain.java:164)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:92)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDirectCallFilter(InvokerFilterChain.java:164)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:92)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDirectCallFilter(InvokerFilterChain.java:184)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:92)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.doFilter(InvokerFilter.java:70)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:224)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:169)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:928)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407)
at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:987)
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:539)
at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:300)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.NullPointerException
at org.apache.jsp.html.celos.view_jsp._jspService(view_jsp.java:188)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
... 190 more
06:59:46,878 ERROR [PortletServlet:97] javax.portlet.PortletException: org.apache.jasper.JasperException: An exception occurred processing JSP page /html/celos/view.jsp at line 32
Vishal Panchal
RE: service builder
26. September 2012 00:56
Antwort

Vishal Panchal

Rang: Expert

Nachrichten: 279

Eintrittsdatum: 20. Mai 2012

Neue Beiträge

Hi ,

In your jsp page
Add two lines

<%@ taglib uri="http://liferay.com/tld/theme" prefix="liferay-theme" %>
<liferay-theme:defineObjects />
and than your code.
<% List<University> uni=UniversityLocalServiceUtil.findByUserId(themeDisplay.getUserId()); %>
<aui:input type="text" label="Name" name="nm" value="<%=uni.get(0).getUniName()%>"/>

Thanks,
Vishal R. Panchal
sasmita swain
RE: service builder
26. September 2012 01:45
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

error:
<% List<University> uni=UniversityLocalServiceUtil.findByUserId(themeDisplay.getUserId());%>
34:
35: <aui:input type="text" label="Name" name="nm" value="<%=uni.get(0).getUniName() %>"/>
36: <aui:input type="text" label="salary" name="sal" value="<%=uni.get(0).getUnisal() %>"/>
37: <aui:button type="submit" value="Save" />
38: </aui:fieldset>


Stacktrace:
at com.liferay.portlet.PortletRequestDispatcherImpl.include(PortletRequestDispatcherImpl.java:110)
at com.liferay.util.bridges.mvc.MVCPortlet.include(MVCPortlet.java:366)
at com.liferay.util.bridges.mvc.MVCPortlet.include(MVCPortlet.java:382)
at com.liferay.util.bridges.mvc.MVCPortlet.doView(MVCPortlet.java:145)
at com.liferay.portal.kernel.portlet.LiferayPortlet.doDispatch(LiferayPortlet.java:211)
at com.liferay.util.bridges.mvc.MVCPortlet.doDispatch(MVCPortlet.java:318)
at javax.portlet.GenericPortlet.render(GenericPortlet.java:233)
at com.liferay.portlet.FilterChainImpl.doFilter(FilterChainImpl.java:100)
at com.liferay.portal.kernel.portlet.PortletFilterUtil.doFilter(PortletFilterUtil.java:64)
at com.liferay.portal.kernel.servlet.PortletServlet.service(PortletServlet.java:93)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:72)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.doFilter(InvokerFilter.java:70)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:684)
at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:593)
at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:530)
at com.liferay.portlet.InvokerPortletImpl.invoke(InvokerPortletImpl.java:637)
at com.liferay.portlet.InvokerPortletImpl.invokeRender(InvokerPortletImpl.java:722)
at com.liferay.portlet.InvokerPortletImpl.render(InvokerPortletImpl.java:426)
at org.apache.jsp.html.portal.render_005fportlet_jsp._jspService(render_005fportlet_jsp.java:1215)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:72)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.doFilter(InvokerFilter.java:70)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:684)
at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:593)
at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:530)
at com.liferay.portal.util.PortalImpl.renderPortlet(PortalImpl.java:4735)
at com.liferay.portal.util.PortalUtil.renderPortlet(PortalUtil.java:1455)
at com.liferay.portlet.layoutconfiguration.util.RuntimePortletImpl.processPortlet(RuntimePortletImpl.java:213)
at com.liferay.portlet.layoutconfiguration.util.RuntimePortletImpl.processPortlet(RuntimePortletImpl.java:148)
at com.liferay.portlet.layoutconfiguration.util.RuntimePortletImpl.processTemplate(RuntimePortletImpl.java:309)
at com.liferay.portlet.layoutconfiguration.util.RuntimePortletImpl.processTemplate(RuntimePortletImpl.java:234)
at com.liferay.portlet.layoutconfiguration.util.RuntimePortletUtil.processTemplate(RuntimePortletUtil.java:106)
at org.apache.jsp.html.portal.layout.view.portlet_jsp._jspService(portlet_jsp.java:512)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:72)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.doFilter(InvokerFilter.java:70)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:684)
at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:593)
at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:530)
at com.liferay.portal.action.LayoutAction.includeLayoutContent(LayoutAction.java:412)
at com.liferay.portal.action.LayoutAction.processLayout(LayoutAction.java:680)
at com.liferay.portal.action.LayoutAction.execute(LayoutAction.java:244)
at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431)
at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)
at com.liferay.portal.struts.PortalRequestProcessor.process(PortalRequestProcessor.java:174)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:621)
at com.liferay.portal.servlet.MainServlet.callParentService(MainServlet.java:533)
at com.liferay.portal.servlet.MainServlet.service(MainServlet.java:510)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:72)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:113)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:113)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:113)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.secure.SecureFilter.processFilter(SecureFilter.java:201)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.autologin.AutoLoginFilter.processFilter(AutoLoginFilter.java:240)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.doFilter(InvokerFilter.java:70)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:684)
at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:471)
at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:402)
at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:329)
at com.liferay.portal.servlet.FriendlyURLServlet.service(FriendlyURLServlet.java:135)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:72)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.strip.StripFilter.processFilter(StripFilter.java:304)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:113)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.gzip.GZipFilter.processFilter(GZipFilter.java:123)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.secure.SecureFilter.processFilter(SecureFilter.java:201)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.i18n.I18nFilter.processFilter(I18nFilter.java:241)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.etag.ETagFilter.processFilter(ETagFilter.java:55)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.autologin.AutoLoginFilter.processFilter(AutoLoginFilter.java:240)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.sso.ntlm.NtlmPostFilter.processFilter(NtlmPostFilter.java:83)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.sharepoint.SharepointFilter.processFilter(SharepointFilter.java:80)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
at com.liferay.portal.servlet.filters.virtualhost.VirtualHostFilter.processFilter(VirtualHostFilter.java:208)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDirectCallFilter(InvokerFilterChain.java:184)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:92)
at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:738)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDirectCallFilter(InvokerFilterChain.java:164)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:92)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDirectCallFilter(InvokerFilterChain.java:164)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:92)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDirectCallFilter(InvokerFilterChain.java:184)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:92)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.doFilter(InvokerFilter.java:70)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:224)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:169)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:928)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407)
at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:987)
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:539)
at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:300)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
sasmita swain
RE: service builder
26. September 2012 02:36
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

hi

when i am loging by different user my portlet is not available means temporarily unavailable..but when i am loging by test@liferay.com it is working

Thanks
sasmita swain
RE: service builder
26. September 2012 02:37
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

hi

when i am loging by different user my portlet is not available means temporarily unavailable..but when i am loging by test@liferay.com it is working
[render_portlet_jsp:154] java.lang.IndexOutOfBoundsException: Index: 0
Thanks
Vishal Panchal
RE: service builder
26. September 2012 03:42
Antwort

Vishal Panchal

Rang: Expert

Nachrichten: 279

Eintrittsdatum: 20. Mai 2012

Neue Beiträge

sasmita swain:
hi

when i am loging by different user my portlet is not available means temporarily unavailable..but when i am loging by test@liferay.com it is working
[render_portlet_jsp:154] java.lang.IndexOutOfBoundsException: Index: 0
Thanks

Hi ,

Exactly what is happening when you logged in as different user you are getting different userID by using themeDisplay.getUserId();
let's assume you r getting 1234 userId fro different user.
now when you try to execute below code.
<%
List<University> uni=UniversityLocalServiceUtil.findByUserId(themeDisplay.getUserId());
%>

than you will have a null uni object because in database you dont have any record whose column userId has value 1234(i mean userId of newly created user)

so as you r getting null uni and your also trying to fetch data from null object by "uni.get(0).getUniName()" so thats why you are getting this java.lang.IndexOutOfBoundsException: Index: 0.

<aui:input type="text" label="Name" name="nm" value="<%=uni.get(0).getUniName() %>"/>

So make sure you have at least one record in your database with the newly created user's userId.
or
you have to place an if condition on the below lines,
<aui:input type="text" label="Name" name="nm" value="<%=uni.get(0).getUniName() %>"/>
<aui:input type="text" label="salary" name="sal" value="<%=uni.get(0).getUnisal() %>"/>
That above lines will only be execute if the uni object is not null.

Thanks,
Vishal R. Panchal
sasmita swain
RE: service builder
26. September 2012 04:02
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

hi
when i am using hard coding it is retreiving.but after giving themedisplay.userid(),it is showing error.newly user is already there.
when i am creating new account new user id is not directly insert in to db.
can give if condition code
Anhänge: kusum-portlet.rar (116,4k)
Vishal Panchal
RE: service builder
26. September 2012 04:12
Antwort

Vishal Panchal

Rang: Expert

Nachrichten: 279

Eintrittsdatum: 20. Mai 2012

Neue Beiträge

Hi ,
modify your code accordingly.
add taglib : <%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>

<%
List<University> uni=UniversityLocalServiceUtil.findByUserId(themeDisplay.getUserId());
%>

<c:if test="${ not empty uni}">

<aui:input type="text" label="Name" name="nm" value="<%=uni.get(0).getUniName() %>"/>
<aui:input type="text" label="Name" name="nm" value="<%=uni.get(0).getUniName() %>"/>
<aui:input type="text" label="salary" name="sal" value="<%=uni.get(0).getUnisal() %>"/>

</c:if>

<aui:button type="submit" value="Save" />
sasmita swain
RE: service builder
26. September 2012 04:24
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

[can not find taglib
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>
Harish Kumar
RE: service builder
26. September 2012 04:51
Antwort

Harish Kumar

Rang: Expert

Nachrichten: 444

Eintrittsdatum: 31. Juli 2010

Neue Beiträge

Add portal-dependency-jars=\
jstl-api.jar,\
jstl-impl.jar,\

in liferay-plugin-package.properties file.
sasmita swain
RE: service builder
26. September 2012 20:45
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

hi
after adding jar files i am getting following errors
<c:if test="${ not empty uni}">
<aui:input type="text" label="Name" name="nm" value="<%=uni.get(0).getUniName() %>"/>
<aui:input type="text" label="salary" name="sal" value="<%=uni.get(0).getUnisal() %>"/>
<aui:button type="submit" value="Save" />
</c:if>
03:39:29,934 ERROR [render_portlet_jsp:154] org.apache.jasper.JasperException: /html/celos/view.jsp (line: 35, column: 0) According to TLD or attribute directive in tag file, attribute test does not accept any expressions
at org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:42)
at org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:408)
at org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:149)
at org.apache.jasper.compiler.Validator$ValidateVisitor.checkXmlAttributes(Validator.java:1235)
at org.apache.jasper.compiler.Validator$ValidateVisitor.visit(Validator.java:870)
at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java:1539)
at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2376)
at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2428)
at org.apache.jasper.compiler.Validator$ValidateVisitor.visit(Validator.java:889)
at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java:1539)
at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2376)
at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2428)
at org.apache.jasper.compiler.Validator$ValidateVisitor.visit(Validator.java:889)
at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java:1539)
at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2376)
at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2428)
at org.apache.jasper.compiler.Node$Visitor.visit(Node.java:2434)
at org.apache.jasper.compiler.Node$Root.accept(Node.java:475)
at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2376)
at org.apache.jasper.compiler.Validator.validateExDirectives(Validator.java:1790)

Thanks
sasmita swain
RE: service builder
26. September 2012 21:09
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

hi vishal
Thanks a lot. i got solution.but one thing is when a new user create new account his user id is not inserting in custom database table.showing error portlet is unavailable.
is there any solution to solve this problem???

Thanks
Vishal Panchal
RE: service builder
26. September 2012 21:32
Antwort

Vishal Panchal

Rang: Expert

Nachrichten: 279

Eintrittsdatum: 20. Mai 2012

Neue Beiträge

sasmita swain:
hi vishal
Thanks a lot. i got solution.but one thing is when a new user create new account his user id is not inserting in custom database table.showing error portlet is unavailable.
is there any solution to solve this problem???

Thanks


Hi sasmita ,
See when new user is created that time the userId will be generated and inserted in users_ table and some other tables like user_roles etc but not in your custom table.
But in your case you have to add the a single row in your custom table by logged In as the newly created user.


Thanks & Regards,
Vishal R. Panchal
sasmita swain
RE: service builder
26. September 2012 21:42
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

hi
only i have to add new column and then insert or what?
can you give example with code
can you tell me briefly??
Thanks
sasmita swain
RE: service builder
26. September 2012 22:00
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

hi vishal
i got that solution.we need not create new column.some logic t wrote in <aui:input type="text" label="Name" name="nm" value='<%=uni.size()>0?uni.get(0).getUniName():"" %>'/>

then it working fine...new user can login and it is inserting to custom db.

Thanks
sasmita swain
RE: service builder
26. September 2012 22:17
Antwort

sasmita swain

Rang: Regular Member

Nachrichten: 185

Eintrittsdatum: 24. Februar 2012

Neue Beiträge

hi

when i am clicking multiple times save button it is inserting multiple times in db.but i want to keep one time in db byclicking save button multiple times

Thanks
Chandrasekhar Kothuri
RE: service builder
3. Oktober 2012 04:40
Antwort

Chandrasekhar Kothuri

Rang: Regular Member

Nachrichten: 149

Eintrittsdatum: 6. Juli 2009

Neue Beiträge

Check the following link:


http://www.liferay.com/community/forums/-/message_boards/message/9175840