Supporting JavaScript

To support each HTML file is a corresponding JavaScript file. The JavaScript implements the process of initializing the page and handling events occur such as when the UI is closed. The code needs to follow the same pattern to allow it to be effectively injected into the framework. To modify the templated content of GeoIP-edit.js and GeoIP-view.js, the following steps are needed:

  1. Change the references to script to cover the three fields needed. Including setting up the observables for the UI elements, retrieving and setting the UI values and initializing the REST representation of the configuration.

The following code is the modified version of the template-GeoIP-edit.js:

 function PolicyConfigurationModel(ko, $, oj, ...

Get Implementing Oracle API Platform Cloud Service now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.