Data View & List View Properties

Last update: Edit

1 Introduction

This document describes a data view and a list view in the page editor of Mendix Studio.

A data view is a starting point for showing the contents of one object on a page. A data view typically contains input widgets like text boxes.

For example, if you want to fill out the information on each customer, a data view is the best way to do that.

In more complex templates, a data view can contain other data views for related objects, for example, showing customer details and showing customer payment status, if these are modeled as two different entities.

A list view is a starting point for showing a list of objects. For example, if you want to display a list of all customers, use a list view.

2 Data View Properties

Data view consists of the following properties:

2.1 Data Source

The data source determines which object will be shown in the data view. For general information on data sources, see Data Sources in the Mendix Studio Pro Guide.

Data Source Property Description
Context A data source determining that wherever you are opening the page from, you are passing the selected object. For example, when you add the Show Page activity in the microflow, you select the page and the object to pass. (For more information on the microflows, see Microflows.) That means that when the page is opened in the microflow, the object of this type is provided and will be shown in the data view on the page. For more technical information on the context source, see Context Source in the Mendix Studio Pro Guide.
Microflow A data source that runs a selected microflow and displays a return value. For more technical information, see Microflow Source in the Mendix Studio Pro Guide.
List widget A data source that allows a data view to display detailed information on an object in the list widget (list view) on the same page. For more technical information, see Listen To Widget Source in the Mendix Studio Pro Guide.

2.2 General

In the General section, you can enable/disable the following options:

  • Read-Only (disabled by default) – when enabled, all input widgets (for example, a text area, a check box) in the data view will be in read-only mode
  • Show Footer (enabled by default) – a footer is an area at the bottom of the document, usually containing information common for all pages, such as copyrights

2.3 Design

For information on the Design section and its properties, see Design Section in Widgets.

3 List View Properties

List view consists of the following properties:

3.1 Data Source

The data source determines which objects will be shown in the list view. For general information about data sources, see Data Sources in the Mendix Studio Pro Guide.

Data Source Property Description
Database A data source that determines that the object or objects shown are retrieved directly from the database. You need to select an Entity (that you have in the domain model), or create a new entity, if you set database as the data source. For more technical information, see Database Source in the Mendix Studio Pro Guide.
Filter – limits data in the list view. You can create a filter only after you specify an entity for the list view. For more information on data filtering, see Data Filters.
Sort Order – the order in which items in the list view are shown. You can specify a sort order only after you select an entity for the list view. You can add multiple sorting rules. For example, you can add two sorting rules: one is to sort item by name in ascending order, and the other one is to sort items by email in descending order. Unique items will be sorted by name in ascending order, but if two or more items have the same name, then these items will be sorted by email.
Microflow A data source that runs a selected microflow and displays a return value (i.e. a list of objects). For more technical information, see Microflow Source in the Mendix Studio Pro Guide.
XPath Currently, this data source can only be configured in Studio Pro. For more information, see XPath Source.
Nanoflow Currently, this data source can only be configured in Studio Pro. For more information, see Nanoflows.
Association Available when a list view is placed inside another data container, for example, a data view. The list view is filled with the objects linked to the data view object by an association. For example, you can show all orders for a customer.

3.2 Events

You can choose the On Click Action in the Events section. The On Click Action defines what action is performed when the user clicks a row of the list view.

For more information on the Events section and on click actions, see Events Section in Widgets.

3.3 General

In the General section, you can select the number of rows to be displayed on the page and set the read-only for the list view:

  • Page Size – the number of rows displayed on the page; after the indicated limit is reached, the Load more… button is displayed on the page.

  • Read-Only (enabled by default) – when enabled, all input widgets (for example, a text area, a check box) in the list view will be in read-only mode

3.4 Design Section

For information on the Design section and its properties, see Design Section in Widgets.

4 Read More