Deepser Deepser
  • Documentation
  • Start Free Trial
Start Free Trial
Deepser Deepser
Start Free Trial
Deepser
  • Documentation
  • Start Free Trial
loading
  1. Home
  2. Documentation
  3. Report Documentation
  4. Report Configuration
Updated on April 22, 2025

Documentation

  • Access and Visibility
    • Resources
    • Roles
    • Creating and Managing Roles in Deepser
    • Creating a new user
    • Password Reset
    • New User Registration
    • LDAP Configuration
    • SSO Deepser Configuration
    • SSO Login/Provisioning Configuration – Azure
    • Multi Factor
    • Groups
    • Groups Creation
    • Manage Users in Groups
    • Company
    • Companies in Deepser
    • Company Creation
    • Parent Companies
    • Email Domains
    • Sync Account CRM Companies
    • Advanced Sync
    • Visibility management in Deepser
    • Permission and Visibility Handling
    • Groups and Rules Definition
    • End Users Visibility Overview
    • Entities Portal Visibility
    • Empowered End User (EEU)
    • Company Supervisors
    • Additional Companies
    • Access Groups
    • Access Users
  • Activity, Worklogs & Comments
    • DeepActivity Comments
    • Placing a comment
    • Comments System Configuration
    • DeepActivity Worklog
    • Entering a Worklog
    • Enabling Worklogs in the User Portal
    • Worklog Global Grid
    • Worklog Global Grid Configuration
    • Activity Global Grid Advanced Configuration
  • Board
    • Enable groups to create boards
    • Creating a FreeForm Board
    • Creating and customizing a Lane
    • Entry Creation
    • Board Live
    • Live Board Creation
    • Advanced Live Board Configuration
    • Creating and customizing a Lane
    • Creation and Advanced Configuration of a Lane and Drop Code
  • Categories
    • Category Overview
    • Category Configuration
    • Category Usage
  • Chat
    • Using the Chat
    • Enabling the Chat on Portals
    • Chat Rooms and Moderators
    • Public Chat
    • Configure a Public Chat Widget
    • Chatbot
    • Chatbot Flow – Example
  • CMDB
    • Deepser CMDB
    • Enable CMDB in the User Portal
    • User Portal CMDB Grid Configuration
    • Advanced Configuration of CMDB Grids
    • Class, Type and Subtype
    • Configuring a CI
  • CRM
    • Deep CRM
    • Creating an account in the CRM
    • Creating a contact in the CRM
    • Creating an opportunity in the CRM
    • Contact Types in CRM
    • Opportunity Types in CRM
    • CRM Lists
    • Sync Contacts and Accounts
    • Address Functioning
    • Sales
    • Mailchimp Integration
  • Deepser API
    • API Notions
    • API Endpoint and URL
    • API Verbs and Format
    • API Authentication
    • API Main Methods
    • Retrieve
    • Multiple Retrieve
    • Create
    • Update
    • Delete
    • API Entities
    • API Company
    • User API
    • Group API
    • Service Operation API
    • Service Type API
    • Activity API
    • CMDB CI API
  • Deepser Fundamentals
    • Deepser Backend
    • Deepser User Menu
    • Deepser Navigation Menu
    • Global Search Usage
    • Deepser Home Page
    • Grids
    • Filters and Order
    • Export Data
    • Mass Action
    • Mass Action Configuration
    • Grid Creation and Cloning
    • Configuring Grids
    • Advanced Collection Configuration
    • Grids Render and Options Configuration
    • Grids Custom Options Configurations
    • Grids Renderer Tooltip Example
    • Grids Renderer Link Example
    • Grids System Configuration
    • Form Template Theory
    • FormTemplates
    • FormTemplates Structure and Buttons
    • Form Template Selection and Creation
    • Form Template Configuration
    • Form Template Structure Configuration
    • Formtemplates Fieldset Configuration
    • Formtemplates Buttons Configuration
    • Formtemplates Field Configuration
    • Advanced Form Template Rules
    • Custom Button Configuration
    • Buttons Conditional Hiding
    • User Portal
    • Browsing the user portal
    • Managing Tickets in The User Portal
    • User Portal Additional Features
    • Configuring Portal Groups
    • Configuring Portal Requests
    • Configuring Service Operations in the User Portal
    • Enabling Other Modules in the User Portal
    • Enabling Other Modules in the User Portal Grid
    • Guest Portal
    • Enabling the Guest Portal
    • Guest Portal Visibility Configuration Overview
    • Enabling Service Types on the Guest Portal
    • Adding a Portal Group in the Guest Portal
    • Adding a Portal Request in the Guest Portal
    • Editing Form Templates in the Guest Portal
    • Enabling Categories in the Guest Portal
    • Enabling Notifications for Guest Users
    • Knowledge Base in the Guest Portal
    • CMS in the Guest Portal
    • Cache Management
    • Quick Reply
    • Mentions
    • Module Creator – Creating a custom module
  • Email Integration
    • Email Integration in Service Management
    • Enable Embedded Images on Message Body
    • Mailbox
    • Configuring an Outgoing Mailbox
    • Configuring an Incoming Mailbox
    • OAuth Client for Email Integration
    • Email Loop Management Tool
    • AZURE OAUTH CLIENT
    • Google Oauth Configuration
    • Email Rules
    • Email Rule Configuration
    • Advanced Email Rule Configuration
    • Avoid Duplicate Tickets By Email
    • Managing additional Email recipients
    • Email Events
    • Enabling / Disabling an Email Event
    • Custom Email Events Creation
    • Custom Email Events Configuration
    • Attach Report to Email Notification
    • Email Templates
    • Email Template Configuration
    • New operation notification template for Requester User
    • New or Updated comment notification template for Requester
    • Email Webclient
  • Escalation
    • Escalation rule levels
    • Configuring Escalation Rules
    • Configure an escalation rule that modifies entity.
    • Escalation rule that sends an email notification
    • Create an escalation rule that is based on a metric
    • Configure an escalation rule that generates other entities
  • Importing Data
    • Import Foundamentals
    • Import Creation
    • Import Basic Data Binding
    • Import Before Run
    • Import Before Run Tutorial
    • Import Before Row
    • Import Before Row Tutorial
    • Import After Row
    • Import Binding The Unique Field “Code”
    • Import Binding the Type Value
    • Import Binding the Dates Values
    • Import Binding a Company, creating the record if it doesn’t exist
    • Global Import
  • IT Asset Management
    • IT Asset Models
    • ITAM Automatic Scan Configuration and Usage
    • ITAM Configuration
    • AnyDesk
    • Supremo
  • Knowledge Base
    • Reading the Knowledge Base
    • Knowledge Base in Service Operations
    • Article Configuration in Knowledge Base
    • Knowledge Base Configuration
    • Knowledge Base Standard Filters
    • Knowledge Base Advanced Filters
  • List
    • Introduction to lists
    • Creating a new list
    • List Values and Model Visibility
    • Use a list as the basis of a custom field
  • Password Management
    • Configuring a Password
    • Using a Password
    • Private Password
    • Password System Configuration
    • Enabling Password Manager Portal
    • Custom Deeppassword fields
    • Password Audit
  • Relations
    • Using a Relation Grid field
    • Configuring a Relation
    • Modifying relation using a custom event.
    • Opposite relation
    • Column Configuration
    • Relation Graph View
  • Service Management
    • Introduction to Services in Deepser
    • Service Operations
    • Creating a Service Operation
    • Adding Comments, Activities, Attachments and Tasks to Operations
    • Service Operation Main Fields
    • Service Operation Additional Fields
    • Service Operation Activities, Relations, Email and SLAs
    • Service Types
    • Routing rules
    • Configuring Routing Rules
    • Advanced Routing Configuration
  • SLA
    • Calendar
    • Metrics
    • Goal
  • Task
    • Creation of task type
    • Form configuration of task types
    • Task Global Grid
    • Task Global Grid Configuration
    • Task Global Grid Advanced Configuration
  • Workflow
    • Workflow Overview
    • Flow Designer
    • Flow Trigger
    • Workflow – Stage Set
    • Workflow – Executions
    • Approval workflows
    • Portal Approval Structure
    • Backend Approval Structure
    • Workflow Actions
    • Workflow Logic
    • Workflow Samples
    • Multi Stage Flow
    • SubFlow
  • Inventory
    • Inventory Overview
    • Inventory Configuration
    • Warehouse
    • Item
    • Movement
  • Custom Fields
    • Custom Field Overview
    • Custom Field – Creation
    • Custom Field – Element Type Simple
    • Custom Field – Element Type Advanced
  • Folder icon closed Folder open iconCustom Event
    • Custom Event Overview
    • Custom Event – Creation
    • Custom Event – Type
  • Dashboard
    • Dashboard Overview
    • Panel Configuration
    • Chart Configuration
  • Project
    • Project Module
    • Gantt
    • Project Task
    • Resource Grid
  • Calendar
    • Calendar Configurations
    • Internal Calendar Configuration
    • Calendar Configuration Example
    • External Calendar Configuration
    • External Calendar – Google Calendar Configuration Example
    • External Calendar – Outlook Calendar Configuration Example
    • Calendar Usage
  • Survey
    • Survey Overview
    • Designer
    • Survey
    • Dashboard
  • Contract and Contract Line
    • Contracts and Contract Lines – General Overview
    • Contracts
    • Contract Lines
    • Contract Creation
    • Line Creation
    • Associate a Contract / Line with other entities
    • Contract Type
    • Line Type
    • Contracts and Escalation Rules
  • Report Documentation
    • Report Configuration
    • Report Usage
  • Sales
    • Catalog and Price List Overview
    • Catalog Configurations
    • Product
    • Price List
    • Billing Overview
    • Order Billing
    • Lines Billing
    • Worklogs Billing
    • Movements Billing
    • Operation Billing
  • Folder icon closed Folder open iconIntegrations
    • Teams Integration
    • NinjaOne Integration

