Initial content
This commit is contained in:
parent
15e5ea6a2f
commit
86fe317055
92 changed files with 13147 additions and 0 deletions
37
vivocore/conf/velocity/head.vm
Normal file
37
vivocore/conf/velocity/head.vm
Normal file
|
@ -0,0 +1,37 @@
|
|||
#**
|
||||
* Provide elements for the <head> section of the HTML document
|
||||
*#
|
||||
|
||||
## An example of using an arbitrary request parameter
|
||||
<title>#param('title')</title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8"/>
|
||||
|
||||
<script type="text/javascript" src="#{url_root}/libs/jquery-1.7.2.min.js"></script>
|
||||
<link rel="stylesheet" type="text/css" href="#{url_for_solr}/admin/file?file=/velocity/main.css&contentType=text/css"/>
|
||||
<link rel="stylesheet" href="#{url_for_solr}/admin/file?file=/velocity/jquery.autocomplete.css&contentType=text/css" type="text/css" />
|
||||
<link rel="icon" type="image/x-icon" href="#{url_root}/img/favicon.ico"/>
|
||||
<link rel="shortcut icon" type="image/x-icon" href="#{url_root}/img/favicon.ico"/>
|
||||
<script type="text/javascript" src="#{url_for_solr}/admin/file?file=/velocity/jquery.autocomplete.js&contentType=text/javascript"></script>
|
||||
|
||||
|
||||
<script>
|
||||
$(document).ready(function(){
|
||||
$("\#q").autocomplete('#{url_for_solr}/terms', { ## backslash escaped #q as that is a macro defined in VM_global_library.vm
|
||||
extraParams:{
|
||||
'terms.prefix': function() { return $("\#q").val();},
|
||||
'terms.sort': 'count',
|
||||
'terms.fl': 'name',
|
||||
'wt': 'velocity',
|
||||
'v.template': 'suggest'
|
||||
}
|
||||
}
|
||||
).keydown(function(e){
|
||||
if (e.keyCode === 13){
|
||||
$("#query-form").trigger('submit');
|
||||
}
|
||||
});
|
||||
|
||||
// http://localhost:8983/solr/collection1/terms?terms.fl=name&terms.prefix=i&terms.sort=count&wt=velocity&v.template=suggest
|
||||
});
|
||||
|
||||
</script>
|
Loading…
Add table
Add a link
Reference in a new issue