<%@ page import="java.util.*" %> <%@ page import="gui.collections.input.CollectionManagement" %> <%@ page import="gui.common.query.UserQuery" %> <%@ page import="gui.common.settings.UIConst" %> <%@ page import="gui.common.management.UIManager" %> <%-- ******************Radio buttons state initialisation************** --%> <% String path = manager.getPath(); String Search=request.getParameter("Search"); String redirection = request.getParameter("redirection"); %> <%manager.setSearchType(UIConst.METADATA_ADVANCED_SEARCH);%> <%manager.setScreenID(UIConst.METADATA_ADVANCED_SEARCH);%> <%manager.setAdditionalTitle(UIConst.EMPTY_STRING);%> <%manager.setaAditionalSubTitle(UIConst.EMPTY_STRING);%> <% if (Search!= null){%> <%if (Search.equals("ALPHABET_ORG")){%> <%manager.setScreenID(UIConst.CORM_ADVANCED_SEARCH_ALPH_LIST);%> <%manager.setAdditionalTitle(manager.getText("alph_title_org"));%><%}%> <%if (Search.equals("ALPHABET_TOWN")){%> <%manager.setScreenID(UIConst.CORM_ADVANCED_SEARCH_ALPH_LIST);%> <%manager.setAdditionalTitle(manager.getText("alph_title_towns"));%><%}%> <%if (Search.equals("ALPHABET_PERSON")){%> <%manager.setScreenID(UIConst.CORM_ADVANCED_SEARCH_ALPH_LIST);%> <%manager.setAdditionalTitle(manager.getText("alph_title_persons"));%><%}%> <%if (Search.equals("ALPHABET_TAXONOMIC_COVERAGE")){%> <%manager.setScreenID(UIConst.CORM_ADVANCED_SEARCH_ALPH_LIST);%> <%manager.setAdditionalTitle(manager.getText("alph_title_tax"));%><%}%> <%if (Search.equals("ALPHABET_COMMON_NAME_COVERAGE")){%> <%manager.setScreenID(UIConst.CORM_ADVANCED_SEARCH_ALPH_LIST);%> <%manager.setAdditionalTitle(manager.getText("alph_title_common"));%><%}%> <%}%> <%-- *******Update query object -if alphabetic items from list selected-***** --%> <%String prevAction=request.getParameter("PreviousAction");%> <%if (prevAction != null) { if (prevAction.compareTo("COUNTRY_MAP") == 0) { String [] theListOfCountries = request.getParameterValues("countries_map"); if (theListOfCountries != null) UserQuery.addcountries(theListOfCountries); } if (prevAction.compareTo("TIME_PERIOD_TABLE") == 0) { String [] theListOfTimeperiodKeywords = request.getParameterValues("strati"); UserQuery.setstratigraphicKeywords(theListOfTimeperiodKeywords); } if (prevAction.compareTo("GEO_TREE") == 0) { String [] theListOfGeoKeywords = request.getParameterValues("geo"); UserQuery.setgeographicKeywords(theListOfGeoKeywords); } String letter=request.getParameter("Letter"); if (prevAction.compareTo("ALPHABET_ORG") == 0) { String [] theListOfOrganisations = request.getParameterValues("organisations"); UserQuery.setmetadataItemNameOrg(theListOfOrganisations, letter); } if (prevAction.compareTo("ALPHABET_TOWN") == 0) { String [] theListOfTowns= request.getParameterValues("towns"); UserQuery.settowns(theListOfTowns, letter); } if (prevAction.compareTo("ALPHABET_PERSON") == 0) { String [] theListOfPersons= request.getParameterValues("persons"); UserQuery.setpersons(theListOfPersons, letter); } if (prevAction.compareTo("ALPHABET_TAXONOMIC_COVERAGE") == 0) { String [] theListOfTaxonomicKeywords= request.getParameterValues("taxon"); UserQuery.settaxonomicKeywords(theListOfTaxonomicKeywords, letter); } if (prevAction.compareTo("ALPHABET_COMMON_NAME_COVERAGE") == 0) { String [] theListOfTCommonNameKeywords= request.getParameterValues("commonName"); UserQuery.setcommonKeywords(theListOfTCommonNameKeywords, letter); } } %> <%if (redirection != null){ HttpSession currSession = request.getSession(); %> <%-- ***************************----Redirections---************************* --%> <% if (redirection.compareTo("advanced_search")==0) { String [] theListOfStratigraphicKeywords= request.getParameterValues("strati"); if (theListOfStratigraphicKeywords != null) UserQuery.setstratigraphicKeywords(theListOfStratigraphicKeywords); String [] theListOfGeographicKeywords= request.getParameterValues("geo"); if (theListOfGeographicKeywords != null) UserQuery.setgeographicKeywords(theListOfGeographicKeywords); UserQuery.settown(request.getParameter("Town")); UserQuery.setorganisationName(request.getParameter("organisationName")); UserQuery.setpersonName(request.getParameter("Persons")); UserQuery.setkeywordTaxonomic(request.getParameter("keywordTaxonomic")); UserQuery.setkeywordCommon(request.getParameter("keywordCommon")); UserQuery.setkeywordGeospatial(request.getParameter("keywordGeospatial")); UserQuery.setkeywordTimeperiod(request.getParameter("keywordTimeperiod")); UserQuery.setclassOfCollection(request.getParameterValues("classOfCollection")); UserQuery.setTypeOfOrganisation(request.getParameterValues("typeOfOrganisation")); UserQuery.setcollectedObjects(request.getParameterValues("collectedObjects")); UserQuery.setcountries(request.getParameterValues("countries")); UserQuery.setstatus(request.getParameter("Types")); UserQuery.setBoolOperator(request.getParameter("operator1")); currSession.setAttribute("UserQuery", UserQuery); manager.addCORMAdvancedQuery(UserQuery); manager.forward(path + manager.getLink("CORM_RESULT") + "?Action=" + UIConst.CORM_ADVANCED_SEARCH, response, request,getServletContext()); } if (redirection.compareTo("Reset")==0) { UserQuery = new UserQuery(); currSession.setAttribute("UserQuery", UserQuery); Search = null; } if (redirection.compareTo("RefineQuery")==0) { UserQuery = manager.getLastCORMQuery(); if (UserQuery != null) currSession.setAttribute("UserQuery", UserQuery); } if (redirection.compareTo("ReloadQuery")==0) { String idx = request.getParameter("ID"); UserQuery = manager.getCurrentCORMAdvancedQuery(idx); System.out.println(UserQuery.getSearchType()); if (idx != null) currSession.setAttribute("UserQuery", UserQuery); } if (redirection.compareTo("AlphList")==0) { System.out.println("list"); } else manager.dispatch(redirection,response, request,getServletContext()); } %> Search
  • »Metadata
  • »Advanced Search
  • "/>
    "> <%if (Search == null){%> <%-- ******************Test if cookies are setting (mandatory************** --%> <% if (request.getParameter("flag")==null) { // the first request Cookie cookie = new Cookie("cookieSetting", "on"); response.addCookie(cookie); String nextUrl = request.getRequestURI() + "?flag=10"; // force the browser to refresh out.println(""); } else { // the second request Cookie[] cookies = request.getCookies(); boolean cookieFound = false; if (cookies!=null) { int length = cookies.length; for (int i=0; i <%-- ******************End cookies settings test************** --%> <%String typeSpecimenStatus = UIConst.EMPTY_STRING; if (UserQuery.getstatus().compareTo("1")==0) typeSpecimenStatus = "CHECKED";%>

    <%=manager.getText("corm_adv_search.col_coverage")%>

    <%=manager.getText("corm_adv_search.l_taxon")%>     " alt="<%=manager.getText("corm_adv_search.h_taxon")%>" > " size="40" onChange="window.document.userSearch.Submit.focus()">
    <%=manager.getText("corm_adv_search.l_common_name")%> " alt="<%=manager.getText("corm_adv_search.h_common_name")%>" > " size="40">

    <%=manager.getText("corm_adv_search.l_geo_spatial")%> " alt="<%=manager.getText("corm_adv_search.h_geo_spatial")%>" > " size="40"> " onClick="javascript:go('Geo')" >
    <%=manager.getText("corm_adv_search.l_time_period") %>           " alt="<%=manager.getText("corm_adv_search.h_time_period")%>" > "> "onClick="javascript:go('ColTimeStrati')">

    <%=manager.getText("corm_adv_search.l_objects")%> " alt="<%=manager.getText("corm_adv_search.h_objects")%>">

    <%=manager.getText("corm_adv_search.l_type_specimens")%> " alt="<%=manager.getText("corm_adv_search.h_type_specimens")%>" > > <%=manager.getText("corm_adv_search.l_yes")%>

    <%=manager.getText("corm_adv_search.data_repository")%>

    <%=manager.getText("corm_adv_search.l_name")%>    " alt="<%=manager.getText("corm_adv_search.h_name_org")%>"> "">
    <%=manager.getText("corm_adv_search.l_country")%> " alt="<%=manager.getText("corm_adv_search.h_country")%>">   " onClick="javascript:go('Map')">
    <%=manager.getText("corm_adv_search.l_town")%>     " alt="<%=manager.getText("corm_adv_search.h_town")%>" > " size="40">

    <%=manager.getText("corm_adv_search.l_organisation")%> " alt="<%=manager.getText("corm_adv_search.h_organisation")%>" >

    <%=manager.getText("corm_adv_search.l_collection")%>      " alt="<%=manager.getText("corm_adv_search.h_collection")%>" >

    <%=manager.getText("corm_adv_search.persons")%>


    <%=manager.getText("corm_adv_search.l_name")%> " alt="<%=manager.getText("corm_adv_search.h_name_person")%>"> " size="40">

    <%=manager.getText("corm_adv_search.operator")%>

    <%=manager.getOperatorCheckBox(UserQuery.getBoolOperator())%>

    <%=manager.getText("record_number")%>



    " onclick="valid()" TITLE="<%=manager.getText("btn_Search_t")%>">     " onClick="resetQuery(document.userSearch.redirection,document.userSearch)" TITLE="<%=manager.getText("btn_Search_t")%>" TITLE="<%=manager.getText("btn_New_Query_t")%>">

    <%-- ***************************----Alphabetic list management---******************** --%> <%} else if (Search!= null){%> <%String letter = request.getParameter("ID");%> <%out.println ("
    ");%> <%if (Search.equals("ALPHABET_ORG")){%> <%=management.buildCheckboxList("ALPHABET_ORG", "organisations", letter, UserQuery.getmetadataItemNameOrg())%> <%out.println("");%> <%}%> <%if (Search.equals("ALPHABET_TOWN")){%> <%=management.buildCheckboxList("ALPHABET_TOWN", "towns", letter, UserQuery.gettowns())%> <%out.println("");%> <%}%> <%if (Search.equals("ALPHABET_PERSON")){%> <%=management.buildCheckboxList("ALPHABET_PERSON","persons", letter, UserQuery.getpersons())%> <%out.println("");%> <%}%> <%if (Search.equals("ALPHABET_TAXONOMIC_COVERAGE")){%> <%=management.buildCheckboxList("ALPHABET_TAXONOMIC_COVERAGE","taxon", letter, UserQuery.gettaxonomicKeywords())%> <%out.println("");%> <%}%> <%if (Search.equals("ALPHABET_COMMON_NAME_COVERAGE")){%> <%=management.buildCheckboxList("ALPHABET_COMMON_NAME_COVERAGE","commonName", letter, UserQuery.getcommonNameKeywords())%> <%out.println("");%> <%}%> <%out.println("");%> <%out.println("");%> <%out.println("");%> <%out.println("

    ");%> <%out.println ("
    ");%> <%}%>


    <%-- **********Main frame table end-*********** --%>