view = view.substring(0, questionMark);
}
}
context.setRequestPath(view);
if (message != null) {
final MessageBroker messageBroker = getMessageBroker();
messageBroker.addMessage(message);
}
if (override != null) {
context.addVariable(resultName, override, Scope.REQUEST);
}
if (!action.hasReturn() && context.getVariable(resultName) == null) {
context.addVariable(resultName, objectId, Scope.REQUEST);
}
} else {
entryState.setForm(formId);
context.addVariable(ENTRY_FIELDS, entryState, Scope.REQUEST);
context.addVariable(resultName, objectId, Scope.REQUEST);
if (override != null) {
context.addVariable(resultName, override, Scope.REQUEST);
}
final String error = entryState.getError();
final String view = context.getParameter("_" + ERROR);
context.setRequestPath(view, Dispatcher.ACTION);
final MessageBroker messageBroker = getMessageBroker();
messageBroker.addWarning(error);
}
} catch (final ConcurrencyException e) {
final ObjectAdapter adapter = getAdapterManager().getAdapterFor(e.getOid());
String user = adapter.getOid().getVersion().getUser();
String errorMessage = "The data for '" + adapter.titleString() + "' was changed by " + user