Skip to content
Snippets Groups Projects
Commit 2ca4a1ce authored by moon's avatar moon
Browse files

Removed log() calls

parent f49b0ed5
No related branches found
No related tags found
No related merge requests found
......@@ -104,11 +104,6 @@ module.exports = createCoreController('api::update-item.update-item', ({ strapi
return super.find(ctx)
},
async filterProteinRequest(ctx) {
// return ctx.send('Hello World!');
console.log();
let res;
switch (ctx.state.user.role.name) {
case 'Public':
......@@ -123,14 +118,14 @@ module.exports = createCoreController('api::update-item.update-item', ({ strapi
ctx.query["filters"] = {
...ctx.query["filters"],
EntityId: ctx.params.id,
};
res = super.find(ctx)
break
case 'Contributor':
// Remove operation should be intact
ctx.query["filters"] = {
...ctx.query["filters"], submittedBy: ctx.state.user.id, EntityId: ctx.params.id
}
......@@ -152,7 +147,7 @@ module.exports = createCoreController('api::update-item.update-item', ({ strapi
ctx.query["filters"] = {
...ctx.query["filters"],
EntityId: ctx.params.id,
};
// res= await strapi.entityService.findMany('api::update-item.update-item', {
......@@ -175,21 +170,15 @@ module.exports = createCoreController('api::update-item.update-item', ({ strapi
ctx.query["filters"] = {
...ctx.query["filters"],
EntityId: ctx.params.id,
};
res = super.find(ctx)
break;
}
console.log(res);
return res
},
async filterCondensateRequest(ctx) {
// return ctx.send('Hello World!');
console.log();
let res;
switch (ctx.state.user.role.name) {
case 'Public':
......@@ -212,7 +201,7 @@ module.exports = createCoreController('api::update-item.update-item', ({ strapi
break
case 'Contributor':
// Remove operation should be intact
ctx.query["filters"] = {
...ctx.query["filters"], submittedBy: ctx.state.user.id, EntityId: {
$contains: ctx.params.id,
......@@ -267,7 +256,6 @@ module.exports = createCoreController('api::update-item.update-item', ({ strapi
res = super.find(ctx)
break;
}
console.log(res);
return res
},
async findOne(ctx) {
......@@ -297,5 +285,4 @@ module.exports = createCoreController('api::update-item.update-item', ({ strapi
return this.transformResponse(sanitizedEntity);
}
}));
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment