Simplify CalculatedEnd
This commit is contained in:
parent
4f02fb27da
commit
36f9fb6654
1 changed files with 1 additions and 9 deletions
|
@ -18,15 +18,7 @@ namespace BlazorApp.Data
|
|||
public string Description { get; set; }
|
||||
public TimeSpan? Duration { get; set; }
|
||||
|
||||
public DateTime? CalculatedEnd
|
||||
{
|
||||
get
|
||||
{
|
||||
if (Duration != null)
|
||||
return DtStart + Duration;
|
||||
return DtEnd;
|
||||
}
|
||||
}
|
||||
public DateTime? CalculatedEnd => DtEnd ?? DtStart + Duration;
|
||||
}
|
||||
|
||||
public class Calendar
|
||||
|
|
Loading…
Reference in a new issue