-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
koehlers
committed
Feb 26, 2018
1 parent
3620fed
commit c5177e9
Showing
7 changed files
with
31 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
eclipse.preferences.version=1 | ||
org.apache.ivyde.eclipse.standaloneretrieve=<?xml version\="1.0" encoding\="UTF-8" standalone\="no"?><setuplist/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -20,7 +20,6 @@ | |
import com.vaadin.event.FieldEvents.FocusEvent; | ||
import com.vaadin.event.FieldEvents.FocusListener; | ||
import com.vaadin.jsclipboard.JSClipboard; | ||
import com.vaadin.server.ExternalResource; | ||
import com.vaadin.server.Page; | ||
import com.vaadin.server.VaadinRequest; | ||
import com.vaadin.server.VaadinServlet; | ||
|
@@ -142,13 +141,11 @@ protected void init(VaadinRequest request) { | |
hpoClassTabFactory.addTermInfoElements(gridContainer, (IHpClassDataProvider) dataProvider); | ||
|
||
addExtraButtons(gridContainer, (IHpClassDataProvider) dataProvider); | ||
} | ||
else if (dataProvider instanceof IDiseaseDataProvider) { | ||
} else if (dataProvider instanceof IDiseaseDataProvider) { | ||
|
||
DiseaseTabFactory diseaseTabFactory = new DiseaseTabFactory(tableUtils); | ||
diseaseTabFactory.addDiseaseInfoElements(gridContainer, (IDiseaseDataProvider) dataProvider); | ||
} | ||
else if (dataProvider instanceof IGeneDataProvider) { | ||
} else if (dataProvider instanceof IGeneDataProvider) { | ||
|
||
GeneTabFactory geneTabFactory = new GeneTabFactory(tableUtils); | ||
geneTabFactory.addGeneInfoElements(gridContainer, (IGeneDataProvider) dataProvider); | ||
|
@@ -161,8 +158,7 @@ else if (dataProvider instanceof IGeneDataProvider) { | |
String ontologyVersion; | ||
if (doParseHpo) { | ||
ontologyVersion = hpData.getExtOwlOntology().getOntologyVersionIri().toString(); | ||
} | ||
else | ||
} else | ||
|
||
{ | ||
ontologyVersion = "some ontology version here"; | ||
|
@@ -173,7 +169,8 @@ else if (dataProvider instanceof IGeneDataProvider) { | |
*/ | ||
Label version = new Label("Ontology version: " + ontologyVersion); | ||
Label copyright = new Label("Copyright 2017 - Sebastian Köhler & The Human Phenotype Ontology Project"); | ||
Link feedback = new Link("Question, Comments, Feedback: [email protected]", new ExternalResource("http:https://drseb.github.io/")); | ||
Link feedback = new Link("Question, Comments, Feedback: [email protected]", | ||
new com.vaadin.server.ExternalResource("http:https://drseb.github.io/")); | ||
addLabelRow(gridContainer, version); | ||
addLabelRow(gridContainer, copyright); | ||
addLabelRow(gridContainer, feedback); | ||
|
@@ -252,39 +249,36 @@ private IEntityDataProvider setupDataProvider(VaadinRequest request, Map<String, | |
|
||
OWLClass hpClass = parseHpId(request); | ||
if (hpClass == null && doParseHpo) { | ||
new Notification("Invalid HPO id input", "<br/><br/>Can't parse HPO id from '" + request.getParameter(CONSTANTS.hpRequestId) + "'", | ||
new Notification("Invalid HPO id input", | ||
"<br/><br/>Can't parse HPO id from '" + request.getParameter(CONSTANTS.hpRequestId) + "'", | ||
Notification.Type.ERROR_MESSAGE, true).show(Page.getCurrent()); | ||
return null; | ||
} | ||
|
||
if (doParseHpo) { | ||
dataProvider = new HpClassDataProvider(hpClass, hpData); | ||
} | ||
else { | ||
} else { | ||
dataProvider = new FakeHpClassDataProvider(); | ||
} | ||
|
||
} | ||
else if (parameterMap.containsKey(CONSTANTS.geneRequestId)) { | ||
} else if (parameterMap.containsKey(CONSTANTS.geneRequestId)) { | ||
|
||
Integer geneId = parseGeneId(request); | ||
if (geneId == null && doParseHpo) { | ||
new Notification("Invalid gene id input", | ||
"<br/><br/>Can't parse gene id from '" + request.getParameter(CONSTANTS.geneRequestId) + "'", Notification.Type.ERROR_MESSAGE, | ||
true).show(Page.getCurrent()); | ||
"<br/><br/>Can't parse gene id from '" + request.getParameter(CONSTANTS.geneRequestId) + "'", | ||
Notification.Type.ERROR_MESSAGE, true).show(Page.getCurrent()); | ||
return null; | ||
} | ||
|
||
if (doParseHpo) { | ||
|
||
dataProvider = new GeneDataProvider(geneId, hpData); | ||
} | ||
else { | ||
} else { | ||
dataProvider = new FakeGeneDataProvider(); | ||
} | ||
|
||
} | ||
else if (parameterMap.containsKey(CONSTANTS.diseaseRequestId)) { | ||
} else if (parameterMap.containsKey(CONSTANTS.diseaseRequestId)) { | ||
|
||
ItemId diseaseId = parseDiseaseId(request); | ||
if (diseaseId == null && doParseHpo) { | ||
|
@@ -296,15 +290,14 @@ else if (parameterMap.containsKey(CONSTANTS.diseaseRequestId)) { | |
|
||
if (doParseHpo) { | ||
dataProvider = new DiseaseDataProvider(diseaseId, hpData); | ||
} | ||
else { | ||
} else { | ||
dataProvider = new FakeDiseaseDataProvider(); | ||
} | ||
} | ||
else { | ||
new Notification("Invalid URL", "<br/><br/>You have to provide one URL parameter (" + CONSTANTS.hpRequestId + "," | ||
+ CONSTANTS.geneRequestId + ", or " + CONSTANTS.diseaseRequestId + ") ! ", Notification.Type.WARNING_MESSAGE, true) | ||
.show(Page.getCurrent()); | ||
} else { | ||
new Notification("Invalid URL", | ||
"<br/><br/>You have to provide one URL parameter (" + CONSTANTS.hpRequestId + "," | ||
+ CONSTANTS.geneRequestId + ", or " + CONSTANTS.diseaseRequestId + ") ! ", | ||
Notification.Type.WARNING_MESSAGE, true).show(Page.getCurrent()); | ||
return null; | ||
} | ||
return dataProvider; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
page.setUriFragment("!" + SampleCrudView2.VIEW_NAME + "/" + fragmentParameter, false); |