一旦我从后端渲染数据我想从数组中删除元素id
我怎么能用angularjs实现呢?
ctrl.js
$scope.array = [{
"name": "Java Class",
"id": "javaClass",
"createdBy": "shu",
"__v": 0,
"properties": [{
"label": "Java Package Name",
"type": "String",
"editable": true,
"binding": {
"type": "property",
"name": "camunda:class"
}
}],
"appliesTo": ["bpmn:ServiceTask"]
}]
答案 0 :(得分:2)
您可以使用delete
delete $scope.array[0].id;