Bläddra i källkod

修改后台每日对账接口

peng 1 år sedan
förälder
incheckning
1c137ca9e5
1 ändrade filer med 3 tillägg och 0 borttagningar
  1. 3 0
      Controller/Cron/CronTaskController.py

+ 3 - 0
Controller/Cron/CronTaskController.py

@@ -1499,6 +1499,7 @@ class CronComparedDataView(View):
     @staticmethod
     @staticmethod
     def compared_ansjer_order(request_dict, response):
     def compared_ansjer_order(request_dict, response):
         start_date_stamp = request_dict.get('time', None)
         start_date_stamp = request_dict.get('time', None)
+        end_time = request_dict.get('end_time', None)
         if start_date_stamp:
         if start_date_stamp:
             start_date = datetime.datetime.fromtimestamp(int(start_date_stamp))
             start_date = datetime.datetime.fromtimestamp(int(start_date_stamp))
             end_date = start_date + datetime.timedelta(days=1)
             end_date = start_date + datetime.timedelta(days=1)
@@ -1511,6 +1512,8 @@ class CronComparedDataView(View):
             start_date_stamp = int(start_date.timestamp())
             start_date_stamp = int(start_date.timestamp())
             end_date_stamp = int(end_date.timestamp())
             end_date_stamp = int(end_date.timestamp())
         try:
         try:
+            if end_time:
+                end_date_stamp = end_time
             order_qs = Order_Model.objects.filter(status__in=[1, 5, 6], payType=1, payTime__gte=start_date_stamp,
             order_qs = Order_Model.objects.filter(status__in=[1, 5, 6], payType=1, payTime__gte=start_date_stamp,
                                                   payTime__lt=end_date_stamp).values('orderID', 'trade_no', 'price')
                                                   payTime__lt=end_date_stamp).values('orderID', 'trade_no', 'price')
             if CONFIG_INFO == CONFIG_EUR:
             if CONFIG_INFO == CONFIG_EUR: