diff --git a/DataVApi.Order/OrderProvider.cs b/DataVApi.Order/OrderProvider.cs index 7b0a670..6ac1ccd 100644 --- a/DataVApi.Order/OrderProvider.cs +++ b/DataVApi.Order/OrderProvider.cs @@ -89,8 +89,8 @@ WHERE var data = db.SqlQueryable(sql).ToList(); List res = new List(); - - for (int index = 10; index >= 0; index--) + int indexcount = input.Count.HasValue ? input.Count.Value : 10; + for (int index = indexcount; index >= 0; index--) { var temp = DateTime.Now.AddDays(-index); var end = DateTime.Parse(temp.ToString("yyyy-MM-dd 23:59:59")); diff --git a/DataVApi.Order/RequestModel/FullScreenBasic.cs b/DataVApi.Order/RequestModel/FullScreenBasic.cs index 8e6ad85..d62bf7b 100644 --- a/DataVApi.Order/RequestModel/FullScreenBasic.cs +++ b/DataVApi.Order/RequestModel/FullScreenBasic.cs @@ -16,5 +16,9 @@ namespace DataVApi.Order.RequestModel /// 设备Id /// public int? DeviceId { get; set; } + /// + /// 统计数量 + /// + public int? Count { get; set; } } } diff --git a/DataVApi.Order/RequestModel/FullScreenInput.cs b/DataVApi.Order/RequestModel/FullScreenInput.cs index c9601b2..96425e7 100644 --- a/DataVApi.Order/RequestModel/FullScreenInput.cs +++ b/DataVApi.Order/RequestModel/FullScreenInput.cs @@ -16,6 +16,5 @@ namespace DataVApi.Order.RequestModel /// 结束时间 /// public DateTime? End { get; set; } - } }