Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛 Bug Report: Subscribing in collection with relationship in another collection #5372

Open
2 tasks done
moshOntong-IT opened this issue Apr 14, 2023 · 2 comments
Open
2 tasks done
Labels
api / realtime Fixes and upgrades for the Appwrite Realtime API. bug Something isn't working product / databases Fixes and upgrades for the Appwrite Database.

Comments

@moshOntong-IT
Copy link

moshOntong-IT commented Apr 14, 2023

👟 Reproduction steps

I have these two collections in my appwrite database which are:

  1. vocabulary
  2. language

I set relationship between them

Vocabulary -> language
vocabulary can contain one language
language can belong to many vocabulary.

Now in my flutter code, I subscribe/listen to the changes of my vocabulary, whenever I create new vocabulary.
Therefore, If I trigger to create new vocabulary, the subscription will be trigger. What is the bugs here? It is the payload response of the subscription.

👍 Expected behavior

The expected payload should be like this:

{
 word: "lorem",
english: "lorem",
$id: "secret",
permissions:"...",
$createdAt: "...",
$updatedAt: "..",
language: {
    $databaseId: "...",
    $collectionId: "...",
    $id: "....",
    name: "mabobo",
},
$databaseId: "...",
$id: "....",
}

👎 Actual Behavior

image
As you can see in the picture I attached, it gives me only 2 attributes of my language collection. It does not provide me the id and name of language attribute's value

🎲 Appwrite version

Version 1.3.x

💻 Operating system

Windows

🧱 Your Environment

No response

👀 Have you spent some time to check if this issue has been raised before?

  • I checked and didn't find similar issue

🏢 Have you read the Code of Conduct?

@moshOntong-IT moshOntong-IT added the bug Something isn't working label Apr 14, 2023
@joeyouss joeyouss self-assigned this Apr 14, 2023
@stnguyen90 stnguyen90 added the api / realtime Fixes and upgrades for the Appwrite Realtime API. label Apr 21, 2023
@Haimantika
Copy link
Contributor

Thanks @moshOntong-IT for opening this issue. Our team is looking into this currently. Thanks for your patience

@joeyouss
Copy link

joeyouss commented Aug 7, 2023

Hi @moshOntong-IT what are your permissions set at? can you try once setting the permissions so that the user can read the language document?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api / realtime Fixes and upgrades for the Appwrite Realtime API. bug Something isn't working product / databases Fixes and upgrades for the Appwrite Database.
Projects
None yet
Development

No branches or pull requests

5 participants
@stnguyen90 @Haimantika @moshOntong-IT @joeyouss and others