Report Configuration

Estimated reading: 8 minutes

Within the report configuration, an admin user can: 

  • Create a custom folder 
  • Create an executable report 
  • Schedule a report for automatic delivery to one or more users 

 Folder Creation 

To create a new folder for your reports, you can go to “System->Report->Folder”. On the folders grid you can see all the previously created folders. 

By clicking on Add Folder button, the following screen will appear:

Below is a description of the available fields: 

Field 

Description 

Name 

Folder’s name 

Code 

This field is used to uniquely identify a folder. It is best  

Position 

This field indicates the position and listing of this folder on the grid. 

Icon 

On this field you can use an image as icon for the folder. 

Enabled Groups 

This field is used to limit visibility of users that can have access to this folder. 

Status 

Select field that is used to enable or disable the folder. 

Report Creation 

To configure a new report, you should go under “System->Report->Report”.  

You can now see the reports grid and the “Add Report” button, when you click on it you can create a new report.

By clicking on Add Report button the following screen will appear: 

Below is a description of available fields: 

Field 

Description 

Name 

Report Name 

Code 

Report’s code field is used to identify the report with a unique string. Utilizing a single string for this purpose is considered the most effective approach. 

Library 

Field of select type where you choose the type of report PDF, XLS and CVS. 

Folder 

Select field where select the destination folder for placing this report. 

