|
@@ -360,8 +360,8 @@ namespace TEAMModelOS.Controllers.Analysis
|
|
{
|
|
{
|
|
studentIds.Add(x.id);
|
|
studentIds.Add(x.id);
|
|
x.classId = classId;
|
|
x.classId = classId;
|
|
- x.className = classroom.name;
|
|
|
|
- x.gradeId = classroom.gradeId;
|
|
|
|
|
|
+ x.className = examClassResults.FirstOrDefault(e => e.info.id.Equals(classId)).info.name;
|
|
|
|
+ x.gradeId = examClassResults.FirstOrDefault(e => e.info.id.Equals(classId)).gradeId;
|
|
var stu = stus.Where(s => s.id == x.id).FirstOrDefault();
|
|
var stu = stus.Where(s => s.id == x.id).FirstOrDefault();
|
|
if (stu != null)
|
|
if (stu != null)
|
|
{
|
|
{
|
|
@@ -419,7 +419,7 @@ namespace TEAMModelOS.Controllers.Analysis
|
|
//var pow = Math.Pow(powSum / stuCount, 0.5);
|
|
//var pow = Math.Pow(powSum / stuCount, 0.5);
|
|
ClassAys classAys = new ClassAys
|
|
ClassAys classAys = new ClassAys
|
|
{
|
|
{
|
|
- gradeId = classroom.gradeId,
|
|
|
|
|
|
+ gradeId = examClassResults.FirstOrDefault(e => e.info.id.Equals(classId)).gradeId,
|
|
year = classroom.year,
|
|
year = classroom.year,
|
|
studentIds = studentIds,
|
|
studentIds = studentIds,
|
|
stuCount = stuCount,
|
|
stuCount = stuCount,
|
|
@@ -1228,7 +1228,7 @@ namespace TEAMModelOS.Controllers.Analysis
|
|
double rhwCount = Math.Floor(resultSum.Count * 0.27);
|
|
double rhwCount = Math.Floor(resultSum.Count * 0.27);
|
|
double rhw = rhwCount > 0 ? resultSum[int.Parse(rhwCount.ToString("0"))] : 0;
|
|
double rhw = rhwCount > 0 ? resultSum[int.Parse(rhwCount.ToString("0"))] : 0;
|
|
double rhlCount = Math.Ceiling(resultSum.Count * 0.73);
|
|
double rhlCount = Math.Ceiling(resultSum.Count * 0.73);
|
|
- double rhl = rhlCount > 0 ? resultSum[int.Parse(rhlCount.ToString("0"))-1] : 0;
|
|
|
|
|
|
+ double rhl = rhlCount > 0 ? resultSum[int.Parse(rhlCount.ToString("0")) - 1] : 0;
|
|
|
|
|
|
//初始化年级总分
|
|
//初始化年级总分
|
|
double total = 0;
|
|
double total = 0;
|
|
@@ -1629,7 +1629,8 @@ namespace TEAMModelOS.Controllers.Analysis
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
- public async Task<string> getGId(int cyear,string periodId,string code) {
|
|
|
|
|
|
+ public async Task<string> getGId(int cyear, string periodId, string code)
|
|
|
|
+ {
|
|
var client = _azureCosmos.GetCosmosClient();
|
|
var client = _azureCosmos.GetCosmosClient();
|
|
School sc = await client.GetContainer(Constant.TEAMModelOS, "School").ReadItemAsync<School>(code, new Azure.Cosmos.PartitionKey("Base"));
|
|
School sc = await client.GetContainer(Constant.TEAMModelOS, "School").ReadItemAsync<School>(code, new Azure.Cosmos.PartitionKey("Base"));
|
|
string gradeId = "";
|
|
string gradeId = "";
|