Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

getTonerData() function doesn't handle Hex-STRING values #81

Open
eduardomozart opened this issue Nov 23, 2020 · 0 comments
Open

getTonerData() function doesn't handle Hex-STRING values #81

eduardomozart opened this issue Nov 23, 2020 · 0 comments

Comments

@eduardomozart
Copy link
Contributor

eduardomozart commented Nov 23, 2020

  • Version of the plugin : 1.7.0

  • Version of your GLPI : 9.5.2

  • Steps to reproduce (which actions have you made) :

  1. Go to "Tools" > "Printer counters".

  2. Click on "Record models".

  3. Select the record model from HP Laserjet M551 printer

  4. Set "Enable toner level" to "Yes".

  5. Goto "Assets" > "Printers".

  6. Click on HP Laserjet M551 printer

  • Expected result :

It should show the cartridge name and the percentage bar with the specific cartridge color, as below:

2020-11-23 13_14_42-Greenshot

  • Actual result :

But it's actually return Hex-STRING values and the progress bar has no color at all:

2020-11-23 13_15_02-Greenshot

It happens because the getTonerData() function doesn't handle Hex-STRING values and HP Laserjet M551 printer return the cartridge type ('black', etc.) and name as Hex-STRINGS. I sent a Pull Request with a possible fix.

  • URL of the page :
  • Screenshot of the problem (if pertinent) :
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant