我使用LSA作为我的适配器。我可以使用此适配器创建记录,但我不知道如何使用此适配器删除或更新记录。当我使用
deleteDragFromModel:function(item){
var item = this.get('store').deleteRecord('axisModel',item);
item.save();
}
我收到一个错误消息:
Uncaught TypeError: Object axisModel has no method 'deleteRecord' ember-data.js:1388
如果我console.log(item)
的结果是:
Class {name: "Cube1-1", caption: "Cube1-1", dimensionUniqueName: "NA", description:
"Cube1-1", levelUniqueName: "NA"…}
__ember1379749368210: "ember743"
__ember1379749368210_meta: Meta
_super: undefined
calculated: false
caption: "Cube1-1"
description: "Cube1-1"
dimensionUniqueName: "NA"
get uniqueName: function () {
hierarchyUniqueName: "NA"
levelUniqueName: "NA"
name: "Cube1-1"
set uniqueName: function (value) {
toString: function () { return ret; }
__proto__: Object