Merge branch 'dev' into 'master'

Dev

See merge request !179
master
Andrey 8 years ago
commit a1f12c9d28
  1. 10
      finance/views.py
  2. 2
      requirements.txt

@ -1,6 +1,7 @@
import csv
import logging
import datetime
import dicttoxml
import requests
from django.contrib.auth import get_user_model
@ -241,15 +242,16 @@ class YandexCheckView(APIView):
# TODO Нужно решение
# pay.invoice_id = int(data['invoiceId'])
# pay.save()
logger_yandex.info('Send success pay with invoice_id(yandex) %s' % str(data['invoiceId']))
return Response({
xml_res = dicttoxml.dicttoxml({
'code': 0,
'shopId': pay.shop_id,
'invoiceId': data['invoiceId'],
'orderSumAmount': pay.order_amount,
'performedDatetime': datetime.datetime.now(),
}, status=200)
})
logger_yandex.info(xml_res)
return xml_res
class YandexAvisoView(APIView):

@ -16,6 +16,8 @@ raven==6.2.1
requests==2.18.4
Unidecode==0.4.21
PyJWT==1.5.3
dicttoxml==1.7.4
gunicorn==19.7.1
# testing
flake8==3.5.0

Loading…
Cancel
Save