Data Binding Overview

The functionality provided by 1.0 binding expressions (in the form of #{expression} ) and 1.0 macros (in the form of #MacroName%expression% ) have been merged into a single expression language. The goals of the new implementation are:

  • Unify the expression language
  • Improve expression evaluation performance
  • Provide both server-side evaluation (for expressions that access server-side objects) and client-side evaluation (for expressions that access dynamic data available only on the client).

The expressions can be used to:

  • Set Boolean properties of UI controls, such as fields, tab pages, or action buttons:

<field readOnly="${!user.isMemberOfGroup('FIM')}"> <action onclick="approveProject" hidden="${record['project.status'] == 'Created'}"> <tab name="page-2" enabled="${user.isMemberOfGroup('FIM')}">

File: ab-products/solutions/assemblies/find-manage/ab-ex-find-manage-conditional.axvw

  • Set text properties of UI controls, such as view title, panel title, field label, or action button text:

<title>Review Project ${record["project.project_id"]}</title>

File: ab-products/solutions/assemblies/find-manage/ab-ex-find-manage-conditional.axvw

  • Set SQL query text or restriction attributes in the data source:

<!-- include user account property -->
<sql dialect="generic">
SELECT project_id, requestor, status FROM project WHERE requestor = '${user.name}'
</sql>
<!-- use date or time values formatted for the current database -->
<sql dialect="generic">
SELECT project_id, date_start, date_end FROM project
WHERE date_start &gt;= ${sql.date('2005-01-01')}
AND date_start &lt;= ${sql.date('2005-12-31')}
</sql>
<!-- use parameters sent to the workflow rule from the client -->
<sql dialect="generic">
SELECT project_id, requestor, status FROM project
WHERE status = '${parameters["status"]}'
</sql>

File: ab-products/solutions/assemblies/find-manage/ab-ex-find-manage-sql-parameters.axvw

Binding expressions defined in the data source (in SQL queries or restrictions) are evaluated on the server. See Server-Side Bindings - Data Source Properties .

Binding expressions defined in the view or panel properties are evaluated on the client. See Client-Side Bindings - View Properties ).