You can implement this behavior with a Custom Numerator.
The attached file contains a project with an example of this behavior.
When the ItemTest object is saved, the Numerator is added depending on the IsTemplate property.
The example does the following:
1.Custom Numerator has been created, which inherits the CustomNumerator class (see file TestCustomNumerator)
2. Added a link between object and Custom Numerator (see module NumeratorTestProjectModule, application_SetupComplete)
Feel free to contact us if you have any questions.
On behalf of Xafari Client Services Team