I'm working in a content development scenario where entities are likely to be created in an incomplete state and remain incomplete for some time. The workflow involved is extremely ad-hoc, preventing me from using a more structured DDD approach.
I have a set of validation rules which must be satisfied at all times, and a further set of validation rules which must be satisfied before an entity is "complete".
I'm already using the built-in ASP.NET MVC validation to validate the former. What approaches could I use to capture the latter?
For example:-
public class Foo
{
public int Id { get; set; }
public virtual ICollection<Bar> Bars { get; set; }
}
public class Bar
{
public int Id { get; set; }
[Required] // A Bar must be owned by a Foo at all times
public int FooId { get; set; }
public virtual Foo Foo { get; set; }
[Required] // A Bar must have a working title at all times
public string WorkingTitle { get; set; }
public bool IsComplete { get; set; }
// Cannot use RequiredAttribute on Description as the
// entity is very likely to be created without one,
// however a Description is required before the entity
// can be marked as "IsComplete"
public string Description { get; set; }
}