mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Printer paper tray status and error states (#9859)
* adding paper tray status and error states * adding paper tray test data * Create jetdirect_papertray.json * Store printer supply type * Update json data * fix style
This commit is contained in:
@@ -78,4 +78,14 @@ class StringHelpers
|
||||
|
||||
return isset($replacements[$string]) ? $replacements[$string] : ucwords(str_replace(['_', '-'], ' ', $string));
|
||||
}
|
||||
|
||||
/**
|
||||
* Convert a camel or studly case string to Title case (with spaces)
|
||||
* @param $string
|
||||
* @return string
|
||||
*/
|
||||
public static function camelToTitle($string)
|
||||
{
|
||||
return ucwords(implode(' ', preg_split('/(?=[A-Z])/', $string)));
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user