{backup,snapshot}: Log and display in control

This commit is contained in:
Tom Wiesing 2022-10-03 11:22:45 +02:00
parent 3b112f1b8e
commit 630da9e12f
No known key found for this signature in database
17 changed files with 294 additions and 44 deletions

View file

@ -0,0 +1,17 @@
package snapshots
import "github.com/FAU-CDI/wisski-distillery/internal/models"
func (backup *Backup) LogEntry() models.Snapshot {
return models.Snapshot{
Created: backup.StartTime,
Slug: "",
}
}
func (snapshot *Snapshot) LogEntry() models.Snapshot {
return models.Snapshot{
Created: snapshot.StartTime,
Slug: snapshot.Instance.Slug,
}
}