Skip to main content

Posts

Font Awesome with ADF

For people who are not aware of Font Awesome, it gives you scalable vector icons that can instantly be customized — size, color, drop shadow, and anything that can be done with the power of CSS. Their whole icon library is based on CSS not Images.

Recently, we had to build a tree table based on Webcenter content's folder and file structure. And we needed to show proper icons for files (pdf, word etc.) and folders. Which should look like this 


 We choose Font Awesome, because it is scalable and easy to use.

But front-end was ADF, so we were a bit sceptical  about how to integrate both. Turned out it was quite easy. Special thanks for Casper Overweter to do the implementation.

1. Create an ADF Skin :

Create a custom skin, via New > Gallery.
Base it on alta-v1 skin.



2. Download Font Awesome :

Download the zip form their website. It's free.



Unzip it inside the "customSkin" folder. Next to your CSS.



3. Extend Font Awesome to your customSkin CSS :

Add the following lines to your C…
Recent posts

Column Sorting in ADF TreeTable

Sorting of columns are not supported in ADF TreeTable by default.  The documentation of 12c says : Unlike the Table, the TreeTable does not support automatic sorting. The underlying TreeModel must support sorting by implementing it's sorting logic in the setSortCriteria(List criteria) method of the TreeModel.
But my client wanted sorting on the tree table on few columns. It was a good challenge and this is how I solved it.
Steps : 1. The treeModel is based on a managed bean. You cannot have the tree based on ADF-BC bindings. Simply because you need to override setSortCriteria(). 2. Added a few Comparators required for sorting of the columns.
Assumptions : 1. Code is in Java 8, using one of the lamda methods of Collections.
Lets get into the implementation details
1. Tree is based on a simple POJO. 
public class UCMContent {     // tree hierarchy in the list of child     private List<UCMContent> children = new ArrayList<>();     // attribute I need to explain for sorting     protected…

Secure your Node/Express REST APIs using Passport JS

Recently I have been involved in various discussions on how to make the REST APIs as secure as SOAP.
First of all, let me start with a very basic statement, about security, it doesn't depend on your Webservice type, be it REST or SOAP, your design decisions depicts whether they can be made secure or not.
In this example blog, I will use "Micro CRUD services for Oracle Database Cloud" APIs and implement (read attach) Passport's "local" authentication strategy, to make them secure.

Code in Github : LeasifyAPIs with Passport

What is Passport JS? (from Documentation)

Passport is authentication middleware for Node. It is designed to serve a singular purpose: authenticate requests. When writing modules, encapsulation is a virtue, so Passport delegates all other functionality to the application. This separation of concerns keeps code clean and maintainable, and makes Passport extremely easy to integrate into an application.

What are "strategies" in P…

Chatbots and Oracle Cloud Services

Thanks to Oracle A-Team, I had a chance to work with Chatbots.
3 pure NodeJS applications, on couple of Oracle Cloud platforms and Facebook messenger, and my chatbot was running.

Let me explain, the architecture a bit. To start with, following is the simple representation of how it works.