angular.js - 如何从$scope中的对象属性中找到父节点
伊谢尔伦
伊谢尔伦 2017-05-15 17:02:29
0
1
637

例如:
$scope.a=
{

a:{a1:1,a2:2,a3:3},
b:{b1:1,b2:2,b3:3},

}
函数从参数中取得了a3,怎样向上访问取到$scope.a

伊谢尔伦
伊谢尔伦

小伙看你根骨奇佳,潜力无限,来学PHP伐。

reply all(1)
我想大声告诉你

This is not possible, attributes are not unique.

$scope.a = {
    a: {a1:1, a2:2, a3:3}
    b: {a1:1, a2:2, a3:3}
}

$scope.b = {
    a: {a1:1, a2:2, a3:3}
    b: {a1:1, a2:2, a3:3}
}

So for the above code, what can we get with a3=3?

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!