Check for null parameters in the interface
This commit is contained in:
parent
021acac780
commit
5f452c026e
|
@ -14,20 +14,28 @@
|
|||
else
|
||||
{
|
||||
<h1>Calendar "@_calendar.Name"</h1>
|
||||
@foreach (var e in _events)
|
||||
@foreach (var @event in _events)
|
||||
{
|
||||
<div class="event">
|
||||
<a href="/calendars/@Id/events/@e.Uid">
|
||||
<h2>@e.Summary</h2>
|
||||
<a href="/calendars/@Id/events/@(@event.Uid)">
|
||||
<h2>@(@event.Summary)</h2>
|
||||
</a>
|
||||
|
||||
<div>
|
||||
<strong>Start:</strong> @e.DtStart
|
||||
</div>
|
||||
<div>
|
||||
<strong>End:</strong> @e.DtEnd
|
||||
</div>
|
||||
<div class="event-description-short">@e.Description</div>
|
||||
@if (@event.DtStart != null)
|
||||
{
|
||||
<div>
|
||||
<strong>Start:</strong> @(@event.DtStart)
|
||||
</div>
|
||||
}
|
||||
|
||||
@if (@event.DtEnd != null)
|
||||
{
|
||||
<div>
|
||||
<strong>End:</strong> @(@event.DtEnd)
|
||||
</div>
|
||||
}
|
||||
|
||||
<div class="event-description-short">@(@event.Description)</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
|
|
|
@ -14,12 +14,21 @@
|
|||
else
|
||||
{
|
||||
<h1>@_event.Summary</h1>
|
||||
<div>
|
||||
<strong>Start:</strong> @_event.DtStart
|
||||
</div>
|
||||
<div>
|
||||
<strong>End:</strong> @_event.DtEnd
|
||||
</div>
|
||||
|
||||
@if (_event.DtStart != null)
|
||||
{
|
||||
<div>
|
||||
<strong>Start:</strong> @_event.DtStart
|
||||
</div>
|
||||
}
|
||||
|
||||
@if (_event.DtEnd != null)
|
||||
{
|
||||
<div>
|
||||
<strong>End:</strong> @_event.DtEnd
|
||||
</div>
|
||||
}
|
||||
|
||||
<p class="event-description">@_event.Description</p>
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue