summaryrefslogtreecommitdiffstats
path: root/apps/workflowengine
diff options
context:
space:
mode:
Diffstat (limited to 'apps/workflowengine')
-rw-r--r--apps/workflowengine/js/admin.js7
-rw-r--r--apps/workflowengine/js/usergroupmembershipplugin.js2
2 files changed, 5 insertions, 4 deletions
diff --git a/apps/workflowengine/js/admin.js b/apps/workflowengine/js/admin.js
index d31add77ef4..891e50c4189 100644
--- a/apps/workflowengine/js/admin.js
+++ b/apps/workflowengine/js/admin.js
@@ -167,7 +167,7 @@
url: OC.generateUrl('settings/users/groups'),
dataType: 'json',
quietMillis: 100,
- }).done(function(response) {
+ }).success(function(response) {
// add admin groups
$.each(response.data.adminGroups, function(id, group) {
self.groups.push({ id: group.id, displayname: group.name });
@@ -177,8 +177,9 @@
self.groups.push({ id: group.id, displayname: group.name });
});
self.render();
- }).fail(function(response) {
- console.error('Failure happened', response);
+ }).error(function(data) {
+ OC.Notification.error(t('workflowengine', 'Unable to retrieve the group list'), {type: 'error'});
+ console.log(data);
});
},
delete: function() {
diff --git a/apps/workflowengine/js/usergroupmembershipplugin.js b/apps/workflowengine/js/usergroupmembershipplugin.js
index c664481562b..b89087bea06 100644
--- a/apps/workflowengine/js/usergroupmembershipplugin.js
+++ b/apps/workflowengine/js/usergroupmembershipplugin.js
@@ -42,7 +42,7 @@
$(element).css('width', '400px');
$(element).select2({
- data: groups,
+ data: { results: groups, text: 'displayname' },
initSelection: function (element, callback) {
var groupId = element.val();
if (groupId && groups.length > 0) {