NOTICKET: Need to pass in project name-ref in project-config
authorKIRAN KASHALKAR <kiran.kashalkar@riftio.com>
Fri, 24 Mar 2017 20:57:34 +0000 (16:57 -0400)
committerKIRAN KASHALKAR <kiran.kashalkar@riftio.com>
Fri, 24 Mar 2017 20:57:34 +0000 (16:57 -0400)
Signed-off-by: KIRAN KASHALKAR <kiran.kashalkar@riftio.com>
skyquake/plugins/project_management/src/dashboard/dashboard.jsx

index 6b613cc..71921a7 100644 (file)
@@ -96,11 +96,13 @@ class ProjectManagementDashboard extends React.Component {
         e.stopPropagation();
         let projectUsers = self.state.projectUsers;
         let cleanUsers = this.cleanUsers(projectUsers);
+        let projectName = self.state['name'];
 
         this.Store.createProject({
-            'name': self.state['name'],
+            'name': projectName,
             'description': self.state.description,
             'project-config' : {
+                'name-ref': projectName,
                 'user': cleanUsers
             }
         });
@@ -111,11 +113,13 @@ class ProjectManagementDashboard extends React.Component {
         e.stopPropagation();
         let projectUsers = self.state.projectUsers;
         let cleanUsers = this.cleanUsers(projectUsers);
+        let projectName = self.state['name'];
 
         this.Store.updateProject(_.merge({
-            'name': self.state['name'],
+            'name': projectName,
             'description': self.state.description,
             'project-config' : {
+                'name-ref': projectName,
                 'user': cleanUsers
             }
         }));