Hi all. I hope everyones well, and sorry for the long post, i'm just trying to make the problem clear as possible. I've attached a couple of diagrams below.
I'm still learning flutterflow although I have now built the UI as well as the db in Supabase. I've linked up the basic parts such as backend queries to retrieve rows from tables and display them in components using their parameters etc. but now I'm trying to hook up the main sections that will only show Posts that adhere to certain filters that the user selects.
I'm new to app building having spent a few decades as a UI/UX designer. OMG flutterflow and supabase changes the whole game, i'm no longer designing in Figma and waiting for developers so that i can see something, I'm building the app and making changes as i go along. This is without a doubt the future (btw, i tried 'all' the other platforms like outsystems, mendix, etc., ver the years, and nothing compare to flutterflow).
With that in mind, sorry if i get some of the terminology wrong. I've attached 2 diagrams that I hope will help explain my problem. Thank you for any help in advance. Now, enough rambling from me, on with the problem...
Database (Supabase)
I learned a lot recently about relational database design and I believe the db i designed is in the Fifth Normal Form. I'm mentioninig that to help you visualise how it's setup.
I've already created it in Supabase.
Background
Organisations can join/create a Project
Projects have 1+ Units (like departments)
Projects have 1+ Goals
Orgs can make 0+ Posts
Posts
A user can create a Post that, as well as a title etc., can include 0 or 1 of the following:
project_id
unit_id
goal_id
Main View
A user selects a project on a previous page and the project_id is passed to this Project Page.
A user can then select from a Unit from the list at the top and from the Goal list at the side. There is also an All tab for both lists.
In the main Posts list , only the Posts that match all the following are shown:
project_id
unit_id
goal_id
Side Panel
Selecting one of the Posts in the list will show the same post in the side panel and will also include entries from the other columns in the Post row
What I've done
The project_id is passed from a previous page into the Page Parameter: projectId
Both the Unit and Goals lists only show their respective items that have the same project_id.
In the Posts list, i have a Supabase Query that filters by the project_id specifies in the projectId page parameter.
I've done a bunch of other parameters and backend queries, but it's essentially a mess and i'm about to delete all the queries and parameters etc. and start hooking it up again.
Could someone let me know the best way to go about this? I have gone through a number of videos and the flutterflow docs, but they all seem to have only parts of the solution.
I greatly appreciate any help, thank you.