Combo box list display parameters

Use this parameter when a particular column that can be defined as a combo box will retrieve records from client application data as drop-down list.
Note: Column to display a list of records from the client application data must be part of the query parameter that needs to be set with value. There is no need for CODE columns to define list as it automatically retrieves its list from the Code table.

JSON Identifier: MFS@DisplayList

Parameter

Description

Possible values

Col

Columns to display in the drop-down list. These columns becomes searchable. This is the SELECT statement in the client's query to the local database.

["Table.column, Table.column,…"]

Tbl

Tables where the record will come from.

["Table, Table",..]

Join or LeftJoin

Used to join two or more tables to retrieve the record from. This is for the FROM statement in the client's query to the local database.

Note: The key column of the table is always defined as "PrimaryKey" as column reference. The joining columns are defined depending on the order of the tables in the "Tbl" property.

["Table.column, Table.column"] OR ["Table.column, Table.column"],["Table.column, Table.column"]

Ftr

Used to define further what records are to be displayed or not. This is for the WHERE statement in the client's query to the local database.

Note: When defining a single filter, only "Ftr" is used. This would contain the column, the operator, and the value or column to take the value from. When defining multiple filters, the "Ftr", "Val" and "Op" are used. "Ftr" will only contain the column and the operator. Each corresponding entry is separated by comma.

["Table.column=Table.column"] OR ["Table.column=(value)"] OR ["Table.column=","Table.column!=", "Table.column",...]

Val

Only used for multiple filters. This is where to define the value for the columns to be used as filter. It can be a column name to flag the application to consider the current value. The values separated by a comma corresponds to the order of the filter columns defined in "Ftr".

["Table.column", "(value)", "IS NULL",...]

Op

Only used for multiple filters. Defines how the filters will be joined in the WHERE statement.

Note:  A single operator is used to connect all of the filters defined.

"AND" or "OR"

"SetVal"

Defines which column to be set with a value based on the record retrieved and selected. The columns will be included in the SELECT statement.

["Table.column"] OR ["Table.column", "Table.column",...]

Pk

This is used when the first table's primary key defined in "Tbl" is not used as a value but it will use another column from that same first table instead.

["Table.column"]

Clr

This is used to clear a certain column value when a record has been selected.

["Table.column"] OR ["Table.column", "Table.column",...]

BTreeFilter

Defines which records to display. This is for the WHERE clause in the client's query to the local database. If this parameter is defined, the Ftr parameter is ignored. This parameter allows greater control over the groupings of conditions in the WHERE clause.

The BTreeFilter must be a Boolean element with an Op, Left, and Right elements. The Op element only accepts "OR" or "AND". The Left and Right elements can be Boolean elements or Condition elements. Condition Elements must contain Ftr and Val elements.

See this example:

MFS@DisplayList={"Col":["Product.ProductNo","ProductDescription.ProductName"],"Tbl":["ProductDescription","Product","ProductWarehouse"],"LeftJoin":[["ProductID","PrimaryKey"],["PrimaryKey","ProductID"]],"Ftr":["ProductWarehouse.WarehouseID=","ProductWarehouse.WarehouseLocationID","Product.ItemCategory","Product.ItemGroupID=","Product.ItemTypeCODE=","Product.InventoryAccounting="],"Val":["ServiceLine.WarehouseID","IS NULL","IN (0,4,7)","Product.ItemGroupID","Product.ItemTypeCODE","Product.InventoryAccounting"],"Op":["AND"],"SetVal":["ProductWarehouse.StockQuantity","Product.BasicUnitCODE=ServiceLine.QtyBasicUnitCODE","ProductDescription.ProductName=ServiceLine.ProductName","Product.ProductNo=ServiceLine.ProductNo","ProductWarehouse.IssueMethod=ServiceLine.IssueMethod","Product.LotControl","Product.ItemTypeCODE","Product.ItemGroupID","Product.SalesPrice=ServiceLine.SalesPrice"],"Pk":"Product.ProductID","Clr":["ServiceLine.SerialNumber"]}