thumbnail

Introduction Liferay Objects is a cool no-code feature that allows us to define full-featured entities - integrated with all Liferay Frameworks and providing auto-generated Headless API for accessing and updating objects information. Liferay Forms is a powerful Liferay tool, providing a lot of possibilities for building and configuring custom forms with advanced rules...

thumbnail

Introduction Roles and Permissions is one of Liferay foundation features that allows to develop secure and reliable applications. It's crucial to organize them in a structured, transparent and easy-manageable way. Sometimes it can be hard, especially when it comes to hierarchical entities. Fortunately, Liferay has a dedicated feature for this case - Permissions Propagator. ...

thumbnail

Introduction During a Liferay project implementation we often have similar pieces of UI and functionality in different widgets - and that's not surprising, as UI/UX should be consistent across the entire portal. We, as developers, try to avoid code duplication in different ways: Create a "common" OSGi service that can be used in multiple widgets; Create a...

thumbnail

Introduction Several months ago I wrote an article about Site Initializers (read if you missed it 😉). It describes how to setup content using Bundle Site Initializer. And it also highlights (in article itself and in comments) that the main issue with Site Initializers was missing "update" support: if any changes to content required - site should be re-created from the...

thumbnail

Introduction It has always been a discussion, whether content creation is a development activity. Even if it's considered as not - we, as developers, often need to set up content: - on local environments; - on DEV servers (to demonstrate some functionality during development); - even on PROD servers (to deliver the initial content for customers). Manual content setup on each...

thumbnail

Overview In this blog I'll explain how to implement a custom Headless API module, configure an OAuth2 authorization and consume the API.  We’ll implement the Headless API for “App manager” functionality with endpoints to get the list of apps, get app details, create/update/delete the app (“App” here is a model, describing some external application with the following...

thumbnail

Overview For the many years Liferay theme was the only way for defining the portal appearance. Usually, when a new project started (or customer requested a new site with a brand new design) - development  began with a new theme creation. With themes it's possible to define the overall styling and the basic page structure. Also, we can define the configuration options with...

thumbnail

Overview   Search is one of the fundamental Liferay features, which provides users with the possibility to quickly find the content they look for. It’s powerful, pretty much configurable, and flexible.  However, during implementation of the latest project for our client we run into a bunch of issues. Some of them were Liferay bugs or missing functionality, other ones - configuration...

thumbnail

Liferay has  an OOTB SSO configuration, and can be configured to use Keycloak as the Authorization Provider.  This article explains, how to make such configuration on Liferay and Keycloak side: https://lifedev-solutions.blogspot.com/2019/10/liferay-keycloak-integration-using.html However, there are two limitations in this approach: Keycloak can't be set as a...

thumbnail

Problem: Running Liferay 7.1 from IDEA in Debug mode throws the following error by default: java.lang.NoClassDefFoundError: com/intellij/rt/debugger/agent/CaptureStorage However, Run mode works without any issues.   Fix: Disable Instrumenting agent in "Settings | Build, Execution, Deployment | Debugger | Async Stacktraces": Hope, this will help :) ...

thumbnail

Introduction   In this blog I'll describe how to migrate data and code from Liferay 6.2 to 7.1. Blog overview: I. Prerequisites - description of demo project and data/content to be migrated. II. Prepare for migration - recommendations for Liferay 6.2 preparation for migration, Liferay 7.1...

thumbnail

Liferay has different types of pages. The default one is Layout - it’s standard, empty by default page, which is displayed in navigation menu. Portlets may be added to such page, themes and layouts may be also applied to this type of page. In most cases this page type is used. But there are different page types, here are they: Link to a Page of This Site -...

thumbnail

To make some custom class available inside a theme velocity template, you need to put it's instance into com.liferay.portal.kernel.util.WebKeys#VM_VARIABLES request attribute. And it will be populated to the velocity context automatically (in com.liferay.portal.velocity.VelocityTemplateContextHelper#prepare method), see: // Insert custom vm variables Map<String,...

thumbnail

Step 1. Liferay Migration to 6.0.6   1. Create 5.2.3 DB dump (db.sql). 2. Create database for LR 6.0.6 (db606). 3. Load 5.2.3 dump into 6.0.6 database: mysql -uroot -p1 db606 < db.sql; Delete all database views (if any). 4. Unzip clean Liferay 6.0.6. 5. Delete all folders from 'webapps' (except 'ROOT' and 'tunnel-web'); delete jre from...