英文:
Firestore Query over Map keys Android
问题
所以我有一些产品存储在不同的仓库中。类似这样:所以在仓库"A25"中我将有4个产品,在仓库"A40"中有3个产品。
Product{
placesDeposited:{
A25:4,
A40:3
}
}
我尝试了这个:
Query query = db.collection("products").whereArrayContains("placesDeposited",storageID)
我想将这个查询放在一个RecyclerView中。
我想要一个查询,返回所有存储在Firestore中仓库"A25"中的产品。
英文:
So I have some products stored in different storages. Something like this: So I would have 4 products in storage "A25" and 3 products in storage "A40".
Product{
placesDeposited:{
A25:4,
A40:3
}
}
I tried this:
Query query = db.collection("products").whereArrayContains("placesDeposited",storageID)
I want to put this Query in a recyclerView
I want to have a query that return all products that are stored in storage "A25" in firestore.
专注分享java语言的经验与见解,让所有开发者获益!
评论