Skip to content

Commit

Permalink
LOCAL: restore lost functionality from merge
Browse files Browse the repository at this point in the history
  • Loading branch information
holmbergius committed Jan 25, 2025
1 parent 3290667 commit 731a32d
Showing 1 changed file with 16 additions and 6 deletions.
22 changes: 16 additions & 6 deletions src/main/java/org/ecocean/servlet/SubmitSpotsAndImage.java
Original file line number Diff line number Diff line change
Expand Up @@ -121,13 +121,23 @@ public void doPost(HttpServletRequest request, HttpServletResponse response)
String speciesString = enc.getTaxonomyString();
Annotation ann = new Annotation(speciesString, crMa);
ann.setMatchAgainst(true);
String iaClass = "whalesharkCR"; // should we change this?
if(enc.getSpecificEpithet()!=null) {
if(enc.getSpecificEpithet().equals("tigrinum")) {
iaClass = "leopard_shark";
}
//WB-1841 only whale sharks are currently matchable via this method
if(speciesString!=null && speciesString.equals("Rhincodon typus")) {
ann.setMatchAgainst(true);
String iaClass = "whaleshark"; // should we change this?
ann.setIAClass(iaClass);
}
ann.setIAClass(iaClass);
else if(speciesString!=null && speciesString.equals("Stegostoma tigrinum")) {
ann.setMatchAgainst(true);
String iaClass = "leopard_shark"; // should we change this?
ann.setIAClass(iaClass);
}
else if(speciesString!=null && speciesString.equals("Scyliorhinus stellaris")) {
ann.setMatchAgainst(true);
String iaClass = "nursehoundsharkCR"; // should we change this?
ann.setIAClass(iaClass);
}

if (rightSide) { ann.setViewpoint("right"); } else { ann.setViewpoint("left"); }
enc.addAnnotation(ann);
System.out.println(" + made annotation " + ann.toString());
Expand Down

0 comments on commit 731a32d

Please sign in to comment.