From: <rv...@us...> - 2009-07-02 22:51:35
|
Revision: 171 http://treebase.svn.sourceforge.net/treebase/?rev=171&view=rev Author: rvos Date: 2009-07-02 22:51:34 +0000 (Thu, 02 Jul 2009) Log Message: ----------- Added CQL search facility to main search pages Modified Paths: -------------- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/matrixSimpleSearchForm.jsp trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/studyKeywordSearchForm.jsp trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/taxonSearchForm.jsp trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeSimpleSearchForm.jsp Modified: trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/matrixSimpleSearchForm.jsp =================================================================== --- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/matrixSimpleSearchForm.jsp 2009-07-02 22:49:58 UTC (rev 170) +++ trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/matrixSimpleSearchForm.jsp 2009-07-02 22:51:34 UTC (rev 171) @@ -17,4 +17,5 @@ <img class="iconButton" src="<fmt:message key="icons.help"/>" /> </a> </fieldset> + <jsp:include page="querySearchBox.jsp"/> </form> Modified: trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/studyKeywordSearchForm.jsp =================================================================== --- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/studyKeywordSearchForm.jsp 2009-07-02 22:49:58 UTC (rev 170) +++ trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/studyKeywordSearchForm.jsp 2009-07-02 22:51:34 UTC (rev 171) @@ -19,4 +19,5 @@ <img class="iconButton" src="<fmt:message key="icons.help"/>" /> </a> </fieldset> + <jsp:include page="querySearchBox.jsp"/> </form> Modified: trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/taxonSearchForm.jsp =================================================================== --- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/taxonSearchForm.jsp 2009-07-02 22:49:58 UTC (rev 170) +++ trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/taxonSearchForm.jsp 2009-07-02 22:51:34 UTC (rev 171) @@ -24,25 +24,29 @@ else { $('searchTermLegend').textContent = 'Enter names (one per line)'; } - $('searchTerm').disabled = true; } - function toggleTextArea(button) { - var noneChecked = true; - var siblings = $(button.parentNode).getElementsByClassName('selectionNeeded'); - for ( var i = 0; i < siblings.length; i++ ) { - if ( siblings[i].checked ) { - noneChecked = false; + function validateForm() { + if ( $('searchTerm').value != "" ) { + if ( $('IdentifiersRadio').checked ) { + if ( $('TreeBASERadio').checked || $('NCBIRadio').checked || $('uBioRadio').checked ) { + return $('searchByTaxonLabel').submit(); + } + alert("Please select either TreeBASE, NCBI or uBio"); } + else if ( $('TextSearchRadio').checked ) { + if ( $('taxonLabelRadio').checked || $('taxonVariantRadio').checked || $('taxonRadio').checked ) { + return $('searchByTaxonLabel').submit(); + } + alert("Please select at least one of Taxon label, Taxon variant or Taxon"); + } + else { + alert("Please select what to search on (identifiers or text)"); + } } - $('searchTerm').disabled = noneChecked; - } - function toggleSubmit(textarea) { - if ( textarea.value != "" ) { - $('submitSearch').disabled = false; - } else { - $('submitSearch').disabled = true; + alert("Please enter search terms in the text area"); } + return false; } </script> @@ -53,25 +57,25 @@ <input type="hidden" name="searchType" value="${searchType }"/> <fieldset id="Identifiers"> <legend> - <input onclick="toggleFieldSet('TextSearch','Identifiers')" type="radio" name="searchOn" value="Identifiers"/>Identifiers + <input onclick="toggleFieldSet('TextSearch','Identifiers')" type="radio" id="IdentifiersRadio" name="searchOn" value="Identifiers"/>Identifiers <a href="#" class="openHelp" onclick="openHelp('taxonSearchIdentifiers')"> <img class="iconButton" src="<fmt:message key="icons.help"/>" /> </a> </legend> - <input type="radio" name="objectIdentifier" class="selectionNeeded" onchange="toggleTextArea(this)" value="TreeBASE" disabled="disabled"/>TreeBASE taxon ID - <input type="radio" name="objectIdentifier" class="selectionNeeded" onchange="toggleTextArea(this)" value="NCBI" disabled="disabled"/> NCBI taxon ID - <input type="radio" name="objectIdentifier" class="selectionNeeded" onchange="toggleTextArea(this)" value="uBio" disabled="disabled"/> uBio nameBankID + <input type="radio" name="objectIdentifier" class="selectionNeeded" id="TreeBASERadio" value="TreeBASE" disabled="disabled"/>TreeBASE taxon ID + <input type="radio" name="objectIdentifier" class="selectionNeeded" id="NCBIRadio" value="NCBI" disabled="disabled"/> NCBI taxon ID + <input type="radio" name="objectIdentifier" class="selectionNeeded" id="uBioRadio" value="uBio" disabled="disabled"/> uBio nameBankID </fieldset> <fieldset id="TextSearch"> <legend> - <input onclick="toggleFieldSet('Identifiers','TextSearch')" type="radio" name="searchOn" value="TextSearch"/>Text search + <input onclick="toggleFieldSet('Identifiers','TextSearch')" type="radio" name="searchOn" id="TextSearchRadio" value="TextSearch"/>Text search <a href="#" class="openHelp" onclick="openHelp('taxonSearchTextSearch')"> <img class="iconButton" src="<fmt:message key="icons.help"/>" /> </a> </legend> - <input type="checkbox" name="stringProperty" class="selectionNeeded" onchange="toggleTextArea(this)" value="taxonLabel" disabled="disabled"/> Taxon label - <input type="checkbox" name="stringProperty" class="selectionNeeded" onchange="toggleTextArea(this)" value="taxonVariant" disabled="disabled"/> Taxon variant - <input type="checkbox" name="stringProperty" class="selectionNeeded" onchange="toggleTextArea(this)" value="taxon" disabled="disabled"/> Taxon + <input type="checkbox" name="stringProperty" class="selectionNeeded" id="taxonLabelRadio" value="taxonLabel" disabled="disabled"/> Taxon label + <input type="checkbox" name="stringProperty" class="selectionNeeded" id="taxonVariantRadio" value="taxonVariant" disabled="disabled"/> Taxon variant + <input type="checkbox" name="stringProperty" class="selectionNeeded" id="taxonRadio" value="taxon" disabled="disabled"/> Taxon <hr style="border: 1px solid #cccccc" /> <input type="checkbox" name="stringModifier" value="caseSensitive" disabled="disabled"/> Case sensitive <input type="checkbox" name="stringModifier" value="exactMatch" disabled="disabled"/> Exact match @@ -83,9 +87,12 @@ <img class="iconButton" src="<fmt:message key="icons.help"/>" /> </a> </legend> - <textarea name="searchTerm" id="searchTerm" style="width:100%" onchange="toggleSubmit(this)" disabled="disabled">${searchTerm}</textarea> + <textarea name="searchTerm" id="searchTerm" style="width:100%">${searchTerm}</textarea> </fieldset> - <input type=submit name="Action" id="submitSearch" value="Search" disabled="disabled"/> + <input type="hidden" name="Action" value="Search"/> + <input type="button" name="Action" id="submitSearch" onclick="validateForm()" value="Search"/> + + <jsp:include page="querySearchBox.jsp"/> </fieldset> </form> </div> \ No newline at end of file Modified: trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeSimpleSearchForm.jsp =================================================================== --- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeSimpleSearchForm.jsp 2009-07-02 22:49:58 UTC (rev 170) +++ trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeSimpleSearchForm.jsp 2009-07-02 22:51:34 UTC (rev 171) @@ -18,4 +18,5 @@ <img class="iconButton" src="<fmt:message key="icons.help"/>" /> </a> </fieldset> + <jsp:include page="querySearchBox.jsp"/> </form> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <yo...@us...> - 2010-04-01 21:05:19
|
Revision: 665 http://treebase.svn.sourceforge.net/treebase/?rev=665&view=rev Author: youjun Date: 2010-04-01 21:05:13 +0000 (Thu, 01 Apr 2010) Log Message: ----------- fix the servername always be localhost issue Modified Paths: -------------- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/study/trees.jsp trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeList.jsp Modified: trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/study/trees.jsp =================================================================== --- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/study/trees.jsp 2010-04-01 20:20:37 UTC (rev 664) +++ trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/study/trees.jsp 2010-04-01 21:05:13 UTC (rev 665) @@ -23,7 +23,14 @@ <!--c:param name="treeid" value="${tree.id}" /--> <!--c:param name="id" value="${tree.study.id}" /--> </c:url> - <a href="http://www.phylowidget.org/full/?tree='http://<%=request.getServerName()%>:<%=request.getServerPort()%>${url}TB2:Tr${tree.id}'" target="myplwidget">Tr${tree.id}</a> + <script type="text/javascript"> + function openPhylowidget(tree_id) + { + var realURL = "http://www.phylowidget.org/full/?tree='http://"+location.host+"${url}"+"TB2:Tr"+tree_id+"'"; + window.open(realURL,'myplwidget') + } + </script> + <a href="javascript:void(0)" onClick="openPhylowidget(${tree.id}">Tr${tree.id}</a> </display:column> <display:column @@ -123,7 +130,8 @@ <!--c:param name="treeid" value="${tree.id}" /--> <!--c:param name="id" value="${tree.study.id}" /--> </c:url> - <a href="http://www.phylowidget.org/full/?tree='http://<%=request.getServerName()%>:<%=request.getServerPort()%>${url}TB2:Tr${tree.id}'" target="myplwidget"> + + <a href="javascript:void(0)" onClick="openPhylowidget(${tree.id}"> <img class="iconButton" src="<fmt:message key="icons.list"/>" Modified: trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeList.jsp =================================================================== --- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeList.jsp 2010-04-01 20:20:37 UTC (rev 664) +++ trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeList.jsp 2010-04-01 21:05:13 UTC (rev 665) @@ -5,6 +5,7 @@ <body id="trees"/ --%> + <display:table name="${resultSet.results}" requestURI="" class="list" @@ -17,9 +18,17 @@ <c:url var="url" value="/tree_for_phylowidget/"> <!--c:param name="treeid" value="${tree.id}" /--> <!--c:param name="id" value="${tree.study.id}" /--> - </c:url> + </c:url> + <script type="text/javascript"> + function openPhylowidget(tree_id) + { + var realURL = "http://www.phylowidget.org/full/?tree='http://"+location.host+"${url}"+"TB2:Tr"+tree_id+"'"; + window.open(realURL,'myplwidget') + } + + </script> <input type="checkbox" id="s-${tree.id }" name="selection" value="${tree.id }" /> - <a href="http://www.phylowidget.org/full/?tree='http://<%=request.getServerName()%>:<%=request.getServerPort()%>${url}TB2:Tr${tree.id}'" target="myplwidget">Tr${tree.id}</a> + <a href="javascript:void(0)" onClick="openPhylowidget(${tree.id})">Tr${tree.id}</a> </display:column> @@ -85,7 +94,7 @@ <!--c:param name="treeid" value="${tree.id}" /--> <!--c:param name="id" value="${tree.study.id}" /--> </c:url> - <a href="http://www.phylowidget.org/full/?tree='http://<%=request.getServerName()%>:<%=request.getServerPort()%>${url}TB2:Tr${tree.id}'" target="myplwidget"> + <a href="javascript:void(0)" onClick="openPhylowidget(${tree.id})"> <img class="iconButton" src="<fmt:message key="icons.list"/>" This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <yo...@us...> - 2010-04-02 00:44:38
|
Revision: 667 http://treebase.svn.sourceforge.net/treebase/?rev=667&view=rev Author: youjun Date: 2010-04-02 00:44:31 +0000 (Fri, 02 Apr 2010) Log Message: ----------- close open bracket, move javascript function out of table Modified Paths: -------------- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/study/trees.jsp trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeList.jsp Modified: trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/study/trees.jsp =================================================================== --- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/study/trees.jsp 2010-04-01 23:16:26 UTC (rev 666) +++ trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/study/trees.jsp 2010-04-02 00:44:31 UTC (rev 667) @@ -9,7 +9,13 @@ <c:url var="studyURL" value="summary.html"> <c:param name="id" value="${study.id}"/> </c:url> - +<script type="text/javascript"> + function openPhylowidget(tree_id) + { + var realURL = "http://www.phylowidget.org/full/?tree='http://"+location.host+"${url}"+"TB2:Tr"+tree_id+"'"; + window.open(realURL,'myplwidget') + } +</script> <display:table name="trees" requestURI="" class="list" @@ -23,14 +29,8 @@ <!--c:param name="treeid" value="${tree.id}" /--> <!--c:param name="id" value="${tree.study.id}" /--> </c:url> - <script type="text/javascript"> - function openPhylowidget(tree_id) - { - var realURL = "http://www.phylowidget.org/full/?tree='http://"+location.host+"${url}"+"TB2:Tr"+tree_id+"'"; - window.open(realURL,'myplwidget') - } - </script> - <a href="javascript:void(0)" onClick="openPhylowidget(${tree.id}">Tr${tree.id}</a> + + <a href="javascript:void(0)" onClick="openPhylowidget(${tree.id})">Tr${tree.id}</a> </display:column> <display:column Modified: trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeList.jsp =================================================================== --- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeList.jsp 2010-04-01 23:16:26 UTC (rev 666) +++ trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeList.jsp 2010-04-02 00:44:31 UTC (rev 667) @@ -4,8 +4,15 @@ <%--content tag="heading"><fmt:message key="search.results.title.trees"/></content> <body id="trees"/ --%> +<script type="text/javascript"> + function openPhylowidget(tree_id) + { + var realURL = "http://www.phylowidget.org/full/?tree='http://"+location.host+"${url}"+"TB2:Tr"+tree_id+"'"; + window.open(realURL,'myplwidget') + } + +</script> - <display:table name="${resultSet.results}" requestURI="" class="list" @@ -19,14 +26,7 @@ <!--c:param name="treeid" value="${tree.id}" /--> <!--c:param name="id" value="${tree.study.id}" /--> </c:url> - <script type="text/javascript"> - function openPhylowidget(tree_id) - { - var realURL = "http://www.phylowidget.org/full/?tree='http://"+location.host+"${url}"+"TB2:Tr"+tree_id+"'"; - window.open(realURL,'myplwidget') - } - - </script> + <input type="checkbox" id="s-${tree.id }" name="selection" value="${tree.id }" /> <a href="javascript:void(0)" onClick="openPhylowidget(${tree.id})">Tr${tree.id}</a> </display:column> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <yo...@us...> - 2010-04-02 18:58:37
|
Revision: 668 http://treebase.svn.sourceforge.net/treebase/?rev=668&view=rev Author: youjun Date: 2010-04-02 18:58:31 +0000 (Fri, 02 Apr 2010) Log Message: ----------- move the javascript function Modified Paths: -------------- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/study/trees.jsp trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeList.jsp Modified: trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/study/trees.jsp =================================================================== --- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/study/trees.jsp 2010-04-02 00:44:31 UTC (rev 667) +++ trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/study/trees.jsp 2010-04-02 18:58:31 UTC (rev 668) @@ -12,7 +12,7 @@ <script type="text/javascript"> function openPhylowidget(tree_id) { - var realURL = "http://www.phylowidget.org/full/?tree='http://"+location.host+"${url}"+"TB2:Tr"+tree_id+"'"; + var realURL = "http://www.phylowidget.org/full/?tree='http://"+location.host+"/treebase-web/tree_for_phylowidget/"+"TB2:Tr"+tree_id+"'"; window.open(realURL,'myplwidget') } </script> Modified: trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeList.jsp =================================================================== --- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeList.jsp 2010-04-02 00:44:31 UTC (rev 667) +++ trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/treeList.jsp 2010-04-02 18:58:31 UTC (rev 668) @@ -7,7 +7,7 @@ <script type="text/javascript"> function openPhylowidget(tree_id) { - var realURL = "http://www.phylowidget.org/full/?tree='http://"+location.host+"${url}"+"TB2:Tr"+tree_id+"'"; + var realURL = "http://www.phylowidget.org/full/?tree='http://"+location.host+"/treebase-web/tree_for_phylowidget/"+"TB2:Tr"+tree_id+"'"; window.open(realURL,'myplwidget') } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rv...@us...> - 2011-04-29 00:20:45
|
Revision: 819 http://treebase.svn.sourceforge.net/treebase/?rev=819&view=rev Author: rvos Date: 2011-04-29 00:20:39 +0000 (Fri, 29 Apr 2011) Log Message: ----------- Reverting Removed Paths: ------------- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/mainSearch.jsp trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/mainSimpleSearchForm.jsp Deleted: trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/mainSearch.jsp =================================================================== --- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/mainSearch.jsp 2011-04-29 00:19:26 UTC (rev 818) +++ trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/mainSearch.jsp 2011-04-29 00:20:39 UTC (rev 819) @@ -1,36 +0,0 @@ -<%@ include file="/common/taglibs.jsp"%> - -<title><fmt:message key="search.main"/></title> -<body id="s-main"/> - -<div id="wrap"> - <!-- these are the tabs that switch between search forms --> - <jsp:include page="/common/search-nav.jsp"/> - <div id="s-clear"></div> - - <c:set var="searchType" value="main" scope="request"/> - - <!-- this is the simple search box --> - <jsp:include page="mainSimpleSearchForm.jsp"/> - <div id="s-clear"></div> - - <!-- this contains any search warnings, e.g. if an empty query string was provided --> - <jsp:include page="searchMessages.jsp"/> - - <div id="searchResultsList"> - <c:set var="resultSet" value="${studyResults}"/> - <jsp:include page="studyList.jsp"/> - - <c:set var="resultSet" value="${matrixResults}"/> - <jsp:include page="matrixList.jsp"/> - - <c:set var="resultSet" value="${treeResults}"/> - <jsp:include page="treeList.jsp"/> - - <c:set var="resultSet" value="${taxonResults}"/> - <jsp:include page="taxonList.jsp"/> - </div> - - <div id="output"></div> - -</div> \ No newline at end of file Deleted: trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/mainSimpleSearchForm.jsp =================================================================== --- trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/mainSimpleSearchForm.jsp 2011-04-29 00:19:26 UTC (rev 818) +++ trunk/treebase-web/src/main/webapp/WEB-INF/pages/search/mainSimpleSearchForm.jsp 2011-04-29 00:20:39 UTC (rev 819) @@ -1,11 +0,0 @@ -<%@ include file="/common/taglibs.jsp"%> -<form id="searchSimple" method="post"> - <fieldset> - <input type="hidden" name="formName" value="mainSimple"/> - <input type="text" class="textCell" style="width:150px" name="query" id="keyword" value="${query}"/> - <input type="submit" value="Search"> - <a href="#" class="openHelp" onclick="openHelp('mainSimpleSearchForm')"> - <img class="iconButton" src="<fmt:message key="icons.help"/>" /> - </a> - </fieldset> -</form> \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |