Hello Edd,

I do not see any reason why the workflow extension should not work with STXX or any 
other extension..Apart from only one reason..STXX needs its own request processor 
which is not working
.But As I have not used STXX,i am not sure about it.

But from what you have posted to me ,I can tell you as follows.

Once the action does a forward, there is some step inSTXX extension, which will use 
the given forward(in your case <forward name="success">
                <transform name="default" path="/wizardScreen1.xsl"/>
            </forward> ) to perform the XML to html conversion using the defined XSLT 
..Most preferably in the  processForwardConfig(request, response, forward) method of 
the  request processor as this is the method that is called after the action returns a 
forward.

Please let me know if STXX uses a custom request processor and have a look in the 
method i have mentioned.

Else I can have a go at it.

HTH.

Regards,
Shirish.


-----Original Message-----
From: Edd Dawson [mailto:[EMAIL PROTECTED]
Sent: Friday, March 12, 2004 2:38 PM
To: Sakhare, Shirishchandra
Subject: RE: My wizard workflow code.. doesnt work :S


Hi Shirish

I am having another crack at getting the workflows working with stxx in
struts...

I am now basically trying converting the example application (the
addition of 2 numbers example) to work with stxx

if the struts-config.xml i have set the following section up :

  <action path="/displayWizardScreen1" 
   
type="com.livinglogic.struts.workflow.demo.PrepareWizardScreen1Action"
        name="wizardForm"
        scope="session"
        validate="false">
        <set-property property="secondaryWorkflow" value="prepareWizard"
/>
        <set-property property="prevState" value="initialized" />
        <set-property property="primaryWorkflow" value="wizardScreen1"
/>
        <set-property property="newState" value="displayed" />
        <set-property property="nextState" value="submitted" />
                   <forward name="success">
                <transform name="default" path="/wizardScreen1.xsl"/>
            </forward>
  </action>


The only change in their to the standard example is :

                   <forward name="success">
                <transform name="default" path="/wizardScreen1.xsl"/>
            </forward>


When i run the application when it trys to show the first page of the
wizard it displays a blank screen, i sent it in debug mode as well which
would show the raw xml being output by struts, and it displayed
absolutely nothing as well.

I am now thinking that the workflow extensions may not be able to work
with stxx at all.

What would your opinion be on this?

cheers
Edd

p.s I still cannot get on the struts-user list as my work havent taken
it off the spam list yet :(

>>> <[EMAIL PROTECTED]> 03/08/04 4:20 PM >>>
Hi,
You should find out what ever is the syntax for html hidden paramaters
and Using XSLT , create that string from the XML/or bean property what
ever approach you are using.

-----Original Message-----
From: Edd Dawson [mailto:[EMAIL PROTECTED]
Sent: Monday, March 08, 2004 5:10 PM
To: Sakhare, Shirishchandra
Subject: RE: My wizard workflow code.. doesnt work :S


Hi Shirish

I tried this method, and it doesn't work as beans don't execute in an
xslt, so it just displays the text : <html:hidden name="RegisterForm"
property="userName">  in plain text above the form!

oh well worth a try :S

Edd

>>> <[EMAIL PROTECTED]> 03/08/04 10:34 AM >>>
I am speaking about html hidden parameters.

In jsp world, After the login page, on the user_details.jsp page would
have something like
<html:hidden mame="myFormBean" property="userName">
<html:hidden mame="myFormBean" property="password">  which will in turn
create 2 hidden parameters of same name on the html for
user_details.jsp(for html details of same, see some HTML site..I am bad
with html syntax..Just know jsps.).So when the user enters all data ,
along with his data, the 2 hidden parameters will be again passed.And
hence available on the second action.SO you can apply similar technique
even with XSLT.


regards,
Shirish

-----Original Message-----
From: Edd Dawson [mailto:[EMAIL PROTECTED]
Sent: Monday, March 08, 2004 11:30 AM
To: Sakhare, Shirishchandra
Subject: RE: My wizard workflow code.. doesnt work :S


How do the hidden paremeters work? do they get passed via the url?

i.e http://mysite.com/Mypage.do?parameter1=hello,parameter2=world

?

>>> <[EMAIL PROTECTED]> 03/08/04 10:26 AM >>>
Hi,
Also just an afterthought.

If this is just oneoff thing then there is a simpler solution to sharing
data.Use hidden parameters..But in this case as the data contains
username/password, I will not recommand it.

Regards,
Shirish.

-----Original Message-----
From: Edd Dawson [mailto:[EMAIL PROTECTED]
Sent: Monday, March 08, 2004 11:24 AM
To: Sakhare, Shirishchandra
Subject: RE: My wizard workflow code.. doesnt work :S


thanks shirish

I will have a go with this and see what comes of it, i will have to
modify to try and use stxx, as i am not using jsp's for this project (i
am useless at jsp's) it has to be done using xslt's

>>> <[EMAIL PROTECTED]> 03/08/04 10:20 AM >>>
Ok.So now I know your workflow.
SO it seems that the only requirement you have is keeping data across
pages and then clear the data from session when user has completed the
workflow.So an ideal requirement to use workflow scope to stuff your
data.

stage1:RegisterSellerActionPage1.java.The action mapping conf will look
like this.

I have only entered workflow related elements of actionMapping.Rest you
can fill in.The struts action form should be in request scope.
<!-- The first page of workflow(username_password_entry.jsp will forward
to this action to start workflow)-->
<!-- The formBean/or user details bean should be copied to workflow
scope now as you want to share it across pages.-->
 <action path="/validateUnamePwd" type="RegisterSellerActionPage1">
    <set-property property="primaryWorkflow" value="user_registration"
/>
    <set-property property="newState"
value="stage1_uname_password_entry" />
    <set-property property="nextState" value="stage2_user_details_entry"
/>
        <forward name="success" path="user_details.jsp" />
  </action>


<!-- This is the action called by userDetails.jsp after user has entered
his details-->
<!-- This should copy all data from struts form in request scope to the
formBean/user details Bean(whatever the case may be)in workFlow scope
using beanUtils.copyProperties after validation succeeds so that the
same data is avaiblable for all actions in same workflow-->
 <action path="/getUserdetails" type="RegisterSellerActionPage1">
    <set-property property="primaryWorkflow" value="user_registration"
/>
    <set-property property="prevState"
value="stage1_uname_password_entry" />
    <set-property property="newState" value="stage2_user_details_entry"
/>
    <set-property property="nextState" value="stage3_register_user" />
   <forward name="success" path="/registerUser.do" />
  </action>

 <!-- get all data from Workflow scope and register user.-->
<action path="/registerUser" type="RegisterSellerActionPage1">
    <set-property property="primaryWorkflow" value="user_registration"
/>
    <set-property property="prevState" value="stage2_user_details_entry"
/>
    <set-property property="newState" value="stage3_register_user" />
    <set-property property="endWorkflow" value="true" />
  </action>

I do not know about STXX..But the same you can use to achieve any
workflow.

HTH.

regards,
Shirish




-----Original Message-----
From: Edd Dawson [mailto:[EMAIL PROTECTED]
Sent: Monday, March 08, 2004 10:54 AM
To: Sakhare, Shirishchandra
Cc: [EMAIL PROTECTED]
Subject: RE: My wizard workflow code.. doesnt work :S


Hi Shirish

Thanks for getting back to me :)

My usecase is as follows :

Page 1 (RegisterSellerActionPage1.java) will let them choose a username
and password (it checks the database to see that the username is not
taken already, and then checks that the two passwords enter match)

Page 2 (RegisterSellerActionPage1.java) will let them enter personal
details such as surname and forename (it checks that all fields are
entered).

Page 3 (RegisterSellerAction.java) will then create the account with the
details provided from the previous 2 pages and forward them onto a
generic page.


I hope this makes sense,

cheers
Edd

P.S i have copied the struts-user list in on this mail, but my work is
still blocking the list as spam, so i myself cannot see the list at the
moment, hence my private mail to you yesterday.


>>> <[EMAIL PROTECTED]> 03/08/04 9:20 AM >>>
Hi Edd,
I am not exactly sure what is your usecase?If you can explain that I
need not understand your action code.

You are just trying to implement a wizard flow as follows:

<extract from your first mail>
page 1 will let  them choose a username and password
page 2 will let them enter their personal details
(forename,surname,email etc)
page 3 will let them enter their postal address
then i want my Action to pool all the details and create their account
and forward them to another page.
</extract from your first mail>

And you want the data to be shared..And then at the end of flow you want
it to be cleared..
Right?

Regards,
Shirish.

N.B:Also if we can share this discussion with struts user mailing list,
it might help somebody.
-----Original Message-----
From: Edd Dawson [mailto:[EMAIL PROTECTED]
Sent: Saturday, March 06, 2004 6:22 PM
To: Sakhare, Shirishchandra
Subject: Re: My wizard workflow code.. doesnt work :S


Hi Shirish

I have tried to implement the wizard workflow code but unfortunately its
not working for me :S

I have included my code and config files in the attached zip, i would
really appreciate it if you had a brief scan of it, i am sure with your
knowledge you will see what is wrong in no time! :)

thanks
Edd

______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email 
______________________________________________________________________


______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email 
______________________________________________________________________


______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email 
______________________________________________________________________


______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email 
______________________________________________________________________


______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email 
______________________________________________________________________


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to