Build beautiful and interactive API documentation for ORDS

Image
In this blog post, I will show you how to quickly build beautiful and interactive API documentation for your Oracle APEX REST data sources using  swagger hub . Using APEX v23.1. I downloaded the  titanic data set  and loaded them into tables in my APEX instance, created some authorized restful services and published them using swagger hub. You can create a free account on swagger hub.   Check out my titanic swagger hub here ; Press Authorize. Username REST, password Glasgow123! I won't go through creating RESTful services and just show you the four I created that sit on top of the titanic data set; The GET is a very simple SQL query;      select * from TITANIC_DATA_SET_NEW A handy tip is to add comments, as there will appear on swagger hub, making your API self documenting; Once you have created your modules, press the Generate Swagger Doc button; This will generate an open API for you.  Copy the API and paste it into swagger hub This will generate the documentation; As mentioned b

Oracle APEX rename Region Display Selector tabs at runtime

This post describes how you can change an RDS tab name at runtime using a P0 value.  I am using APEX 19.2.

I have a form with a standard RDS with the following tabs.  The requirement is the Scholarship, Knowledge, Exchange & Impact tab name should change depending on the value of a P0 value. 


 This Scholarship, Knowledge, Exchange & Impact region has this static ID set;

and is named Scholarship, Knowledge, Exchange & Impact which is what displays on the tab;


Using JavaScript in Execute when page loads we check the PO value, if it is the target form we change the tab name to Scholarship when the page loads.

if ($v( "P0_FORM_ID" ) == '6001')
{
    $('#SKEI_REGION_tab > a > span').text('Scholarship');
    $('#SKEI_REGION > div.t-Region-header > div.t-Region-headerItems.t-Region-headerItems--title').text('Scholarship');    
}


Comments

Popular posts from this blog

Oracle APEX Interactive Grid colour cells based on a condition using JavaScript and CSS

Oracle APEX pretty checkbox item plugin

Build beautiful and interactive API documentation for ORDS