134 lines
4.2 KiB
Go
134 lines
4.2 KiB
Go
// Code generated by sqlc. DO NOT EDIT.
|
|
// versions:
|
|
// sqlc v1.21.0
|
|
|
|
package database
|
|
|
|
import (
|
|
"time"
|
|
)
|
|
|
|
type Activity struct {
|
|
UserID string `json:"user_id"`
|
|
DocumentID string `json:"document_id"`
|
|
DeviceID string `json:"device_id"`
|
|
CreatedAt time.Time `json:"created_at"`
|
|
StartTime time.Time `json:"start_time"`
|
|
Page int64 `json:"page"`
|
|
Pages int64 `json:"pages"`
|
|
Duration int64 `json:"duration"`
|
|
}
|
|
|
|
type Device struct {
|
|
ID string `json:"id"`
|
|
UserID string `json:"user_id"`
|
|
DeviceName string `json:"device_name"`
|
|
CreatedAt string `json:"created_at"`
|
|
Sync bool `json:"sync"`
|
|
}
|
|
|
|
type Document struct {
|
|
ID string `json:"id"`
|
|
Md5 *string `json:"md5"`
|
|
Filepath *string `json:"filepath"`
|
|
Coverfile *string `json:"coverfile"`
|
|
Title *string `json:"title"`
|
|
Author *string `json:"author"`
|
|
Series *string `json:"series"`
|
|
SeriesIndex *int64 `json:"series_index"`
|
|
Lang *string `json:"lang"`
|
|
Description *string `json:"description"`
|
|
Words *int64 `json:"words"`
|
|
Gbid *string `json:"gbid"`
|
|
Olid *string `json:"-"`
|
|
Isbn10 *string `json:"isbn10"`
|
|
Isbn13 *string `json:"isbn13"`
|
|
Synced bool `json:"-"`
|
|
Deleted bool `json:"-"`
|
|
UpdatedAt time.Time `json:"updated_at"`
|
|
CreatedAt time.Time `json:"created_at"`
|
|
}
|
|
|
|
type DocumentDeviceSync struct {
|
|
UserID string `json:"user_id"`
|
|
DocumentID string `json:"document_id"`
|
|
DeviceID string `json:"device_id"`
|
|
LastSynced time.Time `json:"last_synced"`
|
|
Sync bool `json:"sync"`
|
|
}
|
|
|
|
type DocumentProgress struct {
|
|
UserID string `json:"user_id"`
|
|
DocumentID string `json:"document_id"`
|
|
DeviceID string `json:"device_id"`
|
|
Percentage float64 `json:"percentage"`
|
|
Progress string `json:"progress"`
|
|
CreatedAt time.Time `json:"created_at"`
|
|
}
|
|
|
|
type Metadatum struct {
|
|
ID int64 `json:"id"`
|
|
DocumentID string `json:"document_id"`
|
|
Title *string `json:"title"`
|
|
Author *string `json:"author"`
|
|
Description *string `json:"description"`
|
|
Gbid *string `json:"gbid"`
|
|
Olid *string `json:"olid"`
|
|
Isbn10 *string `json:"isbn10"`
|
|
Isbn13 *string `json:"isbn13"`
|
|
CreatedAt time.Time `json:"created_at"`
|
|
}
|
|
|
|
type RawActivity struct {
|
|
ID int64 `json:"id"`
|
|
UserID string `json:"user_id"`
|
|
DocumentID string `json:"document_id"`
|
|
DeviceID string `json:"device_id"`
|
|
StartTime time.Time `json:"start_time"`
|
|
Page int64 `json:"page"`
|
|
Pages int64 `json:"pages"`
|
|
Duration int64 `json:"duration"`
|
|
CreatedAt time.Time `json:"created_at"`
|
|
}
|
|
|
|
type User struct {
|
|
ID string `json:"id"`
|
|
Pass *string `json:"-"`
|
|
Admin bool `json:"-"`
|
|
TimeOffset *string `json:"time_offset"`
|
|
CreatedAt time.Time `json:"created_at"`
|
|
}
|
|
|
|
type UserStreak struct {
|
|
UserID string `json:"user_id"`
|
|
Window string `json:"window"`
|
|
MaxStreak int64 `json:"max_streak"`
|
|
MaxStreakStartDate string `json:"max_streak_start_date"`
|
|
MaxStreakEndDate string `json:"max_streak_end_date"`
|
|
CurrentStreak int64 `json:"current_streak"`
|
|
CurrentStreakStartDate string `json:"current_streak_start_date"`
|
|
CurrentStreakEndDate string `json:"current_streak_end_date"`
|
|
}
|
|
|
|
type ViewRescaledActivity struct {
|
|
UserID string `json:"user_id"`
|
|
DocumentID string `json:"document_id"`
|
|
DeviceID string `json:"device_id"`
|
|
CreatedAt time.Time `json:"created_at"`
|
|
StartTime time.Time `json:"start_time"`
|
|
Page int64 `json:"page"`
|
|
Pages int64 `json:"pages"`
|
|
Duration int64 `json:"duration"`
|
|
}
|
|
|
|
type ViewUserStreak struct {
|
|
UserID string `json:"user_id"`
|
|
Window string `json:"window"`
|
|
MaxStreak interface{} `json:"max_streak"`
|
|
MaxStreakStartDate interface{} `json:"max_streak_start_date"`
|
|
MaxStreakEndDate interface{} `json:"max_streak_end_date"`
|
|
CurrentStreak interface{} `json:"current_streak"`
|
|
CurrentStreakStartDate interface{} `json:"current_streak_start_date"`
|
|
CurrentStreakEndDate interface{} `json:"current_streak_end_date"`
|
|
}
|