【发布时间】:2021-12-10 07:47:54
【问题描述】:
实在找不到怎么办,怎么在我的RecyclerView中获取某个部门的所有值。 首先,这有可能吗? 这就是我的 Firestore 数据库的松散方式,“blue_bottle”和“tops_national”是文档的一部分:
我想用同一部门的“blue_bottle”和“tops_national”中的所有产品填充我的 RecyclerView。 所以我需要一个我认为正确的 DocumentReference:
private val promoOnedb = FirebaseFirestore.getInstance()
private val promoOneRef: DocumentReference = promoOnedb.collection("tops")
.document("promotions")
但是我现在如何查询 DocumentReference 以显示所有产品,在两个集合中显示同一部门的所有产品?请。
【问题讨论】:
标签: android firebase kotlin google-cloud-firestore android-recyclerview