Background:
I have a projects document containing a set of pages that represents different manufacturers we work with. We also have separate docs for each manufacturer which we share with them. In a manufacturer doc, we use sync pages to show all the projects for that manufacturer so they can follow along the progress.
As each project outline will be the same, I want to be able to quickly create a new project that has everything needed. For example, in our case we need to have a compliance checklist, leaflets, material request checklist and more for each project. I have solved all that and used separate reference tables to make it all re-usable, but the issue comes when I want to duplicate all these pages into a specific manufacturer page.
I don’t want to copy the pages into a separate document, as I need to be able to summarize project statuses and get a good overview in our projects doc instead of having to go into each manufacturer document separately.
List of content in the “Create new project” page:
- A user needs to be able to create a new project, so I have a page for that with a set of controls/inputs
- One of the controls is a text input, which will be the name of the project as well as the name of the final duplicated page
- A select control contains all pages in the document, with values coming from a page table generated by Doc Explorer (Doc Explorer Pack, extend Coda with Doc Explorer - Coda) - this is the target I want to copy a set of pages into. This does not contain a reference to the actual object as far as I am concerned – but it does have an ID for it (Internal ID is the column name)
- I have a create button, which runs a formula. I am able to do everything except for duplicating the pages into the selected manufacturer page
- As there are no page objects in the table columns of Doc Explorer, I need to find a way to reference the Internal ID instead, which is the ID for the page basically
Problem:
When using DuplicatePage() in formulas, I cannot figure out how to reference a page by ID as it is expecting a reference and not an ID.
How can I generate a page reference via an ID? I was hoping there was a way to do stuff like getObject(id), getReference(id), getPage(ID), @[id] etc, but I haven’t found any fitting functions for it.
Please let me know if you have any idea on how to proceed. I don’t want my users to have to manually duplicate and drag the pages, as they contain sensitive information that manufacturers don’t want other manufacturers to see. It needs to be automated to lower risk of mistakes.