Book Image

ADempiere 3.6 Cookbook

Book Image

ADempiere 3.6 Cookbook

Overview of this book

Table of Contents (16 chapters)
ADempiere 3.6 Cookbook
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface

Dynamic validations


Dynamic validation is used to filter the valid choices based on the value entered/selected in some other field on the screen. For example, on a screen, say, you want to load the business partners who belong to a selected business partner group.

In this recipe, we will apply this functionality of ADempiere to see how we can make use of it to achieve our specific goal.

Getting ready

On the Discussion Detail tab, we see duplicate values in the MOM Status drop-down list, as shown in the next screenshot:

Find out the details about all the statuses, as shown in the next screenshot, by running the following SQL query:

SELECT ad_client_id,c_momstatus_id,name,isdefault,value FROM c_momstatus;

Note down the ad_client_id, as 0 shows that it was created by the System user. We need to filter these out.

How to do it...

  1. 1. Log in as System/System with the System Administrator role.

  2. 2. Go to the Menu | Application Dictionary | Validation Rules window and create a new validation rule of the...