Ajout des fonctions d'impression des factures sur l'imprimante thermique
This commit is contained in:
parent
6b08464bfc
commit
2d4647e9bf
5 changed files with 133 additions and 11 deletions
|
@ -12,12 +12,12 @@ import config
|
|||
def run():
|
||||
conn = pika.BlockingConnection(config.PARAMS)
|
||||
ch = conn.channel()
|
||||
ch.queue_declare(queue='CransTicket')
|
||||
ch.queue_declare(queue='CransTicketDebug')
|
||||
def callback(ch, method, properties, body):
|
||||
print (" [x] Received %r" % (body,))
|
||||
dump.print_liste(json.loads(body))
|
||||
|
||||
ch.basic_consume(callback, queue='CransTicket', no_ack=True)
|
||||
ch.basic_consume(callback, queue='CransTicketDebug', no_ack=True)
|
||||
ch.start_consuming()
|
||||
conn.close()
|
||||
# fork en arrière plan + pidfile
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue