[CMF-checkins] CVS: CMF - actbox.stx:1.1 basics.stx:1.1 expressions.stx:1.1

shane@digicool.com shane@digicool.com
Mon, 11 Jun 2001 15:33:48 -0400 (EDT)


Update of /cvs-repository/CMF/DCWorkflow/doc
In directory korak.digicool.com:/tmp/cvs-serv30200/doc

Added Files:
	actbox.stx basics.stx expressions.stx 
Log Message:
Added DCWorkflow product to public CVS.



--- Added File actbox.stx in package CMF ---

Names and URLs for the actions box can be formatted using standard Python
string formatting.  An example::

  %(content_url)s/content_submit_form

The string '%(content_url)s' will be replaced by the value of content_url.
The following names are available:

- portal_url

- folder_url

- content_url

- count (Available in work lists only. Represents the number of items in
  the work list.)

The following names are also available, in case there is any use for them.
They are not strings.

- portal

- folder

- content

- isAnonymous

--- Added File basics.stx in package CMF ---

This product can be added to the portal_workflow tool of CMF site.
It provides fully customizable workflow.

To see an example, after installing DCWorkflow, using the "Contents"
tab of your portal_workflow instance add a "CMF default workflow (rev 2)"
instance.  The other way to create it is to add a "Workflow" object,
selecting "dc_workflow" as the type.  The second way will create a
blank workflow.

This tool is easiest to use if you draw a state diagram first.  Your
diagram should have:

- States (bubbles)

- Transitions (arrows)

- Variables (both in states and transitions)

Remember to consider all the states your content can be in.  Consider
the actions users will perform to make the transitions between states.
And consider not only who will be allowed to perform what functions,
but also who will be *required* to perform certain functions.

On the "States" tab, add a state with a simple ID for each state on
your diagram.  On the "Transitions" tab, add a transition with a simple
ID for each group of arrows that point to the same state and have
similar characteristics.  Then for each state choose which transitions
are allowed to leave that state.

Variables are useful for keeping track of things that aren't very well
represented as separate states, such as counters or information about
the action that was last performed.  You can create variables that get
stored alongside the workflow state and you can make those variables
available in catalog searches.  Some variables, such as the review
history, should not be stored at all.  Those variables are accessible
through the getInfoFor() interface.

Worklists are a way to make people aware of tasks they are required
to perform.  Worklists are implemented as a catalog query that puts
actions in the actions box when there is some task the user needs to
perform.  Most of the time you just need to enter a state ID,
a role name, and the information to put in the actions box.

You can manage all of the actions a user can perform on an object by
setting up permissions to be managed by the workflow.  Using the
"Permissions" tab, select which permissions should be state-dependent.
Then in each state, using the "permissions" tab, set up the
role to permission mappings appropriate for that state.

Finally, you can extend the workflow with scripts.  Scripts can be
External Methods, Python Scripts, DTML methods, or any other callable
Zope object.  They are accessible by name in expressions.


--- Added File expressions.stx in package CMF ---

Expressions in DCWorkflow use the same convention as DTML expressions.
The underscore character provides access to certain Python modules and
builtins.  In addition to what is provided by DTML expressions, the
following names are also available.

- All scripts defined using the 'Scripts' tab.

- 'object' is the object being modified by workflow.

- 'workflow' is the workflow definition object.

- 'transition' is the ID of the transition being executed.

- 'new_state' is the ID of the destination state of the transition.

- 'kwargs' is the keyword arguments passed to the doActionFor() method.

- 'getHistory', a function that returns a copy of the object's workflow
   history.

- All status variables, including the current state.