Documents Module

Documents Module

The main mission of the Documents module is to provide you with a unique possibility to 'merge' documents through a built-in integration with Microsoft Word.

Additionally, the Documents module is designed to be a simple and efficient solution to store scanned copies of documents and any other types of files to which you want to have quick access from the Adonis Personnel Manager i.e. Policies, Cheat-Sheets and other vital information you wish to share with the employee. Hyperlinks to external sources, like SharePoint or other repositories may be embedded in the .pdf files you choose to distribute.

For the Word documents merge, you can export/send any kind of personal information using templates in Word format to a big number of crew members instead of working with every document separately (for example invitation letters, contracts, visa letters, etc.). You need only have a word template with common text (hardcoded) and the system will fetch various kinds of personal/employment data for every crewmember from Adonis.


Housekeeping

Configure Document Codes

Document codes allow creating separate folders for storing documents.

To configure a document code:

  1. Navigate to Setup > General Codes > Enclosed Documents > Enclosed Documents Codes.

  2. On the toolbar, click New.

  3. In the General Code Editor (Enclosed Document Codes) dialog, fill in the fields:
    3.1. In Code, enter a unique alphanumeric APM code.
    3.2. Click documents_module_enclosed_document_code_filter_records.png to control the availability of the code for a specific organization. In the Filter this code for organization dialog, clear the organizations for which you want to exclude the code.

    documents_module_enclosed_document_code_filter_records_dialog.png


    3.2. In Sort, enter a number to determine the position of a record, where 0 indicates the first record in the list.
    3.3. In Is Passive, specify whether the record is active or passive. When the option is selected, the record is active. When the option is cleared, the record becomes passive and it is displayed as disabled.
    3.4. In Security Code, enter a number larger than 0 to define the permission levels to the record.
    3.5. In Text, enter the name of the folder where documents will be stored.
    3.6. In Alternative, enter the alternative name of the folder in which you want to organize documents.
    3.7. From the APP Modules dropdown list, select the APP modules where you want to use the current document code.
    3.8. On the Options tab, specify the APM component where you want to use the document code: Documents Module: The document is available in the Documents module as a group of Merge documents
    Enclosed Documents Datagroup,
    Available In the section defines if: 

    a document is displayed in the Documents module as a group of Merge documents – Documents Module option;

    a document is used only for/in Enclosed Documents data group (to add scan of passport or visa) – Enclosed Documents Datagroup option;

    but if you want not only to merge and send the document but also distribute it (attach to persons enclosed documents) – you need Both options.
    Both: Allows you to merge, send, and distribute documents.
    3.7. Click OK to save the changes.

If the Security Code is set to a numeric value other than 0, different user levels can be assigned the Read, Write, or None access to the view. The administrator can manage this in Adonis Control Centre > General Codes > Enclosed Documents > Enclosed Documents Codes.

 

Alternatively, you can control the availability of document codes for certain organizations under the Organization Structure:

  1. Navigate to Setup > Organization Structure.

  2. In Structure, double-click an organization to open its properties.

  3. Navigate to Org. Properties > General Codes > Enclosed Document Codes.

  4. Select or clear the checkbox to make the code available or unavailable for the organization.

    documents_module_enclosed_document_code_filter_records_organization_structure.png
documents_module_enclosed_document_code.png

As a result, a new code appears in the Enclosed Documents Codes list.

documents_module_enclosed_document_code_added_code1.png

 

Configure Method of Storing Documents

To select the method for storing documents:

  1. Navigate to Setup > Global Options > Datagroups > Enclosed Documents > General tab.

  2. Under How To Store Enclosed Documents, select one of the options:

  • Attach - Store Document in Database: Documents are stored in a database. You can specify the Maximum Document Size (KB) that you want to store in a database.

  • Link - Store Document on File Server: Keeps document on a server. You can specify the document locations. Click the ellipsis (…) in the respective Mail Merge and Scans fields and select the required folder.

  1. Under Scan Setup, select the file format for storing documents: PDF, JPEG/JPG.

  2. Under Mail Merge: E-mail and distribute word documents as pdf (office 2010 only)

  3. Click OK to save the changes.

