标签:html task padding class click main params app button
母页:加入$state
<button class="button button-calm button-block" ng-click="toProducer(producerId)" style="padding: 0 50px; background-color:#12B7F5;" >  核     查  </button>
ng-click="toProducer(producerId)"
母页控制器:
$scope.toProducer = function () { var tid = document.getElementById(‘taskid‘); var TaskId = tid.textContent; $state.go(‘main.td‘, {producerId:TaskId}); };
APP.js
.state(‘main.td‘,{ url:‘/td/:producerId‘, views:{ ‘main-kssb‘:{ templateUrl: ‘templates/kssb/td.html‘, controller: ‘TbCtrl‘ } } })
子页控制器:$state $stateParams
var TaskId = $stateParams.producerId;
$stateParams.producerId:获取母页传入的值
标签:html task padding class click main params app button
原文地址:http://www.cnblogs.com/zry2510/p/6130602.html