Update: User.ad console.log of match and pick
This commit is contained in:
parent
fc4abb2546
commit
bec2c5848b
1 changed files with 5 additions and 2 deletions
|
|
@ -418,8 +418,11 @@ exports.ad = (req, res) => {
|
||||||
match = {$match: {isVisible: true, isActive: true}};
|
match = {$match: {isVisible: true, isActive: true}};
|
||||||
pick = {$sample: {size: parseInt(quantity, 10)}};
|
pick = {$sample: {size: parseInt(quantity, 10)}};
|
||||||
}
|
}
|
||||||
|
console.log(match, pick);
|
||||||
Ad.aggregate([match, pick])
|
Ad.aggregate([
|
||||||
|
match,
|
||||||
|
pick
|
||||||
|
])
|
||||||
.then(data => {
|
.then(data => {
|
||||||
return sendMessage(res, 11, data, token);
|
return sendMessage(res, 11, data, token);
|
||||||
})
|
})
|
||||||
|
|
|
||||||
Reference in a new issue