Learn WorkXpress
Tree
| A Tree Layout is a form of List that allows the User to "drilldown" through a series of related Items. One can start at the top level of the Tree, and "expand" or "open" subsequent children levels. The child level must be connected to its parent by a Relationship. WorkXpress Tree's allow you to create any combination of drilldown for your Users by traversing Items and Relationships. For any level of your Tree Layout, you can create an independent set of columns as if each level were it's own List Layout. A common example of a Tree Layout is when you navigate the folders and files on your home computer. |
-

Modes
Show Technical DetailsTrees accept no user input. Thus a Tree in view mode looks exactly the same as it does in add mode or in edit mode.
-

Parts
Show Technical DetailsTrees have three parts:
- Title Bar - Consists of a title, an icon, a drop-point for links/HTML content, and the title bar background. All the settings pertaining to the title bar are located in the Appearance tab of the Block Editor.
- Body - The body of a Tree consists of a series of levels (set in the Tree Settings tab of the Block Editor), each level of which is only shown if an Item exists on that level and the level is expanded from an Item in the level above it. Each level of a Tree is a lot like the body of a List Layout. It consists of any number of columns defined by which Fields are attached to that level. Also, for each column in the level, there are two drop points: one before the Field and one after. If there are no Fields attached to a displayed level of a Tree, the body consists of one drop point.
- Layout Footer - A Layout (other than a page) usually has nothing in the footer. However, if a Layout has independent save controls enabled, a Layout in edit mode will always have a save button in the footer, and, unless security doesn't allow edit mode, a Layout in view mode will always have an edit button in the footer.
-

Expand/Contract
Show Technical DetailsWant to build an interface that includes a long list of things but don't want to dramatically increase the length of the page its' on? Use these Expand/Contract settings to start with a collapsed Layout! You can also give your users the ability to expand or contract layouts on their own, empowering them to shape their experience as they see fit.
Settings:
- Allow the Layout To Be Collapsed - Check this box to allow the Layout to be collapsed by clicking the up arrows icon on the right side of the Layout's Header Bar.
- Start Collapsed - Check this box to initially display the Layout in its collapsed position.
- Remember Collapsed Setting By User - Check this box to allow WorkXpress to remember if a user has collapsed or expanded a Layout and display that Layout in the future based on the user's selection.
-

Header Bar
Show Technical DetailsOften, you'll want to change the appearance of the Header Bar for a Layout Block. Using these settings, you can change the title, icon, and appearance of your Layout's Header Bar.
Settings:
- Title (required) - Use the Expression Builder to choose a name for your Layout.
- Layout Icon - Choose an Icon to appear on the left side of your Layout's title bar.
- Hide Title Bar - Check the box to completely hide the Title Bar for this layout.
- Hide Title Bar Background - Check this box to hide only the Title Bar background. The Title Bar text will remain visible for this Layout.
-

Sizing
Show Technical DetailsDon't want that Layout to stretch for miles down a page? Set a maximum height for it to keep it under control.
Settings:
- Max Height (in pixels) - Enter a maximum height for the Layout.
-

Tooltip
Show Technical DetailsA Tooltip provides helpful text when your User mouses over the field label. This Tooltip feature lets you create the Help Text you want your Users to see.
Settings:
- Tooltip - Enter text to create a tooltip that will display when a user hovers his mouse over this Field's Label.
Hints:
- You can never go wrong by adding tooltips!
-

Inline Add and Single Line Edit
Show Technical DetailsSettings:
- Enable Inline Add - Check this box to enable a link that will allow your users to add to single Items to a Layout without switching modes.
- Enable Single Line Edit - Check this box to give your users the ability to click a wrench icon beside any line Item in a Layout to open an Edit Mode Page about that Item only.
-

Autorefresh
Show Technical DetailsSometimes, you'll need to set up a Layout to automatically refresh its display periodically. Do that here.
Settings:
- Refresh Layout every X seconds - If you would like to autorefresh your Layout, enter an interval, in number of seconds, at which you'd like the Layout to refresh.
-

