Do you have a question?

Enter one or more keywords and find the answer!

Student report generation via ODT template

This mini-guide on generating reports from student records via .odt template is divided into the following paragraphs:

  1. INTRODUCTION
  2. PLACEHOLDER DEFINITION
  3. PLACEHOLDER LISTS
  4. PLACEHOLDERS IN TABLES
  5. CONDITIONAL BLOCKS
  6. LIST OF AVAILABLE PLACE CARDS
  7. UPLOADING ODT TEMPLATE TO SYSTEM
  8. USE OF THE CONTRACT TEMPLATE


1. INTRODUCTION

In the direction of allowing the individual school autonomous management of certificates, certificates, reports and other documents, the system allows for the preparation and activation of documents in total autonomy, which will then be exportable for each course and for each student enrolled in the courses.
The report will have to be a template in .odt format, i.e., OpenOffice, the content will be able to integrate dynamic content through the use of placeholders responsive to a predefined syntax, being able to choose from an extensive list of entities and attributes that will allow documents of various types to be generated.
The system will also allow access to custom fields of courses and users, or to insert tables to list enrollees, with a rather simple syntax, allowing rather rich documents to be generated.

The generation of a report from odt template enables the generation of documents in Open Document Text format (ODF text document, .odt extension), containing dynamic information, using an .odt file, called a template, in which appropriate placeholders are inserted, which, in the final generated document, will be replaced by the value indicated by the placeholder.

WARNING: template refers, in the context of this documentation, to a normal .odt file containing placeholders, the file must be in ODF text document format, extension .odt.

The template for generating the final document, to be uploaded when setting up the report, is a normal odt document, and where there is text, a placeholder can be inserted there, within the normal text flow, even within a table.

This type of report can be linked to a course, to a student in a course, or to a teacher in a course and allows for the generation of certificates, certificates, and reports on the course; it can also be linked to a student in the student registry to generate enrollment forms, for example, or to a teacher in the teacher registry to generate a letter of assignment; another possible use is as a contract template, to be used in order management.

2. DEFINITION OF PLACEHOLDERS

La sintassi per definire un segnaposto è {oggetto.attributo}, il nome dell’oggetto è la parte del nome a sinistra del punto, il nome dell’attributo è la parte a destra del punto; quindi, ad esempio, per mostrare nel documento finale il nome del corso si usa {course.name}, per mostrare la sede del corso si usa {location.location}.

If the name of the object is plural, in English, it means that it is a list of values, which can be used within a table or to create a list of values in the final document, using an appropriate syntax to indicate the beginning and end of the list; the list of placeholders below indicates when a placeholder is a list.

Some placeholders, e.g. course, students, students, teachers, possess an attribute that has a different behavior, the customfields attribute, the syntax of which is {object.customfields[code]}, which is used to show the value of a custom field, e.g., to show the value of the custom field of the course with code _LEVEL, we use {course.customfields[_LEVEL]}.

To summarize, if we wanted to show the name, code, location, and custom field _Level, of the course:

{course.name}

{course.code}

{location.location}

{course.customfields[_LEVEL]}

3. LISTS OF PLACEHOLDERS

The syntax for using a list of values, involves indicating where the list begins and where it ends; in the block of text enclosed between the two markers, placeholders are inserted to show the values of each list item, for example, to list the full names and email address of each student in the course:

[!-- BEGIN students --]

{students.fullName} {students.email}

[!-- END students --]

the line between [!-- BEGIN students --] e [!-- END students --] will be repeated for each student, in the final document.

Two special placeholders are available for each list item, _position, the position of the item in the list, and _total, the total number of items in the list.

4. PLACEHOLDERS IN TABLES

The syntax for using a list of values within a table involves indicating where the table row begins and where it ends; in the block of text enclosed between the two markers, placeholders are inserted to show the values of each item in the list, e.g., to list the full names, email address, and mobile phone of each student in the course, within a table:

[!-- BEGIN row.students --]

{students.fullName}
{students.email}
{students.mobile}

[!-- END row.students --]

the table row between [!- BEGIN row.students -] and [!- END row.students -] will be repeated for each student, in the final document table.

5. CONDITIONAL BLOCKS

The conditional block is a part of the document, delimited by appropriate markers, with which a condition is associated, which can be true or false; if true, the contents of the block are included in the final document; if false, the contents of the block are removed from the final document.

One of the defined custom fields or the conditions given in the CONDITION section of the list of available placeholders can be used as a condition for the block.
The condition using a custom field is true if the field is valorized, it is false if it is empty.

The syntax for defining the conditional block involves stating the beginning and end of the block, indicating the associated condition, e.g., to define a conditional block to be shown only if the order is discounted:

