Customize view and dialog boxes

The View settings of the registration pane and various dialog boxes in WorkZone for Office are stored in the database as an XAML configuration.


View and change settings for dialog boxes and views

To see the views available in the database and (or) change your selected settings, you need to execute the following query in SCANSQL or SQLPLUS:

SELECT*
FROM services_configuration
WHERE Module_name = 'Scanjour.Services.Office'

Below is the full list of customizable dialog boxes and views in WorkZone for Office:

  • AddressSelectDialog
  • CaseConfirmDialog
  • CaseSearchDialog
  • CreateCaseDialog
  • DocumentRegistrationPane
  • OutlookItemRegistrationDialog
  • MultipleSavingCommonMetadataDialog
  • FacetsSelectDialog
  • FileClassSelectDialog
  • FixedListDialog
  • OutlookRecordSearchDialog
  • PartiesSuggestionDialog
  • RecipientSelectDialog
  • RecordSearchDialog
  • RecordSelectDialog

Notes:  

  • As views can contain language specific texts, separate versions of the views for each of the supported languages are stored in the database. See About SJStyles.
  • ColumnSetDefinitions is an xml structure that defines which fields are available for the Office Clients. This configuration is merged into the WorkZone Content Server data dictionary.

Important: You need to load the standard ColumnSet configuration used by WorkZone for Office into the sd_datadict table manually. See Installation Guide for WorkZone.


Make a field required or non-required during the registration of the item

You can add values to the dialog boxes and views and make them required or non-required during the item registration. This is relevant for the following dialog boxes and views:

  • CreateCaseDialog
  • DocumentRegistrationPane
  • OutlookItemRegistrationDialog
  • MultipleSavingCommonMetadataDialog.
  1. Open the relevant XAML file.
  2. Find the control with a field value that you want to make required or non-required.
  3. To make a field required, you must add the following property to the control: prop:ControlBehaviour.IsRequired="True".
    -or-
    To make a field non-required, you must remove its control from the XAML file.
  4. Save your changes.

Important: You can make a field required if it is defined as non-required on the server, but you cannot make a field non-required if it is set as required on the server.

The procedure of making the Role field on the Document registration pane required differs. You can find an example below:


Configure the "ColumnSetDefinitions" file

To open and edit your ColumnSetDefinitions file, you must execute the following query in SCANSQL or SQLPLUS:

SELECT*
FROM sd_datadict>
WHERE name = 'mwrp_columnsetdefinitions'

The copy image is missing

Customized versions of ColumnSetDefinitions and XAML are stored in a local project structure together with the scripts for loading the configuration to database.


Add a text field to the registration pane

You can add an extra field to the Registration pane.

  1. Add the data column for the new field to ColumnSetDefinitions (if it is not present already).
  2. Add the XAML control for the field using the appropriate SjStyle, and bind it to the relevant data column.

A text field example

In the example below, the Record Title field is defined as a simple text field.

The field name in data dictionary: record:title


Add other field types

You can add all common ScanJour WorkZone Content Server field types using the predefined SjStyles.

The example below shows how to add a drop-down list for a domain controlled field. In the example, ‘Record Type’ is defined as a domain bound field.


Remove a field from the registration pane

You can remove any field from the standard Registration pane. You only need to remove the field from XAML; it is not necessary to remove the field from ColumnSetDefinitions.

Important: When you decide to remove a field from the Registration pane, you must make sure that this field is not defined as a required field in the data dictionary.

A required field must always be present for input, unless it has a default value defined in the data dictionary.


Use add-in customization

To write and use the customized add-ins, the following requirements must be met:

  • The AddIn assembly must have a reference to the WorkZone for Office assembly Scanjour.Office.CustomizationContracts.
  • The AddIn class must be inherited from the IAddIn interface.
  • The AddIn class must have an AddIn attribute.
  • All AddIns have the SetContext(HostContext hostContext) method. This HostContext has WorkZone for Office methods that are accessible from the AddIn.
  • All AddIns have the GetViewModel method, which is used to get a view model (that is like a code behind the UI customization on XAML). The access to a view model from XAML uses the XamlViewModelKey attribute from the AddInConfiguration.xml file.
  • You can create an AddIn without a UI (a view model). To do this, you must return null from'AddIn.GetViewModel()' and not provide an XamlViewModelKey attribute for the specific AddIn in the AddInConfiguration.xml file.