Go to next wizard step from Mass Action

  • 1
  • Question
  • Updated 4 years ago
  • Answered
I have used the following JavaScript in the past to get from one wizard step to another:

var wizard = $('.nx-wizard, .wizard').data('object'); 
wizard.navigate('step2');

I am trying to use the same syntax to get from a Mass Action on step1 of the wizard, to step2 and it doesn't seem to be working. I am declaring the wizard variable at the top of my snippet, and calling the navigate part inside of a save callback, could that be cuasing issues? Is it possible to get to the next step from a Mass Action with the above syntax?
Photo of Moshe Karmel

Moshe Karmel, Champion

  • 8,646 Points 5k badge 2x thumb

Posted 4 years ago

  • 1
Photo of Zach McElrath

Zach McElrath, Employee

  • 49,056 Points 20k badge 2x thumb
The problem is that the Wizard object currently doesn't have it's own navigate() method, you have to get a Step, and then call navigate on the Step. Not the most intuitive, unfortunately, but here's the way to do it:

var wizard = $('.nx-wizard').data('object'); 
var currentStep = wizard.steps[wizard.currentstep];
currentStep.navigate('step2');

(Edited)
Photo of Rohit Vakhariya

Rohit Vakhariya

  • 1,054 Points 1k badge 2x thumb
How can i get particular field value with this syntax.If i have one filed first name in the wizard and i want to get that value on click of button than how can i get that value.
Photo of Rob Hatch

Rob Hatch, Official Rep

  • 44,006 Points 20k badge 2x thumb
Once you have filled the field in the first step of the wizard it is in your model.  So you can use the model API to get the data back out of it.  In addition,  if you put a component on step 2 or 3 bound to that model,  you will see the updated data in that component. 

Note: The Page Title component doesn't seem to be updating currently when it is in a wizard step.  You can use a field editor, or a template component and it will show the updated data.
(Edited)
Photo of Rohit Vakhariya

Rohit Vakhariya

  • 1,054 Points 1k badge 2x thumb
I am using model API.But i am facing isuue.
Example:

First i have enter data for first name like Rooit and i am going on second step by clicking on next button.After that i think that I have done some spelling mistake so i am clicking on previous step and change the name to Rohit instead of Rooit but when i am getting first name value in java script it is Rooit. It is not changed in model.

So My question is how i can get changed value from wizard in java script.
Photo of Moshe Karmel

Moshe Karmel, Champion

  • 8,646 Points 5k badge 2x thumb
Thanks Zach.
Photo of Eddie

Eddie

  • 720 Points 500 badge 2x thumb
Hi Moshe I posted this: https://community.skuidify.com/skuid/topics/pass-id-to-step-2-in-wizard

I am trying to pass the Id of an Item in a row I select from one Step to another when I create a Wizard in Skuid. I can't pass it as a URL param in the Steps.
Basically its to create a new quote.

The user Selects a Lender in Step 1, this Id is passed to Step 2 which shows Lender Plans, filtered by Lender Id in Step 1
In Step 2 the User selects a Lender Plan and proceeds to Step 3, both the Lender Id and Lender Plan Id need passed to Step 3, where I want to create a new Quote using the Lender Ids

Can you help as I've been looking at this for days