Fix validazione preliminare liste parametri
This commit is contained in:
@@ -50,7 +50,6 @@ namespace WebWindowComplex.DTO
|
||||
/// <returns></returns>
|
||||
public bool IsValid()
|
||||
{
|
||||
//bool templateOK = TemplateDTO != null && TemplateDTO.Count > 0;
|
||||
bool famHwOK = FamilyHardware != null && FamilyHardware.Count > 0;
|
||||
bool hwOK = Hardware != null && Hardware.Count > 0;
|
||||
bool glassOK = Glass != null && Glass.Count > 0;
|
||||
@@ -58,5 +57,18 @@ namespace WebWindowComplex.DTO
|
||||
bool colorOK = ColorMaterial != null && ColorMaterial.Count > 0;
|
||||
return famHwOK && glassOK && hwOK && colorOK && matOK;
|
||||
}
|
||||
/// <summary>
|
||||
/// Verifica che Payload sia almeno parzialmente popolato
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public bool IsPopulated()
|
||||
{
|
||||
bool famHwOK = FamilyHardware != null && FamilyHardware.Count > 0;
|
||||
bool hwOK = Hardware != null && Hardware.Count > 0;
|
||||
bool glassOK = Glass != null && Glass.Count > 0;
|
||||
bool matOK = Material != null && Material.Count > 0;
|
||||
bool colorOK = ColorMaterial != null && ColorMaterial.Count > 0;
|
||||
return famHwOK || glassOK || hwOK || colorOK || matOK;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user