AnsweredAssumed Answered

Adding new content type to alfresco workflow

Question asked by konart on Jun 19, 2014
Latest reply on Jun 24, 2014 by jpotts
What I'm trying to do is to have a select element on workflow start form with a list of companies. Depending on a chosen company name workflow engine should choose what to do next (choose next step).

I'm still quite lost about how this whole thing works actually (too complicated for me I guess) and this is what I have tried at the moment:

First, I create a new model company.xml:

    <?xml version="1.0" encoding="UTF-8"?>

    <model name="itn:company" xmlns="">

        <description>Company model</description>

            <import uri="" prefix="d"></import>
            <import uri="" prefix="cm"></import>

            <namespace uri="" prefix="itn" />
        <type name="itn:Company">


                <property name="itn:Name">





               <constraint name="itn:Name" type="LIST">
                    <parameter name="AllowedValues">

Next, I add this model  to my workflow's -context file:

    <property name="models">

Then, I add it to the web-client-config-custom.xml:

       <config evaluator="string-compare" condition="Languages">
             <language locale="ru_RU">Russian</language>

       <config evaluator="node-type" condition="dir:start" replace="true">

          <separator name="sep1" display-label-id="general" component-generator="HeaderSeparatorGenerator" />
          <show-property name="bpm:workflowDescription" component-generator="TextAreaGenerator" />
          <show-property name="itn:Company" />

          <show-association name="bpm:assignee" />

And finally to the share-config-custom.xml:

       <config evaluator="string-compare" condition="activiti$PerformDirective">
                   <show id="bpm:workflowDescription"/>
                   <show id="bpm:assignee"/>
                   <show id="packageItems" />
                   <show id="itn:Company" />
                   <set id="" appearance="title" label-id="workflow.set.general" />
                   <set id="assignee" appearance="title" label-id="dir_assignee" />             
                   <set id="items" appearance="title" label-id="dir_items" />

                   <field id="bpm:workflowDescription" label-id="dir_description">
                      <control template="/org/alfresco/components/form/controls/textarea.ftl">
                         <control-param name="style">width: 95%</control-param>
                   <field id="bpm:assignee" label-id="dir_assign_to" set="assignee" />
                   <!–<field id="packageItems" set="items" label-id="dir_pitems" />–>
                   <field id="itn:Company" set="items" label-id="itn_company_name" />

labels are in place too.

This gives no effect at all.

Any tips on where this goes wrong? Or any other suggestions?