Document number | Revision |
---|---|
DOCU12199 | 3 |
<type> element schema referenceIntroductionAttributesElements<type> element<column> element<execute> element<export> element<filter> element<foreign-type> element<reference> element<form> element<execute> element<field> element<html> element<object> element<object-link> element<options> element<option> element<field> element<section> element<xhtml> element<process-outline> element<process-step> element<process-steps> element<section> element<subform> element<switch> element<xhtml> element<grid> element<main> element<menu> element<execute> element<link> element<html> element<section> element<xhtml> element<process> element<step> element<ref-type> element<refinery> element<app> element<ext> element<select> element<sql-setup> element<sqlselect> element<validate> element
This reference article includes the schema documentation for the supported <type> element attributes and elements.
Attribute name | Elements | Description |
---|---|---|
_inherit | <type> | List of types to inherit. The schema will be created from the inherited type(s) left to right and finally the xml contained in this <type> element will be merged. |
add | <type> <object> | Add reference to object. |
add-parameter | <type> <object> | Additional parameters used for searching existing object. |
alias | <field> | - |
app | <ext> | Defines an application |
authentication | <column> <field> <option> | Require authentication for editing field. |
column | <column> | Defines a physical database column or a virtual column |
columns | <type> <grid> <ref-type> | List of columns to show in grid search by default. If not specified then all columns will be shown (may be overruled by grid) |
connection | <type> | Specify the name of the connection string used for database access. Connection strings are defined in web.config .Default connection string has the name default . |
create | <object> | Create new object and reference to the new object. |
cssclass | <column> <step> | This element accepts @[variable-name] .The cascading style sheet class used for column rendering. |
dependency | <type> <column> | Column names specified in dependency attribute is always loaded and will always be queried and available in data result sets. |
description | <column> <filter> <grid> | Optional description about the element. |
disable-constraint-check-on-previous-steps | <step> | Disable constraint check on previous steps. This allows process to move to next step even if constraint violations exists in one or more of the previous steps. |
disabled | <step> | Step may be disabled by setting disabled="1" .This may be used to reserve a step for future use. |
expanded | <section> <main> | Expands the form element. |
expression | <switch> | An expression to match, this attribute accepts @[] parameters, typically a @[data:column] expression. |
files | <export> | File types to include |
filter | <type> <grid> | Specifies filter that will be applied by default. Filters are defined by the <filter> element. (may be overruled by grid) |
foreign | <reference> | - |
foreign-filter | <foreign-type> | TBD. Currently only works when foreign columns are added and is very slow… currently not used anywhere. Optional. Specifies a filter that is always applied on foreign data. This may be necessary to reduce one-to-many to one-to-one. |
form-title-disabled | <field> | Disables title display. |
format | <column> | Format string. Refer to MSDN documentation. |
grid | <type> <ref-type> | Specifies grid that will be applied by default. Filters are defined by the <grid> element |
header-cssclass | <column> | The cascading style sheet class name used for column grid header rendering. |
hidden | <field> | Hide field in create form. |
img | <step> | Specifies process step image shown in upper part of process step box. This is an URL relative to base, example: img="ts/images/stage/slide0.gif" Alternatively, instead of specifying this attribute, the class ts-process-step-image may be used for styling process step. |
js | <app> | URL for JavaScript |
keycolumn | <type> | The name of the column containing an object unique value. This column is essential for identifying objects uniquely. The column must be specified for the table to be editable or referenced. If no value is provided when creating a new object, the keycolumn is given the next id from base type nextid column (which is incremented). |
local | <reference> | - |
lock | <object> | Lock reference to current child version. Default value is defined by SQL server. |
mandatory | <column> <field> <object> | If set then this element must be filled in before continuing to next workflow step. |
max | <type> <grid> | Maximum of rows to display. |
name | <type> <column> <execute> <export> <filter> <foreign-type> <form> <field> <html> <object> <object-link> <options> <option> <section> <xhtml> <process-outline> <process-step> <process-step> <subform> <switch> <grid> <main> <menu> <link> <process> <step> <ref-type> <refinery> <app> <ext> <select> <validate> | Mandatory name of the element. |
namecolumn | <type> | The name of the column containing an object unique value independent of possible revision of an object. The value is static across all revisions. |
object | <object-link> | Id or name of object. If object type supports revisions, use name to obtain link to latest approved revision. |
objlist | <column> | If set then the column represents a list of objects |
obsolete | <column> | Marks the column as obsolete. The column will not be included in the resulting schema unless custom schema clears this flag. |
oldname | <column> | - |
optional | <column> | Marks the column as optional. The column will not be included in the resulting schema unless custom schema clears this flag. |
order | <type> <grid> | Order of rows. List of database columns to be used in SQL order by clause. Following a name by - will result in descending order.This sample orders results by type ascending and eventtime descending: type;eventtime- (may be overruled by grid) |
parameters | <object> | Additional parameters to be transferred to new child object.@[] parameters are accepted. |
processname | <app> | The windows process name. |
properties | <refinery> | Url for property xml file. |
read | <type> | - |
ref-write | <type> | List of vector roles. Defines write permission for references. Extends write attribute, so actual value will include roles specified in write attribute. |
refcolumns | <type> <grid> | List of columns to be shown in <grid> or <type> when displaying references. |
refilter | <type> | Filter used when showing references (may be overruled by grid) |
refine | <refinery> | Determines if edit buttons is shown and if refine is done. |
reforder | <type> <grid> | List of database columns to be used in sql order by clause. Following a name by - will result in descending order.(may be overruled by grid) |
reload | <column> | Reloads web page when column is written. This is useful when writing a column will update other columns and the new values should be presented to user. |
resourcecolumns | <type> | List of columns containing roles that are allowed to work on object. |
search-parameter | <object> | - |
showcount | <section> | Shows data record count in section head. This attribute is only valid when URL attribute is specified. |
sqldefault | <column> | Default value of SQL data column |
sqlfilter | <type> | Specifies a raw SQL filter that will be appended as an AND term to the WHERE clause.The filter will also work from foreign links if proper path is specified. The path [.] will refer to the current level (current table).This attribute may be given as an element as well since SQL queries can be quite complex with special characters that cannot easily be contained in an attribute. |
sqlidentity | <column> | Specifies if SQL data column is an identity column. |
sqlmanage | <type> | sqlmanage="0" is the default and instructs Turbostage to not manage the SQL tablesqlmanage="1" instructs Turbostage to enable the management of the SQL table.When integrating foreign types this field should typically have the value “0”. For public TurboStage tables the value will typically be “1”. If the value is “1” then TurboStage will apply schema and attempt to create non-existent tables and columns in addition to execute <sql-setup> elements as well as make changes to SQL table columns that does not match the XML definition. When integrating to foreign systems this value should be ‘0’ (default) and userid used by TurboStage to access the foreign system database should be readonly , to avoid unintended redefinition of foreign system database. |
sqlnull | <column> | Specifies if SQL data column allows null values. |
sqlselect | <column> | This attribute is only valid for virtual columns. May be replaced by a \<sqlselect> element. An SQL select statement returning a single column. |
sqlsize | <column> | Size of SQL data column (where applicable) |
sqltable | <type> | Fully qualified path to table. If table resides in default TurboStage database then this may be name of database otherwise it must a fully qualified path in the form: [server.]database.schema.table for example server1.axapta.dbo.inventtable or just axapta.dbo.inventtable if the Axapta database resides on the same SQL server as TurboStage.More than one type may exist in the same table. If this is the case then typecolumn and typecolumnvalue attributes must be specified.Alternatively the sqlselect element (below) may be used to specify an SQL view. |
sqltype | <column> | Specifies SQL column type. |
src | <execute> | URL path to execute |
step | <process-step> | A number of steps may be defined for the process. The steps must be named step1 to max step14 (may be extended by setting parameter (MaxStep). Refer to <step> element |
step-column | <process> | Name of column containing step index. Default is step . |
step-write | <process> | Defines additional vector roles that are allowed to change step. Inherits by default write vector roles and step resource. May be extended by setting this value to additional roles. |
subtypecolumn | <type> | Specifies the subtype column. This attribute must always be specified if subtypes for this type are to be used. |
system | <section> | - |
target | <link> | Target frame (same values as html A _target attribute). |
text-add | <column> | When text field with the text-add attribute is edited, the field text in edit dialog is empty. When the user enters text and clicks OK the text is either appended or prepended to the existing field text in database, also datetime and user id is added. Previously entered text cannot be modified. |
timeoutfile | <refinery> | Timeout in seconds used on file related operations like open, export, save. |
timeoutgeneral | <refinery> | Timeout in seconds used for all operations not related to file. |
tiptext | <field> <object> | Tip text displayed when mouse is over element. |
title | <type> <column> <filter> <form> <object-link> <section> <subform> <grid> <main> <step> <select> | The title of the element. This text is what the user will see. If not specified the name attribute will be used as title. |
titlecolumn | <type> | The name of the column containing an object unique value independent of possible revision of an object. The value is static across all revisions. |
treecolumns | <type> | List of columns to be shown in reference grid when references are shown as tree. This will typically be as few as possible to make tree easier to read and not expand too much horizontally. |
trustees | <section> | List of vector roles allowed to see element. |
trusteescolumns | <type> | List of columns containing roles that are allowed to see object. Currently these columns should be added to dependency attribute. In the future trusteescolumn may be added automatically. |
type | <column> <foreign-type> <object> <object-link> <section> | Name of type. |
typecolumn | <type> | Specifies the type column. When more than one type exists in the same table then this attribute as well as typecolumnvalue must be specified. |
typecolumnvalue | <type> | Specifies a column filter value for typecolumn . When more than one type exists in the same table then this attribute as well as typecolumn must be specified. |
types | <grid> | Linked types to display as sections |
uikeycolumn | <type> | - |
url | <type> <column> <section> <main> <link> <select> | Specifies URL for element use. |
urls | <type> | URL to show multiple objects as a list. If this parameter has not been specified then a link for each object will be shown instead using the URL attribute. |
value | <field> | Specifies element value. |
values | <column> | Defines a list of possible data values. |
valuetitles | <column> | Defines labels to values attribute. If not specified or if valuetitle are empty then values are used as labels. |
virtual | <column> | Specifies if column is a physical database column or a virtual column. |
visualcolumn | <step> | This column is shown in the lower part of the process step box. Typically date and/or resource. |
workspacecolumn | <type> | If specified then this type will make use of workspace security and objects must be related to a workspace. An attempt to create an object without specifying a workspace will fail and result in an exception. |
write | <type> <column> <object> <process> <step> | List of vector roles. Defines write permissions on column. These permissions overrules write permissions defined on type element. Process step may also define write permissions applied when the step is the active process step. |
x-index | <subform> | x position relative to main form. Main form has 0 as x-index. |
xpath | <column> | - |
y-index | <subform> | y position relative to main form. Main form has 0 as y-index. |
The type element defines a specific object type.
Attributes:
Name | Description |
---|---|
columns | List of columns to show in grid search by default. If not specified then all columns will be shown (may be overruled by grid) |
connection | Specify the name of the connection string used for database access. Connection strings are defined in web.config .Default connection string has the name default . |
dependency | Column names specified in dependency attribute is always loaded and will always be queried and available in data result sets. |
filter | Specifies filter that will be applied by default. Filters are defined by the <filter> element. (may be overruled by grid) |
grid | Specifies grid that will be applied by default. Filters are defined by the <grid> element. |
_inherit | List of types to inherit. The schema will be created from the inherited type(s) left to right and finally the xml contained in this <type> element will be merged. |
keycolumn | The name of the column containing an object unique value. This column is essential for identifying objects uniquely. The column must be specified for the table to be editable or referenced. If no value is provided when creating a new object, the keycolumn is given the next id from base type nextid column (which is incremented). |
name | The name of the type. The name must be unique. If not unique it will be merged with other <type> elements with the same name.Internally TurboStage will convert the name to lowercase for use in case-sensitive .NET collections. Use the title column to give a short but proper user friendly name shown on web pages. References to this type are done using the name given to the type and the reference is not case sensitive. However Internally name will be stored in lowercase and custom code making collection lookup must use lowercase name to avoid exception. |
namecolumn | The name of the column containing an object unique value independent of possible revision of an object. The value is static across all revisions. |
max | Maximum number of hits to return when searching for objects of this type. (may be overruled by grid) |
order | List of database columns to be used in SQL order by clause. Following a name by - will result in descending order.This sample orders results by type ascending and eventtime descending: type;eventtime- (may be overruled by grid) |
read | - |
refcolumns | List of columns to be shown in reference grid. (may be overruled by grid) |
refilter | Filter used when showing references (may be overruled by grid) |
reforder | List of database columns to be used in sql order by clause. Following a name by - will result in descending order. (may be overruled by grid) |
ref-write | List of vector roles. Defines write permission for references. Extends write attribute, so actual value will include roles specified in write attribute. |
resourcecolumns | List of columns containing roles that are allowed to work on object. |
subtypecolumn | Specifies the subtype column. This attribute must always be specified if subtypes for this type are to be used. |
sqlfilter | Specifies a raw SQL filter that will be appended as an AND term to the WHERE clause.The filter will also work from foreign links if proper path is specified. The path [.] will refer to the current level (current table).This attribute may be given as an element as well since SQL queries can be quite complex with special characters that cannot easily be contained in an attribute. Sample: [.].dataareaid='d1' as a format string ensures that only data from datareadid d1 will be selected |
sqlmanage | sqlmanage="0" is the default and instructs Turbostage to not manage the SQL tablesqlmanage="1" instructs Turbostage to enable the management of the SQL table.When integrating foreign types this field should typically have the value “0”. For public TurboStage tables the value will typically be “1”. If the value is “1” then TurboStage will apply schema and attempt to create non-existent tables and columns in addition to execute <sql-setup> elements as well as make changes to SQL table columns that does not match the XML definition. When integrating to foreign systems this value should be ‘0’ (default) and userid used by TurboStage to access the foreign system database should be readonly , to avoid unintended redefinition of foreign system database. |
sqltable | Fully qualified path to table. If table resides in default TurboStage database then this may be name of database otherwise it must a fully qualified path in the form: [server.]database.schema.table for example server1.axapta.dbo.inventtable or just axapta.dbo.inventtable if the Axapta database resides on the same SQL server as TurboStage.More than one type may exist in the same table. If this is the case then typecolumn and typecolumnvalue attributes must be specified.Alternatively the sqlselect element (below) may be used to specify an SQL view. |
title | User friendly title shown on web pages where relevant to the type. Title should have relation to name to make system transparent and easy to understand. If this attribute has not been specified then the name attribute will be used as title. |
titlecolumn | The name of the column containing an object unique value independent of possible revision of an object. The value is static across all revisions. |
typecolumn | Specifies the type column. When more than one type exists in the same table then this attribute as well as typecolumnvalue must be specified. |
typecolumnvalue | Specifies a column filter value for typecolumn . When more than one type exists in the same table then this attribute as well as typecolumn must be specified. |
treecolumns | List of columns to be shown in reference grid when references are shown as tree. This will typically be as few as possible to make tree easier to read and not expand too much horizontally. |
trusteescolumns | List of columns containing roles that are allowed to see object. Currently these columns should be added to dependency attribute. In the future trusteescolumn may be added automatically. |
uikeycolumn | - |
url | May contain @[<variable-name>] URL to show object of this type. This may be a TurboStage web page like /ts/object.aspx or an external web page in another system. If the URL ends with = the object id will be appended to the URL at runtime. |
urls | URL to show multiple objects as a list. If this parameter has not been specified then a link for each object will be shown instead using the URL attribute. |
workspacecolumn | If specified then this type will make use of workspace security and objects must be related to a workspace. An attempt to create an object without specifying a workspace will fail and result in an exception. |
write | List of vector roles. Defines write permission for data of this type. This setting at type level may be overruled at column level. Also process step element may define write permissions for columns contained in the step form to be applied when the step is active. |
Elements:
Name | Description |
---|---|
<column> | Defines a physical database column or a virtual column |
<execute> | Execute URL after schema load. |
<filter> | Defines a filter selecting specific data. |
<foreign-type> | Link the current type to a foreign type |
<form> | Defines a form |
<grid> | Defines a grid |
<hooks> | Delegates complex rendering and business logic to specific aspx page |
<main> | Defines a standard main page fragment for the type |
<menu> | Defines a standard menu for the type |
<sql-setup> | - |
<select> | Defines how to select objects. Multiple select elements may be specified. Each select element will present one section to the user to select objects objects from. |
<sqlselect> | Defines a SQL view. This element may be used instead of sqltable attribute. If both table attribute and element are specified then the attribute takes precedence. |
<validate> | Defines how to validate object identities. Multiple validate elements may be specified. The validate elements will be iterated until the object is found. If the object is not found then an error will be presented to the user. |
Sample:
The following sample defines the customer object type. Refer to type element documentation for details.
<type name="customer" title="Customer" inherit="ts_entity" max="100" order="obj" columns="customer;active;name;manager" url="/ts/object.aspx?t=customer&o=">
<menu title="Customers" expanded="0">
<link title="Search" url="/ts/objects.aspx?t=customer&objtype=customer&active=1" />
<link title="New" url="/ts/object/new.aspx?t=customer&objtype=customer"/>
</menu>
<column virtual="1" name="Customer" type="customer" column="obj" />
<form name="default">
<field name="Customer" />
<field name="Name" />
<field name="Contact" />
<field name="Url" />
<field name="IP" />
<field name="Note" />
<field name="Manager" />
<field name="Trustees" />
<field name="Active" />
<field name="IsWorkspace" />
<field name="TransferFolder" />
</form>
</type>
Defines a physical database column.
Attributes:
Name | Description | Values or Samples |
---|---|---|
authentication | If set then changing column value requires authentication. | Disable (default): authentication="0" Enable: authentication="1" |
changenote | If set then this column requires a descriptive text (rationale) to be written when updating the column value. The rationale for the update will appear in the event log | Disable (default):changenote="0" Enable: changenote="1" |
column | This attribute is only valid for virtual columns. Links a virtual column to a physical column. | |
cssclass | This element accepts @[variable-name] .The cascading style sheet class used for column rendering. | |
dependency | List of columns to be loaded in addition to this column whenever this column is referenced for example in a grid. Typically this is used if rendering the column is dependent on other column data values. | |
description | Description of column. | |
format | Format string. Refer to MSDN documentation. | The format string {0:F1} formats the number to one decimal |
header-cssclass | The cascading style sheet class name used for column grid header rendering. | |
mandatory | If set then this column must be filled in before continuing to next workflow step. | Disable (default): mandatory="0" Enable: mandatory="1" |
name | The name must be unique. If not unique it will be merged with other <column> elements with the same name. Internally TurboStage will convert the name to lowercase for use in case-sensitive .NET collections. References to this column are done using the name given to the column and the reference is not case sensitive. However Internally name will be stored in lowercase and custom code making collection lookup must use lowercase name to avoid exception. | |
objlist | If set then the column represents a list of objects | Disable (default): objlist="0" Enable: objlist="1" |
obsolete | Marks the column as obsolete. The column will not be included in the resulting schema unless custom schema clears this flag. | Disable (default): obsolete="0" Enable: obsolete="1" |
oldname | - | - |
optional | Marks the column as optional. The column will not be included in the resulting schema unless custom schema clears this flag. | Disable (default): optional="0" Enable: optional="1" |
reload | Reloads web page when column is written. This is useful when writing a column will update other columns and the new values should be presented to user. | Disable (default): reload="0" Enable: reload="1" |
sqltype | Specifies SQL column type. | |
sqlnull | Specifies if SQL data column allows null values. | Disable (default): sqlnull="0" Enable: sqlnull="1" |
sqldefault | Default value of SQL data column | |
sqlselect | This attribute is only valid for virtual columns. May be replaced by a \<sqlselect> element. An SQL select statement returning a single column. | |
sqlsize | Size of SQL data column (where applicable) | |
sqlidentity | Specifies if SQL data column is an identity column. | Disable (default): sqlidentity="0" Enable: sqlidentity="1" |
text-add | When text field with the text-add attribute is edited, the field text in edit dialog is empty. When the user enters text and clicks OK the text is either appended or prepended to the existing field text in database, also datetime and user id is added. Previously entered text cannot be modified. | Append: Appends text to the end of database field. Prepend: Prepends text to start of database field |
title | User friendly title shown on web pages where relevant to the column. Title should have relation to name to make system transparent and easy to understand. If this attribute has not been specified then the name attribute will be used as title. | |
type | Accepts runtime variables @[variable-name] parameter.Name of type. The type controls value selection, ex. validation or URL. | |
url | If URL attribute is specified then the runtime column data value will be added to the URL. If the column data value starts with the URL attribute then only the remaining part will be added. | URL attribute: http:// Runtime data: http://www.cnn.com result: http://www.cnn.com |
values | Defines a list of possible data values. | |
valuetitles | Defines labels to values attribute. If not specified or if valuetitle are empty then values are used as labels. | |
virtual | Specifies if column is a physical database column or a virtual column. | Physical (default): virtual="0" Virtual: virtual="1" |
write | List of vector roles. Defines write permissions on column. These permissions overrules write permissions defined on type element. Process step may also define write permissions applied when the step is the active process step. | |
xpath | - | - |
Elements:
Name | Description | Values or Samples |
---|---|---|
cform | Defines a column form. The following subset of the <type>/<form> elements are available: <field> <xhtml> <section> Refer to <form> element documentation for a description on the above elements. The dependency attribute are available to specify database columns explicitly required to be loaded from database for the cform to run. | Check Samples below for an example of cform element. |
input-guide | Creates a descriptive field associated with a column. Here you can input descriptions, warning, links etc. | <input-guide name="default>"</input-guide> See sample below |
select | Specifies an URL to a list of valid column values. The list is available in the column edit popup as a section. More than one element may exist so that several list may be available to user. | Valid attributes are: Disable (default): expanded="0" Enable: expanded="1" expanded : show the section as expandedname : Name of select element. Used for merging and used as title if no title has been specified.title : Title of section.url : URL to grid to select values from. |
validate | - | - |
values | List of valid column values. The title attribute is optional, if not specified the name attribute is used as value. The value attribute is optional, if not specified the name attribute is used as value. | Check Samples below for an example of values element. |
xcolumns | Specifies a list of columns that replaces the current column in grid. All columns must exist in the same type. The grid element provides an alternative way to specify many columns as a set and may also be used cross type and tables. | - |
Samples:
The following sample shows the cform
element used:
xxxxxxxxxx
<column name="description">
<cform name="default">
<xhtml name="default" dependency="subtype.name">
<i>@[subtype.name] for</i>
</xhtml>
<field name="description" />
</cform>
</column>
The following sample shows the values
element used:
xxxxxxxxxx
<values name=”…”>
<value name=”…” title=”…” description=”…” >
<value name=”…” title=”…” description=”…” >
<values>
The following sample makes use for an input-guide
for Change Notes on documents where HTML is inserted using the xhtml element:
xxxxxxxxxx
<type name="doc">
<column name="Note">
<input-guide name="default">
<xhtml name="default"><![CDATA[ <i class="far fa-info-circle"></i> <span>The content of this item is Read-only </span><a href="#">Read more here</a> ]]></xhtml>
</input-guide>
</column>
</type>
The following input guide are added to the Change note column:
The <execute>
element executes a “code behind” .aspx file on local server. The .aspx file may initialize extended “code behind” functionality and setting including delegates.
Attributes:
Name | Description |
---|---|
name | Name of the element |
src | Local URL to .aspx file. The t parameter will be added to url to identify which type to initialize. |
Samples:
The following sample shows an initialization of custom object security.
xxxxxxxxxx
<execute name="customObjectSecuritySample" src="~/ts/documentation/samples/customobjectsecurity.aspx" />
The <export>
tag defines export format for example for BOM export.
Attributes:
Name | Description |
---|---|
name | Name of the element |
files | File types to include |
Elements:
Name | Description |
---|---|
column | Define an export column, valid attributes for the column are name which is a valid grid column name, and a title which is the column title in export result. |
Samples:
The following sample shows how to use <export>
to define an export format.
xxxxxxxxxx
<export name="default" files=".pdf">
<column name="ts_ref.parenttype" title="ParentType" />
<column name="ts_ref.parent" title="Parent" />
<column name="ts_ref.childtype" title="ChildType" />
<column name="ts_ref.child" title="Child" />
<column name="alias" title="Alias" />
<column name="subtype.name" title="Subtype" />
<column name="description" title="Title" />
<column name="ts_ref.qty" title="Quantity" />
<column name="ts_ref.pos" title="Position" />
<column name="ts_ref.comment" title="Comment" />
</export>
The <filter>
tag defines a data filter that may be applied by default (see type element filter attribute) or set by the _filter
URL parameter.
Attributes:
Name | Description |
---|---|
name | Name of the filter |
title | Optional title of filter displayed on web pages. If no title attribute has been defined then the name attribute will be used as title. |
description | Optional information to user about filter |
trustees | Optional list of vector roles allowed to see element. |
Samples:
The following sample defines a filter for selecting (latest or latest approved) and not obsolete items where everyone has access :
xxxxxxxxxx
<filter name="latestorlatestapproved" title="Latest + latest approved" trustees="Everyone" >
<![CDATA[([.].[latest]=1 OR [.].[latestapproved]=1) AND [.].[obsolete]=0]]>
</filter>
The <foreign-type>
tag allows linking types.
Attributes:
Name | Description |
---|---|
name | Name of the foreign reference |
type | Name of foreign type |
foreign-filter | TBD. Currently only works when foreign columns are added and is very slow… currently not used anywhere. Optional. Specifies a filter that is always applied on foreign data. This may be necessary to reduce one-to-many to one-to-one. |
Elements:
Name | Description |
---|---|
<reference> | Specifies how type is linked to foreign type |
Attributes:
Name | Description |
---|---|
Local | Column name of local bind column. |
Foreign | Column name of foreign bind column |
Samples:
The following sample shows how the item type is linked to the workspace type:
xxxxxxxxxx
<foreign-type name="workspace" type="workspace">
<reference name="workspace" local="workspace" foreign="obj" />
</foreign-type>
The types may be bound using several columns, this sample shows how the item type is linked to the eventlog
type:
xxxxxxxxxx
<foreign-type name="eventlog" type="eventlog">
<reference name="objtype" local="objtype" foreign="objtype" />
<reference name="item" local="item" foreign="obj" />
</foreign-type>
The local bind column may actually be located in another liked type, this is for advanced use. The following sample shows how to link one level of Axapta BOMVERSION/BOM to next BOMVERSION/BOM level for BOM drill down:
xxxxxxxxxx
<type name="@@[typePrefix]BOM" … >
…
<foreign-type name="bomversion2" type="@@[typePrefix]BOMVERSION">
<reference local="itemid" foreign="name" />
<reference local="dataareaid" foreign="dataareaid" />
</foreign-type>
<foreign-type name="bom" type="="@@[typePrefix]BOM">
<reference local="bomversion2.bomid" foreign="bomid" />
<reference local="dataareaid" foreign="dataareaid" />
</foreign-type>
…
</type>
Attributes:
Name | Attributes |
---|---|
name | The name of the form. Using ‘create’ or ‘default’ as name will make it the default form to create or view objects of this type. |
title | Optional title |
Elements:
Name | Description |
---|---|
<feature> | - |
<field> | Column field |
<html> | <html> block containing markup text |
<object> | Object list with the possibility to create new objects of this type/subtype |
<options> | Option alternatives presented to user |
<outline> | Process outline |
<process-outline> | Process outline, a visual presentation of the stage/gate process. |
<process-step> | The currently active process step |
<process-steps> | All enabled process steps |
<section> | Section block |
<switch> | - |
<xhtml> | <xhtml> block containing markup text, must be valid <xhtml> with no CDATA |
Executes the handler for the specified virtual path in the context of the current request. The output is directed to current page.
Attributes:
Name | Description |
---|---|
name | Name used for schema merging |
src | URL path to execute. May be local path starting with ~/ |
Samples:
xxxxxxxxxx
<execute name="Options" src="~/schema/highstage/aspx/options.exe.aspx" />
Defines fields to be displayed on form or in a process step. Observe that field element can not define permissions on field, security must be defined on type, column and process step.
Attributes:
Name | Description | Values |
---|---|---|
authentication | Require authentication for editing field. | Disable: authentication="0" Enable (default): authentication="1" |
form-title-disabled | Disables title display. | Disable: form-title-disabled="0" Enable (default): form-title-disabled="1" |
hidden | Hide field in create form. | Disable: hidden="0" Enable (default): hidden="1" |
mandatory | Mandatory flag used in create form and process steps. | Disable: mandatory="0" Enable (default): mandatory="1" |
name | Name used for schema merging. | |
tiptext | Tip text displayed when mouse is over element. | |
value | Default value in create form. | Disable: value="0" Enable (default): value="1" |
Contains html to be displayed. @[]
parameters are accepted. Provided for backward compatibility, <xhtml> element should be used instead with minimum use of CDATA
.
Attributes:
Name | Description |
---|---|
name | Name used for schema merging |
Specifies child objects.
Attributes:
Name | Description | Values |
---|---|---|
add | Add reference to object. | Disable: add="0" Enable (default): add="1" |
add-parameters | Additional parameters used for searching existing object. | |
create | Create new object and reference to the new object. | Disable: create="0" Enable (default): create="1" |
lock | Lock reference to current child version. Default value is defined by SQL server. | Disable: lock="0" Enable: lock="1" |
mandatory | Specifies if object is mandatory. | Disable (Default): mandatory="0" Enable: mandatory="1" |
max-count | Specifies a maximum number of items to be referenced before the parent item can be progressed any further. Requires mandatory to be enabled. | Example:max-count="3" specifies that a maximum number of three items must be referenced. |
min-count | Specifies a minimum number of items to be referenced before the parent item can be progressed any further. Requires mandatory to be enabled. | Example:min-count="1" specifies that a minimum number of one item must to be referenced. |
min-step | Specifies that referenced Actions must be at a minimum step before the parent item can be progressed any further. Requires mandatory to be enabled. | Example:min-step="2" specifies that a referenced action needs to be at minimum step 2 before an item can be progressed. |
min-status | Specifies that referenced Documents/Parts/Devices must be with a minimum status before the parent item can be progressed any further. Requires mandatory to be enforced. | "1" : Referenced document must be in Working."2" : Referenced document must be in Freeze."3" : Referenced document must be in Review."4" : Referenced document must be in Approval.(Default, if not specified) "5" : Referenced document must be in Approved. |
name | Name of element instance. | |
parameters orcreate-parameters | Additional parameters to be transferred to new child object.@[] parameters are accepted.(If no Workspace is defined, the parent Workspace will be assigned by default.) (If no Description is added, the parent description will be inherited.) | |
search-parameters | Parameters added to search URL. Parameter values must be URL encoded. | Sample searching description column for x=y description=x%3Dy |
tiptext | Tip text displayed when mouse is over element. | |
type | Basetype or subtype. | |
write | List of vector roles, to allow resource to create/add object even though resource does not have general write permissions for references. Vectors are inherited from type, process and step elements. The write value may start with ‘+’ to add vector roles, otherwise the vectors will be overruled. |
Samples:
Sample specifying a RS (Requirements Specification).
If searching for an existing RS the search filter is set to Latest Approved. When creating new child RS the new child note and alias are set as well as reviewer set:to
parent manager and customer set to same value as parent:
xxxxxxxxxx
<object name="RS" type="RS" add-parameters="_filter=latestapproved" parameters="note=test-note&alias=test-alias&reviewby=@[data:manager]&customer=@[data:customer]" />
Sample using search-parameters to specify search filter:
xxxxxxxxxx
<object name="bugs" type="bugs" search-parameters="_filter=open" title="Open bugs"/>
Specifies child objects.
Attributes:
Name | Description |
---|---|
name | Name of element instance |
title | Title displayed in form. |
type | Basetype or subtype of linked object. |
object | Id or name of object. If object type supports revisions, use name to obtain link to latest approved revision. |
Samples:
xxxxxxxxxx
<object-link name="process" title="Process Description" type="doc" object="SOP12345" />
Present user with one or more alternative options for an object. When user clicks an option button the corresponding option form is presented to user for further action.
Attributes:
Name | Description |
---|---|
name | Name of element instance |
Elements:
Name | Description |
---|---|
option | Option transaction form |
The <option>
element contains a form with fields that may or may not be edited by user. When user clicks OK button the form is packed as an XML transaction and send to the transaction XmlHttp service.
Attributes:
Name | Description |
---|---|
authentication | - |
name | - |
Elements:
Name | Description |
---|---|
field | - |
section | Container for same element types contained in option element (this table) |
xhtml | - |
Attributes:
Name | Description |
---|---|
alias | - |
authentication | - |
hidden | - |
name | Name of field |
mandatory | - |
value | Default value of field written to database. If not specified then value is loaded from database as default value. The default value may or may not be edited by user. |
A simplified section element for grouping content.
Attributes:
Name | Description |
---|---|
name | Name used for schema merging. |
title | Title displayed in section |
Strict xhmt to be be displayed. Do not use CDATA in this element, if CDATA element is required then <html>
element must be used.
Attributes:
Name | Description |
---|---|
name | Name used for schema merging. |
Displays process outline, a visual stage/gate presentation.
Attributes:
Name | Description |
---|---|
name | Name used for schema merging. |
Displays active process step.
Attributes:
Name | Description |
---|---|
name | Name used for schema merging. |
step | Leave blank to use active step. |
Displays all process steps.
Attributes:
Name | Description |
---|---|
name | Name used for schema merging. |
Acts as a form in a <form> element meaning that same attributes and elements defined in form applies to section element in addition to the following:
Attributes:
Name | Description | Values |
---|---|---|
name | Name of section. Used for schema merging. | |
expanded | Disable (default): expanded="0" Enable: expanded="1" | |
url | May contain runtime variables @[variable-name] | |
showcount | Shows data record count in section head. This attribute is only valid when URL attribute is specified. | |
trustees | List of vector roles allowed to see element. | |
title | The title of the section. This text is what the user will see. If not specified the name attribute will be used as title. |
Samples:
Sample implementing Action, Document and Part sections in project type:
xxxxxxxxxx
<type name="project">
<form name="default">
<section name="actions" title="Actions" showcount="1" url="~/ts/search.aspx? t=action&workspace==@[obj]"/>
<section name="documents" title="Documents" showcount="1" url="~/ts/search.aspx? t=doc&workspace=@[obj]"/>
<section name="part" title="Parts" showcount="1" url="~/ts/search.aspx? t=part&workspace=@[obj]"/>
</form>
</type>
Acts as a form in a form element meaning that same attributes and elements defined in form applies to section element in addition to the following:
Attributes:
Name | Description |
---|---|
name | Name of subform. Used for schema merging. |
x-index | x position relative to main form. Main form has 0 as x-index. |
y-index | y position relative to main form. Main form has 0 as y-index. |
title | Title displayed at top of form. |
Important All subforms must be defined at the same outmost level in the form since this is the only level searched for subforms.
Samples:
The modern theme form provides good sample for this: ../../themes/modern/theme.xml
Attributes:
Name | Description |
---|---|
name | Name used for schema merging. |
expression | An expression to match, this attribute accepts @[] parameters, typically a @[data:column] expression. |
Elements:
Name | Description | Attributes & Elements |
---|---|---|
case | Defines a case which matches expression for a specific value. | Attributes:name for schema merging.value for listing one or more values. Leaving an empty value field will assign NULL to the value.Elements: Any form element. |
default | Defines a fallback if no matching case. |
Samples:
Sample used in device.schema.xml
to alter part default form:
xxxxxxxxxx
<switch name="TypeSpecific" expression="@[data:objtype]">
<case name="part" value="part">
<switch name="DevicesFree" expression="@[data:subtype.devicetype]">
<case name="NoDeviceType" value="">
</case>
<default name="AnyDeviceType">
<field name="DevicesFree" />
</default>
</switch>
</case>
</switch>
Sample used in type.schema.xml
to customize forms for different subtypes:
xxxxxxxxxx
<switch name="type" expression="@[data:objtype]">
<case name="doc" value="doc;part;device">
<field name="ReviewBy" />
<field name="ReviewByManager" />
<field name="ApproveBy" />
<field name="ApproveByManager" />
<field name="ApproveByEnforcement" />
<field name="TemplateReference" />
<field name="ConfidentialityLevel" />
<field name="ReviewTemplate" />
<field name="DisableRefine" />
<field name="DisableSignAuth" />
<xhtml name="-">
<hr/>
</xhtml>
</case>
<case name="part" value="part;device">
<field name="StaticPath" />
<field name="Revisions" />
<xhtml name="-">
<hr/>
</xhtml>
</case>
<case name="device" value="part">
<field name="DeviceType" />
<xhtml name="-">
<hr/>
</xhtml>
</case>
</switch>
Contains XHTML fragment to be written to client. The fragment may contain runtime variables @[variable-name]
that are replaced with data values.
Attributes:
Name | Description |
---|---|
name | Name used for schema merging. |
Samples:
xxxxxxxxxx
<xhtml>
<a href="/ts/objects.aspx?t=@[t]&item=@[name]">Change history</a>
</xhtml>
Attributes:
Name | Description |
---|---|
columns | List of columns to be displayed |
description | Optional information to user about grid |
filter | Filter |
max | Maximum of rows to display |
name | Mandatory name of element |
order | Order of rows |
refcolumns | List of columns to be displayed when showing references. |
reforder | List of database columns to be used in SQL order by clause. Following a name by - will result in descending order. |
title | Optional title of filter displayed on web pages. If no title attribute has been defined then the name attribute will be used as title. |
types | Linked types to display as sections |
Attributes:
Name | Description |
---|---|
expanded | - |
name | - |
title | - |
url | - |
Elements:
Name | Description |
---|---|
- | - |
Attributes:
Name | Description |
---|---|
name | - |
Elements:
Name | Description |
---|---|
execute | Execute a local sub page |
hide-outer-section | - |
html | - |
link | - |
menu | See section element |
section | - |
xhtml | - |
Executes a local web sub page and appends the output to the current page.
Samples:
Sample using URL relative to current application
xxxxxxxxxx
<execute name="menufooter" src="~/ts/main/menufooter.exe.aspx" />
Adds a hyperlink (html A element). The xhtml element could replace the link element since the xhtml
element provides more flexibility to define any html.
Attributes:
Name | Description |
---|---|
name | Name of element instance |
target | Target frame (same values as html A _target attribute). |
url | url to web page. |
Elements:
Name | Description |
---|---|
- | - |
Html to be displayed. Should be encapsulated in CDATA
Samples:
xxxxxxxxxx
<html><![CDATA[<div align=center><img src="tweak/logo.gif"/></div>]]></html>
Acts as a form in a form element meaning that same attributes and elements defined in form applies to section element in addition to the following:
Attributes:
Name | Description | Values |
---|---|---|
expanded | Disable (default): expanded="0" Enable: expanded="1" | |
name | Name of element instance | |
system | - | |
title | Title to be displayed in section bar | |
trustees | List of vector roles allowed to see element. | |
showcount | Shows data record count in section head. This attribute is only valid when URL attribute is specified. | |
type | Insert standard menu from specified type | |
url | Optional URL to web page to be loaded in section. If omitted then content of <section> element will be used instead of URL. |
Elements:
Name | Description |
---|---|
- | - |
Strict xhtml
to be be displayed. Do not use CDATA in this element, if CDATA element is required then defer to use of <html>
element.
Defines process for the type.
Attributes:
Name | Description |
---|---|
name | Name of process. Used for schema merging. |
step-column | Name of column containing step index. Default is step . |
step-write | Defines additional vector roles that are allowed to change step. Inherits by default write vector roles and step resource. May be extended by setting this value to additional roles. |
write | List of vector roles to be granted write permission. |
Elements:
Name | Description |
---|---|
step | A number of steps may be defined for the process. The steps must be named step1 to max step14 (may be extended by setting parameter (MaxStep). Refer to <step> element |
Defines a process step.
Attributes:
Name | Description | Values |
---|---|---|
name | Name of process. Used for schema merging. | |
cssclass | Defines the cascading style sheet class for the step. This may be used for changing color and text style for a step. | |
disabled | The step may be disabled by setting disabled="1" .This may be used to reserve a step for future use. | Enable (default): disabled="0" Disable: disabled="1" |
disable-constraint-check-on-previous-steps | Disable constraint check on previous steps. This allows process to move to next step even if constraint violations exists in one or more of the previous steps. | Enable (default): disable-constraint-check-on-previous-steps="0" Disable: disable-constraint-check-on-previous-steps="1" |
img | Specifies process step image shown in upper part of process step box. This is an URL relative to base, example: img="ts/images/stage/slide0.gif" Alternatively, instead of specifying this attribute, the class ts-process-step-image may be used for styling process step. | |
title | The title of the step. This text is what the user will see. Default value is name attribute. | |
visualcolumn | This column is shown in the lower part of the process step box. Typically date and/or resource. | |
write | List of vector roles to be granted write permission when this step is active. Fields contained in this step will inherit the step write permission, however field elements within the step element may overrule the permission inherited from step element. The field security will be enforced no matter where the field is viewed (form, step section, or search grid). When this step is not active the value of this attribute has no effect. |
Elements:
The process element can contain any form element.
Controls reference functionality like columns and grid in search grid.
Attributes:
Name | Description |
---|---|
name | Name used for schema merging. For ref element this must be same as child basetype or subtype. |
columns | List of columns to be displayed in search grid.. |
grid | Name of grid to be used in search grid. |
Elements:
Name | Description |
---|---|
- | - |
Samples:
xxxxxxxxxx
<type name="action">
<ref-type name="part" columns="Item;Description;steps" />
</type>
<type name="part">
<ref-type name="part" grid="bom" />
</type>
Attributes:
Name | Description | Values |
---|---|---|
name | Name used for schema merging. For refinery element this must be file or folder | |
properties | Url for property xml file. | |
refine | Determines if edit buttons is shown and if refine is done. | Disable: refine="0" Primary file: refine="1" Matching files: refine="2" All files in folder: refine="3" |
timeoutgeneral | Timeout in seconds used for all operations not related to file. | |
timeoutfile | Timeout in seconds used on file related operations like open, export, save. |
Elements:
Name | Description |
---|---|
app | Defines an application |
ext | Defines a file type |
Samples:
The following xml sample refines all files with known extensions using properties file custom_properties.aspx
located in tweak folder.
General timeout is set to 30 seconds and file related timeout is set to 300 seconds.
xxxxxxxxxx
<refinery name="file" refine="3" timeoutgeneral="30" timeoutfile="300" properties="~/tweak/custom_properties.aspx">
<ext name=".doc" app="ms_word" />
<ext name=".docx" app="ms_word" />
<ext name=".docm" app="ms_word" />
<ext name=".odt" app="ms_word" />
<ext name=".xls" app="ms_excel" />
<ext name=".xlsx" app="ms_excel" />
<ext name=".xlsm" app="ms_excel" />
<ext name=".ppt" app="ms_powerpoint" />
<ext name=".pptx" app="ms_powerpoint" />
<ext name=".pptm" app="ms_powerpoint" />
<app name="ms_word" js="~/ts/refinery/js/ms_word.js" processname="WINWORD" />
<app name="ms_excel" js="~/ts/refinery/js/ms_excel.js" processname="EXCEL" />
<app name="ms_powerpoint" js="~/ts/refinery/js/ms_powerpoint.js" processname="POWERPNT" />
<app name="ms_project" js="~/ts/refinery/js/ms_project.js" processname="WINPROJ" />
<app name="ms_visio" js="~/ts/refinery/js/ms_visio.js" processname="VISIO" />
</refinery>
Attributes:
Name | Description |
---|---|
name | Name used for schema merging. |
js | URL for JavaScript |
processname | The windows process name. |
Attributes:
Name | Description |
---|---|
app | Name of app element which defines application used for refine |
name | Name used for schema merging. |
Contains SQL statement to select data value(s) of this type. Variable @[t]
contains the type name and @[userid]
contains the user id. The SQL statement may need surrounding CDATA element to comply with XML specification in case SQL statement contains special characters etc.
Attributes:
Name | Description |
---|---|
name | Name of element instance |
title | Title of select section |
url | May contain runtime variables @[t] and @[userid] |
Samples:
Sample using URL:
xxxxxxxxxx
<select name="all" title="All workspaces" url="~/ts/object/select.aspx?t=ts_workspace&isworkspace=1" />
Sample using SQL:
xxxxxxxxxx
<select name="recently" title="Recently used workspaces (3 months)" expanded="1"><![CDATA[SELECT Obj as [Workspace], ObjType as [Type], Name, Manager, Trustees FROM Entity WHERE Obj in (SELECT Workspace FROM Item WHERE CreateBy = '@[userid]' AND DateDiff(m, CreateDate, GetDate())<=3) AND (Entity.Active=1) ORDER BY Obj]]></select>
Attributes:
Name | Description |
---|---|
- | - |
Elements:
Name | Description |
---|---|
- | - |
Samples:
Specifies an SQL view and is an alternative to the table attribute which refers a SQL table.
The SQL query must be included in parenthesis and may not contain ORDER BY clause.
Samples:
xxxxxxxxxx
<sqlselect name="default"><![CDATA[ (select hr_competency_type.[group], hr_competency_group.[name] as groupname, hr_competency_type.id as [type], hr_competency_type.name as typename, ts_user.department, ts_user.obj as person, (select level from [HR_COMPETENCY].[dbo].[HR_COMPETENCY] WHERE competency=hr_competency_type.id AND person COLLATE database_default=ts_user.obj) as level, (select id from [HR_COMPETENCY].[dbo].[HR_COMPETENCY] WHERE competency=hr_competency_type.id AND person COLLATE database_default=ts_user.obj) as id from [HR_COMPETENCY].[dbo].[HR_COMPETENCY_TYPE] as hr_competency_type, [TS_Host].[dbo].[Role] as ts_user, [HR_COMPETENCY].[dbo].[HR_COMPETENCY_GROUP] as hr_competency_group WHERE (hr_competency_group.id=hr_competency_type.[group]) AND (ts_user.isemployee=1) ) ]]></sqlselect>
The table element may also use OpenQuery for querying external resources. The following shows an example of an open query to index server:
xxxxxxxxxx
<sqlselect name="default"><![CDATA[OpenQuery(IndexServer, 'SELECT Directory FROM TSD1.TurboStage..SCOPE('' "" '') WHERE CONTAINS(''quality and problem'') ') ]]></sqlselect>
Contains SQL statement to validate data of this type. The SQL statement must return the value if ok and nothing if not ok. The returned value will be the correct case of the data value. If user entered ‘management’ then ‘Management’ may be returned and used for the SQL update statement.
Parameter @[v]
contains the runtime data value to be validated. The SQL statement may need surrounding CDATA element to comply with XML specification in case SQL statement contains special characters etc.
Attributes:
Name | Description |
---|---|
name | Name of element instance |
Samples:
xxxxxxxxxx
<validate><![CDATA[ SELECT TOP 1 Obj FROM Entity WHERE Active=1 AND IsWorkspace=1 AND Obj='@[v]' ]]></validate>
If no validate element is present then validation will be done against type key column. The validation will take into account the object type column and type column value.