CSV Delimiter  

This field is only visible if the library is ‘CSV’. Delimiter field can be populated by a character  such as ‘ ; ’ or ‘ , ’  which will be used as a separator between file records. 

CSV Enclosure  

This field is only visible if library is ‘CSV’. 

CSV enclosure field is used to define the enclosing characters of each record, for example double or single quotes. 

Form Render Expression 

The initial stage in setting up a report involves configuring Form Render Expression. On this field you can configure all the Filters based on which data will be extracted from the report. This field is configured in the same way for both: PDF and Excel report. 

To add the filters the following custom code is used:  

				
					// Firstly it is retrieved type values array. This values will be used as options on the filter field.
$type = Deep::helper('deep_service/type')->typeToOptionArray();
$this->addField(
            'type_id', // this indicates the filter field code, which has to be unique for each field
            'select', // filter field type, in this case its select, but it can also be text, date
            array(
                'label' => Deep::helper('deep_service')->__('Type'), // Label of the filter field
                'multiple' => 'multiple', // In fields of type select you can add this parameter if you want to select multiple choices for this    //filter
                'values' => $type,  // If field is of type select you also need to provide the option values that can be selected from this field. // The given value for this parameter should be of type array. In this case the given value is an array with all the service types.
                'columns' =>1 // This field indicates the width of this field on the report fieldset.
            )
        );
$this->addField(
            'created_at_from',
            'date',
            array(
                'label' => Deep::helper('deep_service')->__('(Created Date) From'),
                'image' => $this->getSkinUrl('images/grid-cal.png'),
                'time' => true,  // this parameter indicates whether you want to display also the time on this field.
// with format parameter you set the format of the date. In this case the given value gives a format date based on the //current user Local time zone.
                'format'  => Mage::app()->getLocale()->getDateTimeFormat(Mage_Core_Model_Locale::FORMAT_TYPE_SHORT),
                'columns' =>1,
            )
    );
