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