Created
July 17, 2020 11:01
-
-
Save hrishi7/89f322d9fef19181ffb8e4c925a52eb3 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// let timeline = await Timeline.aggregate([ | |
// { $match: { timelineTopic: timelineTopic } }, | |
// { | |
// $group: { | |
// _id: "$date", | |
// shortDescription: { $addToSet: "$shortDescription" }, | |
// longDescription: { $addToSet: "$longDescription" }, | |
// articles: { | |
// $push: "$article", | |
// }, | |
// }, | |
// }, | |
// { $unwind: "$shortDescription" }, | |
// { $unwind: "$longDescription" }, | |
// { | |
// $project: { | |
// _id: 1, | |
// date: "$_id", | |
// shortDescription: 1, | |
// longDescription: 1, | |
// timelineTopic: 1, | |
// articles: 1, | |
// }, | |
// }, | |
// ]); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment