From: Laurence Maultsby Date: Wed, 3 May 2017 18:14:32 +0000 (-0400) Subject: Allow for project description change X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=288cfb7d047b5beb2a6f05e58834b4d39c8d6e46;p=osm%2FUI.git Allow for project description change Signed-off-by: Laurence Maultsby --- diff --git a/skyquake/framework/core/modules/api/projectManagementAPI.js b/skyquake/framework/core/modules/api/projectManagementAPI.js index 25fcebe5c..195f45700 100644 --- a/skyquake/framework/core/modules/api/projectManagementAPI.js +++ b/skyquake/framework/core/modules/api/projectManagementAPI.js @@ -104,14 +104,21 @@ ProjectManagement.create = function(req) { }); }; ProjectManagement.update = function(req) { + //"rw-project:project" var self = this; var api_server = req.query['api_server']; var bodyData = req.body; - data = bodyData['project-config'] + var data = { + "rw-project:project" : { + "name": bodyData.name, + "description": bodyData.description, + "project-config": bodyData['project-config'] + } + } var updateTasks = []; var updateProject= rp({ - uri: utils.confdPort(api_server) + '/api/config/project/' + bodyData.name + '/project-config', + uri: utils.confdPort(api_server) + '/api/config/project/', method: 'PUT', headers: _.extend({}, constants.HTTP_HEADERS.accept.data, { 'Authorization': req.session && req.session.authorization