[#80,refactor][xs]: switch to _.each in view-graph.js.
This commit is contained in:
@@ -275,9 +275,9 @@ my.Graph = Backbone.View.extend({
|
|||||||
createSeries: function () {
|
createSeries: function () {
|
||||||
var self = this;
|
var self = this;
|
||||||
var series = [];
|
var series = [];
|
||||||
$.each(this.state.attributes.series, function (seriesIndex, field) {
|
_.each(this.state.attributes.series, function(field) {
|
||||||
var points = [];
|
var points = [];
|
||||||
$.each(self.model.currentDocuments.models, function (index, doc) {
|
_.each(self.model.currentDocuments.models, function(doc, index) {
|
||||||
var x = doc.get(self.state.attributes.group);
|
var x = doc.get(self.state.attributes.group);
|
||||||
var y = doc.get(field);
|
var y = doc.get(field);
|
||||||
if (typeof x === 'string') {
|
if (typeof x === 'string') {
|
||||||
|
|||||||
Reference in New Issue
Block a user