this.afs
.collection('userroutes' + cityid, ref =>
ref.where(
'requestList',
'array-contains',
'str'
)
)
.valueChanges()
.subscribe(data => {
//I get the data
//this works
});`
不起作用
this.afs
.collection('userroutes' + cityid, ref =>
ref.where(
'requestList.id', <-- in case of object search what it will
'array-contains',
'ED8r2DWAcyM0sKJiAJxwwAVDm2q2'
)
)
.valueChanges()
.subscribe(data => {
//this do not give any data....
//though this id is present id firebase db
});
不起作用
this.afs
.collection('userroutes' + cityid, ref =>
ref.where(
'requestList', <-- in case of object search what it will
'array-contains',
'ED8r2DWAcyM0sKJiAJxwwAVDm2q2'
)
)
.valueChanges()
.subscribe(data => {
//this do not give any data....
//though this id is present id firebase db
});
我正在尝试使用Firebase 5.3.0中包含数组的新功能;我看到它仅适用于字符串,不适用于对象;
这在使用字符串的情况下可以正常工作。