Office +1 (678) 666-2100
Fax: +1 (678) 666-1997

Search:

Installation and Setup of Field Level and Data Security on NAV 2013 and later

Before starting the installation please review the Best Practices for NAV Easy Security setup

Field Level and Data Security is not a replacement for regular permissions in Microsoft Dynamics NAV but adds additional levels of security. NAV Easy Security - Logins and Permissions or manual editing must be used for dealing with the maintenance of Users and Permission Sets in standard NAV. Without a proper setup of regular permissions some things can be bypassed by an experienced user.

The setup should be performed by a person familiar with page design. If the customer is not maintaining or developing their own customizations, a partner should always be performing the implementation of Field Level and Data Security.

Importing Objects



If Easy Security - Logins and Permissions has already been implemented, then the source code analysis of the objects has already been imported. In that case, proceed to Installation and Code Modification.

Objects are imported in the Development Environment, Object Designer. The objects for NAV Easy Security are all new objects. This simplifies integration with a customized database because objects can be imported without overwriting existing objects. The objects are distributed in 2 files "ES1.xx.xx y.yy.yy.fob" and "ESACC Empty Objects ES1.xx.xx.fob".

The latter should only be imported when initially installing Easy Security, because the application generates code in these objects to accommodate setup and so they should not be overwritten. For future upgrades only the first file should be imported. The version y.yy.yy refers to the executable version used by the customer.



If the MenuSuite used by Easy Security (1052) is already in use by the customer, additional menuSuites may be imported from the file "ES1.xx.x MenuSuite 1051-1060.fob". Only import one MenuSuite. More detailed information is available at this link:

Installing a different MenuSuite

During the import of the objects, a warning may be shown about the code using an older version of NAV (based on hotfixes being applied). This is not a problem because the code is going to be recompiled to ensure the C# code matches the current executable.

After importing the objects, remember to compile all the objects within the filter Version List=ES*.



Language modules are available in Danish, Dutch, English, French, German, Italian, Portuguese and Spanish. To import the language module, filter on the Version List with the filter "ES*" and select all objects, then use Tools, Language Module, Import and select the needed language.



Some extra "empty" Codeunits needs to be imported from "ESACC Empty Objects ES1.xx.xx.fob" before modification of the objects. These Codeunits will be modified by the code modification process to contain certain functions and lookup data. This will be used when doing modifications in the future or doing setup in other companies for Field Level and Data Security.

Installation and Code Modification



Before starting the installation, export all the objects to a fob-file. This will ensure all changes can be reverted to the state before Field Level and Data Security was installed.

The company where security is installed and maintained should be a new company with limited data for the application. A common method setup method would be to create a new "Easy Security" company. If Easy Security - Logins and permissions has already been implemented, then the security company may have already been created.

After importing the objects, the steps below are required to get Field Level and Data Security installed and set up.

1: Additional permissions must be assigned to all non-Super users for Read to TableData 14123801 to 14123809, 14123817, 14123818 and Execute for Codeunit 14123801, 14123806, 14123811, 14123812, 14123814, 14123817, 1412381 and, 14123819. This can be accomplished by adding the permission in the permission set BASIC or FOUNDATION with a standard NAV permission setup.

2: If the Windows Client is open, close and reopen to refresh. Easy Security will appear on the Departments menu.



3: In the Easy Security company, Field Level and Data Security menu, select Setup, Field Level and Data Security Setup, then check the field "Install Allowed". Only one company in the database can have Install Allowed checked as this company contains the security setup and is considered the "parent" company for Field Level and Data Security.



5: Since import/export from code is not available in NAV 2013 or later, all tables and forms must be exported manually. This will require a partner developer license. From the Development Environment, Object Designer, filter on tables and pages.



6. Select File, Export and save the objects to a location on your hard drive or a network drive in text format.



7. After the export has completed, return to Field Level and Data Security Setup and enter the text file name in the Source Code File Name. If the following prompt appears, be sure to select Allow for this client session.



Use the "Functions, Get Relations from Source Code" to start the Source Code Analysis. If Easy Security - Logins and Permissions has already been implemented, the resulting Source Code Analysis can be used to reduce the implementation time.



8: Open the "Source Table Setup" and enter the tables for which field level security is required. It is better to start out with a few tables like 15 (G/L Account), 17 (G/L Entry), 18 (Customer), 21 (Customer Ledger Entry), 27 (Item), 36 (Sales Header) and 37 (Sales Line) because it is very easy to add additional tables later and the installation can be tested within a few minutes after finishing the install. Just remember that if tables are added later, a partner developer license will be required to export objects and to execute Implement Changes in Code. For further information, please see the following link:

How To Add Additional Tables to Source Table Setup in Field Level, Actions and Data Security



9: From the Field Level and Data Security Setup click on "Implement Changes in Code". This process will use the previously exported text file to apply the necessary code changes to forms based on the tables in Source Table Setup and write the resulting object changes to the "-out" file specified under Output File Name. Only those objects will be modified. A Function "Set DBM Table No." can also be used to filter the objects in the Development Environment so only the needed objects can be exported.



10. From the Development Environment, Object Designer, import the "-out" file specified in Output File Name in Field Level and Data Security Setup



After importing the objects they must be compiled.

11: Open the Object Designer and filter on object types Page or Codeunit (Page|Codeunit). Filter on Compiled = No, Date = today. Select all objects and compile.



Sometimes objects cannot be compiled based on code being wrong even if the object was originally compiled. Consult a programmer to figure out what the problem is. Field Level and Data Security should not create any errors in the code.

Field Level and Data Security has now been installed. The partner license is not required after this portion of the setup is completed. If additional tables need to be setup later, only steps 8-11 need be repeated but performing a complete install will not cause a problem. Only objects actually changed compared to the original source code will be in the output of the re-install process. This ensures as few objects as possible get modified.

The Codeunits 14123811 ES FLADS Get Editable, 14123812 ES FLADS Set Filters and 14123813 ES FLADS Lookup Data should not be replaced at any time with the original objects. These Codeunits contain code and data that is used by the Field Level and Data Security install engine. When moving objects from a test system to a live system, the 3 codeunits must also be included.

The codeunit 14123814 ES Dynamic Filter Customize is intended for customization of the Dynamic Filters by the customer or partner. This codeunit should not be replaced in future updates of the Easy Security objects.


Un-installing Field Level and Data Security



The code changes done by Field Level and Data Security can be uninstalled at any time. There normally should not be a reason to uninstall Field Level and Data Security during normal programming, but sometimes is it easier for programmers to work without other modifications and it can be done. Installation of Field Level and Data Security will always produce the same result with only the Date and Time of the object being changed.

To uninstall follow the steps below.

1: Export all objects to a fob file before continuing so that changes may easily be reverted.

2: From the Field Level and Data Security Setup click on "Delete Changes in Code". It is suggested to run the removal process on all objects. This is to ensure that even if the Source Table Setup was deleted the code is still removed properly. If the data is correct, only the modified objects can be exported to speed up the process. This must be done manually from Object Designer as in the previous steps. Be sure to change the Source Code File Name above as needed.



3: When the processing has finished the objects must be compiled. Open the Object Designer, filter on object types Page or Codeunit (Page|Codeunit). Filter on Compiled = No, Date = today. Select all objects and compile.

Sometimes objects cannot be compiled based on code being wrong even if the object was originally compiled. Consult a programmer to figure out what the problem is.
Field Level and Data Security should not create any errors in the code.
All the code changes have now been removed and only Date and Time should be changed in the objects.



Like   Don't Like

© 2017 Mergetool.com. All rights reserved.



Related resources

Download software from Mergetool.com