ember-cli-simple-store
Advanced tools
Comparing version 4.1.0 to 4.2.0
@@ -12,4 +12,4 @@ import Ember from 'ember'; | ||
updateContent() { | ||
var source = this.get("source"); | ||
var filter_func = this.get("filter_func"); | ||
var source = this.get("_source"); | ||
var filter_func = this.get("_filter_func"); | ||
@@ -25,5 +25,5 @@ return Ember.A(source.filter(filter_func)); | ||
_unregisterRecordArray() { | ||
var store = this.get("store"); | ||
var store = this.get("_store"); | ||
store._unsubscribe(this); | ||
} | ||
}); |
@@ -6,18 +6,18 @@ import Ember from 'ember'; | ||
export default ArrayProxy.extend({ | ||
store: null, | ||
type: null, | ||
_store: null, | ||
_type: null, | ||
content: computed(function () { | ||
return Ember.A(this.get("source")); | ||
return Ember.A(this.get("_source")); | ||
}), | ||
push(data) { | ||
var type = this.get('type'); | ||
return this.get('store').push(type, data); | ||
var type = this.get('_type'); | ||
return this.get('_store').push(type, data); | ||
}, | ||
remove(id) { | ||
var type = this.get('type'); | ||
this.get('store').remove(type, id); | ||
var type = this.get('_type'); | ||
this.get('_store').remove(type, id); | ||
} | ||
}); |
@@ -7,7 +7,7 @@ import Ember from 'ember'; | ||
export default Ember.ObjectProxy.extend({ | ||
source: null, | ||
store: null, | ||
type: null, | ||
_source: null, | ||
_store: null, | ||
_type: null, | ||
content: computed("source.[]", function() { | ||
content: computed("_source.[]", function() { | ||
return this.compute(); | ||
@@ -18,4 +18,4 @@ }), | ||
this._super(...arguments); | ||
const store = this.get('store'); | ||
const type = this.get('type'); | ||
const store = this.get('_store'); | ||
const type = this.get('_type'); | ||
@@ -22,0 +22,0 @@ var model = getOwner(store).lookup(`model:${type}`); |
@@ -157,7 +157,7 @@ import Ember from "ember"; | ||
return RecordProxy.create({ | ||
store: this, | ||
type: type, | ||
source: this._findAll(type), | ||
_store: this, | ||
_type: type, | ||
_source: this._findAll(type), | ||
compute() { | ||
return this.get("source").objectAt(0); | ||
return this.get("_source").objectAt(0); | ||
} | ||
@@ -175,5 +175,5 @@ }); | ||
return RecordArray.create({ | ||
type: type, | ||
store: this, | ||
source: this._findAll(type) | ||
_type: type, | ||
_store: this, | ||
_source: this._findAll(type) | ||
}); | ||
@@ -183,7 +183,7 @@ }, | ||
var func = FilteredRecordArray.create({ | ||
type: type, | ||
store: this, | ||
id: Ember.uuid(), | ||
filter_func: filter_func, | ||
source: this._findAll(type) | ||
_type: type, | ||
_store: this, | ||
_id: Ember.uuid(), | ||
_filter_func: filter_func, | ||
_source: this._findAll(type) | ||
}); | ||
@@ -208,9 +208,9 @@ var filtersMap = this.get("filtersMap"); | ||
return RecordProxy.create({ | ||
store: this, | ||
type: type, | ||
filter_value: actualId, | ||
source: this._findAll(type), | ||
_store: this, | ||
_type: type, | ||
_filter_value: actualId, | ||
_source: this._findAll(type), | ||
compute() { | ||
var filter_value = this.get("filter_value"); | ||
return this.get("source").findBy(primaryKey, filter_value); | ||
var filter_value = this.get("_filter_value"); | ||
return this.get("_source").findBy(primaryKey, filter_value); | ||
} | ||
@@ -217,0 +217,0 @@ }); |
ember-cli-simple-store Changelog | ||
============================== | ||
4.2.0 | ||
----- | ||
* [BUG]: Switch the names of the properties on a record proxy to avoid collisions with defined values | ||
([#57](https://github.com/toranb/ember-cli-simple-store/pull/57)) | ||
4.1.0 | ||
@@ -5,0 +12,0 @@ ----- |
{ | ||
"name": "ember-cli-simple-store", | ||
"version": "4.1.0", | ||
"version": "4.2.0", | ||
"description": "ember-cli addon that provides a simple identity map for ember.js web applications", | ||
@@ -5,0 +5,0 @@ "directories": { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
39613