List of usage examples for com.liferay.portal.kernel.service LayoutLocalServiceUtil addLayout
public static com.liferay.portal.kernel.model.Layout addLayout(long userId, long groupId, boolean privateLayout, long parentLayoutId, java.util.Map<java.util.Locale, String> nameMap, java.util.Map<java.util.Locale, String> titleMap, java.util.Map<java.util.Locale, String> descriptionMap, java.util.Map<java.util.Locale, String> keywordsMap, java.util.Map<java.util.Locale, String> robotsMap, String type, String typeSettings, boolean hidden, java.util.Map<java.util.Locale, String> friendlyURLMap, ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException
From source file:com.liferay.layout.test.LayoutFriendlyURLTest.java
License:Open Source License
protected void addLayout(long groupId, boolean privateLayout, Map<Locale, String> friendlyURLMap) throws Exception { ServiceContext serviceContext = ServiceContextTestUtil.getServiceContext(groupId); LayoutLocalServiceUtil.addLayout(TestPropsValues.getUserId(), groupId, privateLayout, LayoutConstants.DEFAULT_PARENT_LAYOUT_ID, RandomTestUtil.randomLocaleStringMap(), RandomTestUtil.randomLocaleStringMap(), RandomTestUtil.randomLocaleStringMap(), RandomTestUtil.randomLocaleStringMap(), RandomTestUtil.randomLocaleStringMap(), LayoutConstants.TYPE_PORTLET, StringPool.BLANK, false, friendlyURLMap, serviceContext); }
From source file:eu.gerhards.liferay.services.angular.service.impl.AngularLayoutServiceImpl.java
License:Open Source License
@Override public Layout createLayout(long groupId, boolean privateLayout, long parentLayoutId, Map<Locale, String> nameMap, Map<Locale, String> titleMap, Map<Locale, String> descriptionMap, Map<Locale, String> keywordsMap, Map<Locale, String> robotsMap, String type, String typeSettings, boolean hidden, Map<Locale, String> friendlyURLMap) throws PortalException { _log.info("Creating layout ... "); PortalPermissionUtil.check(getPermissionChecker(), ActionKeys.ADD_LAYOUT); _log.debug(" ... creating layout ..."); long userId = this.getGuestOrUserId(); com.liferay.portal.kernel.service.ServiceContext serviceContext = new com.liferay.portal.kernel.service.ServiceContext(); serviceContext.setUserId(this.getGuestOrUserId()); com.liferay.portal.kernel.model.Layout layout = LayoutLocalServiceUtil.addLayout(userId, groupId, privateLayout, parentLayoutId, nameMap, titleMap, descriptionMap, keywordsMap, robotsMap, type, typeSettings, hidden, friendlyURLMap, serviceContext); return layout; }