控制器代码:
shows
这是来自usersList的1个用户对象:
function usersView() {
var directive = {
templateUrl : "users/users.html",
restrict : "E",
replace : true,
bindToController : true,
controller : UsersCtrl,
controllerAs : 'usrs',
link : link,
scope : {}
};
return directive;
function link(scope, element, attrs) {}
}
//....
initUsersDirect();
function initUsersDirect() {
ApiFactory.getUsers().success(function(data) {
vm.usersList = data.users;
displayUsersList();
console.log('vm.usersList',vm.usersList);
});
}
function displayUsersList() {
vm.usersLoaded = true;
}
标记:
{
active: 1
firstname: "Alexander"
id: 1345324526
lastname: "Finkle"
role_id: 4
session: Object
username: "stackoverflow@gmail.com"
}
知道我为什么会收到此错误?的 Error: ngRepeat:iidexp Invalid Identifier
答案 0 :(得分:3)
标记应为:
accept()