mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
webui: better error reporting
- ActionDropdownWidget - report error if required action is missing - report build errors to console Reviewed-By: Martin Basti <mbasti@redhat.com>
This commit is contained in:
parent
cd5fe9b407
commit
847b5fd8d2
@ -262,7 +262,6 @@ define([
|
||||
if (error.results) {
|
||||
var msg = error.results.message;
|
||||
var stack = error.results.stack.toString();
|
||||
window.console.error(msg);
|
||||
window.console.error(stack);
|
||||
details.append('<h3>Technical details:</h3>');
|
||||
details.append($('<div/>', { text: error.results.message }));
|
||||
|
@ -356,6 +356,7 @@ define(['dojo/_base/declare',
|
||||
// object is not to be built
|
||||
obj = null;
|
||||
} else {
|
||||
window.console.error(e.stack);
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
@ -69,6 +69,10 @@ define(['dojo/_base/declare',
|
||||
obj = this._map[type] = this.builder.build(type);
|
||||
} catch (e) {
|
||||
if (e.code === 'no-ctor-fac') obj = null;
|
||||
else {
|
||||
window.console.error('Error while building: ' + type);
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -74,6 +74,12 @@ define(['dojo/_base/declare',
|
||||
for (i=0; i<this.action_names.length; i++) {
|
||||
name = this.action_names[i];
|
||||
action = this.facet.actions.get(name);
|
||||
if (!action) {
|
||||
window.console.error(
|
||||
"ActionDropDown: cannot find action: " + name +
|
||||
"\nFacet: "+facet.name);
|
||||
continue;
|
||||
}
|
||||
this.add_action(action, true);
|
||||
}
|
||||
this.recreate_options();
|
||||
|
Loading…
Reference in New Issue
Block a user