Skip to content

Display FIX_DDL Options as Radio Buttons or Checkboxes in Merciglobal Cloud ERP

This guide helps MerciGlobal Cloud ERP developers configure FIX_DDL (Fixed Dropdown Lists) to appear as radio buttons or checkboxes using a small JavaScript tweak.


Objective

To enhance user experience by rendering dropdowns as radio buttons or checkboxes, especially useful when the list has a small number of fixed options.


Step-by-Step Instructions

1. Locate the {project}_core.js File

This file is typically found in your project's / directory.

2. Add the Following Code

Replace {project} with your actual project name, and {table} with the name of the table you want to modify.

function {table}_add_afterload() {
    fix_ddl_as_radio();
}

Note: This hook will execute after the table loads, converting eligible dropdowns (defined using FIX_DDL) into radio buttons or checkboxes automatically.


Customization

You can also customize which FIX_DDL fields become radio buttons by tweaking the fix_ddl_as_radio() function. This allows granular control over which fields change their UI representation.


Best Practices

  • Use radio buttons when only one option can be selected.
  • Use checkboxes if you intend to allow multiple selections (requires more advanced customization).
  • Keep your FIX_DDL lists short and meaningful.

Use Case Example

If you have a status field with FIX_DDL values: Active, Inactive, Pending, converting these to radio buttons improves visibility and reduces clicks for users.


Access Control

Make sure users have the right permissions to view and interact with the modified FIX_DDL controls.


For Merci Developers

  • This method is lightweight and does not require core system modifications.
  • Works perfectly with all versions of MerciGlobal Cloud ERP post-2023.


For more guides, visit docs.merciglobal.com

Happy Coding! 🧑‍💻