minor changes
This commit is contained in:
@@ -10,6 +10,7 @@ import (
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/davecgh/go-spew/spew"
|
||||
"github.com/dromara/carbon/v2"
|
||||
"github.com/go-shiori/dom"
|
||||
"github.com/jmoiron/sqlx"
|
||||
@@ -25,6 +26,17 @@ type Prescene struct {
|
||||
db *sqlx.DB
|
||||
}
|
||||
|
||||
func (s *Prescene) GetSrrDb() ([]model.ExternalSources, error) {
|
||||
entries := make([]model.ExternalSources, 0)
|
||||
now := time.Now()
|
||||
yesterday := now.Add(-24 * time.Hour)
|
||||
todayStr := now.Format("2006-01-02")
|
||||
yesterdayStr := yesterday.Format("2006-01-02")
|
||||
spew.Dump(entries, todayStr, yesterdayStr)
|
||||
|
||||
return []model.ExternalSources{}, nil
|
||||
}
|
||||
|
||||
func NewPresceneRepository(db *sqlx.DB) *Prescene {
|
||||
return &Prescene{db: db}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user