May 17, 2021 3:25 AM
We've created a HubDB table and a module to show it on a page.
We want to show different queries from the table on different pages so this seems the way to go, rather than holding the data with a single module.
My question is, is there any way to write to the table from a module?
I'm just trying to avoid the user having to leave the usual CMS editor to create entries.
May 17, 2021 3:49 AM
@stephenpratley_ Basically, no. The only other way (that I know of, admittedly) to update a HubDB is to use the API but using that from within the editor doesn't seem possible, at least not in a secure, well managed way. It's not too onerous to simply have the HubDB open in another tab next to the page being edited, no?
Unless @dennisedson knows something I don't (which is usually true).
May 17, 2021 4:14 AM
The issue isn't the ectual editing.
It's someone going into the CMS on the page where they want to add another entry and thinking "where do I go now?"
A content manager shouldn't have to leave the editor.
"Files and templates" isn't an intuitive label for it either.
Plus manging the extra permissions.
I'll see if we can just add a lebel of some sort in the module we built to display the data, but that sounds like a hack.
May 17, 2021 10:20 AM
@piersg is correct here. I appreciate your concern with that editing experience. I wonder what it would look like in your ideal scenario. If you are feeling up to it, could you add how you believe it should look to the ideas board and link back here? At the minimum, I can get some eye on it. I know the product teams are always looking for these types of ideas.
May 17, 2021 10:33 AM
I'm not sure what you can see in the back end of each portal, but we have a page here that is managed with a custom moodule:
That module has all the functionaliyty we need, but the data is tied to the module and can't be re-used.
If I wanted to have a "lastest event" signpost on the homepage, I couldn't.
From an editor perspective, it should be exactly the same, but the data should be stored in a HubDB table to allow it to be re-used elsewhere.
Using the HuBDB tables shoudl also make it a lot easier to reskin sites at a later date.
Currently too much is stuck in custom modules so just moving from one theme to another feel like a rebuild on some occasions.
Jul 6, 2021 10:24 AM - edited Jul 6, 2021 10:27 AM
But for the editor, this means, he/she has to edit this HubDB for every page that he/she wants to tag. It would be way easier if the user could tag the pages (like in the blog) from within the page editor. As far as I know, we could read the tags from HubDB within the module, but I don't know a way to write the selected tags/categories back into a HubDB which associates page and selected tags.
We'd be using Enteprise CMS in most cases - so does anyone know if I could write from a module into HubDB? I don't think that serverless components would run from the backend.
Thanks in advance!
Jul 6, 2021 11:28 AM - edited Jul 13, 2021 11:42 AM
@magmar You could:
A bit long winded maybe and you would need serverless functions to do it.