登録番組の定期確認を追加(24 時間ごと、予告の除外、確認エラーの記録)
This commit is contained in:
@@ -15,6 +15,7 @@ type subscriptionActionView struct {
|
||||
|
||||
type subscriptionView struct {
|
||||
ID, Title, CreatedAtText, LastCheckedText string
|
||||
CheckErrorAtText, CheckErrorText string
|
||||
Enabled bool
|
||||
Jobs int64
|
||||
}
|
||||
@@ -136,6 +137,10 @@ func (s *server) loadSubscriptions(ctx context.Context) (subscriptionsView, erro
|
||||
if sub.LastCheckedAt != nil {
|
||||
item.LastCheckedText = sub.LastCheckedAt.In(s.zone).Format("2006-01-02 15:04 MST")
|
||||
}
|
||||
if sub.LastCheckErrorAt != nil && sub.LastCheckError != nil {
|
||||
item.CheckErrorAtText = sub.LastCheckErrorAt.In(s.zone).Format("2006-01-02 15:04 MST")
|
||||
item.CheckErrorText = *sub.LastCheckError
|
||||
}
|
||||
view.Items = append(view.Items, item)
|
||||
}
|
||||
return view, nil
|
||||
|
||||
Reference in New Issue
Block a user