liferay

Best way to include Dynamic Data List Records in search in Liferay 6.1

百般思念 提交于 2019-12-08 09:31:46
问题 In Liferay 6.2 it is possible to set the Indexable option on fields of Dynamic Data List Definitions, thereby making them searchable (as explained in the Documentation for Liferay 6.2) I want to include DDL records in my search and have to use Liferay 6.1. I am wondering, what would be the best way to go about this. Right now I have looked into customizing the search, but Dynamic Data Lists are not being mentioned there as an option. I also looked at Creating an Indexer Post-Processor hook,

Mockito Liferay service testing

血红的双手。 提交于 2019-12-08 09:31:26
问题 I try testing my LocalServiceUtil classes, generated by service builder, with PowerMock but always getting 'null' or '0' from Util's methods. Test class @RunWith(PowerMockRunner.class) @PrepareForTest(EntityLocalServiceUtil.class) public class EntityTest { @Test public void testGetAnswer() throws PortalException, SystemException { PowerMockito.mockStatic(EntityLocalServiceUtil.class); assertEquals("hello", EntityLocalServiceUtil.getHello()); } } Util class contains public static java.lang

Velocity (VM) template request parameters: Getting GET variables

。_饼干妹妹 提交于 2019-12-08 09:31:12
问题 How do i access GET variables as passed in the URI in a VM template? This works only when loading the widget URL: $request.get("parameters").get("fav").get(0) I'm looking for a neat solution that works with friendly URLs. Here's my testing template: <br><br><br> #set($url = $request.attributes.CURRENT_URL) <h2>url: $url</h2> #set($favs = $url.split("fav=")) favs: $favs<br> favs.size(): $favs.size() <br> #if($favs.size() > 1) #set($fav1 = $favs.get(1).split("&").get(0)) fav1: $fav1<br> #else

Integrate Jsf application into Liferay

流过昼夜 提交于 2019-12-08 09:19:29
问题 I am developing a JSF 2.0 (with primefaces 3.2) application, and I want to integrate my JSF application inside Liferay. I am new to Liferay and the requirement is that the application will have entrance through Liferay. That means User will login, which should happen through Liferay. Then as I have seen in liferay basic videos after login in liferay 'Liferayhomepage' comes. Now please guide me, inside that homepage or after login I should be able to see a JSF application that I am developing,

Could not reserve enough space for object heap liferay tomcat

喜夏-厌秋 提交于 2019-12-08 07:24:25
问题 When I am running i am getting following exception repeatedly each time i try to run the program. Several ports (8005, 8080, 8009) required by Liferay v6.1 CE Server (Tomcat 7) at localhost are already in use. The server may already be running in another process, or a system process may be using the port. To start this server you will need to stop the other process or change the port number(s). I tired to increase my virtual memory(page size) and ram size. But it not workinge Currently, I

How to set the selected item in Alloy UI combo box?

江枫思渺然 提交于 2019-12-08 06:51:13
问题 After filling an Alloy UI combo box with items, How can I set the Selected Item? I mean, one of the items inserted into combo box should be the default selected item. How I can set that? 回答1: jsp: <aui:select name="selectedCity" label="City:" id="selectedCity"> <c:forEach items="${cities}" var="city"> <aui:option value="${city}" label="${city}" selected="${selectedCity == city}"/> </c:forEach> </aui:select> java: renderRequest.setAttribute("selectedCity", selectedCity); List<String> cities =

Peoplesoft screens in an iFrame

那年仲夏 提交于 2019-12-08 06:26:23
问题 Has anyone successfully integrated Peoplesoft screens or navigation via an iFrame in a third party app like Liferay or uPortal? We are trying to integrate Liferay Portal as a web front end and consume some of the PeopleSoft screens in an iFrame portlet. Both the Liferay Portal and Peoplsoft systems are on different top level domains. We are using Oracle Single Sign On on bot the applications. We have a couple of issues with this. The screens display in the iFrame - however, the JavaScript on

Liferay - Creating PDF and outputing to stream

北战南征 提交于 2019-12-08 05:32:24
Having a little trouble here. Basic premise is that I need to hit a button, generate HTML, create PDF, and throw into output-stream for download: <ice:commandButton title="Download" image="/images/dl.png" value="Download" action="#{bean.downloadPDF}"> </ice:commandButton> public void downloadPDF() throws IOException { PD4ML pdf = new PD4ML(); pdf.setPageSize(PD4Constants.LETTER); pdf.setPageInsets(new Insets(0, 0, 0, 0)); pdf.setHtmlWidth(1000); pdf.enableImgSplit(false); pdf.generateOutlines(false); File pdfFile = new File("tmp.pdf"); FileOutputStream fos = new FileOutputStream(pdfFile);

Why isn't Liferay Faces processing JSF portlet action events?

本秂侑毒 提交于 2019-12-08 04:05:16
问题 I am having issues with trying to use Liferay Faces along with any JSF components to fire action events. I've gone through the first part of Liferay's Developing JSF Portlets instruction page up until (but not including) the Internationalize JSF Portlets section with success. I went ahead and added some other JSF components with some success as well, however, events are not working. The goal of this example is to have a text box where the user can change the default text of "World", and a

Liferay development in Eclipse [closed]

半腔热情 提交于 2019-12-08 03:08:10
问题 As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance. Closed 7 years ago . I've seen that most of the documentation in the Liferay Wiki (concerning Eclipse plugins and the like) refers to Liferay version 4.x.