Web Designer Views Overview Paige Freeman July 11, 2023 15:17 Updated A “view” represents a visible portion of ThreeSixty Web Client that can be customized to display or edit data or contain other views. Under the hood, a view can consist of multiple xml files: a view file, a resource file, a repository file, and/or a viewmodel file. The View file is responsible for determining the placement of html controls on the page, like textboxes and links and labels. The Resource file can be used to specify what text is written on the page and resource references are denoted by a “$” at the front. For example a button might have a text value of “$btnSave” which references a key-value pair in the resource file The Repository file specifies which API Objects/Collections/Schemas that data will be sourced from The ViewModel file is a mapping between the datasources from the repository and the UI controls on the page via the “PropertyName” tag. There is also a JavaScript Extension file that can be added to some views that need custom UI interactions not supported by the standard control palette; it gets imported along with the generated JavaScript upon runtime. Views also come in two major flavors: Simple Views (also known as Shared or CRUD Views), located in the special “Shared Module”, and Regular Views (also known as non-shared, partial, or non-simple Views). Simple Views are comprised of only a View File and optionally a Resource File, meaning they have at most two XML files (View and Resource). They can be accessed from any module in ThreeSixty Web Client as long as they are passed the correct context data (for example, MasterCustomerId). Shared module views are usually simple views. A simple view can take on three forms: List, AddEdit, and ReadOnly. Visually, they appear as three different pages but they all live within the same xml file. The list form for a BusinessObjectCollection will show one BusinessObject per row, and there are links on each row to transition the list form to a read-only or edit form. Above the list there will usually be a create link to transition the page to an add form. The read-only form displays non-editable data whereas the add/edit form usually contains input controls to edit data. The add page uses the same xml as the edit form; but whether the page should be in add or edit mode is determined from an isCreate flag based on if the user reached the page via clicking a table-row-link vs clicking on the create button. This flag is usually used to determine if the title of the page says “Add” or “Edit”. Clicking on a cancel or save button will return the user to the list page (or the read-only page if the user is working with a BusinessObject instead of a Collection). Regular or Non-Simple Views usually are confined to usage within one module and usually employ all four xml types to work correctly (View, Resource, Repository, ViewModel). Additionally, creating a non-simple view with three forms (List, AddOrEdit, ReadOnly) can result in the creation of a total of 12 XML files(3 View, 3 Resource, 3 Repository, 3 ViewModel) to power this one set of Non-Simple Views when created in the Web Designer view creation wizard.