You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by up...@apache.org on 2015/10/24 13:40:07 UTC

svn commit: r1710333 - in /lucene/dev/trunk/solr/webapp/web: WEB-INF/web.xml css/angular/menu.css index.html js/angular/app.js js/angular/services.js

Author: upayavira
Date: Sat Oct 24 11:40:07 2015
New Revision: 1710333

URL: http://svn.apache.org/viewvc?rev=1710333&view=rev
Log:
SOLR-7858 Add web.xml changes

Modified:
    lucene/dev/trunk/solr/webapp/web/WEB-INF/web.xml
    lucene/dev/trunk/solr/webapp/web/css/angular/menu.css
    lucene/dev/trunk/solr/webapp/web/index.html
    lucene/dev/trunk/solr/webapp/web/js/angular/app.js
    lucene/dev/trunk/solr/webapp/web/js/angular/services.js

Modified: lucene/dev/trunk/solr/webapp/web/WEB-INF/web.xml
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/solr/webapp/web/WEB-INF/web.xml?rev=1710333&r1=1710332&r2=1710333&view=diff
==============================================================================
--- lucene/dev/trunk/solr/webapp/web/WEB-INF/web.xml (original)
+++ lucene/dev/trunk/solr/webapp/web/WEB-INF/web.xml Sat Oct 24 11:40:07 2015
@@ -141,7 +141,12 @@
 
   <servlet-mapping>
     <servlet-name>LoadAdminUI</servlet-name>
-    <url-pattern>/admin.html</url-pattern>
+    <url-pattern>/old.html</url-pattern>
+  </servlet-mapping>
+
+  <servlet-mapping>
+    <servlet-name>LoadAdminUI</servlet-name>
+    <url-pattern>/index.html</url-pattern>
   </servlet-mapping>
 
   <servlet-mapping>
@@ -156,7 +161,7 @@
   </mime-mapping>
 
   <welcome-file-list>
-    <welcome-file>admin.html</welcome-file>
+    <welcome-file>index.html</welcome-file>
   </welcome-file-list>
 
 </web-app>

Modified: lucene/dev/trunk/solr/webapp/web/css/angular/menu.css
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/solr/webapp/web/css/angular/menu.css?rev=1710333&r1=1710332&r2=1710333&view=diff
==============================================================================
--- lucene/dev/trunk/solr/webapp/web/css/angular/menu.css (original)
+++ lucene/dev/trunk/solr/webapp/web/css/angular/menu.css Sat Oct 24 11:40:07 2015
@@ -278,7 +278,7 @@ limitations under the License.
 .sub-menu .analysis a { background-image: url( ../../img/ico/funnel.png ); }
 .sub-menu .documents a { background-image: url( ../../img/ico/documents-stack.png ); }
 .sub-menu .files a { background-image: url( ../../img/ico/folder.png ); }
-.sub-menu .schema-browser a { background-image: url( ../../img/ico/book-open-text.png ); }
+.sub-menu .schema a { background-image: url( ../../img/ico/book-open-text.png ); }
 .sub-menu .replication a { background-image: url( ../../img/ico/node.png ); }
 .sub-menu .distribution a { background-image: url( ../../img/ico/node-select.png ); }
 .sub-menu .ping a { background-image: url( ../../img/ico/system-monitor.png ); }

Modified: lucene/dev/trunk/solr/webapp/web/index.html
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/solr/webapp/web/index.html?rev=1710333&r1=1710332&r2=1710333&view=diff
==============================================================================
--- lucene/dev/trunk/solr/webapp/web/index.html (original)
+++ lucene/dev/trunk/solr/webapp/web/index.html Sat Oct 24 11:40:07 2015
@@ -39,7 +39,7 @@ limitations under the License.
   <link rel="stylesheet" type="text/css" href="css/angular/documents.css?_=${version}">
   <link rel="stylesheet" type="text/css" href="css/angular/query.css?_=${version}">
   <link rel="stylesheet" type="text/css" href="css/angular/replication.css?_=${version}">
-  <link rel="stylesheet" type="text/css" href="css/angular/schema-browser.css?_=${version}">
+  <link rel="stylesheet" type="text/css" href="css/angular/schema.css?_=${version}">
   <link rel="stylesheet" type="text/css" href="css/angular/segments.css?_=${version}">
   <link rel="stylesheet" type="text/css" href="css/angular/threads.css?_=${version}">
   <link rel="stylesheet" type="text/css" href="css/angular/chosen.css?_=${version}">
@@ -74,7 +74,7 @@ limitations under the License.
   <script src="js/angular/controllers/query.js"></script>
   <script src="js/angular/controllers/plugins.js"></script>
   <script src="js/angular/controllers/replication.js"></script>
-  <script src="js/angular/controllers/schema-browser.js"></script>
+  <script src="js/angular/controllers/schema.js"></script>
   <script src="js/angular/controllers/segments.js"></script>
 
 </head>
@@ -185,7 +185,7 @@ limitations under the License.
               <li class="documents" ng-class="{active:page=='documents'}"><a href="#/{{currentCollection.name}}/documents"><span>Documents</span></a></li>
               <li class="files" ng-class="{active:page=='files'}"><a href="#/{{currentCollection.name}}/files"><span>Files</span></a></li>
               <li class="query" ng-class="{active:page=='query'}"><a href="#/{{currentCollection.name}}/query"><span>Query</span></a></li>
