0
I have two types of users: Vendedores
and Usuarios
. Applicants can display their data if the Ids are the same (already functional). Users should see Sellers' values if their child ("City") has the same value.
I tried to:
//Vendedores
"Vendedores": {
"$uid": {
".read": "auth.uid == $uid || (data.child(auth.uid).child('Cidade').val() === data.child($uid).child('Cidade').val())",
".write": "auth.uid == $uid"
}
But it’s always true
.
Could you translate your question ?
– RXSD
To have access to the Seller, the user needs to have in the key City, the same "City" / Variable, that the Seller has.
– Wiharlley Yitzhak
I would like to know how to do this. Since the rule I wrote is always true.
– Wiharlley Yitzhak
Your question is in English, you could translate it to improve the experience with other users.
– RXSD
I’m new, I didn’t know I would fall in the Brazilian forum.
– Wiharlley Yitzhak
I made some adjustments to your question!
– RXSD