问题描述
我无法删除/移除模态。当模态出现时,当计数等于 @H_502_1@0 时发生倒计时,我希望删除模态。一切正常,直到计数为 @H_502_1@0。但是一旦计数为 @H_502_1@0,模态关闭并重新启动计数器。
@H_502_1@$s@R_404[email protected] = function () { if ($s@R_404[email protected]) { $s@R_404[email protected](); } else { $ionicModal.fromTemplateUrl('templates/ctmodal.html',{ s@R_404_6433@e: $s@R_404_6433@e,animation: 'slide-in-up' }).then(function (modal) { $s@R_404[email protected] = modal; modal.show(); }); } startTimer(); }; function startTimer() { // stop if any interval is running stop(); $s@R_404[email protected] = $interval(function(){ // .........a function to start countdown.. // when count reaches 0 remove modal. ........... if ($s@R_404[email protected] === 0) { dismissModal(); } },1000); } function stop() { $interval.cancel($s@R_404[email protected]); } $s@R_404_6433@e.$on('$destroy',function() { stop(); }); function dismissModal() { stop(); $s@R_404[email protected](); delete $s@R_404[email protected]; }
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)