create databases first portal-ext.properties配置 hibernate.dialect=org.hibernate.dialect.PostgreSQLDialect hibernate.show_sql=true jdbc.default.driverClassName=org.postgresql.Driver jdbc.default.url=jdbc:postgresql://127.0.0.1:5432/lportal_default jdbc…
Provide helper methods to replace a string from multiple replaced strings to multiple substitutes import java.util.regex.Matcher; import java.util.regex.Pattern; public class StringHelper { /** * This is test method to replace a string from: * aaa >…
问题描述 在Portlet中,Javascript中通过Liferay.Language.get("key")的方式是拿不到自己添加的property的值,原因是Liferay.Language是从portal的language property中去找的,对于portlet的property是不理睬的,所以解决方案是通过hook去添加property,这里你不用担心portal property会造成性能的问题: Liferay provides a way to get the va…
Liferay ext project在install war包之后需要重启服务器,重启服务器中会执行ExtHotDeployListener中的逻辑,这里有一个坑,如果是第二次以后install ext war包,会发现新修改的文件不起作用,原因如下 ExtHotDeployListener.java protected void doInvokeDeploy(HotDeployEvent hotDeployEvent) throws Exception { ServletContext se…
Unexpected exception thrown when create new site: 09:47:10,114 ERROR [ajp-bio-8009-exec-113][JDBCExceptionReporter:82] Batch entry 0 insert into ResourcePermission (companyId, name, scope, primKey, roleId, ownerId, actionIds, resourcePermissionId) va…
EditFileEntryAction.java protected FileEntry updateFileEntry(PortletConfig portletConfig, ActionRequest actionRequest, ActionResponse actionResponse) throws Exception { /* 此处强转获取uploadPortletRequest,用于获取InputStream,也可以使用如下代码: * HttpServletRequest req…
以admin的帐号登陆 Navigation to Users and Organizations -> All Users 找到你要查看的user,点击Actions->Impersonate User,记录url中?之后的数据,likedoAsUserId=xxxxxx 进入你要到的页面,比‵my account',如果页面的url有parameter就在url最后加上&doAsUserId=xxxxxx,没有的话需要多加一个问号…
今天遇到liferay-ext无法卸载,log中显示卸载了,但是在App Manager中依然可以看到安装过的ext,其中一个原因是webapps下面的**-ext文件夹的权限只有root才能修改,将文件夹/*的权限改为普通用户也能修改即可.…
http://www.onjava.com/pub/a/onjava/2001/05/30/optimization.htmlComparing the performance of LinkedLists and ArrayLists (and Vectors) (Page last updated May 2001, Added 2001-06-18, Author Jack Shirazi, Publisher OnJava). Tips: ArrayList is faster than…
原文地址:[1]https://spring.io/blog/2013/07/02/spring-security-java-config-preview-introduction/ [2]https://spring.io/blog/2013/07/03/spring-security-java-config-preview-web-security/ [3]https://spring.io/blog/2013/07/04/spring-security-java-config-previe…