Twitter bootstrap 3 引导模式窗口保留旧值

Twitter bootstrap 3 引导模式窗口保留旧值,twitter-bootstrap-3,bootstrap-modal,Twitter Bootstrap 3,Bootstrap Modal,嗨,我有问题与引导模式窗口我的链接打开模式是这样的 <a href="#" data-toggle="modal" data-target="#postponed_modal" data-sch_date="{{sch_date}}" data-flht_id="{{flht_id}}">Modal Window</a> 这对我不起作用,我正在使用Bootstrap3.3.4,并从链接到模式获取值 $('#postponed_modal').on(

嗨,我有问题与引导模式窗口我的链接打开模式是这样的

<a href="#" 
  data-toggle="modal" 
  data-target="#postponed_modal"
  data-sch_date="{{sch_date}}" 
  data-flht_id="{{flht_id}}">Modal Window</a>
这对我不起作用,我正在使用Bootstrap3.3.4,并从链接到模式获取值

$('#postponed_modal').on('show.bs.modal', function (e) {

      var schDate = $(e.relatedTarget).data('sch_date');
      var flhtId = $(e.relatedTarget).data('flht_id');
      $(e.currentTarget).find('input[name="sch_date"]').val(schDate);
      $(e.currentTarget).find('input[name="flht_id"]').val(flhtId);

   });

你的问题还不清楚,你是说变化没有反映回你的角度模型吗?不,我只是说模态窗口,没有更多信息。看起来链接向模态提供了来自angularjs单向绑定的数据,这些数据在模态调用之间没有更新?实际上模态没有清除旧值。是否需要清除模型的旧值?如果您指的是角度绑定提供的数据中的“旧值”,则需要自己更新该数据(schu-date,flht-id),因为它们是单向绑定。
$('#postponed_modal').on('show.bs.modal', function (e) {

      var schDate = $(e.relatedTarget).data('sch_date');
      var flhtId = $(e.relatedTarget).data('flht_id');
      $(e.currentTarget).find('input[name="sch_date"]').val(schDate);
      $(e.currentTarget).find('input[name="flht_id"]').val(flhtId);

   });