blob: 360b1fb81fca0c65c3ab30e431132cde2e36dc65 [file] [log] [blame]
<md-content layout="column" layout-align="center stretch" class="content">
<ul class="breadcrumb">
<li><a href="#/documentation/2.0.2">2.0.2</a> <span class="divider">/</span></li>
<li><a href="#/documentation/2.0.2/language/overview">Language</a> <span class="divider">/</span></li>
<li><a href="#/documentation/2.0.2/language/widgets">Widgets</a></li>
<h2 id="List">List</h2>
<h3 id="description">Description</h3>
<p>The list in EEF lets you display and edit a list of elements easily. On top of the common properties of all widgets (identifier, labelExpression, helpExpression, isEnabledExpression, propertyValidationRules), it has the following properties:</p>
<li>valueExpression: This expression will be used to compute all the valued will be displayed in the table. This expression must return an object.</li>
<li>displayExpression: This expression is used to compute each label of the table. This expression can use the result of the valueExpression thanks to the variable
<code>value</code>. This expression must return a string.
<li>onClickExpression: This expression will be executed when the user will click on the value. The user will be able to double click on a value. To determine whether the click on a single click or a double click, the kind of the click realized is available as a String in the variable
<code>onClickEventKind</code> which can have the value
<code>SINGLE_CLICK</code> or
<code>DOUBLE_CLICK</code>. This expression does not have to return anything.
<li>actions: The actions are a list of buttons which will be available next to the widget to allow the user to trigger some actions for the list. An action has a labelExpression which must return a string used as the label of the button created for the action. An action also has an action expression used to execute some behavior when the end user will click on the button. The action expression does not have to return anything. The action expression will have access to the selected elements in a variable named
<code>selection</code>. An action can also have an imageExpression, used to compute the image of the button created for the action. This expression must return a string with the following structure PROJECT_NAME/IMAGE_PATH.
<li>style: The style of the list widget.</li>
<li>conditionalStyles: All the conditional styles of the list widget.</li>
<h3 id="displayereference">Display an EReference</h3>
<p>In order to display in the user interface a list widget with the value of a multi-valued EReference, you can create a list widget with the following properties:</p>