mateusznitka / protocolsmanager

GLPI Plugin to report users inventory
8 stars 13 forks source link

Generated document and unit #26

Closed Nomino-pl closed 3 years ago

Nomino-pl commented 3 years ago

With a larger number of units (companies) there is a problem - the document is assigned to the unit we are currently on, and not to the one to which the user for whom we generate the protocol is assigned. In the example: There is Company A, Company B, and both in the main Root branch. There is User1 assigned to company (unit) A, and employee Employee1 assigned to Root and all children. If Employee1 will work on the Root + slave unit, then when generating the protocol for User1, it will be added to the Root unit. To keep order, it should add to unit A. The unit for the protocol should be taken from the unit that the user has access to, or the default user unit if he has access to more than one company.

Nomino-pl commented 3 years ago

Corrected :)