InfotelGLPI / printercounters

Plugin Printercounters for GLPI
http://blogglpi.infotel.com
GNU General Public License v2.0
14 stars 9 forks source link

New pt-BR translation and Bugfixes #72

Closed eduardomozart closed 3 years ago

eduardomozart commented 3 years ago

Update search.class.php: See #69

Bugfix and pt-BR Translation: A pt_BR translation was added to the columns title of reports. There was a bug at printercountersreport4.en_GB.php that shows the title of the report as "Array" because it's translation variables was defined as an Array instead of Strings. The "%s1" and "%s2" variables was replaced by "%s" and "%s" because it was printing something like "Page number from 11-18-20201 to 11-18-20202" (note the "1" and "2" after "2020").

Update printercountersreport5.php: The printercountersreport5.php report was failing to generate when a printer has 2 or more Network Ports with the SQL error: "Subquery returns more than 1 row in query". It's possible a printer have 2 or more Network Ports. This bugfix uses the 'mainitemtype' column from 'glpi_ipaddresses' table instead of 'itemtype' from 'glpi_networkports' to select the row with the IP address of the printer.

New translations: Translated to pt_BR missing columns from reports.