Index: openacs-4/packages/workflow/www/doc/developer-guide.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/workflow/www/doc/developer-guide.html,v diff -u -N -r1.1.2.4 -r1.1.2.5 --- openacs-4/packages/workflow/www/doc/developer-guide.html 23 Apr 2003 09:20:05 -0000 1.1.2.4 +++ openacs-4/packages/workflow/www/doc/developer-guide.html 23 Apr 2003 09:27:48 -0000 1.1.2.5 @@ -152,9 +152,10 @@
The workflow API is designed so that whenver you're using features
that are specific to finite state machines, the procedure name will
- include the letters "fsm" in the name, as in
- workflow::case::fsm::get
. That way you'll know when
- you're hard-wiring a dependency on the particular workflow model.
+ include the letters "fsm" in the name, as in workflow::case::fsm::get
. That
+ way you'll know when you're hard-wiring a dependency on the
+ particular workflow model.
@@ -327,7 +328,7 @@ } } -set workflow_id [workflow::fsm::new_from_spec -spec $spec] +set workflow_id [workflow::fsm::new_from_spec -spec $spec]
@@ -796,7 +797,7 @@ } } - set workflow_id [workflow::fsm::new_from_spec -spec $spec] + set workflow_id [workflow::fsm::new_from_spec -spec $spec] return $workflow_id } @@ -1099,9 +1100,9 @@
- Using workflow::case::add_log_data, you can add arbitrary key/value + Using workflow::case::add_log_data, you can add arbitrary key/value pairs to a log entry. These can the be retrieved later using - workflow::case::get_log_data_by_key, and workflow::case::get_log_data. + workflow::case::get_log_data_by_key, and workflow::case::get_log_data.
@@ -1117,14 +1118,14 @@workflow::fsm::new_from_spec
)
+ workflow::fsm::new_from_spec
)
workflow::delete
)
+ workflow::delete
)
workflow::fsm::clone
)
+ the instance (workflow::fsm::clone
)
workflow::delete
)
+ Delete the workflow attached to the instance (workflow::delete
)
workflow::case::get_id
to get the case_id for your
- object, and then either workflow::case::get
or
- workflow::case::fsm::get
in order to get state
+ workflow::case::get_id
to get the case_id for your
+ object, and then either workflow::case::get
or
+ workflow::case::fsm::get
in order to get state
information from workflow to include in the data set returned by
your API proc.
workflow::case::new
.
+ case for that object using workflow::case::new
.
First, you should update your application object data as normal.
Then you'll probably want to use
- workflow::case::get_id
to find the case_id. If you
+ workflow::case::get_id
to find the case_id. If you
have assignment integrated in your form, you'll want to call
- workflow::case::role::assign
to pass these on to
+ workflow::case::role::assign
to pass these on to
workflow, and finally you'll say
- workflow::case::action::execute
to execute the
+ workflow::case::action::execute
to execute the
action, including state changes, side-effects, and notifications.
@@ -1243,7 +1244,7 @@
- Use workflow::case::get_id
to get the case_id.
+ Use workflow::case::get_id
to get the case_id.
@@ -1270,20 +1271,20 @@
Then you should check that this action is currently available to
this user by saying
- workflow::case::action::available_p
.
+ workflow::case::action::available_p
.
To get the currently available actions so you can offer them to the
- user, use workflow::case::get_available_actions
which
- will return the action_id's, then workflow::action::get
+ user, use workflow::case::get_available_actions
which
+ will return the action_id's, then workflow::action::get
to get the details about each of the actions.
If you're using ad_form
, and you want only one assignee
per role, and you want assignment integrated with your form, use
- workflow::case::role::add_assignee_widgets
to add the
+ workflow::case::role::add_assignee_widgets
to add the
widgets. It'll do an ad_form -extend
, so they'll appear
at the point at which you call this proc.
if { ![empty_string_p $action_id] } { - foreach field [workflow::action::get_element -action_id $action_id -element edit_fields] { + foreach field [workflow::action::get_element -action_id $action_id -element edit_fields] { element set_properties bug $field -mode edit } } @@ -1306,13 +1307,13 @@To populate values of the assignee widgets, use -
workflow::case::role::set_assignee_values
in your +workflow::case::role::set_assignee_values
in youron_request
block.To add the case log to the comment field, use -
workflow::case::get_activity_html
and feed it to the +workflow::case::get_activity_html
and feed it to thebefore_html
property of a textarea.