Попытка преобразовать шаги jquery в директиву шага angularjs, в то время как дочерний html директивы шага содержит ng-repeat, а параметры ng не получили рендер.
Мне нужно добавить компонент $ timeout services для работы директивы step (как указано в коде ниже).
var steps = ""
// $timeout(function(){
steps = angular.element(element).children('.steps-wrapper').steps({
onStepChanging: function (event, currentIndex, newIndex){
if (currentIndex == 0) {
return true
}else if (currentIndex == 1) {
return true
}else if (currentIndex == 2) {
return true
}
}
})
// })
$compile(steps)(scope)
сайт html ** /
<div step class="">
<div id="checkout" class="cui-wizard steps-wrapper">
<h3>
<i class="icmn-cart5 wizard--steps--icon"></i>
<span class="wizard--steps--title">Cart</span>
</h3>
<section>
...
<table>
<tbody>
<tr ng-repeat="(x, y) in vm.cart.getCart().items">
<td class="text-center">{{x+1}}</td>
</td>
</tbody>
</table>
...
</section>
</div>
Plunkr ссылка для тестирования.
plunkr
Пожалуйста, проверьте шаг 3, цикл не рендерится внутри директивы steps. Но бегите за пределами директивы шага.