SOLR-7666 Resolve exceptions and tidy HTML label name

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1707463 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Upayavira 2015-10-08 09:31:24 +00:00
parent 7e6ba558ff
commit 37341ab1c8
3 changed files with 9 additions and 10 deletions

View File

@ -103,14 +103,13 @@ function($scope, $rootScope, $routeParams, Luke, CoreSystem, Update, Replication
$scope.refreshPing = function() {
Ping.status({core: $routeParams.core}, function(data) {
$scope.healthcheckStatus = data.status == "enabled";
}).$promise.catch(function(error) {
if (error.status == 404) {
if (data.error) {
$scope.healthcheckStatus = false;
if (data.error.code == 503) {
$scope.healthcheckMessage = 'Ping request handler is not configured with a healthcheck file.';
}
} else {
$scope.healthcheckStatus = false;
delete $rootScope.exception;
$scope.healthcheckMessage = 'Ping request handler is not configured with a healthcheck file.';
$scope.healthcheckStatus = data.status == "enabled";
}
});
};

View File

@ -136,7 +136,7 @@ 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'}},
"schema": {params: {show:'schema'}},
"field": {},
"fields": {params: {show:'schema'}, interceptor: {
@ -178,8 +178,8 @@ solrAdminServices.factory('System',
['$resource', function($resource) {
return $resource('/solr/:core/admin/ping', {wt:'json', core: '@core', ts:Date.now(), _:Date.now()}, {
"ping": {},
"status": {params:{action:"status"}}
});
"status": {params:{action:"status"}, headers: {doNotIntercept: "true"}
}});
}])
.factory('Mbeans',
['$resource', function($resource) {

View File

@ -109,7 +109,7 @@ limitations under the License.
<input type="text" id="swap_core" name="core" ng-model="selectedCore" readonly="readonly"></p>
<p class="clearfix"><label for="swap_other">and:</label>
<select name="other" ng-model="swapOther" ng-options="core.name as core.name for core in swapCorelist" class="other">
<select id="swap_other" ng-model="swapOther" ng-options="core.name as core.name for core in swapCorelist" class="other">
</select></p>
<p class="clearfix note error" ng-show="swapMessage">