Commit 35b99756 authored by Piotr Gawron's avatar Piotr Gawron
Browse files

lint issues

parent b69fa8cd
......@@ -31,9 +31,9 @@ SearchPanel.prototype.createTableElement = function(element, icon) {
} else {
throw new Error("Unknown element type: " + element.constructor.name);
}
}
};
SearchPanel.prototype.createPreamble = function(reaction) {
SearchPanel.prototype.createPreamble = function() {
return document.createElement("div");
};
......
......@@ -17,7 +17,6 @@ var PointMarker = require('./marker/PointMarker');
var ReactionMarker = require('./marker/ReactionMarker');
var ReactionOverlay = require('./overlay/ReactionOverlay');
var ReferenceGenome = require('./data/ReferenceGenome');
var SearchDbCollection = require('./overlay/SearchDbOverlay');
var Submap = require('./Submap');
var TouchMap = require('./TouchMap');
......@@ -439,7 +438,7 @@ CustomMap.prototype.registerSource = function(overlayCollection) {
return self.updateOverlayCollection(overlayCollection, false);
});
}
if (overlayCollection.getName() === "drug" || overlayCollection.getName() === "chemical") {
if (overlayCollection.getName() === "drug" || overlayCollection.getName() === "chemical" ||overlayCollection.getName() === "mirna" ) {
overlayCollection.addListener("onSearch", function() {
return self.updateOverlayCollection(overlayCollection, false);
});
......
"use strict";
/* exported logger */
var logger = require('../../logger');
var Promise = require("bluebird");
......@@ -119,11 +121,11 @@ AbstractDbOverlay.prototype.getQueries = function(){
return this._queries ;
};
AbstractDbOverlay.prototype.createIdentifiedElementsForTargetingClass = function(element, colourId){
AbstractDbOverlay.prototype.createIdentifiedElementsForTargetingClass = function(targetingElement, colourId){
var self = this;
var result =[];
var iconCounter =1;
var targets = element.getTargets();
var targets = targetingElement.getTargets();
for (var k=0;k<targets.length;k++) {
var target = targets[k];
if (target.isVisible()) {
......
"use strict";
/* exported logger */
var logger = require('../../logger');
var Promise = require("bluebird");
......@@ -7,8 +9,6 @@ var Promise = require("bluebird");
var IdentifiedElement = require('../data/IdentifiedElement');
var AbstractDbOverlay = require('./AbstractDbOverlay');
var ServerConnector = require('../../ServerConnector');
function AbstractTargettingDbOverlay(params) {
// call super constructor
AbstractDbOverlay.call(this, params);
......
"use strict";
var logger = require('../../logger');
/* exported logger */
var Promise = require("bluebird");
var logger = require('../../logger');
var IdentifiedElement = require('../data/IdentifiedElement');
var AbstractTargettingDbOverlay = require('./AbstractTargettingDbOverlay');
var ServerConnector = require('../../ServerConnector');
......@@ -22,10 +21,10 @@ ChemicalDbOverlay.prototype.constructor = ChemicalDbOverlay;
ChemicalDbOverlay.prototype.getNamesByTargetFromServer = function(param) {
return ServerConnector.getChemicalNamesByTarget(param);
}
};
ChemicalDbOverlay.prototype.getElementsByQueryFromServer = function(param) {
return ServerConnector.getChemicalsByQuery(param);
}
};
module.exports = ChemicalDbOverlay;
"use strict";
var logger = require('../../logger');
/* exported logger */
var Promise = require("bluebird");
var logger = require('../../logger');
var IdentifiedElement = require('../data/IdentifiedElement');
var AbstractTargettingDbOverlay = require('./AbstractTargettingDbOverlay');
var ServerConnector = require('../../ServerConnector');
function DrugDbOverlay(params) {
params.iconType= "drug";
params.iconColorStart = 5
params.iconColorStart = 5;
// call super constructor
AbstractTargettingDbOverlay.call(this, params);
}
DrugDbOverlay.prototype = Object.create(AbstractTargettingDbOverlay.prototype);
......@@ -22,10 +20,10 @@ DrugDbOverlay.prototype.constructor = DrugDbOverlay;
DrugDbOverlay.prototype.getNamesByTargetFromServer = function(param) {
return ServerConnector.getDrugNamesByTarget(param);
}
};
DrugDbOverlay.prototype.getElementsByQueryFromServer = function(param) {
return ServerConnector.getDrugsByQuery(param);
}
};
module.exports = DrugDbOverlay;
"use strict";
var logger = require('../../logger');
/* exported logger */
var Promise = require("bluebird");
var logger = require('../../logger');
var IdentifiedElement = require('../data/IdentifiedElement');
var AbstractTargettingDbOverlay = require('./AbstractTargettingDbOverlay');
var ServerConnector = require('../../ServerConnector');
......@@ -22,10 +21,10 @@ MiRnaDbOverlay.prototype.constructor = MiRnaDbOverlay;
MiRnaDbOverlay.prototype.getNamesByTargetFromServer = function(param) {
return ServerConnector.getMiRnaNamesByTarget(param);
}
};
MiRnaDbOverlay.prototype.getElementsByQueryFromServer = function(param) {
return ServerConnector.getMiRnasByQuery(param);
}
};
module.exports = MiRnaDbOverlay;
"use strict";
/* exported logger */
var logger = require('../../logger');
var Promise = require("bluebird");
......
......@@ -56,7 +56,7 @@ function restoreSearchQuery(customMap) {
} else {
return Promise.resolve();
}
};
}
function restoreDrugQuery(customMap) {
var query = ServerConnector.getSessionData().getDrugQuery();
......@@ -65,7 +65,7 @@ function restoreDrugQuery(customMap) {
} else {
return Promise.resolve();
}
};
}
function restoreChemicalQuery(customMap) {
var query = ServerConnector.getSessionData().getChemicalQuery();
......@@ -74,7 +74,7 @@ function restoreChemicalQuery(customMap) {
} else {
return Promise.resolve();
}
};
}
function restoreMiRnaQuery(customMap) {
var query = ServerConnector.getSessionData().getMiRnaQuery();
......@@ -83,7 +83,7 @@ function restoreMiRnaQuery(customMap) {
} else {
return Promise.resolve();
}
};
}
function create(params) {
var project = params.project;
......@@ -174,7 +174,6 @@ function create(params) {
return new Promise(function(resolve, reject) {
var sessionData =ServerConnector.getSessionData();
result.refreshOverlays().then(function() {
return restoreSearchQuery(result);
}).then(function(){
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment