Jump to: navigation, search

Scout/Concepts/TablePageData


Scout
Wiki Home
Website
DownloadGit
Community
ForumsBlogTwitter
Bugzilla
Bugzilla


TablePageData is the standard data transfert object for TablePage between the client Plug-In and the server.

  • extends: C obj.pngAbstractTablePageData

Description

Important.png
Required version
The API described here requires version 3.10.0 or bigger.


TablePageData are based on bean-based TableData to hold the data. In Addition, TablePageData also contains a boolean flag (limitedResult) to indicate if the table contains all rows or if the request was limited to X rows in the server. In this case, when the PageData is imported, a status is displayed in the status bar of the table.

Usage

  • A page date is the typical return value for the methods of the outline services.
  • Importation in TablePage during the LoadData event. Here an example:
@Override
protected void execLoadData(SearchFilter filter) throws ProcessingException {
  PersonSearchFormData formData = (PersonSearchFormData) filter.getFormData();
  if (formData == null) {
    formData = new PersonSearchFormData();
  }
 
  PersonTablePageData pageData = SERVICES.getService(IStandardOutlineService.class).getPersonTableData(formData);
  importPageData(pageData);
}
  • OutlineService

The SQL Support of Scout also offer support to select into TablePage data. For example:

SQL.selectInto("SELECT person_nr, last_name, first_name FROM person INTO :{personNr}, :{lastName}, :{firstName}", pageData);

For your table field, if you decide to switch your TableData from array based table data to bean based table data, the SQL support provides you the same possibilites (holder, input bind, output bind, filter...).

Please note that it is not possible to use input and output bindings which use the same field names (e.g. input bind SearchForm :lastName and output bind TablePageData :{lastName}) as discussed in the forum. As a workaround please provide a name for the output bindings:

SQL.selectInto(""
  + "SELECT person_nr, last_name, first_name FROM person "
  + "WHERE last_name like :lastName "
  + "INTO :{out.personNr}, :{out.lastName}, :{out.firstName}",
  searchFormData, 
  new NVPair("out", pageData));

Generation

SDK Support

Note.png
TODO
Add a screenshot


PageData anotation

A obj.pngPageData FormData annotation

Note.png
TODO
Add a description


See Also