Creating a model

To create your own model, perform these tasks:

  1. Duplicate the standard model.
  2. Add object types to the new model.
  3. Add actions to the object types.
  4. If the object consists of multiple tables, add table relations to the object type.
  5. Add mappings to the object type.
  6. Validate the model.

See these sections.

Upon completion of this procedure, you must deploy the model. See Deploying a model .

Note: When you customize a model, you probably must modify scripts and libraries. See the Infor ES Programmer's Guide.

Duplicating the standard model

To duplicate the standard model:

  1. Start the Models (ttocm0101m000) session.
  2. Select the standard model and click Duplicate.
  3. Specify the model code and description for the new model.
  4. Save the new model.

Adding object types to the new model

You can add multiple object types to the model.

To add an object type to the new model:

  1. In the Models (ttocm0101m000) session, select the new model.
  2. On the appropriate menu, select Object Types. The Object Types (ttocm0102m000) session is started.
  3. Add an object type. See the session help.
  4. Save the new object type.

Adding actions to the object types

You can add one or more actions to each object type.

To add an action an object type:

  1. In the Object Types (ttocm0102m000) session, navigate to the object type.
  2. On the Actions tab, click New Action.
  3. Add an action. See the session help.
  4. Save the new action.

Adding table relations to the object types

If the object contains data from multiple tables, you must specify table relations between the tables that are used in the object.

For example, the sales order object is based on the Sales Orders (tdsls400) and Sales Order Lines (tdsls401) tables. An order header without lines is useless. Therefore, for the sales order object type, specify a relation from the Sales Order (orno) field in the tdsls401 table to the tdsls400 table.

To add a table relation to an object type:

  1. In the Object Types (ttocm0102m000) session, navigate to the object type.
  2. On the Table Relations tab, click New Table Relation.
  3. Add a table relation. See the session help.
  4. Save the new table relation.

Adding mappings to the object types

You can add one or more mappings to each object type.

To add a mapping to an object type:

  1. In the Object Types (ttocm0102m000) session, navigate to the object type.
  2. On the Mappings tab, click New Mapping.
  3. Add a mapping. See the session help.
  4. Save the new mapping.

Validating the model

To validate the model:

  1. In the Models (ttocm0101m000) session, select the new model.
  2. On the appropriate menu, select Validate. A message, indicating whether the validation was successful, is displayed.
  3. If errors occurred, view the log file and solve the problem.