Browse Source

wpint: be more specific about what we're logging

master
Harald Welte 5 months ago
parent
commit
df04434e5d
  1. 4
      inema/wpint.py

4
inema/wpint.py

@ -232,12 +232,12 @@ class WarenpostInt(object):
def api_create_order(self, items, contact_name, order_status='FINALIZE'):
"""Issue an API request to create an order consisting of items."""
order = self.build_order(items, contact_name=contact_name, order_status=order_status)
_logger.info("Order: %s", order)
_logger.info("Order Request: %s", order)
r = self.request('POST', 'orders', json = order)
# TODO: figure out the AWB and the (item, barcode, voucherId, ...) for the items
json_resp = r.json()
#print(json.dumps(json_resp, indent=4))
_logger.info("Response: %s", json_resp)
_logger.info("Order Response: %s", json_resp)
# TODO: download the PDF for each AWB
return json_resp

Loading…
Cancel
Save