【修复】修复没有检查容器中bean类型数据的子数据的bug
parent
38b410f0a5
commit
eb34a4cb7f
|
|
@ -75,6 +75,20 @@ namespace Luban.Job.Cfg.DataVisitors
|
|||
_path.Pop();
|
||||
}
|
||||
}
|
||||
|
||||
if (elementType is TBean)
|
||||
{
|
||||
int index = 0;
|
||||
foreach (var value in eles)
|
||||
{
|
||||
_path.Push(index++);
|
||||
if (value != null)
|
||||
{
|
||||
elementType.Apply(this, value);
|
||||
}
|
||||
_path.Pop();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void Accept(TBool type, DType x)
|
||||
|
|
@ -219,13 +233,28 @@ namespace Luban.Job.Cfg.DataVisitors
|
|||
if (v is IValidator eleVal)
|
||||
{
|
||||
eleVal.Validate(Ctx, valueType, e.Value);
|
||||
valueType.Apply(this, e.Value);
|
||||
if (e.Value != null)
|
||||
{
|
||||
valueType.Apply(this, e.Value);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
_path.Pop();
|
||||
}
|
||||
}
|
||||
if (valueType is TBean)
|
||||
{
|
||||
foreach (var e in ((DMap)x).Datas)
|
||||
{
|
||||
_path.Push(e.Key);
|
||||
if (e.Value != null)
|
||||
{
|
||||
valueType.Apply(this, e.Value);
|
||||
}
|
||||
_path.Pop();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void Accept(TVector2 type, DType x)
|
||||
|
|
|
|||
Loading…
Reference in New Issue