如何使用value user == to?
的条件在mongoose中查找查询这是json数据:
{
"_id": {
"$oid": "5ad8096151fe2d391cae9110"
},
"user": {
"$oid": "5acc15622ec84a0bb4200fdb"
},
"to": {
"$oid": "5acc16e92ec84a0bb4200fdc"
},
"message": "hello",
"status": "pending",
"created": {
"$date": "2018-04-19T03:13:37.257Z"
},
"__v": 0
}