Re: [Perl-workflow-devel] Can't get grouped actions
Brought to you by:
jonasbn
From: Ivan P. <iva...@gm...> - 2009-04-27 21:03:49
|
Andrew, Jim, Thanks a lot for the explanation. Anyone, with commit rights, please change one line in State.pm (sub get_available_action_names) my $action_group = FACTORY->{_action_config}{$action_name}{'group'}; should be my $action_group = FACTORY->{_action_config}{$self->type()}{$action_name}{'group'}; Thanks. > If I'm understanding the question, your description is correct. If you > don't provide a type for your actions, it uses 'default' as a > placeholder. This was also done for backward compatibility. > But if you want to use types, they need to match between the workflow > config and the actions config. This allows you to have one workflow > "engine" support multiple types, and each type can have an action with > the same name but different implementations (like two Submit actions > that do different things for different types). This snippet tries to > explain this set-up: > http://search.cpan.org/~jonasbn/Workflow-1.32/lib/Workflow/Action.pm#CONFIGURATION > Any suggestions for making the docs clearer are welcome. > Jim > Andrew O'Brien wrote: >> Hi Ivan, >> >> We have exactly the same type set in the workflow.xml as in our >> associated actions.xml. >> >> Ie given a workflow "helpdesk" and the following files: >> >> wf_helpdesk.xml >> wf_helpdesk_action.xml >> wf_helpdesk_condition.xml >> >> .. Each of these files has a <type>helpdesk</type> entity. >> >> As far as I under stand the config structure, that's almost required but >> if not, it certainly saves a lot of confusion. >> >> In that case you could just call ->type() and use it directly which I >> believe is the way things should be set up. >> >> Can anyone else comment whether setting the same type value in all files >> for a worklog is The Way Things Are Supposed To Be? >> >> Cheers, >> >> Andrew >> -- Best regards, Ivan Paponov iva...@gm... |