Insert excerpt | ||||||||
---|---|---|---|---|---|---|---|---|
|
This page is for application designers who need to create views of data and bind them to components on screens. Todo-Anthony- check this page is correct when the GUI is finalised.
Overview
PhixFlow stores data in tables, formally known as streams. Views are used to display the data in these Tables. Often they can contain more data than you want to show to a user. For this reason, whenever you show data on a screen, you first compile a view of the data, which only displays the information you specify.
A view is made up of:
- Attributes
- Attributes from the base table
Specify which attributes to include in your view. You can hide attributes that you want access to but do not necessarily want a user to see, such as the UID of a record. - Attributes from related tables.
These are the attributes available to the view as the table they originate from shares a relationship with the base table as defined in the ERDs; see Understanding ERDs. Views which contain these type of attributes are referred to as a relational view.
- Attributes from the base table
Records:
- For each table, the view includes records specified in the tables default period. This can be all data (usually for transactional data) or only the latest.
- You can sort , and filter and order records.
Components:
The components in the list below are designed to display a view of data in different ways. Add a view component to a screen then drag specific attributes from a table onto the view component. In the case of a card view, any palette item can be added.
Insert excerpt _grid _grid nopanel true Insert excerpt _graph_line _graph_line nopanel true Insert excerpt _graph_vertical _graph_vertical nopanel true Insert excerpt _graph_horizontal _graph_horizontal nopanel true Insert excerpt _chart _chart nopanel true Insert excerpt _card _card nopanel true Insert excerpt _form _form nopanel true
How to Create and Display a View
As views are designed to display data on a screen, for more information on setting up charts and graphs see Creating Dashboards and Reports.
Step 1 Select a table
- Drag a table onto a screen, this can be achieved by dragging
- a table from the list in the repository.
- a table icon from a table's properties.
- PhixFlow asks you how you want the data to be displayed, select the desired option:
- The view will be added to the screen.
Step 2 Select attributes
- Drag attributes from the Available Attributes window onto the view.
- Start with attributes from the current (base) table.
- Optionally, click on related tables to show additional attributes that are available.
- When you have dragged all the attributes you require, close the window.
- These attributes can be changed at a later time when for different view types when a screen is unlocked by:
- Forms, click the attributes button from the toolbar.
- Card Components, right-clicking on the card and selecting Show table view configuration
- Grid and Charts: right-clicking on the item, selecting Show Table view configuration. In the attributes section click
.Insert excerpt _attributes _attributes nopanel true
- See Available Attributes Window for details.
Step 3 Apply filtering and sorting for records
You have now created your view and added it to a screen. Optionally, specify if you want to apply any filters or sort orders to the data records:
- Select the view you have added.
You may need to right-click the view and select Show Stream View Configuration.
PhixFlow opens the view properties. Select an existing Default Sort Order, Default Filter or Background Filter or create new ones, see Sort Order and Filter for more detail.
PhixFlow applies filters when the application user sees the view in the application window.Tip The application user can remove the default filter where as background filters are permanent.
Reusing Views
Once you have created a view, you can reuse it in multiple locations. In the repository navigate the the table which owns the view, the base table, open the table and in the views section drag the desired view onto your screen. Be aware however that changes made to the view will affect all instances of that view.
Form Field Name
When you drag attributes from the Attribute Selection window or table onto a form, PhixFlow adds a field and label for each attribute. By default, the label is the attribute's name. However, for an attribute from a related stream, the Display Name will be shown and not the foreign key value.
For example:
Example | Base Table | Related Table | Value Displayed | Form Field Label |
---|---|---|---|---|
syntax | table.UID | RelatedTable.ForeignKey | RelatedTable Attribute set to DisplayName | - |
Example Syntax | Company.UID | Supplier.RelatedCompany | Supplier attribute set to RelatedCompanyName | Related Company Name |
Example Values | 1024 | 1024 | "Cloud and Pixel Ltd" | Related Company Name |
For information about primary and foreign keys and the Display Name option; see Understanding ERDs.