Attach - Store Document in Database allows replicating documents in Replicator

Configure E-signature Web service connection

To configure connection to the Signature web service:

  1. Navigate to Setup > Global Options.

  2. In the Global Options dialog, select Import\Export > Web Service.

  3. Under E-signature, enter the connection details:

    • URL: Enter the URL to the Signature web service.

    • E-sign API Password: Enter the API password.

    • Read Time Out (ms): Enter the time in milliseconds after which the connection to the service will time out.

  4. Optional: Click Test to verify the configuration.

  5. Click OK to close the dialog.

global_options_web_service.png

Ensure the same connection details are available in Adonis Administrator Portal.

Functionality

The Documents module allows you to organize all types of scanned documents, create groups, and link them to individual data records (e.g. such as a passport/certificates).
It also allows you to scan other image files and attach them to each person (to the Enclosed data group) using Distribute option.
There are advanced tools to pick up scans directly from e-mail or a folder and preview, before selecting the record it will be attached to.
With this module, it is also possible to create and add merge templates in MS Word, bookmark and add fields for automatic report generation in MS Word.
Merging is done automatically for all tagged persons in the current crew list, one or many.
You can open the Documents module either by selecting

the icon on the Modules ribbon or pressing Ctrl+Alt+D hotkeys.

 To have access and work there, you should have corresponding rights set for routine 301 Documents (302 Distribute, 303 Merge, 304 Merge Properties) in ACC.


The standard work-flow for merging:

  1. Create a Word template with needed bookmarks.

  2. Link it to the record in the Documents module.

  3. Use Merge Properties and Fast Query Builder to choose view/table, select fields, generate script, and define aliases for the merge document.

  4. Tag some persons in the Crew List whose data you want to merge into the Word document. 

  5. Go to the Documents module > select needed group and record > click Merge button under Manage menu > set options. 



 Let's consider these steps in detail below.

Add Document

  1. Open the Documents Module.

  2. Under All Documents, select the group to which you want to add a document.

  3. On the toolbar, click New.

  4. In the Document dialog, follow the steps below.
    4.1. Fill in the fields:

    • Description

    • Document type

    • Keywords

4.2. Select an option:

  • Click New and

To start merge, please open the Documents module. A list of all available documents for merge will appear.
By clicking one of the groups in the tree structure to the left, only the documents belonging to that particular group will appear.

  • Various document groups are defined by the company administrator in General Codes (see Housekeeping section).

New Merge documents may be added to each group at any time. There is no limit to the number of documents that can be added.
Click the New button under the Manage menu to create a new record/document.

  • It's available only when you choose a certain group.

When All Documents mode is selected, it is not possible to create a new document or modify an existing one.
A Document window appears:

The Document type corresponds to the selected group name.

You may add a Description to easily distinguish between a large number of templates.

Keywords field can be used for various notes.
To create a note put the cursor on the field, in the right-click menu choose New, a window where you can type any comment will appear. Type the comments & click OK to save.
Several lines of comments can be added.
It's possible to delete or edit them. You need to select a comment and choose the necessary option from the right-click menu.

Click

and locate the word template that was prepared for this record beforehand (see How to Prepare Bookmarks in a Word Document in the section below).

 Options:

Merge Properties (see Define Merge Properties by Fast Query Builder section).

Attachment Properties, click to see the file name, size, location, time of creation, etc.

Mail Properties – from ver. 2018.3, we introduce a new option that allows you to customize email subject & email text when a merged document is generated using Email Merge Output.

Bookmark Setup (see Pre-Editing of Bookmarks section).

Click

to edit the template.
This will open Microsoft Word and load the template automatically. Now you may change the content of the template to what is required. When you are done, save the changes.

  • You cannot edit records under the All Documents folder if you are using Attach option for storing documents.

    The records are read-only in this case.
    Save To File allows you to save the linked document to your hard drive




Click OK to save the new document record.



How to Prepare Bookmarks in Word Document

