10 Extensible Development

This topic describes about the Extensible Development

Developer can add his code in hook packages and release specific JavaScript file.

Extensibility in JavaScript Coding

For release specific JavaScript coding, code has to be written in release specific JavaScript file. It follows the naming convention as : (Function Id)_(Release Type).js

Example: Code in CFCTRCHG_CLUSTER.js is exclusive to cluster release

This JavaScript file allows developer to add functional code and is specific to release. The functions in this file are generally triggered by screen events. A developer working in cluster release would add functions based on two categories:

  • Functions triggered by screen loading events

    Example: fnPreLoad_CLUSTER(), fnPostLoad_CLUSTER()

  • Functions triggered by screen action events

    Example: fnPreNew_ CLUSTER (), fnPostNew_ CLUSTER ()

Extensibility in Backend Coding

Release specific code has to be written in the Hook Packages generated. Structure of a Maintenance and Transaction Call Form hook packages are almost the same

Note:

though structure is almost the same ,arguments differ in transaction and maintenance call forms .Hence Transaction Call Form can be attached only with Transaction screen and similarly for Maintenance screens

Different functions available in the Hook Package of a Call Form are:

  1. Skip Handler : Pr_Skip_Handler

    This can be used to skip the logic written in another release.

    Example: logic written in KERNEL release can be skipped in CLUSTER release

  2. Fn Main

    This is called form the fn_main in main package.

  3. Fn_pre_query
  4. Fn_post_query

    Any specific logic while querying can be written in these functions. It is called from fn_query of the main package

  5. Fn_pre_upload_db
  6. Fn_post_upload_db

    Any logic while uploading data to tables can be written here.

  7. Fn_pre_default_and_validate
  8. Fn_post_default_and_validate

    Any release specific logic for defaulting and validation can be written here . It is called from the fn_default_and_validate in the main package

  9. Fn_pre_check_mandatory
  10. Fn_post_check_mandatory

    Any mandatory checks can be validated here.

  11. Fn_pre_process
  12. Fn_post_process

    These hook functions are specific to transaction call form screens. These are called from fn_process of the main package which in turn is called from fn_process of the calling function id

Refer maintenance and Transaction Screen development document for further explanation