Progetti
This commit is contained in:
@@ -188,7 +188,7 @@ ProjectSchema.statics.findAllProjByUserId = async function (userId, idapp) {
|
||||
{
|
||||
$and: [
|
||||
{ idapp }, {
|
||||
$or: [{ privacyread: server_constants.Privacy.all }, { userId: userId }],
|
||||
$or: [{ privacyread: { $ne: server_constants.Privacy.onlyme } }, { userId: userId }],
|
||||
}],
|
||||
$or: [{ deleted: { $exists: false } }, { deleted: { $exists: true, $eq: false } }],
|
||||
}
|
||||
@@ -336,7 +336,7 @@ ProjectSchema.statics.enabletoModify = async function (userId, idProj) {
|
||||
return Project.findOne({
|
||||
'_id': idProj,
|
||||
$or: [{
|
||||
privacywrite: server_constants.Privacy.all,
|
||||
privacywrite: { $ne: server_constants.Privacy.onlyme },
|
||||
userId: userId
|
||||
}]
|
||||
}).then(ris => {
|
||||
|
||||
Reference in New Issue
Block a user