Hi there,
I have been looking through the SJS reference doc, but could not find an example of a wizard implementation in SJS. Is it possible to provide such an example?
Many thanks,
JO
Hi there,
I have been looking through the SJS reference doc, but could not find an example of a wizard implementation in SJS. Is it possible to provide such an example?
Many thanks,
JO
Hi JO, and welcome to Jspresso !
Here is an SJS fragment defining a wizard. The idea is to define wizard-steps as SJS generic beans and reference them into the wizard action :
bean 'WizardStep.first',
class:'org.jspresso.framework.application.frontend.action.wizard.StaticWizardStepDescriptor',
custom:[
name:'first.step.name',
viewDescriptor_ref:'WizardModel.wizard.first.view',
nextStepDescriptor_ref:'WizardStep.second'
]
bean 'WizardStep.second',
class:'org.jspresso.framework.application.frontend.action.wizard.StaticWizardStepDescriptor',
custom:[
name:'second.step.name',
viewDescriptor_ref:'WizardModel.wizard.second.view',
nextStepDescriptor_ref:'WizardStep.third'
]
bean 'WizardStep.third',
class:'org.jspresso.framework.application.frontend.action.wizard.StaticWizardStepDescriptor',
custom:[
name:'third.step.name',
viewDescriptor_ref:'WizardModel.wizard.third.view'
]
action 'myWizardAction',
class:'org.jspresso.framework.application.frontend.action.wizard.WizardAction',
custom:[
width:'600',
height:'150',
firstWizardStep_ref:'WizardStep.first',
]
HTH,
Vincent
Hi Vincent,
Many thanks for your quick response and greetings! This is very much appreciated. I will chew on this and revert.
BTW, the framework is impressive, and I would like to take this opportunity to congratulate you!
Best regards,
JO