Commit 9021d490 by wyc

录入审核(添加合计)

parent 6be8cabb
......@@ -4806,6 +4806,11 @@
汇总
</summary>
</member>
<member name="P:Performance.DtoModels.GatherInfo.Total">
<summary>
合计
</summary>
</member>
<member name="P:Performance.DtoModels.Gather.UserId">
<summary>
用户Id
......
......@@ -19,6 +19,10 @@ public class GatherInfo
public int TotalPages { get; set; }
public int PageSize { get; set; }
public int TotalCount { get; set; }
/// <summary>
/// 合计
/// </summary>
public Dictionary<string, decimal?>[] Total { get; set; }
}
public class GatherDropResponse
......
......@@ -1700,14 +1700,20 @@ public GatherInfo GetGather(Gather gather)
t.Name = t.Name.ToLower();
});
GatherInfo gatherInfo = new GatherInfo()
var total = new Dictionary<string, decimal?>[]
{
new Dictionary<string, decimal?> { { gather.Category, datas.Sum(s => s.Fee) } }
};
var gatherInfo = new GatherInfo()
{
Heads = head,
Datas = result.Skip((gather.PageNumber - 1) * gather.PageSize).Take(gather.PageSize).ToList(),
CurrentPage = gather.PageNumber,
TotalCount = result.Count(),
PageSize = gather.PageSize,
TotalPages = (int)Math.Ceiling((double)result.Count() / gather.PageSize)
TotalPages = (int)Math.Ceiling((double)result.Count() / gather.PageSize),
Total = total
};
return gatherInfo;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment