Complete CCS results and rating flow
This commit is contained in:
@@ -58,6 +58,7 @@ public static class CcsCaseValidator
|
||||
errors.Add(prefix + "scoring criterion ids must be present and unique");
|
||||
foreach (var criterion in item.ScoringCriteria)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(criterion.Title)) errors.Add(prefix + $"criterion {criterion.Id} requires a title");
|
||||
var targets = criterion.TargetCodes.Count > 0 ? criterion.TargetCodes : [criterion.TargetCode];
|
||||
if (criterion.Points == 0) errors.Add(prefix + $"criterion {criterion.Id} points cannot be zero");
|
||||
if (targets.Any(string.IsNullOrWhiteSpace)) errors.Add(prefix + $"criterion {criterion.Id} requires a target code");
|
||||
|
||||
Reference in New Issue
Block a user