Fix public-ldb for multiple origin/destination
This commit is contained in:
@@ -125,8 +125,24 @@
|
||||
</tr>
|
||||
{#each services as service}
|
||||
<tr>
|
||||
<td class="origdest from">{service.origin?.location?.locationName || ''}</td>
|
||||
<td class="origdest to">{service.destination?.location?.locationName || ''}</td>
|
||||
<td class="origdest from">
|
||||
{#if Array.isArray(service.origin?.location)}
|
||||
{service.origin.location[0]['locationName'] +
|
||||
" & " +
|
||||
service.origin.location[1]['locationName']}
|
||||
{:else}
|
||||
{service.origin?.location?.locationName || ''}
|
||||
{/if}
|
||||
</td>
|
||||
<td class="origdest to">
|
||||
{#if Array.isArray(service.destination?.location)}
|
||||
{service.destination.location[0]['locationName'] +
|
||||
" & " +
|
||||
service.destination.location[0]['locationName']}
|
||||
{:else}
|
||||
{service.destination?.location?.locationName || ''}
|
||||
{/if}
|
||||
</td>
|
||||
<td class="plat">{service.platform || '-'}</td>
|
||||
<td class="time">{parseTime(service.sta).data}</td>
|
||||
<td class="time {parseTime(service.eta).changed}">{parseTime(service.eta).data}</td>
|
||||
|
||||
Reference in New Issue
Block a user