The following code changes can be made to TeamSite::WFconstructor in order to allow the use of success/failure transitions from submittasks:
... around line 83 ...
if ($options{'type'} eq "locktask") {
add_success_and_failure($doc, $task_element, $options{'success'},
$options{'failure'});
}
elsif ($options{type} eq "submittask" && defined($options{success}) && defined($options{failure})){
add_success_and_failure($doc, $task_element, $options{success}, $options{failure});
}
elsif (defined $options{'successors'}) {
my $sref = $options{'successors'};
...
}
...
sub add_success_and_failure
{
my ($doc, $task, $sref, $fref) = @_;
... around line 177 ...
for my $task_ref ( @$tref ) {
for my $task_id ( @{ expand_task_id($task_ref) } ) {
...
}
}
$task->appendChild( $the_element );
}
}
An alternative to modifying the actual WFconstructor.pm in
iw-home/iw-perl/vendor/lib/TeamSite, is to copy-and-modify it in
iw-home/iw-perl/
site/lib/TeamSite.
I will be sending these changes to support in the hopes that it makes it out into a patch or service pack some day - but I figured I'd pass it along.