Classifications are static lists used to populate a field/property of a table in the UI design of your app. e.g. to provide a drop down selection of product names, standard responses to questions, etc. It is probable that you will want some of the Properties (data entry boxes) in your App UI to be populated by the App User selecting from a drop-down list of options.
In Evoke these are "Classifications". An example of the user of a Classification is shown on the right as the "datatype" value used in the Evoke Entities definition page is a Classification. Classifications can be lissts of static data or dynamic lists populated from data in your database, details of how to use each option may be found below.
Each Classification may be populated either from:
A specific Classification table in your backend database
Via a selection from multiple tables in your backend database or
A fixed list that you define in your database.
Classifications that you wish to use from a specific Classification table in your backend database are defined in the Evoke Classifications menu option. The screen on the right shows an example list of Classifications that can be created on the Evoke screen accessed by the Classifications menu option.
A specific Classification table in your backend database (Static lists)
If you are using a specific Classifications table/file in your database to hold your static lists then map this file onto the Classifications Entity in the Data Mappings section. Add records to your Classifications file in your database that contain the following fields 'Type' (this is the classification name you have used), 'Code' (Classification option for the drop down), 'info1' (will be used to set the drop down order - user numbers or letters to set the order e.g. a, b c, d...), 'description', 'info2', 'info3' are free format fields except for the classification culture.
On the Classifications screen, that is accessed from the Evoke menu and shown on the above/right of this page, you can add new Classifications that you will use as Entity properties. Add a new classification by clicking the + symbol or using "add" in the header menu; name the classification and add a free-format description. Delete one Classification by clicking on it to select it and then using the "delete current" menu option, delete more than one classifications by using the "Tick Select on" option, when you have "ticked" multiple classifications use the "delete ticked" menu option to delete your selected choices.
Using this type of Classification on the Pages involves setting up a template. On the image on the right you can see an Entity property of type Classification used in a single entity template. The editor type has been automatically set to Lookup and the sub-property (property being displayed) is the 'Code' field from the Classification Entity.
In the editor specific settings the datasource (selected via the build button) is the Classification Name (it is automatically preceded by GlobalData as it is a global value). The drop down fields, used when the user picks the value they want, are 'Code' and 'Description' again Properties from the Classification Entity.
Via a selection from multiple tables in your backend database (Dynamic Data Lists)
If you wish to offer a drop down list of dynamic data retrieved from your database tables/files then you can also set up the drop down list of options through a Selection. A Selection is used to select data from your database and copies it into a DataSource. For example, if you want to populate a Products DataSource with all the records in your Products file you might perform a "SelectAll" selection or alternatively you might just select the records that have a type of bathroom product or similar.
You can then use this DataSource as the source for the list of options that can be selected in a "Lookup" Widget. The image on the right shows that the DataSource of Products is being use, this has been populated on entry to this Page Series (in actions on load) or via a Click Action on entry into this Page. The population was in the form of a Selection and examples of this can be found in Populating a DataSource.
The Widget also defines the property (field) that will appear in the drop down list (in this case "Description"). The Property of Product (used in the Template has been set up in Entities to have a data type of Entity and to be a single entity of the Product entity.
A fixed list that you define in your database (Static Lists in separate data Files/Tables).
If you choose then you can simply set up files on your database that hold fixed lists that are used for single dropdowns for selection in your app. For example, you may have a list of Public Holidays in a separate file that only has this one field in and want a user to pick one. These can be used either using the Selection method above or by reading the file in, at the time the Classification is used, via your MultiValue DataBase CRUD code or your SQL C# code in Visual Studio.
A Culture Classification can used to set the Data Format and Currency options for a user beyond the standard Table of Language Culture Names, Codes, and ISO Values and is defined with the following Classification properties (fields) being used: 'description'=currency name 'info2'=currency symbol 'info3'=dateformat for this user e.g. MM/DD/YYYY, DD/MM/YYYY etc. Culture is used in the AppUser Entity.
If you prefer videos, the video on the right provides a basic description of using Classifications within Evoke and may be reviewed for an explanation of how to use Static List Classifications.