mirror of
https://github.com/OCA/report-print-send.git
synced 2025-02-16 07:11:31 +02:00
[IMP] send an already pushed document. handle exceptions differently for the client or internal call
This commit is contained in:
@@ -155,10 +155,15 @@ class Pingen(object):
|
||||
:param int/str color: type of print, 0 = B/W, 1 = Color
|
||||
:return: id of the post on pingen.com
|
||||
"""
|
||||
data = {
|
||||
'speed': speed,
|
||||
'color': color,
|
||||
}
|
||||
response = self._send(
|
||||
requests.post,
|
||||
'document/send',
|
||||
params={'id': document_id})
|
||||
params={'id': document_id},
|
||||
data={'data': json.dumps(data)})
|
||||
|
||||
return response.json['id']
|
||||
|
||||
|
||||
Reference in New Issue
Block a user