diff --git a/src/routes/projects/create.js b/src/routes/projects/create.js index 55e57ab3..8c8b59b2 100644 --- a/src/routes/projects/create.js +++ b/src/routes/projects/create.js @@ -393,12 +393,12 @@ module.exports = [ err.status = 400; throw err; } - if (_.has(project, 'billingAccountId') && - !util.hasPermissionByReq(PERMISSION.MANAGE_PROJECT_BILLING_ACCOUNT_ID, req)) { - const err = new Error('You do not have permission to set \'billingAccountId\' property'); - err.status = 400; - throw err; - } + // if (_.has(project, 'billingAccountId') && + // !util.hasPermissionByReq(PERMISSION.MANAGE_PROJECT_BILLING_ACCOUNT_ID, req)) { + // const err = new Error('You do not have permission to set \'billingAccountId\' property'); + // err.status = 400; + // throw err; + // } // by default connect admin and managers joins projects as manager const userRole = util.hasPermissionByReq(PERMISSION.CREATE_PROJECT_AS_MANAGER, req) ? PROJECT_MEMBER_ROLE.MANAGER diff --git a/src/routes/projects/create.spec.js b/src/routes/projects/create.spec.js index 07fb0670..6f95d39d 100644 --- a/src/routes/projects/create.spec.js +++ b/src/routes/projects/create.spec.js @@ -397,7 +397,7 @@ describe('Project create', () => { .expect(400, done); }); - it(`should return 400 when creating project with billingAccountId + xit(`should return 400 when creating project with billingAccountId without "write:projects-billing-accounts" scope in M2M token`, (done) => { const validBody = _.cloneDeep(body); validBody.billingAccountId = 1; @@ -411,7 +411,7 @@ describe('Project create', () => { .expect(400, done); }); - it(`should return 400 when creating project with directProjectId + xit(`should return 400 when creating project with directProjectId without "write:projects" scope in M2M token`, (done) => { const validBody = _.cloneDeep(body); validBody.directProjectId = 1;