【问题标题】:jQuery Smart Wizard - Reset certain stepsjQuery 智能向导 - 重置某些步骤
【发布时间】:2021-06-13 15:33:53
【问题描述】:

我在我的 MVC 项目中使用它: http://techlaboratory.net/jquery-smartwizard#func-stepstate

这里解释了如何禁用或隐藏步骤,但是如何重置/标记撤消某些特定步骤?

我需要这个的原因:我有 7 个步骤,如果他的用户返回到步骤 3 并更改某些内容,则必须重置以下所有步骤,让用户再次执行它们。

谢谢!

【问题讨论】:

    标签: smart-wizard


    【解决方案1】:

    找到了方法!

    首先我为每个步骤添加一个 id,例如:

    <a class="nav-link" href="#step-1" id="stepper-step-1">
    

    然后我可以删除完成的类以将它们标记为撤消:

    $('#stepper-step-1').removeClass('done')
    $('#stepper-step-2').removeClass('done')
    $('#stepper-step-3').removeClass('done')
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2014-05-15
      • 2014-07-07
      • 2015-04-09
      • 2018-03-28
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多