$this->addField(
            'created_at_to',
            'date',
            array(
                'label' => Deep::helper('deep_service')->__('(Created Date) To'),
                'image' => $this->getSkinUrl('images/grid-cal.png'),
                'time' => true,
                'format'  => Mage::app()->getLocale()->getDateTimeFormat(Mage_Core_Model_Locale::FORMAT_TYPE_SHORT),
                'columns' =>1,   ));
				
			

After the configuration of form render expression is finished you can click on the “Preview” button, to see all the filters created. An example PDF report is shown below where there are extracted tickets filtered by type and creation date. 

Here is the preview of report filters: 

Then to extract the report based on these filters, you can click on the “Run” button on the right corner. 

NOTE: If the “Before Run Expression” or “Run Expression” script is not correct, the report will not run. 
 

Before Run Expression 

Before Run Expression is used to filter the collection that will be shown on the report, by using the filter fields configured on the “Form Render Expression”. 

On the first line the PDF library is initialized by setting the paper format and orientation. 

The following code iterates through each filter field and filters the collection based on those. Then the variable assigned with the operation collection is set to the report object. 

				
					// PDF library is initialized by setting the paper format and orientation.
$this->loadLibraryObj()->setPaper('A4', 'landscape'); 
$filters = $this->getFormData(); // Retrieve all the filters from Form Render Expression
// Retrieve the operation collection
$collection = Deep::getResourceModel('deep_service/operation_collection'); 
// Iterate through each filter field and filter the collection based on those. 
if ($filters['created_at_from'] !='') 
        {
             $collection->addFieldToFilter( 'main_table.created_at', [ 'gt' => 
            Deep::helper('deep_calendar')->filterDateTime($value) ] );
        }
        
        if ($filters['created_at_to']) 
        { 
$collection->addFieldToFilter( 'main_table.created_at', [ 'lt' => 
Deep::helper('deep_calendar')->filterDateTime($value) ] );
        }
  
        if ($filters['type_id'] !='') {
            $collection->addFieldToFilter( 'main_table.type_id', [ 'in' => $value ] );
        } 
// Then the variable assigned with the operation collection is set to the report object.
 
$this->setData('operation_collection',$collection);
				
			

Run Expression 

The run Expression Field is used to configure the layout structure of the report as well as retrieve all the records from the “Before Run Expression” field and display them on the report. On case of a PDF report, you can write html code to create tables and styles for it and Php code to retrieve all the needed values that are to be shown. 

When the report is of type PDF here is the example of it: On the first part of the code there are some styles to format the page structure and also the table that will display the operation data. 

				
					<!DOCTYPE html>
<html>
<head>
    <style>
        /** Define the margins of the page and the font **/
        @page {
            margin: 70px 25px;
font-family: Helvetica;
font-size: 12px;
        }
            /** Define the header style */
            header {
                position: fixed;
                top: -70px;
                left: 0px;
                right: 0px;
                height: 50px;
                color: grey;
                text-align: center;
                line-height: 35px;
	font-size: 18px;
            }
            footer {
                position: fixed; 
                bottom: -70px; 
                left: 0px; 
                right: 0px;
                height: 50px;
                
                /** Extra personal styles **/
                color: grey;
                text-align: center;
                line-height: 35px;
	font-size: 12px;
            }
            
            #report-title{
text-align: center;
}
 
 #report-title{
text-align: center;
}
#report-table {
border-collapse: collapse;
width: 100%;
	}
#report-table td, #report-table th {	
    border: 1px solid #ddd;		
    padding: 8px;
			}
#report-table tr:nth-child(even){
    background-color: #f2f2f2;
			}
#report-table th {		
    padding-top: 12px;	
    padding-bottom: 12px;	
    text-align: left;	
    background-color: #D90C0C;	
    color: white;
			}
   
    </style>
    
  <?php
        // get the report name
        $reportName = $this->getName();
        // collection of operation to be later used on the table
        $collection = $this->getData('collection');
// map the  fields that are to be shown on the table of operation records
        $fields = [
            'entity_id'=>'Id',
            'type_id'=>'Service Type',
            'title'=>'Title',
            'requester_username'=>'Requester User',
            'status'=>'Status',
        ];