[!-- IF order.isDiscounted --]

Sconto: {order.discount}

[!-- ENDIF order.isDiscounted --]

order.isDiscounted is the condition, if it is true the order is discounted and the discount applied is shown, if it is false the order is not discounted and the discount line will not be included in the final document.

You can reverse the condition check by adding NOT to the syntax to define the conditional block, for example, to define a conditional block to be shown only if the order is not discounted:

[!-- IF NOT order.isDiscounted --]
Discount not applicable.
[!-- ENDIF NOT order.isDiscounted --]

order.isDiscounted is the condition, if it is true the order is discounted and the text "Discount not applicable" will not be shown in the final document, if it is false the order is not discounted and therefore the text "Discount not applicable" will be shown in the final document.

To use a custom field as a condition use the following syntax:

[!-- IF student.customfields[CERTIFICAZIONI] --]
Certifications: {student.customfields[CERTIFICATIONS]}
[!-- ENDIF student.customfields[CERTIFICAZIONI] --]

the row within the block will be shown only the student's certifications have been indicated, that is, if the custom field with code CERTIFICATIONS of the student is not empty.

6. LIST OF AVAILABLE PLACEHOLDERS

Branch placeholders

Data related to the School branch, for management systems that manage more than one branch.
SIGNAGEVALUENOTES
{branch.code}branch code
{branch.description}branch description
{branch.name}branch name

Placeholder report

Report data
SIGNAGEVALUENOTES
{report.parameters[name]}possible parameter of the report

Placeholder configuration

Configuration data
SIGNAGEVALUENOTES
{configuration.settinga[name]}configuration parameter value

Placeholder currentDate

data for the current date
SIGNAGEVALUENOTES
{currentDate.date}current date
{currentDate.day}current day01 to 31
{currentDate.year}current year
{currentDate.month}current month1 to 12
{currentDate.monthName}current month name
{currentDate.weekDay}day of the week

Student placeholder student registry

Student data available in Master Data → Students section.
SIGNAGE
VALUE
NOTES
{student.address}
address
{student.birthdate}date of birth
{student.birthday}
birthday
{student.birthplace}place of birth
{student.birthprovince}province of birth
{student.birthcountry}country of birth
{student.cap}zip code
{student.city}city
{student.country}country
{student.countryCode}country
{student.citizenship}citizenship
{student.passport}passport
{student.profession}profession
{student.qualification}qualification
{student.customfields[]}
custom fieldThe custom field code should be indicated between the square brackets
{student.email}
email
{student.fullName}
call sign
{student.gender}
genre
{student.maritalstatus}marital status
{student.id}identifier
{student.mobile}mobile phone
{student.name}
name
{student.phone}
landline
{student.province}
province
{student.surname}
surname
{student.taxcode}
tax code
{student.vatnumber}
VAT number
{student.cardnumber}number from the card, if any
{student.notes}notes
CONDITIONVALUENOTES
student.isAdulttrue if the student is of age, false otherwise
student.isNotAdulttrue if the student is a minor, false otherwise

TeachingYear placeholders

data for the school year
SIGNAGEVALUENOTES
{teachingYear.endDate}final date
{teachingYear.firstLesson}first lesson date
{teachingYear.lastLesson}last lecture date
{teachingYear.name}name academic year
{teachingYear.startDate}start date

TeachingYear placeholders (if divided into periods)

Data on the periods into which the school year is divided
SIGNAGEVALUENOTES
{teachingYear.firstPeriod}first period name
{teachingYear.firstPeriodStartDate}starting date first period
{teachingYear.firstPeriodEndDate}end date first period
{teachingYear.secondPeriod}second period name
{teachingYear.secondPeriodStartDate}starting date second period
{teachingYear.secondPeriodEndDate}final date second period
{teachingYear.thirdPeriod}third period name
{teachingYear.thirdPeriodStartDate}starting date third period
{teachingYear.thirdPeriodEndDate}final date third period
{teachingYear.fourthPeriod}name fourth period
{teachingYear.fourthPeriodStartDate}starting date fourth period
{teachingYear.fourthPeriodEndDate}final date fourth period

ParentTutor Placeholders

