/// <summary> /// 班组活动统计 /// </summary> /// <param name="deptId"></param> /// <returns></returns> public Dictionary <string, int> GetACMonthCount(string deptId) { var time = DateTime.Now; var startTime = new DateTime(time.Year, time.Month, 1); var endTime = startTime.AddMonths(1).AddMilliseconds(-1); var queryJson = "{\"startTime\":\"" + startTime + "\",\"endTime\":\"" + endTime + "\",\"deptId\":\"" + deptId + "\",\"State\":\"Finish\",\"haveEvaluate\":\"0\"}"; Pagination pagination = new Pagination() { page = 1, rows = 100000 }; //业务分类有安全日活动|政治学习|民主管理会|班务会|其他 Dictionary <string, int> result = new Dictionary <string, int>(); var data = _aCService.GetAcJobCount(pagination, queryJson); var aqrhd = data.Count(x => x.ActivityType == "安全日活动"); result.Add("安全日活动", aqrhd); var zzxx = data.Count(x => x.ActivityType == "政治学习"); result.Add("政治学习", zzxx); var mzglh = data.Count(x => x.ActivityType == "民主管理会"); result.Add("民主管理会", mzglh); var bwh = data.Count(x => x.ActivityType == "班务会"); result.Add("班务会", bwh); var qt = pagination.records - (aqrhd + zzxx + mzglh + bwh); result.Add("其他", qt); return(result); }