Display FIX_DDL Options as Radio Buttons or Checkboxes in Merciglobal Cloud ERP
This guide is tailored for Merciglobal Cloud ERP developers to configure FIX_DDL (Fixed Dropdown Lists) so they appear as radio buttons or checkboxes, enhancing user interface and experience with a simple JavaScript tweak.
π― Objective
To improve usability by rendering dropdown fields as radio buttons or checkboxesβespecially beneficial when the list contains a few fixed options.
π οΈ Step-by-Step Instructions
1. Locate the {project}_core.js
File
This file is typically located in your projectβs root directory.
2. Add the Following Code
Replace {project}
with your actual project name and {table}
with the relevant table name:
function {table}_add_afterload() {
fix_ddl_as_radio();
}
β Note: This hook triggers after the table loads, converting all eligible FIX_DDL dropdowns into radio buttons or checkboxes automatically.
π§ Customization Options
- Modify the
fix_ddl_as_radio()
function to specify which FIX_DDL fields should be transformed. - Enables selective UI control over dropdown rendering.
β Best Practices
- Use radio buttons when users must select only one option.
- Use checkboxes if multiple selections are necessary (requires advanced customization).
- Keep FIX_DDL lists concise and descriptive for better UX.
π‘ Use Case Example
A status
field with values like Active
, Inactive
, and Pending
defined via FIX_DDL can be displayed as radio buttons to make options more visible and reduce user interaction steps.
π Access Control
Ensure users have the proper access rights to interact with these enhanced UI controls.
π¨βπ» For Merci Developers
- This method is non-intrusive and does not alter core system files.
- Fully compatible with MerciGlobal Cloud ERP versions released post-2023.
π Related Topics
For more implementation guides, visit the Merciglobal Cloud ERP Documentation.
Happy Coding! π§βπ»