Send request to update group settings.

This commit is contained in:
Pierre HUBERT
2018-07-04 11:26:18 +02:00
parent 218e9b6fbe
commit 4c3985fc24
3 changed files with 94 additions and 3 deletions

View File

@ -65,6 +65,21 @@ ComunicWeb.components.groups.interface = {
id: id
};
ComunicWeb.common.api.makeAPIrequest(apiURI, params, true, callback);
}
},
/**
* Set (update) the settings of a group
*
* @param {Number} id The ID of the target group
* @param {Object} settings The new settings to apply to
* the group
* @param {Function} callback
*/
setSettings: function(id, settings, callback){
//Perform the request over the API
var apiURI = "groups/set_settings";
settings.id = id;
ComunicWeb.common.api.makeAPIrequest(apiURI, settings, true, callback);
},
};