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 screensDifferent functions available in the Hook Package of a Call Form are:
- 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
- Fn Main
This is called form the fn_main in main package.
- Fn_pre_query
- Fn_post_query
Any specific logic while querying can be written in these functions. It is called from fn_query of the main package
- Fn_pre_upload_db
- Fn_post_upload_db
Any logic while uploading data to tables can be written here.
- Fn_pre_default_and_validate
- 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
- Fn_pre_check_mandatory
- Fn_post_check_mandatory
Any mandatory checks can be validated here.
- Fn_pre_process
- 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