APEX 5.0: New Plug-in Attribute Types

Besides the Plug-In Attribute Enhancements described in my previous posting, we have also added new Attribute Types in Oracle APEX 5.0 for increased usability in Page Designer.

Link to Target Page/Url

If your Plug-in had to exposed a Link attribute in APEX 4.x you had to use an attribute of type Text. But this provided no input help for developers, they had to manually enter the APEX Url syntax f?p=&APP_ID.:... to link to a page and APEX had no knowledge that the attribute actually contains a link. In APEX 5.0 you can now use the new type Link to Target Page/Url which will use the Link Builder Dialog in Page Designer to make it a lot easier to link to a target page and specify the items to set.

If you develop a Region Type Plug-in where the Standard Attribute Region Source is SQL Statement is checked, you will also be able to specify the Include Columns in Items Picker flag. If you set it to Yes then the Link Builder Dialog will also expose the columns of the SQL statement entered in the region source. You can see an example below.

Note: Don’t forget to set the flag Substitute Attribute Values to false if you allow row level substitutions! Otherwise at runtime, APEX will automatically substitute your column &COLUMN_NAME. substitution with an empty string when calling your plug-in.

Link Builder Dialog

HTML

In the new release we have added Code Editors with Syntax Highlighting to Page Designer. With the new HTML attribute type your Plug-in can make use of it. The HTML type is useful when you want to expose advanced formatting where developers can enter a HTML expression. This attribute type also supports the Include Columns in Items Picker flag as described above. It’s exposed as quick pick next to the textarea.

Icon

APEX 5.0 has added support for the Font Awesome Icon Library. If your Plug-in wants to allow to specify custom icons, this type is ideal because in Page Designer developers will get the following nice dialog to pick an icon CSS class.

Icon Picker in Page Designer

Color

Want to allow to set custom colors? Then this type is the right one to use. In Page Designer you get a nice color picker and the quick pick menu next to the input field allows the pick colors which match together.

Color Picker

JavaScript Code

Same as with type HTML, with the new JavaScript Code type you can make use of the new Code Editor.

PL/SQL Expression Returning BOOLEAN

In addition to the existing PL/SQL Expression Returning VARCHAR2 the new attribute type expects that a BOOLEAN is returned. This information will be used by the Code Editor and Advisor to validate the entered PL/SQL Expression to return a boolean.

PL/SQL Function Body Returning BOOLEAN

In addition to the existing PL/SQL Function Body Returning VARCHAR2 the new attribute type expects that a BOOLEAN is returned. This information will be used by the Code Editor and Advisor to validate the entered PL/SQL Function Body to return a boolean.

Page Numbers

APEX 4.x already supported to enter a single Page Number, the new type now allows to specify multiple page numbers.

XML

Same as with type HTML, with the new XML type you can me use of the new Code Editor.

Screenshot of all new attribute types in action

New Custom Plug-in Attribute Types

Interested in more Plug-in Enhancements?

Check out my other blog postings of this series of Plug-in Enhancements in Oracle APEX 5.0.