Apache Lucene open-source search software
SOLR-3371: update sammy paths so the core name is not assumed in request
Ryan McKinleycfbabcf54f27
diff --git a/solr/webapp/web/css/styles/menu.css b/solr/webapp/web/css/styles/menu.cssindex a1c7e3deb99..b23bbdf4484 100644--- a/solr/webapp/web/css/styles/menu.css+++ b/solr/webapp/web/css/styles/menu.css@@ -177,12 +177,12 @@color: #333;}-#menu #index p a { background-image: url( ../../img/ico/dashboard.png ); }-#menu #logging p a { background-image: url( ../../img/ico/inbox-document-text.png ); }-#menu #java-properties p a { background-image: url( ../../img/ico/jar.png ); }-#menu #threads p a { background-image: url( ../../img/ico/ui-accordion.png ); }-#menu #cores p a { background-image: url( ../../img/ico/databases.png ); }-#menu #cloud p a { background-image: url( ../../img/ico/network-cloud.png ); }+#menu #index.global p a { background-image: url( ../../img/ico/dashboard.png ); }+#menu #logging.global p a { background-image: url( ../../img/ico/inbox-document-text.png ); }+#menu #java-properties.global p a { background-image: url( ../../img/ico/jar.png ); }+#menu #threads.global p a { background-image: url( ../../img/ico/ui-accordion.png ); }+#menu #cores.global p a { background-image: url( ../../img/ico/databases.png ); }+#menu #cloud.global p a { background-image: url( ../../img/ico/network-cloud.png ); }#menu-selector .ping.error a{@@ -228,6 +228,9 @@padding-left: 26px;padding-top: 5px;padding-bottom: 5px;+ overflow: hidden;+ text-overflow: ellipsis;+ white-space: nowrap;}#content #navigation a:hoverdiff --git a/solr/webapp/web/js/scripts/app.js b/solr/webapp/web/js/scripts/app.jsindex 00f3b9a97ca..c67e3405263 100644--- a/solr/webapp/web/js/scripts/app.js+++ b/solr/webapp/web/js/scripts/app.js@@ -98,7 +98,11 @@ var sammy = $.sammyif( this.params.splat ){- var active_element = $( '#' + this.params.splat[0], menu_wrapper );+ var selector = '~' === this.params.splat[0][0]+ ? '#' + this.params.splat[0].replace( /^~/, '' ) + '.global'+ : '#menu-selector #' + this.params.splat[0];++ var active_element = $( selector, menu_wrapper );if( 0 === active_element.size() ){diff --git a/solr/webapp/web/js/scripts/cloud.js b/solr/webapp/web/js/scripts/cloud.jsindex cfd19003492..bbb7e9dd86d 100644--- a/solr/webapp/web/js/scripts/cloud.js+++ b/solr/webapp/web/js/scripts/cloud.js@@ -661,7 +661,7 @@ var init_tree = function( tree_element )// #/~cloudsammy.get(- /^#\/~(cloud)$/,+ /^#\/(~cloud)$/,function( context ){var content_element = $( '#content' );diff --git a/solr/webapp/web/js/scripts/cores.js b/solr/webapp/web/js/scripts/cores.jsindex 09b5d2ca860..05f21b1f71b 100644--- a/solr/webapp/web/js/scripts/cores.js+++ b/solr/webapp/web/js/scripts/cores.js@@ -104,7 +104,7 @@ sammy.bind// #/~coressammy.get(- /^#\/~(cores)$/,+ /^#\/(~cores)$/,function( context ){delete app.cores_template;@@ -134,7 +134,7 @@ sammy.get// #/~coressammy.get(- /^#\/~(cores)\//,+ /^#\/(~cores)\//,function( context ){var content_element = $( '#content' );diff --git a/solr/webapp/web/js/scripts/java-properties.js b/solr/webapp/web/js/scripts/java-properties.jsindex f4e35ec44aa..af33195d0c5 100644--- a/solr/webapp/web/js/scripts/java-properties.js+++ b/solr/webapp/web/js/scripts/java-properties.js@@ -18,7 +18,7 @@// #/~java-propertiessammy.get(- /^#\/~(java-properties)$/,+ /^#\/(~java-properties)$/,function( context ){var core_basepath = $( 'li[data-basepath]', app.menu_element ).attr( 'data-basepath' );diff --git a/solr/webapp/web/js/scripts/logging.js b/solr/webapp/web/js/scripts/logging.jsindex 6fbb93cb350..7b95b21b117 100644--- a/solr/webapp/web/js/scripts/logging.js+++ b/solr/webapp/web/js/scripts/logging.js@@ -383,7 +383,7 @@ var load_logging_viewer = function()// #/~loggingsammy.get(- /^#\/~(logging)$/,+ /^#\/(~logging)$/,function( context ){var core_basepath = $( 'li[data-basepath]', app.menu_element ).attr( 'data-basepath' );diff --git a/solr/webapp/web/js/scripts/threads.js b/solr/webapp/web/js/scripts/threads.jsindex 547139a31c0..f0291b4d8bf 100644--- a/solr/webapp/web/js/scripts/threads.js+++ b/solr/webapp/web/js/scripts/threads.js@@ -18,7 +18,7 @@// #/~threadssammy.get(- /^#\/~(threads)$/,+ /^#\/(~threads)$/,function( context ){var core_basepath = $( 'li[data-basepath]', app.menu_element ).attr( 'data-basepath' );