|
@@ -54,33 +54,52 @@
|
|
if (item.item != null)
|
|
if (item.item != null)
|
|
{
|
|
{
|
|
var track = DataSet.AllTracks.FirstOrDefault(p => p.Path == item.item);
|
|
var track = DataSet.AllTracks.FirstOrDefault(p => p.Path == item.item);
|
|
- <tr>
|
|
|
|
- <td></td>
|
|
|
|
- <td><img src="@track.Disc.CoverPath" style="height:50px" /></td>
|
|
|
|
- <td class="align-middle w-100">@track?.Tag?.Title</td>
|
|
|
|
- <td></td>
|
|
|
|
- <td></td>
|
|
|
|
- <td>
|
|
|
|
- <button type="button" class="btn btn-primary p-2" @onclick="()=>Remove(Playlist.Value.Key, item.index,item.item)">
|
|
|
|
- <i class="bi bi-trash"></i>
|
|
|
|
- </button>
|
|
|
|
- </td>
|
|
|
|
- <td></td>
|
|
|
|
- </tr>
|
|
|
|
|
|
+ if (track != null)
|
|
|
|
+ {
|
|
|
|
+
|
|
|
|
+ <tr>
|
|
|
|
+ <td></td>
|
|
|
|
+ <td><img src="@track.Disc.CoverPath" style="height:50px" /></td>
|
|
|
|
+ <td class="align-middle w-100 ">
|
|
|
|
+ <div class="text-nowrap">@((track.Tag?.Title).NullOrEmptyEscape(track.Name))</div>
|
|
|
|
+ <small class="text-nowrap text-muted">@track.Tag?.Duration.SecondToDur() @track.Tag?.Artist</small>
|
|
|
|
+ </td>
|
|
|
|
+ <td></td>
|
|
|
|
+ <td></td>
|
|
|
|
+ <td>
|
|
|
|
+ <button type="button" class="btn btn-primary p-2" @onclick="()=>Remove(Playlist.Value.Key, item.index,item.item)">
|
|
|
|
+ <i class="bi bi-trash"></i>
|
|
|
|
+ </button>
|
|
|
|
+ </td>
|
|
|
|
+ <td></td>
|
|
|
|
+ </tr>
|
|
|
|
+ }
|
|
|
|
+ else
|
|
|
|
+ {
|
|
|
|
+ <tr>
|
|
|
|
+ <td></td>
|
|
|
|
+ <td><img src="blazor-192.png" style="height:50px" /></td>
|
|
|
|
+ <td class="align-middle w-100"> - broken reference - </td>
|
|
|
|
+ <td></td>
|
|
|
|
+ <td></td>
|
|
|
|
+ <td>
|
|
|
|
+ <button type="button" class="btn btn-primary p-2" @onclick="()=>Remove(Playlist.Value.Key, item.index,item.item)">
|
|
|
|
+ <i class="bi bi-trash"></i>
|
|
|
|
+ </button>
|
|
|
|
+ </td>
|
|
|
|
+ <td></td>
|
|
|
|
+ </tr>
|
|
|
|
+ }
|
|
}
|
|
}
|
|
else
|
|
else
|
|
{
|
|
{
|
|
<tr>
|
|
<tr>
|
|
<td></td>
|
|
<td></td>
|
|
- <td><img src="blazor-192.png" style="height:50px" /></td>
|
|
|
|
- <td class="align-middle w-100"> - broken reference - </td>
|
|
|
|
|
|
+ <td></td>
|
|
|
|
+ <td class="align-middle w-100"> - empty - </td>
|
|
|
|
+ <td></td>
|
|
<td></td>
|
|
<td></td>
|
|
<td></td>
|
|
<td></td>
|
|
- <td>
|
|
|
|
- <button type="button" class="btn btn-primary p-2" @onclick="()=>Remove(Playlist.Value.Key, item.index,item.item)">
|
|
|
|
- <i class="bi bi-trash"></i>
|
|
|
|
- </button>
|
|
|
|
- </td>
|
|
|
|
<td></td>
|
|
<td></td>
|
|
</tr>
|
|
</tr>
|
|
}
|
|
}
|