|
@@ -173,10 +173,10 @@ namespace TEAMModelBI.Controllers.BINormal
|
|
|
|
|
|
foreach (var item in teachers)
|
|
|
{
|
|
|
- var tchSchool = item.schools.Find(f => f.schoolId.Equals($"{schoolId}") && f.areaId.Equals($"{areaId}"));
|
|
|
+ var tchSchool = item.schools.Where(f => f.schoolId.Equals($"{schoolId}")).FirstOrDefault();
|
|
|
if (tchSchool != null)
|
|
|
{
|
|
|
- item.schools.Remove(tchSchool);
|
|
|
+ tchSchool.areaId = "";
|
|
|
await cosmosClient.GetContainer("TEAMModelOS", "Teacher").ReplaceItemAsync<Teacher>(item, item.id, new PartitionKey("Base"));
|
|
|
}
|
|
|
}
|