84669 person learning
152542 person learning
20005 person learning
5487 person learning
7821 person learning
359900 person learning
3350 person learning
180660 person learning
48569 person learning
18603 person learning
40936 person learning
1549 person learning
1183 person learning
32909 person learning
想做的效果是这样:
点击这个p获取到里面span 845这个值,然后将这个数据绑定到下图中。该怎么做?刚转到angular学习,似乎用angular.element这种方法不是很好,有种jQuery的套路,该怎么做才能体现angular的思想?用Directive?
ringa_lee
app.controller('mainCtrl', function($scope) { $scope.li = [1, 2, 3, 4]; //套餐列表 $scope.selectLi = function(item) { $scope.value = item //价格 } }) HTML:部分 {{item}} {{value}}
感谢 angular的思路确实简洁明了
感谢 angular的思路确实简洁明了