-              <li class="schema-browser" ng-class="{active:page=='schema-browser'}"><a href="#/{{currentCollection.name}}/schema-browser"><span>Schema Browser</span></a></li>
+              <li class="schema" ng-class="{active:page=='schema'}"><a href="#/{{currentCollection.name}}/schema"><span>Schema</span></a></li>
         </ul>
           </div>
           <div id="core-selector">
@@ -212,7 +212,7 @@ limitations under the License.
               <li class="plugins" ng-class="{active:page=='plugins'}"><a href="#/{{currentCore.name}}/plugins"><span>Plugins / Stats</span></a></li>
               <li ng-hide="isCloudEnabled" class="query" ng-class="{active:page=='query'}"><a href="#/{{currentCore.name}}/query"><span>Query</span></a></li>
               <li class="replication" ng-class="{active:page=='replication'}"><a href="#/{{currentCore.name}}/replication"><span>Replication</span></a></li>
-              <li ng-hide="isCloudEnabled" class="schema-browser" ng-class="{active:page=='schema-browser'}"><a href="#/{{currentCore.name}}/schema-browser"><span>Schema Browser</span></a></li>
+              <li ng-hide="isCloudEnabled" class="schema" ng-class="{active:page=='schema'}"><a href="#/{{currentCore.name}}/schema"><span>Schema</span></a></li>
               <li class="segments" ng-class="{active:page=='segments'}"><a href="#/{{currentCore.name}}/segments"><span>Segments info</span></a></li>
       </ul>
           </div>

Modified: lucene/dev/trunk/solr/webapp/web/js/angular/app.js
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/solr/webapp/web/js/angular/app.js?rev=1710333&r1=1710332&r2=1710333&view=diff
==============================================================================
--- lucene/dev/trunk/solr/webapp/web/js/angular/app.js (original)
+++ lucene/dev/trunk/solr/webapp/web/js/angular/app.js Sat Oct 24 11:40:07 2015
@@ -121,9 +121,9 @@ solrAdminApp.config([
         templateUrl: 'partials/dataimport.html',
         controller: 'DataImportController'
       }).
-      when('/:core/schema-browser', {
-        templateUrl: 'partials/schema-browser.html',
-        controller: 'SchemaBrowserController'
+      when('/:core/schema', {
+        templateUrl: 'partials/schema.html',
+        controller: 'SchemaController'
       }).
       when('/:core/segments', {
         templateUrl: 'partials/segments.html',
@@ -156,6 +156,31 @@ solrAdminApp.config([
     }
   };
 })
+.directive('escapePressed', function () {
+    return function (scope, element, attrs) {
+        element.bind("keydown keypress", function (event) {
+            if(event.which === 27) {
+                scope.$apply(function (){
+                    scope.$eval(attrs.escapePressed);
+                });
+                event.preventDefault();
+            }
+        });
+    };
+})
+.directive('focusWhen', function($timeout) {
+  return {
+    link: function(scope, element, attrs) {
+      scope.$watch(attrs.focusWhen, function(value) {
+        if(value === true) {
+          $timeout(function() {
+            element[0].focus();
+          }, 100);
+        }
+      });
+    }
+  };
+})
 .filter('readableSeconds', function() {
     return function(input) {
     seconds = parseInt(input||0, 10);

Modified: lucene/dev/trunk/solr/webapp/web/js/angular/services.js
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/solr/webapp/web/js/angular/services.js?rev=1710333&r1=1710332&r2=1710333&view=diff
==============================================================================
--- lucene/dev/trunk/solr/webapp/web/js/angular/services.js (original)
+++ lucene/dev/trunk/solr/webapp/web/js/angular/services.js Sat Oct 24 11:40:07 2015
@@ -136,7 +136,8 @@ solrAdminServices.factory('System',
 .factory('Luke',
   ['$resource', function($resource) {
     return $resource('/solr/:core/admin/luke', {core: '@core', wt:'json', _:Date.now()}, {
-      "index":  {params: {numTerms: 0}},
+      "index":  {params: {numTerms: 0, show: 'index'}},
+      "raw": {params: {numTerms: 0}},
       "schema": {params: {show:'schema'}},
       "field": {},
       "fields": {params: {show:'schema'}, interceptor: {
@@ -238,5 +239,18 @@ solrAdminServices.factory('System',
        return $resource('/solr/:core/admin/segments', {'wt':'json', core: '@core', _:Date.now()}, {
            get: {}
        });
-   }
-]);
+}])
+.factory('Schema',
+   ['$resource', function($resource) {
+     return $resource('/solr/:core/schema', {wt: 'json', core: '@core', _:Date.now()}, {
+       get: {method: "GET"},
+       check: {method: "GET", headers: {doNotIntercept: "true"}},
+       post: {method: "POST"}
+     });
+}])
+.factory('Config',
+   ['$resource', function($resource) {
+     return $resource('/solr/:core/config', {wt: 'json', core: '@core', _:Date.now()}, {
+       get: {method: "GET"}
+     })
+}]);