Block Association
Show Technical DetailsBlock Association is the tie that binds all WorkXpress Blocks to each other and enables them to work together. There are permanent, global Block Associations and temporary, local ones. First, all Blocks are permanently associated with either an Item Type or Relationship--this defines an application's structure. Second, Layouts and Fields can permanently nest inside of Layouts to create your interface. Third, Actions can permanently nest inside of Actions to create logic. Finally, at any point in time, a Layout, Field, or Action will temporarily be "about" a particular Item in the database, to give context.
Introduction:
- Block Association makes WorkXpress unique and powerful as an application development tool. It's the glue that connects all WorkXpress Blocks to each other.
- Permanent Block Associations define the application's structure.
- Temporary Block Associations give the interface and logic "context", which helps the application to interact with the database at a point in time.
Permanent (Global) Block Associations
Item Type or Relationship Type AssociationThe most basic type of all Associations, this defines your application structure. At the topmost level, an application is a group of Item Types. These Item Types may have associated Relationship Types. Collectively, all other Blocks in WorkXpress then are associated ultimately with an Item Type. Therefore, an "application" is defined as a set of Item Types and all their associated Blocks.
When searching for Blocks in the build tools, you will tend to find them by first beginning your search on a particular Item Type or Relationship Type, and viewing their associated Blocks.
This choice of Association also effects data backup and restoration.
Blocks with permanent Item Type Association only: Relationships
Blocks with permanent Item Type or Relationship Type Association: Layouts, Fields, Actions
Layout AssociationTo build an interface you must nest Layouts and Fields inside of other Layouts. This nesting generates Layout Association.
Blocks with permanent Layout Association: Layouts, Fields
Action AssociationTo build a logic model (aka business rules, scripting, etc.) you must nest Actions inside of other Actions within a procedure.
Blocks with permanent Action Assocation: Actions
Global and Local Actions
Actions may be associated with an event and block globally, or they may be associated locally. A "Global Action" exists everywhere and every time the Action's parent Block undergoes that same event. A "Local Action", however, only exists when the Action's parent block undergoes this specific event, in this context. In this case though, context refers to the context of the triggering Block within the interface, not the Item context. This is a unique kind of context.
In other words, although a Field may trigger a local Action when it is saved from within one Layout, it will not trigger that same local Action when it is saved from within a different Layout. In both cases, however, its global save Actions will be triggered from either Layout.
For example, for a certain Field, Action A is global to its "Field Save" event for all pages and Action B is local to its "Field Save" event for a specific page. Later, that same Field is added to a new page. When that new page is saved, Action A will fire, but Action B will not exist at all on that page (in that unique context).
Item Association and Context
An Action is always associated with the building block for whom it is a "local" or "global" action (see below). Placing an Action in the Action Manager will result in that Action being associated with an Item Type based on where it is placed. Actions may be associated with Layouts, Fields, Items, or Relationships.
Similarly, an Action typically requires context to function properly. That context comes from the Block for whom this Action Manager Tool was opened and may not be the same Block for which this Action is a local or global Action. Context and Item Association for an Action may be different.
Further, some Actions can change the context. For example, when a list of Items is passed into an Action Manager from a "Mass Action" button in Layout Type - List, the context is each of the Items passed. However if they pass through a "foreach" control structure, the subsequent context passed to subordinate action is that of a single one of the Items in the list, changing each time the loop is repeated.
Temporary (Local) Block Association
Temporary Item Association (Context)At any given time, what is the page you are on "about"? If the page is about a company, then the context of that page is the specific company it is displaying (e.g. "Acme Company", where Acme Company is an "Item" in the database of "Type" Company). Any Fields or Actions need to be about that specific item and not some other item (i.e. about "Acme company and not some other company), so those Fields or Actions need to be provided with this context. For a much more detailed examination of this concept, which is critical to successfully building applications with WorkXpress, please see our lesson about Context.
If the page is about a specific Item of Type: User...for example the "current user"...then perhaps it is about you? When the page displays data, it needs to display that data about you. When Actions on the page shoot off an email notifying of a change to username, it needs to shoot that email to you, not to some other User. YOU are an Item in the database of Type User, and are also the context in this second example.
Context then is the specific Item (Not Item Type) in the database which the current Layout, Field or Action is displaying data about.
Blocks with temporary Item Association: Layouts, Fields, Actions
-

Tree Configuration
Show Technical DetailsSettings:
- Tree Builder - Click the "Add Tree Level Configuration" button to open the Tree Builder and configure your Tree Layout. Enter the Level ID at which you'd like this set of Items to appear. The Level ID is a number that defines the level of depth for your Items in the Tree. Start with 1 and go up. Then, use the Query Builder to pick the Items you'd like to display in the Tree.
-

Enable Layout Security
Show Technical DetailsWorkXpress gives you fine-grained control over your application's security. Use Layout Security to control which of your users may access and/or edit which Layouts.
Settings:
- Enable Layout Security - Check this box to enable security for this Layout only. If this box isn't checked, security, if any, for this Layout will be inherited from its Parent.
- Configure Layout Security - Use these settings to set up granular control of your Layout's security.
- Map - Use the Query Builder to select the Items (usually users or groups) whose access you want to control.
- Independent Save Controls - Check this box to allow this Layout to be saved independently of the rest of the page. You will need to select "Allow View" and "Allow Edit" for this functionality to work properly.
- Allow View - Check this box to allow the Item(s) selected in the Map section to view this Layout.
- Allow Edit - Check this box to allow the Item(s) selected in the Map section to edit this Layout.
- Allow Add - Check this box to allow the Item(s) selected in the Map section to add Item(s) using this Layout.
- Starting Mode (required) - Select View, Edit, or Add from the dropdown to choose the starting mode for this Layout.
- Order (required) - If you're configuring security for a single Query Builder map of Item(s), enter 1 for this setting. If you choose to configure security for Item(s) defined by additional Query Builder Maps, you must enter the order in which you'd like them to be processed in the text entry box for this setting. Please note: your security settings will be processed in reverse order. That is, the highest number listed for the order setting will be processed first, and so on to the lowest.



