mirror of https://github.com/apache/nifi.git
NIFI-6160 Apply config error handling convention
What this PR changed: - Standardized required name error message to 'The name of the xxxx must be specified' - Added nfErrorHandler.handleConfigurationUpdateAjaxError - Replaced existing custom error handling for 400 status code - Replaced handleAjxError with this where appropriate - Standardized config error dialog title to 'Configuration Error' - Close the configuration dialog when configuration is successfully updated Above convention applied to following components: - ProcessGroup - Input/OutputPort - RemoteProcessGroup - RemoteGroupPort - Template - Connection - ControllerService - Label - Processor - ReportingTask - NiFi Settings/GENERAL tab - Variable - User NIFI-6170 Provide consistent UX at Connection config Fixed Label. Incorporated review comments Removed unnecessary else block. Disable canvas when the message pane is shown This closes #3401
This commit is contained in:
parent
0e5a80d23f
commit
31463c5dad
|
@ -252,7 +252,7 @@ public final class StandardProcessGroup implements ProcessGroup {
|
||||||
@Override
|
@Override
|
||||||
public void setName(final String name) {
|
public void setName(final String name) {
|
||||||
if (StringUtils.isBlank(name)) {
|
if (StringUtils.isBlank(name)) {
|
||||||
throw new IllegalArgumentException("The name cannot be blank.");
|
throw new IllegalArgumentException("The name of the process group must be specified.");
|
||||||
}
|
}
|
||||||
|
|
||||||
this.name.set(name);
|
this.name.set(name);
|
||||||
|
|
|
@ -162,7 +162,7 @@ public class StandardInputPortDAO extends ComponentDAO implements PortDAO {
|
||||||
List<String> validationErrors = new ArrayList<>();
|
List<String> validationErrors = new ArrayList<>();
|
||||||
|
|
||||||
if (isNotNull(portDTO.getName()) && portDTO.getName().trim().isEmpty()) {
|
if (isNotNull(portDTO.getName()) && portDTO.getName().trim().isEmpty()) {
|
||||||
validationErrors.add("Port name cannot be blank.");
|
validationErrors.add("The name of the port must be specified.");
|
||||||
}
|
}
|
||||||
if (isNotNull(portDTO.getConcurrentlySchedulableTaskCount()) && portDTO.getConcurrentlySchedulableTaskCount() <= 0) {
|
if (isNotNull(portDTO.getConcurrentlySchedulableTaskCount()) && portDTO.getConcurrentlySchedulableTaskCount() <= 0) {
|
||||||
validationErrors.add("Concurrent tasks must be a positive integer.");
|
validationErrors.add("Concurrent tasks must be a positive integer.");
|
||||||
|
|
|
@ -158,7 +158,7 @@ public class StandardOutputPortDAO extends ComponentDAO implements PortDAO {
|
||||||
List<String> validationErrors = new ArrayList<>();
|
List<String> validationErrors = new ArrayList<>();
|
||||||
|
|
||||||
if (isNotNull(portDTO.getName()) && portDTO.getName().trim().isEmpty()) {
|
if (isNotNull(portDTO.getName()) && portDTO.getName().trim().isEmpty()) {
|
||||||
validationErrors.add("Port name cannot be blank.");
|
validationErrors.add("The name of the port must be specified.");
|
||||||
}
|
}
|
||||||
if (isNotNull(portDTO.getConcurrentlySchedulableTaskCount()) && portDTO.getConcurrentlySchedulableTaskCount() <= 0) {
|
if (isNotNull(portDTO.getConcurrentlySchedulableTaskCount()) && portDTO.getConcurrentlySchedulableTaskCount() <= 0) {
|
||||||
validationErrors.add("Concurrent tasks must be a positive integer.");
|
validationErrors.add("Concurrent tasks must be a positive integer.");
|
||||||
|
|
|
@ -102,7 +102,7 @@
|
||||||
|
|
||||||
// update the birdseye
|
// update the birdseye
|
||||||
nfBirdseye.refresh();
|
nfBirdseye.refresh();
|
||||||
}).fail(nfErrorHandler.handleAjaxError);
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
};
|
};
|
||||||
|
|
||||||
function GroupComponent() {
|
function GroupComponent() {
|
||||||
|
@ -235,18 +235,18 @@
|
||||||
// get the name of the group and clear the textfield
|
// get the name of the group and clear the textfield
|
||||||
var groupName = $('#new-process-group-name').val();
|
var groupName = $('#new-process-group-name').val();
|
||||||
|
|
||||||
// hide the dialog
|
|
||||||
groupComponent.modal.hide();
|
|
||||||
|
|
||||||
// ensure the group name is specified
|
// ensure the group name is specified
|
||||||
if (nfCommon.isBlank(groupName)) {
|
if (nfCommon.isBlank(groupName)) {
|
||||||
nfDialog.showOkDialog({
|
nfDialog.showOkDialog({
|
||||||
headerText: 'Create Process Group',
|
headerText: 'Configuration Error',
|
||||||
dialogContent: 'The group name is required.'
|
dialogContent: 'The name of the process group must be specified.'
|
||||||
});
|
});
|
||||||
|
|
||||||
deferred.reject();
|
deferred.reject();
|
||||||
} else {
|
} else {
|
||||||
|
// hide the dialog
|
||||||
|
groupComponent.modal.hide();
|
||||||
|
|
||||||
// create the group and resolve the deferred accordingly
|
// create the group and resolve the deferred accordingly
|
||||||
createGroup(groupName, pt).done(function (response) {
|
createGroup(groupName, pt).done(function (response) {
|
||||||
deferred.resolve(response.component);
|
deferred.resolve(response.component);
|
||||||
|
|
|
@ -91,12 +91,15 @@
|
||||||
'selectAll': true
|
'selectAll': true
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// hide the dialog
|
||||||
|
inputPortComponent.modal.hide();
|
||||||
|
|
||||||
// update component visibility
|
// update component visibility
|
||||||
nfGraph.updateVisibility();
|
nfGraph.updateVisibility();
|
||||||
|
|
||||||
// update the birdseye
|
// update the birdseye
|
||||||
nfBirdseye.refresh();
|
nfBirdseye.refresh();
|
||||||
}).fail(nfErrorHandler.handleAjaxError);
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
};
|
};
|
||||||
|
|
||||||
function InputPortComponent() {
|
function InputPortComponent() {
|
||||||
|
@ -217,9 +220,6 @@
|
||||||
// get the name of the input port and clear the textfield
|
// get the name of the input port and clear the textfield
|
||||||
var portName = $('#new-port-name').val();
|
var portName = $('#new-port-name').val();
|
||||||
|
|
||||||
// hide the dialog
|
|
||||||
inputPortComponent.modal.hide();
|
|
||||||
|
|
||||||
// create the input port
|
// create the input port
|
||||||
createInputPort(portName, pt);
|
createInputPort(portName, pt);
|
||||||
};
|
};
|
||||||
|
|
|
@ -91,12 +91,15 @@
|
||||||
'selectAll': true
|
'selectAll': true
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// hide the dialog
|
||||||
|
outputPortComponent.modal.hide();
|
||||||
|
|
||||||
// update component visibility
|
// update component visibility
|
||||||
nfGraph.updateVisibility();
|
nfGraph.updateVisibility();
|
||||||
|
|
||||||
// update the birdseye
|
// update the birdseye
|
||||||
nfBirdseye.refresh();
|
nfBirdseye.refresh();
|
||||||
}).fail(nfErrorHandler.handleAjaxError);
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
};
|
};
|
||||||
|
|
||||||
function OutputPortComponent() {
|
function OutputPortComponent() {
|
||||||
|
@ -208,9 +211,6 @@
|
||||||
// get the name of the output port and clear the textfield
|
// get the name of the output port and clear the textfield
|
||||||
var portName = $('#new-port-name').val();
|
var portName = $('#new-port-name').val();
|
||||||
|
|
||||||
// hide the dialog
|
|
||||||
outputPortComponent.modal.hide();
|
|
||||||
|
|
||||||
// create the output port
|
// create the output port
|
||||||
createOutputPort(portName, pt);
|
createOutputPort(portName, pt);
|
||||||
};
|
};
|
||||||
|
|
|
@ -113,25 +113,7 @@
|
||||||
|
|
||||||
// update the birdseye
|
// update the birdseye
|
||||||
nfBirdseye.refresh();
|
nfBirdseye.refresh();
|
||||||
}).fail(function (xhr, status, error) {
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
if (xhr.status === 400) {
|
|
||||||
var errors = xhr.responseText.split('\n');
|
|
||||||
|
|
||||||
var content;
|
|
||||||
if (errors.length === 1) {
|
|
||||||
content = $('<span></span>').text(errors[0]);
|
|
||||||
} else {
|
|
||||||
content = nfCommon.formatUnorderedList(errors);
|
|
||||||
}
|
|
||||||
|
|
||||||
nfDialog.showOkDialog({
|
|
||||||
dialogContent: content,
|
|
||||||
headerText: 'Configuration Error'
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
nfErrorHandler.handleAjaxError(xhr, status, error);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
};
|
};
|
||||||
|
|
||||||
function RemoteProcessGroupComponent() {
|
function RemoteProcessGroupComponent() {
|
||||||
|
|
|
@ -1642,8 +1642,8 @@
|
||||||
// ensure the template name is not blank
|
// ensure the template name is not blank
|
||||||
if (nfCommon.isBlank(templateName)) {
|
if (nfCommon.isBlank(templateName)) {
|
||||||
nfDialog.showOkDialog({
|
nfDialog.showOkDialog({
|
||||||
headerText: 'Create Template',
|
headerText: 'Configuration Error',
|
||||||
dialogContent: "The template name cannot be blank."
|
dialogContent: "The name of the template must be specified."
|
||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
|
@ -41,17 +41,10 @@
|
||||||
}(this, function (ajaxErrorHandler, nfCommon, nfCanvas, nfContextMenu) {
|
}(this, function (ajaxErrorHandler, nfCommon, nfCanvas, nfContextMenu) {
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
return {
|
var disableCanvas = function() {
|
||||||
|
// In case no further requests will be successful based on the status,
|
||||||
/**
|
// the canvas is disabled, and the message pane is shown.
|
||||||
* Method for handling ajax errors. This also closes the canvas.
|
if ($('#message-pane').is(':visible')) {
|
||||||
*
|
|
||||||
* @argument {object} xhr The XmlHttpRequest
|
|
||||||
* @argument {string} status The status of the request
|
|
||||||
* @argument {string} error The error
|
|
||||||
*/
|
|
||||||
handleAjaxError: function (xhr, status, error) {
|
|
||||||
ajaxErrorHandler.handleAjaxError(xhr, status, error);
|
|
||||||
nfCommon.showLogoutLink();
|
nfCommon.showLogoutLink();
|
||||||
|
|
||||||
// hide the splash screen if required
|
// hide the splash screen if required
|
||||||
|
@ -65,8 +58,36 @@
|
||||||
// shut off the auto refresh
|
// shut off the auto refresh
|
||||||
nfCanvas.stopPolling();
|
nfCanvas.stopPolling();
|
||||||
|
|
||||||
// allow page refresh with ctrl-r
|
// disable page refresh with ctrl-r
|
||||||
nfCanvas.disableRefreshHotKey();
|
nfCanvas.disableRefreshHotKey();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
return {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Method for handling ajax errors. This also closes the canvas if necessary.
|
||||||
|
*
|
||||||
|
* @argument {object} xhr The XmlHttpRequest
|
||||||
|
* @argument {string} status The status of the request
|
||||||
|
* @argument {string} error The error
|
||||||
|
*/
|
||||||
|
handleAjaxError: function (xhr, status, error) {
|
||||||
|
ajaxErrorHandler.handleAjaxError(xhr, status, error);
|
||||||
|
disableCanvas();
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Method for handling ajax errors when submitting configuration update (PUT/POST) requests.
|
||||||
|
* This method delegates error handling to ajaxErrorHandler.
|
||||||
|
*
|
||||||
|
* @argument {object} xhr The XmlHttpRequest
|
||||||
|
* @argument {string} status The status of the request
|
||||||
|
* @argument {string} error The error
|
||||||
|
*/
|
||||||
|
handleConfigurationUpdateAjaxError: function (xhr, status, error) {
|
||||||
|
ajaxErrorHandler.handleConfigurationUpdateAjaxError(xhr, status, error);
|
||||||
|
disableCanvas();
|
||||||
|
}
|
||||||
|
};
|
||||||
}));
|
}));
|
|
@ -129,9 +129,6 @@
|
||||||
handler: {
|
handler: {
|
||||||
click: function () {
|
click: function () {
|
||||||
addConnection(getSelectedRelationships());
|
addConnection(getSelectedRelationships());
|
||||||
|
|
||||||
// close the dialog
|
|
||||||
$('#connection-configuration').modal('hide');
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -195,9 +192,6 @@
|
||||||
click: function () {
|
click: function () {
|
||||||
// add the connection
|
// add the connection
|
||||||
addConnection();
|
addConnection();
|
||||||
|
|
||||||
// close the dialog
|
|
||||||
$('#connection-configuration').modal('hide');
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -971,6 +965,9 @@
|
||||||
'selectAll': true
|
'selectAll': true
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// close the dialog
|
||||||
|
$('#connection-configuration').modal('hide');
|
||||||
|
|
||||||
// reload the connections source/destination components
|
// reload the connections source/destination components
|
||||||
nfCanvasUtils.reloadConnectionSourceAndDestination(sourceComponentId, destinationComponentId);
|
nfCanvasUtils.reloadConnectionSourceAndDestination(sourceComponentId, destinationComponentId);
|
||||||
|
|
||||||
|
@ -979,10 +976,7 @@
|
||||||
|
|
||||||
// update the birdseye
|
// update the birdseye
|
||||||
nfBirdseye.refresh();
|
nfBirdseye.refresh();
|
||||||
}).fail(function (xhr, status, error) {
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
// handle the error
|
|
||||||
nfErrorHandler.handleAjaxError(xhr, status, error);
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -1051,21 +1045,15 @@
|
||||||
dataType: 'json',
|
dataType: 'json',
|
||||||
contentType: 'application/json'
|
contentType: 'application/json'
|
||||||
}).done(function (response) {
|
}).done(function (response) {
|
||||||
|
// close the dialog
|
||||||
|
$('#connection-configuration').modal('hide');
|
||||||
|
|
||||||
// update this connection
|
// update this connection
|
||||||
nfConnection.set(response);
|
nfConnection.set(response);
|
||||||
|
|
||||||
// reload the connections source/destination components
|
// reload the connections source/destination components
|
||||||
nfCanvasUtils.reloadConnectionSourceAndDestination(sourceComponentId, destinationComponentId);
|
nfCanvasUtils.reloadConnectionSourceAndDestination(sourceComponentId, destinationComponentId);
|
||||||
}).fail(function (xhr, status, error) {
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
if (xhr.status === 400 || xhr.status === 404 || xhr.status === 409) {
|
|
||||||
nfDialog.showOkDialog({
|
|
||||||
headerText: 'Connection Configuration',
|
|
||||||
dialogContent: nfCommon.escapeHtml(xhr.responseText),
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
nfErrorHandler.handleAjaxError(xhr, status, error);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
} else {
|
} else {
|
||||||
return $.Deferred(function (deferred) {
|
return $.Deferred(function (deferred) {
|
||||||
deferred.reject();
|
deferred.reject();
|
||||||
|
@ -1120,7 +1108,7 @@
|
||||||
|
|
||||||
if (errors.length > 0) {
|
if (errors.length > 0) {
|
||||||
nfDialog.showOkDialog({
|
nfDialog.showOkDialog({
|
||||||
headerText: 'Connection Configuration',
|
headerText: 'Configuration Error',
|
||||||
dialogContent: nfCommon.formatUnorderedList(errors)
|
dialogContent: nfCommon.formatUnorderedList(errors)
|
||||||
});
|
});
|
||||||
return false;
|
return false;
|
||||||
|
@ -1495,9 +1483,6 @@
|
||||||
deferred.reject();
|
deferred.reject();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// close the dialog
|
|
||||||
$('#connection-configuration').modal('hide');
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
@ -1614,16 +1614,7 @@
|
||||||
}).done(function (response) {
|
}).done(function (response) {
|
||||||
// request was successful, update the entry
|
// request was successful, update the entry
|
||||||
nfConnection.set(response);
|
nfConnection.set(response);
|
||||||
}).fail(function (xhr, status, error) {
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
if (xhr.status === 400 || xhr.status === 404 || xhr.status === 409) {
|
|
||||||
nfDialog.showOkDialog({
|
|
||||||
headerText: 'Connection',
|
|
||||||
dialogContent: nfCommon.escapeHtml(xhr.responseText)
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
nfErrorHandler.handleAjaxError(xhr, status, error);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
};
|
};
|
||||||
|
|
||||||
// removes the specified connections
|
// removes the specified connections
|
||||||
|
|
|
@ -77,33 +77,6 @@
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
|
||||||
* Handle any expected controller service configuration errors.
|
|
||||||
*
|
|
||||||
* @argument {object} xhr The XmlHttpRequest
|
|
||||||
* @argument {string} status The status of the request
|
|
||||||
* @argument {string} error The error
|
|
||||||
*/
|
|
||||||
var handleControllerServiceConfigurationError = function (xhr, status, error) {
|
|
||||||
if (xhr.status === 400) {
|
|
||||||
var errors = xhr.responseText.split('\n');
|
|
||||||
|
|
||||||
var content;
|
|
||||||
if (errors.length === 1) {
|
|
||||||
content = $('<span></span>').text(errors[0]);
|
|
||||||
} else {
|
|
||||||
content = nfCommon.formatUnorderedList(errors);
|
|
||||||
}
|
|
||||||
|
|
||||||
nfDialog.showOkDialog({
|
|
||||||
dialogContent: content,
|
|
||||||
headerText: 'Controller Service'
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
nfErrorHandler.handleAjaxError(xhr, status, error);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Determines whether the user has made any changes to the controller service configuration
|
* Determines whether the user has made any changes to the controller service configuration
|
||||||
* that needs to be saved.
|
* that needs to be saved.
|
||||||
|
@ -1606,7 +1579,7 @@
|
||||||
$.each(previouslyReferencedServiceIds, function (_, oldServiceReferenceId) {
|
$.each(previouslyReferencedServiceIds, function (_, oldServiceReferenceId) {
|
||||||
reloadControllerService(serviceTable, oldServiceReferenceId);
|
reloadControllerService(serviceTable, oldServiceReferenceId);
|
||||||
});
|
});
|
||||||
}).fail(handleControllerServiceConfigurationError);
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
} else {
|
} else {
|
||||||
return $.Deferred(function (deferred) {
|
return $.Deferred(function (deferred) {
|
||||||
deferred.reject();
|
deferred.reject();
|
||||||
|
|
|
@ -295,15 +295,7 @@
|
||||||
id: d.id
|
id: d.id
|
||||||
});
|
});
|
||||||
}).fail(function (xhr, status, error) {
|
}).fail(function (xhr, status, error) {
|
||||||
if (xhr.status === 400 || xhr.status === 404 || xhr.status === 409) {
|
nfErrorHandler.handleAjaxError(xhr, status, error);
|
||||||
nfDialog.showOkDialog({
|
|
||||||
headerText: 'Component Position',
|
|
||||||
dialogContent: nfCommon.escapeHtml(xhr.responseText)
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
nfErrorHandler.handleAjaxError(xhr, status, error);
|
|
||||||
}
|
|
||||||
|
|
||||||
deferred.reject();
|
deferred.reject();
|
||||||
});
|
});
|
||||||
}).promise();
|
}).promise();
|
||||||
|
@ -357,14 +349,7 @@
|
||||||
id: d.id
|
id: d.id
|
||||||
});
|
});
|
||||||
}).fail(function (xhr, status, error) {
|
}).fail(function (xhr, status, error) {
|
||||||
if (xhr.status === 400 || xhr.status === 404 || xhr.status === 409) {
|
nfErrorHandler.handleAjaxError(xhr, status, error);
|
||||||
nfDialog.showOkDialog({
|
|
||||||
headerText: 'Component Position',
|
|
||||||
dialogContent: nfCommon.escapeHtml(xhr.responseText)
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
nfErrorHandler.handleAjaxError(xhr, status, error);
|
|
||||||
}
|
|
||||||
|
|
||||||
deferred.reject();
|
deferred.reject();
|
||||||
});
|
});
|
||||||
|
|
|
@ -76,6 +76,7 @@
|
||||||
},
|
},
|
||||||
handler: {
|
handler: {
|
||||||
click: function () {
|
click: function () {
|
||||||
|
var self = this;
|
||||||
// get the label data
|
// get the label data
|
||||||
var labelData = d3.select('#id-' + labelId).datum();
|
var labelData = d3.select('#id-' + labelId).datum();
|
||||||
|
|
||||||
|
@ -109,10 +110,11 @@
|
||||||
|
|
||||||
// inform Angular app values have changed
|
// inform Angular app values have changed
|
||||||
nfNgBridge.digest();
|
nfNgBridge.digest();
|
||||||
}).fail(nfErrorHandler.handleAjaxError);
|
|
||||||
|
|
||||||
// reset and hide the dialog
|
// reset and hide the dialog
|
||||||
this.modal('hide');
|
self.modal('hide');
|
||||||
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
@ -121,32 +121,7 @@
|
||||||
|
|
||||||
// close the details panel
|
// close the details panel
|
||||||
$('#port-configuration').modal('hide');
|
$('#port-configuration').modal('hide');
|
||||||
}).fail(function (xhr, status, error) {
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
// handle bad request locally to keep the dialog open, allowing the user
|
|
||||||
// to make changes. if the request fails for another reason, the dialog
|
|
||||||
// should be closed so the issue can be addressed (stale flow for instance)
|
|
||||||
if (xhr.status === 400) {
|
|
||||||
var errors = xhr.responseText.split('\n');
|
|
||||||
|
|
||||||
var content;
|
|
||||||
if (errors.length === 1) {
|
|
||||||
content = $('<span></span>').text(errors[0]);
|
|
||||||
} else {
|
|
||||||
content = nfCommon.formatUnorderedList(errors);
|
|
||||||
}
|
|
||||||
|
|
||||||
nfDialog.showOkDialog({
|
|
||||||
dialogContent: content,
|
|
||||||
headerText: 'Port Configuration'
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
// close the details panel
|
|
||||||
$('#port-configuration').modal('hide');
|
|
||||||
|
|
||||||
// handle the error
|
|
||||||
nfErrorHandler.handleAjaxError(xhr, status, error);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
@ -129,7 +129,7 @@
|
||||||
});
|
});
|
||||||
|
|
||||||
nfCanvasUtils.reload();
|
nfCanvasUtils.reload();
|
||||||
}).fail(nfErrorHandler.handleAjaxError);
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -140,33 +140,6 @@
|
||||||
}];
|
}];
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
|
||||||
* Handle any expected processor configuration errors.
|
|
||||||
*
|
|
||||||
* @argument {object} xhr The XmlHttpRequest
|
|
||||||
* @argument {string} status The status of the request
|
|
||||||
* @argument {string} error The error
|
|
||||||
*/
|
|
||||||
var handleProcessorConfigurationError = function (xhr, status, error) {
|
|
||||||
if (xhr.status === 400) {
|
|
||||||
var errors = xhr.responseText.split('\n');
|
|
||||||
|
|
||||||
var content;
|
|
||||||
if (errors.length === 1) {
|
|
||||||
content = $('<span></span>').text(errors[0]);
|
|
||||||
} else {
|
|
||||||
content = nfCommon.formatUnorderedList(errors);
|
|
||||||
}
|
|
||||||
|
|
||||||
nfDialog.showOkDialog({
|
|
||||||
dialogContent: content,
|
|
||||||
headerText: 'Processor Configuration'
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
nfErrorHandler.handleAjaxError(xhr, status, error);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Creates an option for the specified relationship name.
|
* Creates an option for the specified relationship name.
|
||||||
*
|
*
|
||||||
|
@ -426,7 +399,7 @@
|
||||||
if (errors.length > 0) {
|
if (errors.length > 0) {
|
||||||
nfDialog.showOkDialog({
|
nfDialog.showOkDialog({
|
||||||
dialogContent: nfCommon.formatUnorderedList(errors),
|
dialogContent: nfCommon.formatUnorderedList(errors),
|
||||||
headerText: 'Processor Configuration'
|
headerText: 'Configuration Error'
|
||||||
});
|
});
|
||||||
return false;
|
return false;
|
||||||
} else {
|
} else {
|
||||||
|
@ -508,7 +481,7 @@
|
||||||
}).done(function (response) {
|
}).done(function (response) {
|
||||||
// set the new processor state based on the response
|
// set the new processor state based on the response
|
||||||
nfProcessor.set(response);
|
nfProcessor.set(response);
|
||||||
}).fail(handleProcessorConfigurationError);
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
} else {
|
} else {
|
||||||
return $.Deferred(function (deferred) {
|
return $.Deferred(function (deferred) {
|
||||||
deferred.reject();
|
deferred.reject();
|
||||||
|
|
|
@ -110,25 +110,7 @@
|
||||||
|
|
||||||
// close the details panel
|
// close the details panel
|
||||||
$('#remote-process-group-configuration').modal('hide');
|
$('#remote-process-group-configuration').modal('hide');
|
||||||
}).fail(function (xhr, status, error) {
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
if (xhr.status === 400) {
|
|
||||||
var errors = xhr.responseText.split('\n');
|
|
||||||
|
|
||||||
var content;
|
|
||||||
if (errors.length === 1) {
|
|
||||||
content = $('<span></span>').text(errors[0]);
|
|
||||||
} else {
|
|
||||||
content = nfCommon.formatUnorderedList(errors);
|
|
||||||
}
|
|
||||||
|
|
||||||
nfDialog.showOkDialog({
|
|
||||||
dialogContent: content,
|
|
||||||
headerText: 'Remote Process Group Configuration'
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
nfErrorHandler.handleAjaxError(xhr, status, error);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
@ -146,38 +146,16 @@
|
||||||
$('#' + remotePortId + '-batch-size').text(batchSettings.size);
|
$('#' + remotePortId + '-batch-size').text(batchSettings.size);
|
||||||
$('#' + remotePortId + '-batch-duration').text(batchSettings.duration);
|
$('#' + remotePortId + '-batch-duration').text(batchSettings.duration);
|
||||||
|
|
||||||
}).fail(function (xhr, status, error) {
|
|
||||||
if (xhr.status === 400) {
|
|
||||||
var errors = xhr.responseText.split('\n');
|
|
||||||
|
|
||||||
var content;
|
|
||||||
if (errors.length === 1) {
|
|
||||||
content = $('<span></span>').text(errors[0]);
|
|
||||||
} else {
|
|
||||||
content = nfCommon.formatUnorderedList(errors);
|
|
||||||
}
|
|
||||||
|
|
||||||
nfDialog.showOkDialog({
|
|
||||||
dialogContent: content,
|
|
||||||
headerText: 'Remote Process Group Ports'
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
nfErrorHandler.handleAjaxError(xhr, status, error);
|
|
||||||
}
|
|
||||||
}).always(function () {
|
|
||||||
// close the dialog
|
// close the dialog
|
||||||
$('#remote-port-configuration').modal('hide');
|
$('#remote-port-configuration').modal('hide');
|
||||||
});
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
} else {
|
} else {
|
||||||
nfDialog.showOkDialog({
|
nfDialog.showOkDialog({
|
||||||
headerText: 'Remote Process Group Ports',
|
headerText: 'Configuration Error',
|
||||||
dialogContent: portValidationErrors.reduce(function (prev, curr) {
|
dialogContent: portValidationErrors.reduce(function (prev, curr) {
|
||||||
return typeof(prev) === 'string' ? prev + ' ' + curr : curr;
|
return typeof(prev) === 'string' ? prev + ' ' + curr : curr;
|
||||||
})
|
})
|
||||||
});
|
});
|
||||||
|
|
||||||
// close the dialog
|
|
||||||
$('#remote-port-configuration').modal('hide');
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -440,23 +418,8 @@
|
||||||
transmissionSwitch.replaceWith(newTransmissionSwitch);
|
transmissionSwitch.replaceWith(newTransmissionSwitch);
|
||||||
// update transmissionSwitch variable to reference the new switch
|
// update transmissionSwitch variable to reference the new switch
|
||||||
transmissionSwitch = newTransmissionSwitch;
|
transmissionSwitch = newTransmissionSwitch;
|
||||||
if (xhr.status === 400) {
|
|
||||||
var errors = xhr.responseText.split('\n');
|
|
||||||
|
|
||||||
var content;
|
nfErrorHandler.handleConfigurationUpdateAjaxError(xhr, status, error);
|
||||||
if (errors.length === 1) {
|
|
||||||
content = $('<span></span>').text(errors[0]);
|
|
||||||
} else {
|
|
||||||
content = nfCommon.formatUnorderedList(errors);
|
|
||||||
}
|
|
||||||
|
|
||||||
nfDialog.showOkDialog({
|
|
||||||
headerText: 'Remote Process Group Ports',
|
|
||||||
dialogContent: content
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
nfErrorHandler.handleAjaxError(xhr, status, error);
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -81,33 +81,6 @@
|
||||||
return $('#controller-services-table');
|
return $('#controller-services-table');
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
|
||||||
* Handle any expected reporting task configuration errors.
|
|
||||||
*
|
|
||||||
* @argument {object} xhr The XmlHttpRequest
|
|
||||||
* @argument {string} status The status of the request
|
|
||||||
* @argument {string} error The error
|
|
||||||
*/
|
|
||||||
var handleReportingTaskConfigurationError = function (xhr, status, error) {
|
|
||||||
if (xhr.status === 400) {
|
|
||||||
var errors = xhr.responseText.split('\n');
|
|
||||||
|
|
||||||
var content;
|
|
||||||
if (errors.length === 1) {
|
|
||||||
content = $('<span></span>').text(errors[0]);
|
|
||||||
} else {
|
|
||||||
content = nfCommon.formatUnorderedList(errors);
|
|
||||||
}
|
|
||||||
|
|
||||||
nfDialog.showOkDialog({
|
|
||||||
dialogContent: content,
|
|
||||||
headerText: 'Reporting Task'
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
nfErrorHandler.handleAjaxError(xhr, status, error);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Determines whether the user has made any changes to the reporting task configuration
|
* Determines whether the user has made any changes to the reporting task configuration
|
||||||
* that needs to be saved.
|
* that needs to be saved.
|
||||||
|
@ -322,7 +295,7 @@
|
||||||
}).done(function (response) {
|
}).done(function (response) {
|
||||||
// update the reporting task
|
// update the reporting task
|
||||||
renderReportingTask(response);
|
renderReportingTask(response);
|
||||||
}).fail(handleReportingTaskConfigurationError);
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
} else {
|
} else {
|
||||||
return $.Deferred(function (deferred) {
|
return $.Deferred(function (deferred) {
|
||||||
deferred.reject();
|
deferred.reject();
|
||||||
|
|
|
@ -108,6 +108,33 @@
|
||||||
return $('#controller-services-table');
|
return $('#controller-services-table');
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Validates the configured settings.
|
||||||
|
*
|
||||||
|
* @argument {object} configuration The settings to validate
|
||||||
|
*/
|
||||||
|
var validateSettings = function (configuration) {
|
||||||
|
var errors = [];
|
||||||
|
|
||||||
|
// ensure numeric fields are specified correctly
|
||||||
|
if (nfCommon.isDefinedAndNotNull(configuration['maxTimerDrivenThreadCount']) && !$.isNumeric(configuration['maxTimerDrivenThreadCount'])) {
|
||||||
|
errors.push('Maximum Timer Driven Thread Count must be an integer value');
|
||||||
|
}
|
||||||
|
if (nfCommon.isDefinedAndNotNull(configuration['maxEventDrivenThreadCount']) && !$.isNumeric(configuration['maxEventDrivenThreadCount'])) {
|
||||||
|
errors.push('Maximum Event Driven Thread Count must be an integer value');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (errors.length > 0) {
|
||||||
|
nfDialog.showOkDialog({
|
||||||
|
dialogContent: nfCommon.formatUnorderedList(errors),
|
||||||
|
headerText: 'Configuration Error'
|
||||||
|
});
|
||||||
|
return false;
|
||||||
|
} else {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Saves the settings for the controller.
|
* Saves the settings for the controller.
|
||||||
*
|
*
|
||||||
|
@ -116,35 +143,38 @@
|
||||||
var saveSettings = function (version) {
|
var saveSettings = function (version) {
|
||||||
// marshal the configuration details
|
// marshal the configuration details
|
||||||
var configuration = marshalConfiguration();
|
var configuration = marshalConfiguration();
|
||||||
var entity = {
|
// ensure settings are valid as far as we can tell
|
||||||
'revision': nfClient.getRevision({
|
if (validateSettings(configuration)) {
|
||||||
'revision': {
|
var entity = {
|
||||||
'version': version
|
'revision': nfClient.getRevision({
|
||||||
}
|
'revision': {
|
||||||
}),
|
'version': version
|
||||||
'disconnectedNodeAcknowledged': nfStorage.isDisconnectionAcknowledged(),
|
}
|
||||||
'component': configuration
|
}),
|
||||||
};
|
'disconnectedNodeAcknowledged': nfStorage.isDisconnectionAcknowledged(),
|
||||||
|
'component': configuration
|
||||||
|
};
|
||||||
|
|
||||||
// save the new configuration details
|
// save the new configuration details
|
||||||
$.ajax({
|
$.ajax({
|
||||||
type: 'PUT',
|
type: 'PUT',
|
||||||
url: config.urls.controllerConfig,
|
url: config.urls.controllerConfig,
|
||||||
data: JSON.stringify(entity),
|
data: JSON.stringify(entity),
|
||||||
dataType: 'json',
|
dataType: 'json',
|
||||||
contentType: 'application/json'
|
contentType: 'application/json'
|
||||||
}).done(function (response) {
|
}).done(function (response) {
|
||||||
// close the settings dialog
|
// close the settings dialog
|
||||||
nfDialog.showOkDialog({
|
nfDialog.showOkDialog({
|
||||||
headerText: 'Settings',
|
headerText: 'Settings',
|
||||||
dialogContent: 'Settings successfully applied.'
|
dialogContent: 'Settings successfully applied.'
|
||||||
});
|
});
|
||||||
|
|
||||||
// register the click listener for the save button
|
// register the click listener for the save button
|
||||||
$('#settings-save').off('click').on('click', function () {
|
$('#settings-save').off('click').on('click', function () {
|
||||||
saveSettings(response.revision.version);
|
saveSettings(response.revision.version);
|
||||||
});
|
});
|
||||||
}).fail(nfErrorHandler.handleAjaxError);
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -519,10 +549,11 @@
|
||||||
var row = registriesData.getRowById(registryEntity.id);
|
var row = registriesData.getRowById(registryEntity.id);
|
||||||
nfFilteredDialogCommon.choseRow(registriesGrid, row);
|
nfFilteredDialogCommon.choseRow(registriesGrid, row);
|
||||||
registriesGrid.scrollRowIntoView(row);
|
registriesGrid.scrollRowIntoView(row);
|
||||||
}).fail(nfErrorHandler.handleAjaxError);
|
|
||||||
|
|
||||||
// hide the dialog
|
// hide the dialog
|
||||||
$('#registry-configuration-dialog').modal('hide');
|
$('#registry-configuration-dialog').modal('hide');
|
||||||
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
|
|
||||||
|
|
||||||
return addRegistry;
|
return addRegistry;
|
||||||
};
|
};
|
||||||
|
@ -560,10 +591,10 @@
|
||||||
registriesData.updateItem(registryId, $.extend({
|
registriesData.updateItem(registryId, $.extend({
|
||||||
type: 'Registry'
|
type: 'Registry'
|
||||||
}, registryEntity));
|
}, registryEntity));
|
||||||
}).fail(nfErrorHandler.handleAjaxError);
|
|
||||||
|
|
||||||
// hide the dialog
|
// hide the dialog
|
||||||
$('#registry-configuration-dialog').modal('hide');
|
$('#registry-configuration-dialog').modal('hide');
|
||||||
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
|
|
||||||
return updateRegistry;
|
return updateRegistry;
|
||||||
};
|
};
|
||||||
|
|
|
@ -1503,15 +1503,17 @@
|
||||||
variableGrid.scrollRowIntoView(matchingRow);
|
variableGrid.scrollRowIntoView(matchingRow);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// close the new variable dialog
|
||||||
|
$('#new-variable-dialog').modal('hide');
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
nfDialog.showOkDialog({
|
nfDialog.showOkDialog({
|
||||||
headerText: 'Variable Name',
|
headerText: 'Configuration Error',
|
||||||
dialogContent: 'Variable name must be specified.'
|
dialogContent: 'The name of the variable must be specified.'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// close the new variable dialog
|
|
||||||
$('#new-variable-dialog').modal('hide');
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -37,7 +37,7 @@
|
||||||
}(this, function ($, nfDialog, nfCommon) {
|
}(this, function ($, nfDialog, nfCommon) {
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
return {
|
var self = {
|
||||||
/**
|
/**
|
||||||
* Method for handling ajax errors.
|
* Method for handling ajax errors.
|
||||||
*
|
*
|
||||||
|
@ -142,6 +142,36 @@
|
||||||
// show the error pane
|
// show the error pane
|
||||||
$('#message-pane').show();
|
$('#message-pane').show();
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Method for handling ajax errors when submitting configuration update (PUT/POST) requests.
|
||||||
|
* In addition to what handleAjaxError does, this function splits
|
||||||
|
* the error message text to display them as an unordered list.
|
||||||
|
*
|
||||||
|
* @argument {object} xhr The XmlHttpRequest
|
||||||
|
* @argument {string} status The status of the request
|
||||||
|
* @argument {string} error The error
|
||||||
|
*/
|
||||||
|
handleConfigurationUpdateAjaxError: function (xhr, status, error) {
|
||||||
|
if (xhr.status === 400) {
|
||||||
|
var errors = xhr.responseText.split('\n');
|
||||||
|
|
||||||
|
var content;
|
||||||
|
if (errors.length === 1) {
|
||||||
|
content = $('<span></span>').text(errors[0]);
|
||||||
|
} else {
|
||||||
|
content = nfCommon.formatUnorderedList(errors);
|
||||||
|
}
|
||||||
|
|
||||||
|
nfDialog.showOkDialog({
|
||||||
|
dialogContent: content,
|
||||||
|
headerText: 'Configuration Error'
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
self.handleAjaxError(xhr, status, error);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
return self;
|
||||||
}));
|
}));
|
|
@ -307,16 +307,7 @@
|
||||||
if (processorRelationships.is(':visible') && processorRelationships.get(0).scrollHeight > Math.round(processorRelationships.innerHeight())) {
|
if (processorRelationships.is(':visible') && processorRelationships.get(0).scrollHeight > Math.round(processorRelationships.innerHeight())) {
|
||||||
processorRelationships.css('border-width', '1px');
|
processorRelationships.css('border-width', '1px');
|
||||||
}
|
}
|
||||||
}).fail(function (xhr, status, error) {
|
}).fail(nfErrorHandler.handleAjaxError);
|
||||||
if (xhr.status === 400 || xhr.status === 404 || xhr.status === 409) {
|
|
||||||
nfDialog.showOkDialog({
|
|
||||||
headerText: 'Error',
|
|
||||||
dialogContent: nfCommon.escapeHtml(xhr.responseText)
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
nfErrorHandler.handleAjaxError(xhr, status, error);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
}));
|
}));
|
||||||
|
|
|
@ -252,6 +252,8 @@
|
||||||
|
|
||||||
// if the user was successfully created
|
// if the user was successfully created
|
||||||
userXhr.done(function (userEntity) {
|
userXhr.done(function (userEntity) {
|
||||||
|
$('#user-dialog').modal('hide');
|
||||||
|
|
||||||
var xhrs = [];
|
var xhrs = [];
|
||||||
$.each(selectedGroups, function (_, selectedGroup) {
|
$.each(selectedGroups, function (_, selectedGroup) {
|
||||||
var groupEntity = usersData.getItemById(selectedGroup.id)
|
var groupEntity = usersData.getItemById(selectedGroup.id)
|
||||||
|
@ -266,7 +268,7 @@
|
||||||
usersGrid.scrollRowIntoView(row);
|
usersGrid.scrollRowIntoView(row);
|
||||||
});
|
});
|
||||||
}).fail(nfErrorHandler.handleAjaxError);
|
}).fail(nfErrorHandler.handleAjaxError);
|
||||||
}).fail(nfErrorHandler.handleAjaxError);
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -302,6 +304,8 @@
|
||||||
|
|
||||||
userXhr.done(function (updatedUserEntity) {
|
userXhr.done(function (updatedUserEntity) {
|
||||||
|
|
||||||
|
$('#user-dialog').modal('hide');
|
||||||
|
|
||||||
// determine what to add/remove
|
// determine what to add/remove
|
||||||
var groupsAdded = [];
|
var groupsAdded = [];
|
||||||
var groupsRemoved = [];
|
var groupsRemoved = [];
|
||||||
|
@ -340,7 +344,7 @@
|
||||||
$.when.apply(window, xhrs).always(function () {
|
$.when.apply(window, xhrs).always(function () {
|
||||||
nfUsersTable.loadUsersTable();
|
nfUsersTable.loadUsersTable();
|
||||||
}).fail(nfErrorHandler.handleAjaxError);
|
}).fail(nfErrorHandler.handleAjaxError);
|
||||||
}).fail(nfErrorHandler.handleAjaxError);
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -357,6 +361,7 @@
|
||||||
dataType: 'json',
|
dataType: 'json',
|
||||||
contentType: 'application/json'
|
contentType: 'application/json'
|
||||||
}).done(function (groupEntity) {
|
}).done(function (groupEntity) {
|
||||||
|
$('#user-dialog').modal('hide');
|
||||||
nfUsersTable.loadUsersTable().done(function () {
|
nfUsersTable.loadUsersTable().done(function () {
|
||||||
// add the user
|
// add the user
|
||||||
var usersGrid = $('#users-table').data('gridInstance');
|
var usersGrid = $('#users-table').data('gridInstance');
|
||||||
|
@ -367,7 +372,7 @@
|
||||||
usersGrid.setSelectedRows([row]);
|
usersGrid.setSelectedRows([row]);
|
||||||
usersGrid.scrollRowIntoView(row);
|
usersGrid.scrollRowIntoView(row);
|
||||||
});
|
});
|
||||||
}).fail(nfErrorHandler.handleAjaxError);
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
};
|
};
|
||||||
|
|
||||||
var updateGroup = function (groupId, groupIdentity, selectedUsers) {
|
var updateGroup = function (groupId, groupIdentity, selectedUsers) {
|
||||||
|
@ -394,8 +399,9 @@
|
||||||
dataType: 'json',
|
dataType: 'json',
|
||||||
contentType: 'application/json'
|
contentType: 'application/json'
|
||||||
}).done(function (groupEntity) {
|
}).done(function (groupEntity) {
|
||||||
|
$('#user-dialog').modal('hide');
|
||||||
nfUsersTable.loadUsersTable();
|
nfUsersTable.loadUsersTable();
|
||||||
}).fail(nfErrorHandler.handleAjaxError);
|
}).fail(nfErrorHandler.handleConfigurationUpdateAjaxError);
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -459,7 +465,6 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$('#user-dialog').modal('hide');
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
|
|
Loading…
Reference in New Issue