// retrieve the status List values 
$statusList = Deep::helper('deep_list')->loadListValues(Deep_Service_Model_Operation::LIST_CODE_STATUS)->toOptionHash();
    ?>
<title><?php echo Deep::helper('deep_report')->__($reportName); ?>

<title><?php echo Deep::helper('deep_report')->__($reportName); ?></title>
</head>
<body>
    <script type="text/php">
        if ( isset($pdf) ) {
            $x = 800; // position on y 
            $y = 580; // position on x 
            $text = "{PAGE_NUM} / {PAGE_COUNT}";
            $font = $fontMetrics->get_font("helvetica", "bold"); // document’s font
            $size = 8; 
            $color = array(0,0,0);
            $word_space = 0.0;  //  default
            $char_space = 0.0;  //  default
            $angle = 0.0;   //  default
// add page numbers (in the format of "{PAGE_NUM} / {PAGE_COUNT}") to the generated PDF 
// document at the specified position using the specified font and styling
            $pdf->page_text($x, $y, $text, $font, $size, $color, $word_space, $char_space, $angle);
        }
    </script>
<!-- document’s header -->
    <header>
        <?php echo Deep::helper('deep_report')->__($reportName); 
        ?>
    </header>
    
<?php 
if (!$collection || $collection->count() == 0){
    echo "No data found";
    return;}?>
<!-- table that shows the operations-->
<table id="report-table" style="page-break-inside: auto;">
    <thead><tr><?php foreach ($fields as $field => $value): ?>
    	<th><?php echo Deep::helper('deep_service')->__($value); ?></th>
    	<?php endforeach; ?>
    	</tr></thead>
<!-- iterate through all the operations and add each record as a table row  -->
<?php foreach ($collection as $operation): ?>
	<tr>    <?php foreach ($fields as $field => $value): ?>
<td>   <?php 
		    if($field =='requester_username') // Retrieve the requester Name And Surname
		    {$value = Deep::getModel('deep_admin/user')->load($operation->getData($field),'username')->getId()  ? Deep::getModel('deep_admin/user')->load($operation->getData($field),'username')->getName() :''  ;
		    }else if($field == 'status')
		    {
		        $value = $statusList[$operation->getData($field)]; // Retrieve status Value Label
		    }else if($field == 'type_id') 
		    {
     $value = Deep::getModel('deep_service/type')->load($operation->getData($field))->getId() ? Deep::getModel('deep_service/type')->load($operation->getData($field))->getName() :'' ;
		    }else{
		        $value = $operation->getData($field);
		    }
		        echo $value;
		    ?>
		    </td>	    
<?php endforeach; ?>
</tr>
<?php endforeach; ?>
 
</table>
</body>

  <!-- Report’s footer -->
    <footer class="footer">
        <?php echo Deep::helper('deep_report')->__('Powered by DeepDesk'); ?>
        <span class="page-number">Page </span>
    </footer>
				
			

Scheduled Report 

 Scheduled Reports are reports that are sent by email periodically through a cron expression. To configure a scheduled report you should go under “System->Report-> Scheduled Report” and click on the ‘Add Scheduled Report’ button. 

By clicking on “Add Scheduled Report” button you can create a scheduled report. 

Below there is an example of a scheduled report that sends an email with the Invoice Report attached, every first day of the month. 

Below is a description of the available fields: 

Field 

Description 

Name 

With this field you can set the Scheduled Report’s name. 

Report 

Select field where you can select a configured report that will be used as the scheduled report. 

Cron Expression 

On this field you can set the time period on which the report will be sent. 

Send To 

Text field where you can set the email addresses divided by ‘;’ that will receive the report. 

Message Subject 

Custom code expression field where you can set the email subject in html format, the same format used as in email template. 

Message Body 

Custom code expression field where you can set the email message body in html format, the same format used as in email template. 

Mailbox Id 

Select field where you can choose the mailbox from which the email will be sent. 

Email Template 

Select field where you can choose the email template that will be used for this email. When selecting an email template, the ‘message subject’ and ‘message body’ fields will be ignored. 

Status 

With this field you can ‘enable’ or ‘disable’ the scheduled report. 

Was this guide helpful? Yes No

Share this Doc

Report Configuration

Or copy link

Clipboard Icon
CONTENTS
Leaf Illustration

Deepser srl
Via Luigi Dalla Via 3/B,Torre A, piano 7, int. 12
36015 Schio (VI), Italy

© Deepser. All right reserved.

Privacy Policy
Terms of Service