我有一些数组,在数组内部我想定义另一个数组。这两个定义是否相等?非常感谢 :)
args: [{
key: "data",
ajaxOptions: {
url: '/rest/adrestresource/1.0/activedirectory/findgroups%20test@lab.local%20Bezhesla1%20localhost%20CN=Builtin,DC=lab,DC=local',
type: "GET",
dataType: "xml"
}
}];
args: function () {
return [{
key: "data",
ajaxOptions: {
url: '/rest/adrestresource/1.0/activedirectory/findgroups%20test@lab.local%20Bezhesla1%20localhost%20CN=Builtin,DC=lab,DC=local',
type: "GET",
dataType: "xml"
}
}];
}
它用于配置小工具,文档说:对象数组或返回一个对象的函数。T 第一种方法工作正常,但通过返回它的函数定义数组不起作用:?