General overview:
The plugin creates a Macro, that can be used to assign new documents in Confluence with a unique document number.
Macro would do something like this:
IR – Incident Report:
The structure of the document number is:
XX-YYYY-dtDDHHMM where dt = Document Type
Functional limitations:
The document number is to be generated on initial save of the document and should not update if changes are made at a later time.
Any ideas how I can achieve this?
The Create from Template macro does allow you to insert the date into the title, although this is limited to YYYY-MM-DD. However, users can easily overwrite this.
But what's your use case here?
Out of the box, Confluence knows what a document is first created - the only thing that isn't part of the standard meta-data would be what you call the document type, since everything is a page (or a blogpost).
You may be able to develop something to do this, using development features such as Webhooks, Custom Content types, and custom Content Properties.
But equally you might achieve the same using default macros, like the Page Properties and Page Properties Report macros to track document type.
Use case - It would be used to assign a unique reference number to a document in the existing company format. Think along the lines of a case or doc reference number you might see on a headed letter (see example below).
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
If you are tied to the existing format, then the only way I can think of achieving this is as I outlined above.
An easier option for a unique reference number would be to use the Page ID.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for the guidance James. I will look into the template option you mentioned.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Not on Cloud, there's no way to add the sort of macro you would need.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for your insight - I am exploring the possibility of writing a plugin; should I progress with it, I will post the solution here.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.