XML Customization guide
Introduction
This guide explains how to customize GCON4 MFL XML files to override standard GCON4 MFL settings, such as:
- Include customized mandatory fields.
- Change the name of standard fields to be displayed in GCON4 MFL
- Customize descriptive text.
- Add additional attributes performed by batch upload.
- Others
Pre-requisites
- MFL 7.0.1 should be installed in the Business Server
- Grant access to the MFL06 Menu access through menu-based access
- Download the XML files of the desired Masterfiles from this site:
Master file XML attributes
A customized XML file can be created to override the standard settings of all master files in GCON4 MFL.
The specified XML template is read during the startup of the software and the field names and properties are applied.
Structure
The fields marked in green can be changed without affecting GCON4 MFL functionality.
The fields marked in yellow may cause problems during GCON4 MFL validation (you should be able to change the mandatory status of the field, from optional to mandatory).
The fields marked in red must not be changed.
Possible values
Field |
Example |
Description |
---|---|---|
DisplayName |
MYFieldDisplay |
How the field is displayed in GCON4 MFL and in Excel |
Mandatory |
InsertionOnly |
Accepted values are: InsertionOnly Always Never |
AcceptDefault |
True |
Accepts a default value or not |
DefaultValue |
MYVALUE |
Default value, where the field accepts default values |
Text |
Explanation text |
Text displayed in GCON4 MFL and Excel as an explanation |
Restriction |
- |
Here you can specify a restriction. For more details, please read below. |
Example
Below an example is shown where the display name and description of the Main Project field has been changed, and the field's mandatory status has been changed from Optional to Mandatory:
- Download the Project.xml XML template from GCON4's website.
- Change the following items in the XML code.
FROM |
TO |
---|---|
. . . <Field> <DisplayName>Main project</DisplayName> <Name>HeadProject</Name> <DBName>head_project</DBName> <Mandatory>Never</Mandatory> <AcceptDefault>true</AcceptDefault> <DefaultValue/> <Type>String</Type> <Text>The main project id</Text> <Restriction source="attribute"> <AttributeId>B0</AttributeId> <AcceptEmpty>true</AcceptEmpty> <AcceptField>Project</AcceptField> </Restriction> </Field> . . . |
. . . <Field> <DisplayName>Agreement</DisplayName> <Name>HeadProject</Name> <DBName>head_project</DBName> <Mandatory>Always</Mandatory> <AcceptDefault>true</AcceptDefault> <DefaultValue/> <Type>String</Type> <Text>Agreement Id</Text> <Restriction source="attribute"> <AttributeId>B0</AttributeId> <AcceptEmpty>true</AcceptEmpty> <AcceptField>Project</AcceptField> </Restriction> </Field> . . . |
- Go to the data import folder, paste the xml file there:
- Go to the MFL06 Server Process 'XML upload'
- Enter the name of the XML file including its extension, in this example Project.xml
Note the following:
Delete check box cleared: upload the XML file to the system and modifies the structure of the excel template according to the XML.
Delete check box marked: This option is used to remove previous custom XML in case you need to replace the file in the data import folder.
The log result when running the MFL06 with the check box cleared:
The log result when running the MFL06 with the check box marked:
As a result, in the Generate window, the field and description has been renamed:
The excel should be presented like this:
Restrictions
- A field cannot be changed from Mandatory to Optional, but it can be changed from Optional to Mandatory.
- Customized data validation is not possible; however, existing validation can be removed by removing the values in the Restriction node and changing the attribute to source="none"
Example:
FROM |
TO |
---|---|
. . . <Restriction source="query"> <ValueCol>account_rule</ValueCol> <DescriptionCol>description</DescriptionCol> <TableName>aglrules</TableName> <FilterByClient>true</FilterByClient> <FilterByStatus>N</FilterByStatus> </Restriction> . . . |
. . . <Restriction source="none"> </Restriction> . . . |