i have a collection "Orders", having a srtucture like this
dishname :
"Biryani"
dishprice:
"350"
dishquantity:
"1"
hotelemail:
"apk@gmail.com"
hotelname :
"Apk"
time
April 13, 2020 at 2:51:11 PM UTC+5
useremail
"checking@gmail.com"
username
"pasha"
usernum
"03416889912"
orderstatus
"Pending"
now i want's to perform a query on this collection which resembles like this get ALL the orders where (orderstatus == "Pending" OR (orderstatus == "collected" AND useremail = "someemail") OR (orderstatus == "distapched" AND useremail = "someemail")