parent/guardian data in the order section, valued only if there is only one student in the order linked to one parent/guardian
SIGNAGE
VALUE
NOTES
{parentTutor.address}
address
{parentTutor.birthdate}date of birth
{parentTutor.birthday}
birthday
{parentTutor.birthplace}place of birth
{parentTutor.birthprovince}province of birth
{parentTutor.cap}zip code
{parentTutor.city}city
{parentTutor.country}country
{parentTutor.countryCode}country iso code
{parentTutor.citizenship}citizenship
{parentTutor.passport}passport
{parentTutor.profession}profession
{parentTutor.qualification}qualification
{parentTutor.customfields[]}
custom fieldThe custom field code should be indicated between the square brackets
{parentTutor.email}
email
{parentTutor.fullName}
call sign
{parentTutor.gender}
genre
{parentTutor.maritalstatus}marital status
{parentTutor.id}
identifier
{parentTutor.invoiceDataAddress}address (billing)Valued in case the master data includes billing data other than residence data
{parentTutor.invoiceDataCity}city (billing)Valued in case the master data includes billing data other than residence data
{parentTutor.invoiceDataCountry}Country (billing)Valued in case the master data includes billing data other than residence data
{parentTutor.invoiceDataEmail}Email (billing)Valued in case the master data includes billing data other than residence data
{parentTutor.invoiceDataFiscalCode}Tax code (billing)Valued in case the master data includes billing data other than residence data
{parentTutor.invoiceDataMobilePhone}Mobile number (billing)Valued in case the master data includes billing data other than residence data
{parentTutor.invoiceDataName}Name/Company (billing)Valued in case the master data includes billing data other than residence data
{parentTutor.invoiceDataPec}Pec (billing)Valued in case the master data includes billing data other than residence data
{parentTutor.invoiceDataPhone}landline phone (billing)Valued in case the master data includes billing data other than residence data
{parentTutor.invoiceDataProvince}Province (billing)Valued in case the master data includes billing data other than residence data
{parentTutor.invoiceDataRecipientCode}Recipient code (billing)Valued in case the master data includes billing data other than residence data
{parentTutor.invoiceDataVatNumber}VAT number (billing)Valued in case the master data includes billing data other than residence data
{parentTutor.invoiceDataZipCode}ZIP code (billing)Valued in case the master data includes billing data other than residence data
{parentTutor.mobile}mobile phone
{parentTutor.name}
name
{parentTutor.pec}certified e-mail address
{parentTutor.phone}
landline
{parentTutor.province}
province
{parentTutor.surname}
surname
{parentTutor.taxcode}
tax code
{parentTutor.vatnumber}
VAT number
CONDITIONVALUENOTES
parentTutor.isAdult
true if parent/guardian is of age, false otherwise
parentTutor.isNotAdult
true if the parent/guardian is a minor, false otherwise
{parentTutor.cardnumber}number of the card, if any
{parentTutor.notes}notes

Placeholders parentsTutors

data of parents/guardians of the order section, list
SIGNAGE
VALUE
NOTES
{parentsTutors.address}
address
{parentsTutors.birthdate}date of birth
{parentsTutors.birthday}
birthday
{parentsTutors.birthplace}place of birth
{parentsTutors.birthprovince}province of birth
{parentsTutors.cap}zip code
{parentsTutors.city}city
{parentsTutors.country}country
{parentsTutors.countryCode}country iso code
{parentsTutors.citizenship}citizenship
{parentsTutors.passport}passport
{parentsTutors.profession}profession
{parentsTutors.qualification}qualification
{parentsTutors.customfields[]}
custom fieldThe custom field code should be indicated between the square brackets
{parentsTutors.email}
email
{parentsTutors.fullName}
call sign
{parentsTutors.gender}
genre
{parentsTutors.maritalstatus}marital status
{parentsTutors.id}
identifier
{parentsTutors.invoiceDataAddress}address (billing)Valued in case the master data includes billing data other than residence data
{parentsTutors.invoiceDataCity}city (billing)Valued in case the master data includes billing data other than residence data
{parentsTutors.invoiceDataCountry}Country (billing)Valued in case the master data includes billing data other than residence data
{parentsTutors.invoiceDataEmail}Email (billing)Valued in case the master data includes billing data other than residence data
{parentsTutors.invoiceDataFiscalCode}Tax code (billing)Valued in case the master data includes billing data other than residence data
{parentsTutors.invoiceDataMobilePhone}Mobile number (billing)Valued in case the master data includes billing data other than residence data
{parentsTutors.invoiceDataName}Name/Company (billing)Valued in case the master data includes billing data other than residence data
{parentsTutors.invoiceDataPec}Pec (billing)Valued in case the master data includes billing data other than residence data
{parentsTutors.invoiceDataPhone}landline phone (billing)Valued in case the master data includes billing data other than residence data
{parentsTutors.invoiceDataProvince}Province (billing)Valued in case the master data includes billing data other than residence data
{parentsTutors.invoiceDataRecipientCode}Recipient code (billing)Valued in case the master data includes billing data other than residence data
{parentsTutors.invoiceDataVatNumber}VAT number (billing)Valued in case the master data includes billing data other than residence data
{parentsTutors.invoiceDataZipCode}ZIP code (billing)Valued in case the master data includes billing data other than residence data
{parentsTutors.mobile}mobile phone
{parentsTutors.name}
name
{parentsTutors.pec}certified e-mail address
{parentsTutors.phone}
landline
{parentsTutors.province}
province
{parentsTutors.surname}
surname
{parentsTutors.taxcode}
tax code
{parentsTutors.vatnumber}
VAT number
{parentsTutors._position}position of the item in the list
{parentsTutors._total}total number of items in the list
CONDITIONVALUENOTES
parentsTutors.isAdult
true if parent/guardian is of age, false otherwise
parentsTutors.isNotAdult
true if the parent/guardian is a minor, false otherwise
{parentsTutors.notes}notes
{parentsTutors.cardnumber}number of the card, if any

