def METHOD_NAME(self):
    """获取的订单统计数据"""
    def gen_bar_config(dt_list):
        success_order_count = [self._get_by_dt(dt).order_count for dt in dt_list]
        return {
            "title": f"总订单数量:{sum(success_order_count)}",
            "labels": [f"{date.month}-{date.day}" for date in dt_list],
            "data": success_order_count,
            "data_title": "每日订单数量",
            "x_label": f"最近{len(dt_list)}天",
            "y_label": "订单数量",
        }
    def gen_doughnut_config(dt_list):
        now = utils.get_current_datetime()
        today_amount = (
            sm.UserOrder.objects.filter(
                status=sm.UserOrder.STATUS_FINISHED,
                created_at__range=[
                    now.start_of("day"),
                    now.end_of("day"),
                ],
            ).aggregate(amount=models.Sum("amount"))["amount"]
            or "0"
        )
        total_amount = (
            sm.UserOrder.objects.filter(
                status=sm.UserOrder.STATUS_FINISHED,
                created_at__range=[
                    dt_list[0].start_of("day"),
                    dt_list[-1].end_of("day"),
                ],
            ).aggregate(amount=models.Sum("amount"))["amount"]
            or "0"
        )
        return {
            "title": f"总收入{total_amount}元",
            "labels": ["总收入", "今日收入"],
            "data": [
                int(decimal.Decimal(total_amount)),
                int(decimal.Decimal(today_amount)),
            ],
            "data_title": "收入分析",
        }
    def gen_line_config(dt_list):
        amount_data = [self._get_by_dt(dt).order_amount for dt in dt_list]
        return {
            "title": f"最近{len(dt_list)}天 总收益为{sum(amount_data)}元",
            "labels": ["{}-{}".format(t.month, t.day) for t in dt_list],
            "data": amount_data,
            "data_title": "收益",
            "x_label": f"最近{len(dt_list)}天",
            "y_label": "金额/元",
        }
    return {
        "bar_config": gen_bar_config(self.dt_list),
        "doughnut_config": gen_doughnut_config(self.dt_list),
        "line_config": gen_line_config(self.dt_list),
    }