Notes: In this tutorial, Domain indicates the domain that you are working in.

What you will build

In this tutorial, you will learn:

  • How to set expressions related to a domain entity.

Create your model

  1. Log in to the design application Designer with your user name and password.
  2. Click Modeler on top menu to navigate to models page.
  3. Click on left top of the page in. A pop-up page will be open for you to fill in.
  4. Fill in the fields inside Entity Definition dialog box.
  5. Click Domain Entity, and type Employee inside Type your entity name here field.
  6. Enter Name for Type your field name here select Field Type as String, click Add.
  7. To add LastName as a field repeat the previous instructions.
  8. To add EmployeeNumber as a field repeat the previous instructions, but instead of selecting String, select Int32 for Field Type.
  9. Click Save in order to save this.
  10. This will take you to your Modeller page, here you will see an indication which states: “There are 1 pending database migrations.”
  11. Click Run Migrations on the right side of the page.
  12. Now you are ready to use your model.

Create your app

  1. Click Apps on top menu to navigate to apps page.
  2. Click  on left top of the page in.A pop-up page will be open for you to fill in.
  3. Fill in the fields inside New App dialog box:
    • Enter Employee Record inside Type your app’s name here field.
    • (Optional) Enter a description inside Your app’s Description.
  4. Click Create.

This will create your application including 5 pre created canvas pages.
Click OpeningPage (Starting Screen) in order to start.This will open a predesigned canvas.

Drop a Domain Entity and Set Expressions

  1. On the left side of the page, you can see Display Items (Screen Design Toolbox). Click on Domain Entities. Drag and drop Employee to Screen Design Canvas at the center of the page.
  2. On the dialog box opened;
  • Set Action to Input.
  • Set Renderer to Field:Value Pair.
  • Check Name, LastName and EmployeeNumber.
  • Click Submit.
  1. Click LastName inside the canvas. Display Item Properties panel opens on the right side of the page.
  2. On Display Item Properties panel, in Entity Variables list, click on LastName_label.
  3. Under the menu bar on the top, you can see Expression Editor. Set expression
 LastName_label = “Last Name”
  1. Click on Expression Editor to save the expression.
  2. Click EmployeeNumber inside the canvas.Display Item Properties panel opens on the right side of the page.
  3. On Display Item Properties panel, change EmployeeNumber to Employee Number and click  to save it.

Add Buttons

  1. Click on Widget Toolbox in Display Items (Screen Design Toolbox) on the left side of the page. Drag and drop Button to the canvas.
  2. Click Button inside the canvas.
  3. On Display Item Properties Panel rename your Button to Save. Click to save.
  4. From Events sub panel, click Save_Click on Display Item Properties Panel.
  5. To enable Save button to save the Employee record in the corresponding database table, check Employee_out option in Variables To Save.
  6. Check Go Back and Exit App options in Actions.
  7. Click Save Changes.
  8. From Stylings sub panel, select button:Background Color and click Add.
  9. Pick green color from the color picker (or whichever color you would like).
  10. Click on Widget Toolbox in Display Items (Screen Design Toolbox) on the left side of the page. Drag and drop Button to the canvas.
  11. Click Button inside the canvas.
  12. On Display Item Properties Panel rename your Button to Cancel. Click to save.
  1. From Events sub panel, click Cancel_Click on Display Item Properties Panel.
  2. Check Cancel and Go Back option in Actions.
  3. Click Save Changes.
  4. From Stylings sub panel, select button:Background Color and click Add.
  5. Pick red color from the color picker (or whichever color you would like).

Generate and deploy your application

  1. Click Menu > Publish on the top-right corner of the page.

Your application is generated and deployed!

Run your application

  1. Click Menu > Preview on the top-right corner of the page.

Your app is running!

  • Fill in Name, Last Name and Employee Number fields as you like.
  • To save the new Employee record in database, click Save. Otherwise, click Cancel.

Congratulations! You created an app that uses a domain entity.