Defining and publishing views with the View Designer
To open the View Designer, click . Your access permissions determine whether the menu item is displayed.
The View List is displayed.
The View List
The View List shows the views that are defined. From the View List, you can:
- Open a view. The View Designer opens and you can view or change the view.
- Filter the View List by typing in the Search box.
- Filter the View List by object type and view type by using the Filter by boxes.
- Select Include system views to show system views in the View List. The setting is cleared by default. Custom views are always listed.
- Click a column header to change the sort order of the list.
- Select the checkbox next to a single view or multiple views to update numerous views. The bulk update options are Delete, Enable, and Disable. Clear the check boxes to hide the bulk update options.
- Click New View to create a new view. After you define the initial properties, the View Designer opens.
For more information, see the following topics:
The View Designer
Design tab
The Design tab shows the definition of the view in a graphical format. It has the following components:
- Canvas
- The canvas is where you lay out the view, create sections, and add fields to sections.
- Palette
- You can use UI components on the palette to add inline guidance, groups, relationship fields, object fields, and workflow fields to a view. Use Hide fields already in view to control whether fields that are already added to the view are displayed in the palette.
- Property panel
- The content of the property panel changes depending on what you select on the canvas. It can be properties that apply to a field or to a UI component such as relationship field, group, and inline guidance.
The following example shows the components on the Design tab:
The Design tab is displayed for system views but you can't interact with it.
JSON tab
The JSON tab shows a view definition as JSON code.
In version 9.0.0.3 or later, the JSON tab might not be displayed depending on the OpenPages® Content Security Policy. For more information, see Content-Security-Policy (CSP) registry settings.
The following example shows the JSON code for the previous task view definition.
For more information about JSON, see Editing JSON for a view definition.
Preview tab
The Preview tab shows a view definition for an object instance. Up to 50 objects are displayed. Filters are disabled. Objects are read only and cannot be changed. Workflow stages and workflow stage overrides are not considered. You cannot use the Preview tab to test how a view appears at different stages in a workflow and whether workflow task overrides are functioning correctly.
The following example shows the Preview tab for the previous task view definition.
Working in the View Designer
- Automatically translating labels
-
You can configure View Designer to automatically translate labels.
- Saving a view
-
Your work is automatically saved as you edit a view. A general syntax validation check is performed every time that a view is saved.
- Discarding a draft version of a view
-
To discard changes you made to a view, click Discard Draft. All changes since the last published version are discarded.
- Disabling a view
-
To disable a view, select the view in the View list, and then click Disable.
Alternatively, click the Edit icon for a view, and then clear the Enabled checkbox.
- Working on a view as a team
-
When you have a view open in the View Designer, the URL contains the view's internal name. If you are working on the view with colleagues, you can send them the URL to share your progress. Although you can collaborate with colleagues, only one user can work on a view in the View Designer at a time.
Publishing a view
Click Publish when the view is finished. A detailed validation check is performed every time that a view is published. This validation check is more in depth than the one performed by the auto-save. It looks at whether the view is suitable for use and crosschecks the entire view. If you receive an error when you publish a view, you need to resolve it.
Copying a view
When you open a view in the View Designer, you can copy the view to create a new view.
Procedure
- Click .
- Click the label of the view that you want to copy.
View Designer is displayed with a Copy view link in the View Designer header.
- Click Copy view. The Object type of the new view is set to the object type of the view that you are copying from.
What to do next
Complete the steps for the type of view that you want to create. You don't need to create the same type of view that you are copying from. For example, you can click Copy view with an Admin View open in View Designer even if you want to create a Task View. When you copy from a different view type, only compatible sections are copied to the new view. For example, not all view types have a Parent and child relationships section.
- To create Admin Views, see Defining an Admin View.
- To create Task Views, see Defining a Task View.
- To create Creation Views, see Defining a Creation View.
- To create Grid Views, see Defining a Grid View.
Displaying debug information
Use Display debug info to turn on debug mode and resolve problems as you configure views.
When Display debug info is enabled, the following additional elements are displayed in the header when you access views:
- The name of the view that is open.
When the view name is shown, you can test the view rules and verify that the correct view is displayed. Click the view name, and the View Designer opens.
- Why can't I save?
If there's a problem that prevents you from saving your work, Why can't I save? is displayed in Creation, Task, and Admin Views. For example, if a required field for an object is empty, the Save button is disabled. Click Why can't I save? to view informational text that explains why Save is not enabled.
Procedure
- Click .
Debug mode is turned on and a check mark displays next to Display Debug Info.
- Click Display debug info again to turn off debug
mode.
Debug mode is turned off and the check mark is removed.
Editing JSON for a view definition
The content and layout of views is defined in JSON, which is the syntax for defining structured data.
When to use the JSON tab
Use the JSON tab to copy views. For more information, see Creating a custom view from a System view.
Other than copying views, there is no need to use the JSON tab. You can optionally check how a view is structured and search for JSON property and element names. You can solely use the Design tab to create and design custom views. All the capabilities in the JSON tab are also in the Design tab.
Tips for fixing JSON mistakes
The JSON editor checks syntax and shows mistakes.
- The mistake is usually in the line just before the line with a red x.
- Check first for mismatched delimiters, braces, brackets, and trailing commas. They are the most common mistakes. The error message might not clearly state that the problem is a delimiter.
Tips for copying JSON and minimizing copy errors
Avoid errors by copying an entire view rather than JSON snippets.
If you copy a JSON snippet, use the small triangles in the left gutter to collapse the JSON before you select a JSON snippet. When the text is collapsed, it is easier for you to select what you want to copy.
Before you paste a JSON snippet, collapse the area that you are pasting into so that it is easier to identify the correct insertion point.