Feature: Additional XSD attributes for dynamic forms

Questions you have about using YAWL

Feature: Additional XSD attributes for dynamic forms

Postby felix » Fri Feb 17, 2012 1:50 pm

Cross post from here (http://www.yaug.org/node/43):

I've recently been in a project, that is using YAWL to capture workflows and make them executable via YAWL's dynamic form generation. YAWL was very useful to build a prototype of the system. We had to capture an comparative large amount data that is always redisplayed (and edited) throughout the whole workflow. We used XML Schema to define different structured data types. These data types were very useful as we need to save/load from/to a database.

Unfortunately it is not possible to provide a label for each element of the XML Schema or a description that is displayed above the generated field in a dynamic form. Of course it is possible to specify this information in the extended attributes of a task decomposition variable. But this means that we're loosing the advantage of mapping only one variable with a complex type. Additionally we've to specify the label and description in each task that is using our variable.

We needed a way to customize the appearance of the dynamic form (generated by the YAWL Resource Service) if using complex types defined in XSD.

From my point of view there are two ways to achieve this:

1. Define additional attributes (e.g. label, description) in a YAWL namespace that may be used to customize the appearance in the dynamic form. For example:
Code: Select all
  <xs:complexType name="placeOfBirthType">
    <xs:sequence>
            <xs:element name="place" type="xs:string" yawl:label="City of Birth" yawl:description="The city of birth as it appears in your passport." />
            <xs:element name="country" type="xs:string" yawl:label="Country of Birth" yawl:description="The country of birth as it appears in your passport." />
        </xs:sequence>
  </xs:complexType>

A complex type would be displayed in the same layout everywhere.

2. Extend the YAWL Editor with a feature that allow me to specify extended attributes for each element contained in a XSD complex type. Not only the whole complex type.

What is your opinion on this matter?
--
Felix
yaug.org / Bonn-Rhein-Sieg University
felix
 
Posts: 1
Joined: Tue Jan 10, 2012 9:06 pm
Location: Bonn, Germany

Re: Feature: Additional XSD attributes for dynamic forms

Postby michael » Mon Feb 20, 2012 3:37 am

This is a feature that has been on the todo list for quite a while, but other priorities have so far bumped it down the list. Both would require quite a bit of work, with option (2) being much more so. I prefer the idea of additional attributes in the data type definitions (the editor annotates the variable instance definition rather than the data type definition), but it would need to look something like this:

Code: Select all
    <xs:complexType name="placeOfBirthType">
        <xs:sequence>
            <xs:element name="place" type="xs:string">
                <xs:annotation>
                    <xs:appinfo>
                        <yawl:label value="City of Birth"/>
                        <yawl:description value="The city of birth as it appears in your passport."/>
                   </xs:appinfo>
                </xs:annotation>
            </xs:element>
           <xs:element name="country" type="xs:string">
                <xs:annotation>
                    <xs:appinfo>
                        <yawl:label value="Country of Birth"/>
                        <yawl:description value="The country of birth as it appears in your passport."/>
                   </xs:appinfo>
                </xs:annotation>
          </xs:element>
      </xs:sequence>
  </xs:complexType>


Work to do would include changing the way the engine parses specification data type definitions to preserve the annotations, passing the annotations to variables based on the data type at runtime, and adding the functionality into dynamic forms to again parse the annotations for each variable and take the appropriate action.

Any volunteers?
User avatar
michael
 
Posts: 171
Joined: Tue Sep 29, 2009 8:26 am


Return to General

Who is online

Users browsing this forum: No registered users and 0 guests

cron