Fixeda bug where the group description was not sent to the server side, which caused an exception while creating a group.

This commit is contained in:
Marc Hannappel committed 2017-10-23 11:11:06 +02:00
1 parent e5f6824304
commit eb2ed341a2
3 files changed
+4 -1

No files matched your search

+2
View File
@@ -50,6 +50,8 @@ def add_group():
if not "name" in data:
return make_response("Missing mandatory name field", 400)
if not "description" in data:
return make_response("Missing mandatory description field", 400)
if not "permissions" in data:
return make_response("Missing mandatory permission field", 400)
@@ -54,6 +54,7 @@
var data = {
name: group.name,
description: group.hasOwnProperty("description") ? group.description : "",
permissions: group.hasOwnProperty("permissions") ? group.permissions : [],
defaultOn: group.defaultOn
};
@@ -284,7 +284,7 @@ $(function() {
newValue.forEach(function(g) {
var needs = [];
g.permissions.forEach(function(p) {
for (key in p.needs) {
for (var key in p.needs) {
p.needs[key].forEach(function(value) {
needs.push(access.permissions.need(key, value));
});