[FIX] hw_drivers: Fix printer unknow in PrinterDriver
We add a condition to add printer. Printer, for protocol DNSSD and LPD, must have a "model" closes odoo/odoo#41591 X-original-commit: a07f118fc7182fa96344fad4a0164ed86c446352 Signed-off-by: Quentin Lejeune (qle) <qle@odoo.com>
This commit is contained in:
@@ -93,7 +93,7 @@ class PrinterDriver(Driver):
|
||||
@classmethod
|
||||
def supported(cls, device):
|
||||
protocol = ['dnssd', 'lpd']
|
||||
if any(x in device['url'] for x in protocol) or 'direct' in device['device-class']:
|
||||
if any(x in device['url'] for x in protocol) and device['device-make-and-model'] != 'Unknown' or 'direct' in device['device-class']:
|
||||
model = cls.get_device_model(device)
|
||||
ppdFile = ''
|
||||
for ppd in PPDs:
|
||||
|
||||
Reference in New Issue
Block a user