Skip to content
Kamoorjdocs
Documentation

Reference template editor

Build student and employee certificates with variables, partials, manual fields and preview.

On this page

Purpose and opening the editor

Open Human Resources → Reference Templates and select a template. The editor at /reference-templates/:id (new for a new record) defines a certificate concerning a student or employee. It determines future document content without changing a person's record or issuing a certificate.

The shared document builder provides certificate-specific settings. Unlike the content export editor, this is one document, without multiple sheets or arbitrary module options.

Workspace

  • Document toolbar: return to the library, name, languages, Save and Undo/Redo.
  • Insertion and preview: add rows, columns and blocks to the body and select elements directly on the canvas.
  • Inspector: document, section, row, cell or block settings depending on selection.
  • Layout: paper format (A3, A4, A5, Letter), portrait or landscape orientation, margins, page settings and background color/image.
  • Preview: the current draft’s schematic preview and a separate saved-template preview with an actual person.

Header and footer come from the reference partial library. Only the body is authored directly in this template. To change a shared header, edit the corresponding partial separately. One partial can be used by several templates.

Certificate settings

In the document inspector, configure:

Property Value
Name Localized template name, at least one nonempty translation, up to 255 characters
Subject type Student (student) or employee (employee); defaults to student
Enabled is_enabled: enabled templates are available for issuance; defaults to enabled
Header / footer Optional selection of saved partials matching the subject type
Manual fields Additional values entered by an operator at issuance
Paper, orientation, background Document appearance

To review a new template before use, uncheck Enabled, save and preview. After checking, enable and save it again. There is no separate publication status or approval stage.

Changing the subject type

Switching the subject refreshes the variable catalog, clears selected header/footer and detects incompatible variables in the body. If any are found, a modal lists the keys and asks for confirmation to remove them. Confirm only when you intend to change this template. Recheck all text and variable placement after the switch, including name components. Saving a partial for the wrong subject is rejected; a shared partial with no subject type is accepted by the server.

Content

Create a section with an appropriate grid, such as one column for the body text and two for signature and date. Insert blocks and adjust sizes, alignment, colors, fonts, spacing and borders using the editor tools. Individual elements can be duplicated or removed, and edits can be undone.

Element Purpose
Rich text Heading, certificate text, inline variables
Ordinary table Tabular presentation of details
Image Approved logo or another available image
Date Current date with configurable format
Signature Signature area
Divider, spacer, group Arrangement and visual separation
Input, select Dynamic builder fields, distinct from additional manual-field variables

Use static sections (none) for ordinary certificates. The server’s student catalog contains collections for academic courses, educational statuses, semester results, liquidations and student movements. Loop variables require a compatible section source. However, the current certificate adapter does not load the ordinary content-export row-source catalog, so do not assume all repeat modes are selectable for new sections in this shared editor. Dynamic content export tables and the performance summary/photo blocks are hidden from the certificate palette.

Variables

Select a variable from the current catalog in the rich text editor rather than typing an arbitrary key. The available sets depend on the subject:

Student Employee
student.full_name, student.first_name, student.last_name, student.patronymic, student.birthdate employee.full_name, employee.first_name, employee.last_name, employee.patronymic, employee.birth_date
enrollment.faculty, enrollment.profession, enrollment.degree, enrollment.study_year, enrollment.group, enrollment.status employee.position, employee.position_abbreviation, employee.academic_position, employee.department
admission.order_num, admission.order_date, admission.date, admission.grade_book_num employee.work_start_date, employee.work_end_date, employee.rate
student.sequence_number, computed.cumulative_gpa, computed.total_credits employee.scientific_degree, employee.scientific_title
university.name, university.address, contact.phone and other student catalog details Employee personal and work details; student and tuition variables are unavailable

Student financial certificates also support tuition.amount, tuition.final, tuition.discount_percentage, tuition.paid_total, tuition.balance, tuition.payment_type, tuition.academic_year, tuition.course.

Both subjects support document.number, document.authority, document.date_of_issue and document.type_name with a document type, and employee.by_role_scope for a signatory’s name by role. Select the role and optionally pin an eligible employee. If an unpinned role has multiple candidates, issuance can request a specific signatory. A signature area in the layout is not an electronic signature.

Employee work variables use the main workplace by default, falling back to the first recorded workplace. A workplace can be selected during issuance. Missing source data such as position or scientific degree can produce blank variables; maintain the employee register.

Additional manual fields

  1. Add a field in the certificate settings.
  2. Enter a key, for example purpose. It must use 1–64 Latin letters, digits or underscores and be unique ignoring case.
  3. Choose text, date or multiline text, and mark it required if appropriate.
  4. Insert the new manual.purpose variable into the body.

Declaring a field does not print it automatically: insert its variable into the content. The issuer fills its value. If the key is renamed or deleted, update the corresponding variable placements. Neither schematic preview nor the editor’s real-person preview substitutes for entering manual data during issuance.

Example: proof of enrollment

  1. Create a template called Proof of enrollment with subject student, A4 and portrait orientation.
  2. Select an appropriate student header with the institution name.
  3. Add the body text: “This certifies that [student.full_name] studies [enrollment.profession], faculty [enrollment.faculty], year [enrollment.study_year].” Brackets here denote variables to insert, not literal output.
  4. Add a required text field purpose and a sentence with manual.purpose.
  5. Insert the date and signature area, optionally a signatory variable for the Dean role.
  6. Complete the localized name and text, save and test with a student. Enable the template after checking.

For an employment certificate, choose employee instead and use employee full name, position, department, start date and rate variables.

Saving, preview and output

Save submits the body, translations, page settings, selected partials, subject, manual fields and enabled status. The server validates layout, allowed variables, required variable properties and subject compatibility. Correct the indicated element if validation fails.

Schematic preview helps inspect the draft and its languages. Save before previewing with real data. In the document settings, click Live preview, search for and select an employee or student, then Refresh. This renders the saved template on server without creating an issued certificate; unsaved edits will not appear. Use the issuance form to verify manual fields and ambiguous signatories.

Issuance creates a separate record with a content snapshot. Changing a template does not automatically replace already issued certificates; their history and relevant updates are handled in the reference register. The final file comes from issuance or the register, not the editor’s Save action.

Permissions and scopes

Action Permission
Templates, details, variable catalog and saved preview reference-templates.index (bound show, variables, preview)
Create and edit reference-templates.store (bound reference-templates.update)
Select header/footer reference-header-templates.index, reference-footer-templates.index
Find preview subject Student or employee list permission as appropriate
Issue Separate references.issue and references.employee-issue

Template configuration is global and its routes have no organizational scopes of their own. Issuance and personal records have separate permissions and applicable scopes (faculty, profession, department for references). Subject type selects the data source, not an access grant.

Implementation references

Updated Nov 27, 2026