update for addorder and printer
This commit is contained in:
@@ -37,14 +37,15 @@ class Printer::PrinterWorker
|
||||
Cups.default_printer
|
||||
end
|
||||
|
||||
def print(file_path,printer_destination = nil )
|
||||
def self.printer_exists?(printer)
|
||||
Cups.show_destinations.include? printer
|
||||
end
|
||||
|
||||
def print(file_path, printer_destination = nil )
|
||||
if printer_destination.nil?
|
||||
printer_destination = self.printer_destination
|
||||
end
|
||||
|
||||
puts printer_destination
|
||||
puts '........Printer Destination..........'
|
||||
|
||||
copy = self.print_copies
|
||||
#Print only when printer information is not null
|
||||
if !self.printer_destination.nil?
|
||||
|
||||
Reference in New Issue
Block a user