File tree Expand file tree Collapse file tree 1 file changed +0
-19
lines changed Expand file tree Collapse file tree 1 file changed +0
-19
lines changed Original file line number Diff line number Diff line change @@ -61,25 +61,6 @@ module.exports = function defineProject(sequelize, DataTypes) {
6161 { fields : [ 'directProjectId' ] } ,
6262 ] ,
6363 classMethods : {
64- /*
65- * @Co -pilots should be able to view projects any of the following conditions are met:
66- * a. they are registered active project members on the project
67- * b. any project that is in 'reviewed' state AND copilot is invited
68- * @param userId the id of user
69- */
70- getProjectIdsForCopilot ( userId ) {
71- return this . findAll ( {
72- where : {
73- $or : [
74- [ 'EXISTS(SELECT * FROM "project_members" WHERE "deletedAt" ' +
75- 'IS NULL AND "projectId" = "Project".id AND "userId" = ? )' , userId ] ,
76- ] ,
77- } ,
78- attributes : [ 'id' ] ,
79- raw : true ,
80- } )
81- . then ( res => _ . map ( res , 'id' ) ) ;
82- } ,
8364 /**
8465 * Get direct project id
8566 * @param id the id of project
You can’t perform that action at this time.
0 commit comments