跳至内容
菜单
此问题已终结
1 回复
4777 查看

How to disable the PosBox Status printing everytime the posbox rebooted. It waste a lot of paper if everyday the system is rebooted.

The posbox status I mean the IP address and Homepage infiormation that printed automatically everytime we turn on the posbox.

形象
丢弃
最佳答案

Looks like all you have to do is comment it out and put in a pass statement (in bold below):

(excerpt from file on the posbox: /home/pi/odoo/addons/hw_escpos/controllers/main.py -Line 177 has call to comment)

Make sure to indent the pass with 4 spaces to align with old function call position.

elif task == 'xml_receipt':
if timestamp >= time.time() - 1 * 60 * 60:
printer.receipt(data)
elif task == 'cashbox':
if timestamp >= time.time() - 12:
self.open_cashbox(printer)
elif task == 'printstatus':
#self.print_status(printer)
pass

elif task == 'status':
pass
error = False


形象
丢弃
编写者

It works.... thank you.

相关帖文 回复 查看 活动
0
2月 21
2764
3
10月 17
5756
0
11月 15
4482
1
8月 24
7468
1
12月 19
4567