Hi My requirment is to have a editable form review page beform submition , Should I build the form again will the values submited in prior steps

Comments

satishb’s picture

msnf module hides all the fields which do not belong to a specific step you can patch it by excluding your step no to not take that hide action then your final step will show all the fields of all steps togather

diff --git msnf.module msnf.module
index ac23942..6add413 100644
--- msnf.module
+++ msnf.module
@@ -288,12 +288,9 @@ function msnf_form_node_form_alter(&$form, &$form_state, $form_id) {

// Add step buttons to form.
_msnf_form_attach_buttons($form, $form_state);
-//unhide the 4th step which will be review/edit kind of form- Patch: Author-Satish B
- if ($form_state['storage']['step'] !== 'step_app_4')
-{
+
// Hide all elements that do not belong to the current step.
_msnf_hide_fields($form, $form_state);
-}

// Restore field values.
_msnf_restore_values($form, $form_state);

farbodsedghi’s picture

Try to don't modify a contributed module in this way.

You may also unset msnf form alter to include your custom form alter instead.

function your_module_module_implements_alter(&$implementations, $hook){

  if($hook == 'form_alter' && isset($implementations['your_module'])) {
  
    unset($implementations['msnf']);

  }

}

Now, you can define your own form alter function to include any condition you need.

Don't forgot that you need to copy msnf_form_node_form_alter() body since you should not break msnf module.

Of course, you need to include clear comment to your custom function linked to msnf_form_node_form_alter.