diff options
author | Alvin Li <liweitianux@gmail.com> | 2013-08-13 14:42:32 +0800 |
---|---|---|
committer | Alvin Li <liweitianux@gmail.com> | 2013-08-13 14:42:32 +0800 |
commit | 755463eed74ed7de9a3c1a12495d2dad655d31d5 (patch) | |
tree | f2a77a7a95cd5135ef7b253aa765652ba8323a90 /isuifang_solr/solr/conf/velocity/query.vm | |
parent | 9636d4a6767f49384d5c386bc3f1142c88b90613 (diff) | |
download | 97dev-755463eed74ed7de9a3c1a12495d2dad655d31d5.tar.bz2 |
added 'isuifang_solr'
Diffstat (limited to 'isuifang_solr/solr/conf/velocity/query.vm')
-rw-r--r-- | isuifang_solr/solr/conf/velocity/query.vm | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/isuifang_solr/solr/conf/velocity/query.vm b/isuifang_solr/solr/conf/velocity/query.vm new file mode 100644 index 0000000..2247c53 --- /dev/null +++ b/isuifang_solr/solr/conf/velocity/query.vm @@ -0,0 +1,56 @@ +<!-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + --> + +<div class="query-box"> + <form id="query-form" action="#{url_for_home}" method="GET"> + <div class="inputs"> + <span #annTitle("Add the query using the &q= parameter")>Find: <input type="text" id="q" name="q" value="$!esc.html($params.get('q'))"/> <input type="submit" id="querySubmit"/> <input type="reset"/></span> + <div class="query-boost"><span #annTitle("Add the boost function &bf=price to the query")><input type="checkbox" name="bf" value="price" #if($request.params.get('bf') == 'price')checked="true"#end>Boost by Price</input></span> + #parse("querySpatial.vm") + </div> + </div> + + #if($request.params.get('debugQuery')) + <input type="hidden" name="debugQuery" value="true"/> + #end + #if($annotate == true) + <input type="hidden" name="annotateBrowse" value="true"/> + #end + #foreach($fq in $request.params.getParams('fq')) + #if ($fq != "{!bbox}") + <input type="hidden" name="fq" id="allFQs" value="$esc.html($fq)"/> + #end + #end + <div class="constraints" #annTitle("Lists out the &fq filters. Click to remove.")> + #foreach($fq in $params.getParams('fq')) + #set($previous_fq_count=$velocityCount - 1) + #if($fq != '') + > <a style="{text-decoration: line-through;}" href="#url_for_filters($request.params.getParams('fq').subList(0,$previous_fq_count))">$fq</a> + #end + #end + </div> + #if($request.params.get('debugQuery')) + <a href="#" onclick='jQuery(this).siblings("pre").toggle(); return false;'>toggle parsed query</a> + <pre style="display:none">$response.response.debug.parsedquery</pre> + #end + #set($queryOpts = $request.params.get("queryOpts")) + #if($queryOpts && $queryOpts != "") + <input type="hidden" name="queryOpts" value="$queryOpts"/> + #end + </form> + +</div> |