When working with a Merge Word template, we advise you to turn on the Show bookmarks option (File > Options > Advanced > Show document content > Show bookmarks):


In our example, we will create a new Word document with proper bookmarks.
The document will contain basic information about a person (Name, Rank, Address, and Phone).

  1. Step 1: Create a new Word document:


  2. Create some text in it, for example, we need to prepare an invitation to the annual officers meeting without variable information like name, address, rank. This information will be merged into the document automatically.

  3. Place bookmarks for each separate piece of information 

    We advise you to type a needed field name, then double-click it and select the Insert > Bookmark.
    Under Bookmark name, you should type a field/bookmark name (e.g.: Address2), then click Add.


    Bookmark names should begin with a letter and can contain numbers.

    You can't include spaces in a bookmark name. But, you can use the underscore to separate words (e.g.: First_Name).

    It is not necessary to use the same bookmark names as the field names in APM, you may use Aliases.

    Later you just need to type your alias under the Bookmark column in front of the correct field name In Query Builder (see Defining Merge Properties by Fast Query Builder section).

    It is possible to define the same predefined bookmark several times in the output document. For example, if you need to define a user's first name several times in the document, then you should add bookmarks into the output document as bkUserFirstName_1, bkUserFirstName_2, bkUserFirstName_N, etc., and then add them to the script manually during setting Merge Properties (see Defining Merge Properties by Fast Query Builder section).

    The text enclosed in grey brackets represents bookmarks.


Create other bookmarks in the same way. You need to add a bookmark for each data field you want to merge into the document.
If you are using three fields for the addresses, you need to define three bookmarks, one for each address field (as in our example).
If there is no information to be placed into a corresponding bookmark, a space will be put.

Defining Merge Properties by Fast Query Builder

You need to check the Merge Document box to indicate that your document is a merged one.
Click Options > Merge Properties to add an SQL statement/script:

You can write the script yourself or use Query Builder Designer.
By clicking the Query Builder button, you may easily generate the SQL query statement to use for merging:

  1. The tables appearing on the right are sorted alphabetically. You should move down to find the needed table/view and double-click it. 

    For our case, we need to find the SRV views.

    We are using a database table (view) called PW001SRV0, which corresponds to the content of the Standard Crew List. A view is a virtual table that usually contains data from several database tables. It may be easier to use one of the crew list views than use a standard table, making it much easier to select numerous fields from one view.
    e.g.: PW001SRV1 corresponds to Current Activity view, PW001SRV2 - Last Appraisal view.



  2. The fields of the selected table or view will appear in a small box to the left. 

    You should tag the corresponding fields you will use for Merge.








  3. As soon as you tag a field, it will appear in the left column of the grid.
    The last step is to type the Alias for each field in the Bookmark column, exactly as it is written as a bookmark in your Word document if they differ.
    Currently, you are at the Model tab.
    You may check the script by choosing the SQL tab:


    And the result of the SQL statement by choosing the Result tab.
    To save your merge properties, click
    button.
    The menu also allows:
    - to load from file.
    - to save to file.
    - to clear the selections.
    - to cancel script building.



It is possible to define the same bookmark several times in the output document.


For example, if you need to define a crew member's name several times in the document, then you should add bookmarks into the Word template as Name_1, Name_2, etc.
And then add them to the script manually during setting Merge Properties:


When a Word template is loaded to the Merge record, you can at any time open it and make any changes in the text.

If you change the bookmarks in any way, you need to make sure that the merge properties are changed accordingly.



Pre-Editing of Bookmarks

It is possible to check existing bookmarks & manually modify them before merging a document.
This gives to end-user more flexibility compared to a static set of data that is returned by the SQL query.
It is very useful for situations when some information is not stored inside the Adonis database but should be added to a merged document.
It cannot be extracted but you want to add it manually, e.g. your company's comments for a certain position (when offering vacancy) or others.
Open ready merge document, click Options > Bookmark Setup, Bookmark Setup Form appears.
Setup
You can select to upload all bookmarks that exist in the enclosed document or you can add them one by one as per necessity, using Insert/Delete buttons:

