UPDATE I think I may have figured this out. I will test some more and post the solution when I am sure it works.
I originally posted this question here but after further investigation I am able to explain more succinctly.
I have a single page app which is made from groups which are either shown/hidden. There are no pages, only groups. We have a group for settings, contact, about me etc.
One group is called “my-customers” and lists the Users customers in a RG.
When a customers name is clicked from the list, I hide that group and show “customer-details” (to display more details on that customer).
I have an invoice page and users can attach one of their Customers to that invoice. When they click ‘attach customer’ they need to go the same list of customer, ie. “my-customers” and this time, instead of showing “customer-details”, it needs to show the “my-invoice” group.
This may be possible using CustomStates but I have tried every which way. Could someone tell me step by step how I can achieve the above?
Thanking you in advance!