I have quite a basic question, but I can’t seem to find the answer anywhere, so would greatly appreciate your help.
The question is how you define workflows to connect different data types.
I have 2 data types:
Location
Hot desk
Locations contain hot desks, but they have a one-one relationship.
I have created fields in each of the data types that refers to the other.
What I have created (which doesn’t seem to work):
User creates a location.
User clicks on a button ‘hot desk’ in a repeating group, which navigates them to a page where they can create inputs for the data type ‘hot desk’. Here I have sent data ‘location’ as part of this navigation.
User completes the ‘hot desk’ data inputs and clicks on ‘save’. Upon clicking ‘save’, I’ve defined the workflow ‘Make changes to location’, which changes ‘The current page location’ and the thing that is changed is ‘Hot desks = Current page Location’s Hot desks’.
I expected that after defining that last workflow, the ‘location’ field in the ‘hot desk’ data type would show the location it was meant to be associated with. But the location field just shows blank in the database, whilst all the other fields are showing the defined attributes.
I’m trying to define this exact type of workflow that connects different data types in other parts of my app too, but I can’t seem to figure out how to. Am I missing something fundamental about how data types are connected through workflows in Bubble?
thanks for responding @deadpoetnsp - I have managed to solve the issue.
I was basically trying to create 1 page where a user could create information and then also edit it in the future.
But I realised that the way Bubble works with data, I actually needed 2 pages - one where users create hot desks, and another where users can edit their existing hot desks - because the way Bubble is designed, each page can only have 1 ‘data type’.
You don’t need to make different pages or limit yourself to the data type of a page. You can do everything on one page using different groups. See the Bubble “clone” tutorials and forum, if you haven’t. That way the user won’t be interrupted by page navigations.
thanks @deadpoetnsp - I tried to find the Bubble ‘clone’ tutorials but no luck. I have however come across page cloning in the app (and actually used that to copy the ‘create new’ and ‘edit’ pages for hot desks. I can envision how creating clones of multiple pages leads to a much neater UI. One thing I just realised though is that you somewhat need to create the basic structure of the page that you are cloning before actually creating the different pages. Will look to do that now before building out the full app and then having to recreate everything.
By “clone” I meant these series of official tutorials by Bubble, which show you how to clone many popular websites using Bubble: https://bubble.io/how-to-build
I strongly recommend going through each one of them.