|
@@ -272,7 +272,13 @@ namespace TEAMModelOS.FunctionV4.CosmosDB
|
|
List<string> stus = new();
|
|
List<string> stus = new();
|
|
foreach (var lost in stuInfo)
|
|
foreach (var lost in stuInfo)
|
|
{
|
|
{
|
|
- stus = stus.Intersect(lost.stu).ToList();
|
|
|
|
|
|
+ if (stus.Count == 0)
|
|
|
|
+ {
|
|
|
|
+ stus = stus.Union(lost.stu).ToList();
|
|
|
|
+ }
|
|
|
|
+ else {
|
|
|
|
+ stus = stus.Intersect(lost.stu).ToList();
|
|
|
|
+ }
|
|
LostStudent lostStudent = new()
|
|
LostStudent lostStudent = new()
|
|
{
|
|
{
|
|
code = lost.code,
|
|
code = lost.code,
|
|
@@ -301,7 +307,14 @@ namespace TEAMModelOS.FunctionV4.CosmosDB
|
|
List<string> stus = new();
|
|
List<string> stus = new();
|
|
foreach (var (code, sub, stu) in stuInfo)
|
|
foreach (var (code, sub, stu) in stuInfo)
|
|
{
|
|
{
|
|
- stus = stus.Intersect(stu).ToList();
|
|
|
|
|
|
+ if (stus.Count == 0)
|
|
|
|
+ {
|
|
|
|
+ stus = stus.Union(stu).ToList();
|
|
|
|
+ }
|
|
|
|
+ else
|
|
|
|
+ {
|
|
|
|
+ stus = stus.Intersect(stu).ToList();
|
|
|
|
+ }
|
|
LostStudent lostStudent = new()
|
|
LostStudent lostStudent = new()
|
|
{
|
|
{
|
|
code = code,
|
|
code = code,
|