Placeholder Courses student master data

Dati dello studente relativi ai corsi.
Sono disponibili i segnaposti relativi a:
1) Corsi frequentati "attendedCourses.name"
2) Corsi a cui è attualmente iscritto "enrolledCourses.name"
3) Corsi totalmente saldati "{paidCourses.name}"
4) Corsi aperti (NON chiusi, archiviati e cancellati) in cui lo studente risulta ancora iscritto. "enrolledOpenCourses"
SIGNAGE
VALUE
NOTES
{attendedCourses.code}course code
{attendedCourses.name}course name
{attendedCourses.duration}course duration
{attendedCourses.hours}total hours of the course
{attendedCourses.lessons}total lessons course
{attendedCourses.subject}matter
{attendedCourses.startDate}start date
{attendedCourses.endDate}end date
{attendedCourses.teachingYear}school year
{attendedCourses.teachersFullNameList}names of course instructors, separated by commas
{attendedCourses.booksTitleList}textbook list, the separator is the comma
{attendedCourses.customfields}custom fields
{attendedCourses.certificateStartLevel}starting certification
{attendedCourses.certificateEndLevel}final certification
{attendedCourses.internalStartLevel}internal starting level
{attendedCourses.internalEndLevel}final internal level
{attendedCourses.studentsFullNameList}student list, the separator is the comma
{attendedCourses.enrolledStudents}number of students enrolled
{attendedCourses.plannedHours}planned class hours
{attendedCourses.lessonsPerWeek}number of lessons per week
{attendedCourses.lessonsWeekDay}day of the week class
{attendedCourses.lessonsStartTime}class start time
{attendedCourses.lessonsEndTime}end of class time
{attendedCourses.locationName}name of the venue where the course is held
{attendedCourses.locationCompleteAddress}Address of the venue where the course is held
{attendedCourses.cost}cost
{attendedCourses.costIfInstallments}cost in case of payment in installments
{attendedCourses.installmentsNumber}Number of installments under the installment plan, if any
{attendedCourses.firstInstallmentAmount}First installment amount of any installment plan
{attendedCourses.firstInstallmentDate}first installment date of any installment plan
{attendedCourses.firstInstallmentDay}day first installment of any installment plan
{attendedCourses.firstInstallmentMonth}month first installment of any installment plan
{attendedCourses.installmentsAdvanceAmount}amount paid in advance
{attendedCourses.model}template name used to create the course
{attendedCourses.lessonsDuration}lesson duration, set only if regular course, in minutes
{attendedCourses.enrollmentDate}course registration date
{attendedCourses.attendanceLastDate}last attendance date

7. UPLOADING ODT TEMPLATE TO SYSTEM

To enter the report template into the system navigate to Configuration → Reports and click the "Add Report".
From the next screen fill in the following fields:

  • Name*: the name of the report
  • Description: any description of the report
  • Report type: choose the "From odt template" option to be able to upload your own template
  • Section in which to show the report *: Students
  • Template extension: OpenOffice Write (.odt)
  • Report template: upload the template with odt extension of your report
  • Select type: select the type of file extension that the report should have when exporting it, being able to choose from:
    • OpenOffice Write (.odt)
    • Portable Document Format (.pdf)
  • Order *: the order in which the reports are listed (e.g. 1, 2, 3, etc.)

Click the "Add report" to save the operation.

After uploading the template, go into editing the template (by clicking the icon with the edit stick) and check the "Enabled" to enable the export of the report from the courses and click one of the two buttons at the bottom of the page to save the operation.

Finally, click the icon on the row of the uploaded template to enable administrative accounts that will be able to view and export the report from courses or enrolled students.

8. USE OF REPORTS

To export a student's report navigate to the menu item Master Data → Students and click on the name of the master record.

From the next pop-up shown by the system, choose the report via its drop-down menu (in case more than one report has been uploaded) and click the "Download" button to perform the export.

Leave a comment

You must be logged in to leave a comment.