Bookmark displays the name of the bookmark as it exists in a merged document.
Label. Type the name of a bookmark to be shown on the Pre-edit screen.
Editable. The state of this checkbox defines whether the label will be available on the pre-editing screen or it will be ignored & the value will be fetched from the database.
The order defines the order of appearance for bookmarks on the Pre-edit screen.
The hint is the text that will be displayed for a tagged bookmark on the Pre-edit screen.

Please note that some bookmarks are mandatory. They can be also uploaded to the list, but they are shown grey & cannot be set Editable as this will break the logic of the query.



Pre-Editing
Once you've set up all the necessary bookmarks, you can close the dialog window & start merging a document.
The box will display all bookmarks with the corresponding setup:

  1. Bookmarks list defined for pre-editing.
    Labels are shown instead of bookmark names.


  2. The default value is fetched by the query.
    You can input a value to any editable empty bookmark.
    Or you can modify the value fetched by the query & this will override the result shown in the merged document.

  3. Hint for the tagged bookmark.



You can set up bookmarks for every person tagged in the list, just click the Next/Previous Person buttons.

These buttons are enabled if you selected several needed persons in the Crew List and choose any selection option except Selected Person in Merge Output Form.

  • Predefined bookmarks (bkUserPhone, bkUserEMail, bkUserSignature, bkUserPosition, bkFirstname, bkLastname) are disabled in Setup form.

It's not possible to redefine the value for such bookmarks when merging (see Predefined Bookmarks section).
After you're are done, you can follow by merging the document.

Document Merging

The result can look like this:


Tag person(s) in the Crew List whose data you want to export.
Locate the correct merge document in the Documents module and click the

button:

In the window that appears, choose one of the Selection options:

  •  

    • Selected Person;

    • Entire Crew Selection;

    • Tagged Persons (you need to tag the persons you want to merge the doc. in Crew List before merging);

    • UnTagged Persons (all persons who are not tagged in the crew list).


Choose a Merge Output option:

  • Send to the default printer - the merged document is sent directly to the printer without previewing it in MS Word;


  • Send to common Word document- the document appears as an open document in MS Word, from where it may be printed later;


  • Save to separate file(s) - the document will be saved as a .doc file.

    In this case, please specify a file name and select a directory on your hard drive you want to save the document in;


  • E-mail - the doc. will be sent to the selected crew member(s) using his e-mail address in the Personal Details data group (see Mail Properties the section below).


Distribute the option is separated from Merge output and can be selected in addition.
When this option is checked, the merged document is added to the Enclosed documents of a person with the Test code.

  • Depending on the state of the global option Merge: E-mail and distribute word documents as pdf (office 2010 only) the document can be saved as an MS Word document or as a pdf file.


  • When the option is selected, merge documents can be sent as pdf files, and the distributed file is added to Enclosed documents as .pdf, too (if the user has Microsoft Office 2010 installed). If the option is not set, the document is sent as word documents (doc., Docx files).


When you are ready, click OK.
The pre-merge form will appear if the merged document contains any Bookmark Setup (see Pre-Editing of Bookmarks section).



Mail Properties

From ver. 2018.3, We introduce a new option for Mail Properties which allows you to customize email subject & email text when a merged document is generated using Email Merge Output:

  1. Open a merge document Options > Mail Properties


  2. Input customized text for email subject & body.
    Note that you can use any of the fields which are returned by Merge SQL, wrapping them into [] symbols, e.g. [PIN], [FIRSNTAME] & those will be fetched accordingly.


  3. Merge a document with the Email Merge Output option.
    Customized subject & body will be used for the generated & sent email.



Predefined Bookmarks

Adding User Data to Merge Document

There is a possibility to fetch any of the following user-related information from the user account properties to the merged document:

  • First/Last Name;

  • Position;

  • Office address;

  • Phone;

  • E-mail;

  • Signature.


The result can look like below:



First, the corresponding data should be added to the user profile in the ACCESS > Defining User Profile > More section.

OR
In APM > Backstage View

> View Profile: