improved format of 'last-modified'

This commit is contained in:
Martin Wagner 2020-05-25 21:57:51 +02:00
parent 343a1d23dd
commit feaa958547

View File

@ -2825,6 +2825,9 @@ class AudioType(Gtk.Button):
for tag, value in song.items():
if tag == "time":
self.store.append([tag+":", str(datetime.timedelta(seconds=int(value)))])
elif tag == "last-modified":
time=datetime.datetime.strptime(value, '%Y-%m-%dT%H:%M:%SZ')
self.store.append([tag+":", time.strftime('%a %d %B %Y, %H:%M')])
else:
self.store.append([tag+":", value])
self.treeview.show()