fixed full deals
This commit is contained in:
12
app/mongo.py
12
app/mongo.py
@ -334,6 +334,7 @@ async def additional_deals_data(*deals: dict, full: bool):
|
||||
|
||||
|
||||
async def get_all_summaries(full: bool):
|
||||
if not full:
|
||||
deals = await deals_collection.find({
|
||||
"$and": [
|
||||
{
|
||||
@ -350,4 +351,15 @@ async def get_all_summaries(full: bool):
|
||||
}
|
||||
]
|
||||
}, {"_id": False}).sort("id", asc).to_list()
|
||||
else:
|
||||
deals = await deals_collection.find({
|
||||
"$and": [
|
||||
{
|
||||
"$or": [
|
||||
{"isDeleted": False},
|
||||
{"isDeleted": {"$exists": False}}
|
||||
]
|
||||
}
|
||||
]
|
||||
}, {"_id": False}).sort("id", asc).to_list()
|
||||
return await additional_deals_data(*deals, full=full)
|
||||
|
||||
Reference in New Issue
Block a user