|
From: Daniele <d.t...@ic...> - 2002-08-19 08:18:21
|
On Friday 02 August 2002 12:01, Your Name wrote: > Hi, > > I've defined a process with a couple of activities and one application > on the first activity. > > I've trouble to understand how the application is called since when I > call the startInstance function I expect to see my application while I > receive an empty page. > > The structure of my Zope application is: > index file the start wfAction > wfAction calling startInstance > application that has to be called by the first activity. Ok, let's see. Did you create an application in openflow (Applications tab)? Did you link the application to the activity (activity edit page)? Did you create a workflow user corresponding to your zope login (users and roles tab)? If you said "yes" to all questions: the startInstance starts the flowing of the instance in the process; when the instance reaches the first activity it waits for a user to fetch it to work on it (thereby starting the application). What you expect is: the first activity/application will be started as soon as the instance reaches it; so I should be prompted by this first application as soon as there is a new instance. What it is: the first activity/application will hold the just arrived instance, waiting for some user to fetch it (using the callApplication). So you probably need to explicitly call the callApplication on the newly created instance (after the startInstance). Remember that a workflow activity could be handled (generally speaking) by more than one actor: do not think that the submitter of an instance should be always prompted for its first activity/application. > Looking at the openflow source, I found that the callApplication is > invoked by the hasNewWorkItem() without the REQUEST argument and I > dont' figure why the startInstance doesn't pass the REQUEST argument to > hasNewWorkItem. Would this solve your problem? I have trouble seeing why you would need the REQUEST argument: do you need to pass some extra arguments during the call to a startInstance? Could you explain this a little further? Daniele =) |