feat: daily vani
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
package model
|
||||
|
||||
import "time"
|
||||
|
||||
// VaniPayload is the prebuilt display blob for the "Vāṇī of the Day" CTA. It's
|
||||
// owned by the frontend's rendering needs and stored verbatim as JSONB, so the
|
||||
// home page can render without re-reading Mongo.
|
||||
type VaniPayload struct {
|
||||
Kind string `json:"kind"` // "verse" | "prose" | "transcript"
|
||||
Label string `json:"label"` // "Verse" | "Chapter" | "Lecture" | "Conversation"
|
||||
Title string `json:"title"` // reference / chapter title / lecture name
|
||||
Subtitle string `json:"subtitle"` // short excerpt or date · place
|
||||
Href string `json:"href"` // in-app path to open the item
|
||||
BookTitle string `json:"book_title,omitempty"` // e.g. "Bhagavad-gītā As It Is"
|
||||
}
|
||||
|
||||
// VaniPick is one persisted day's choice. RefID is `<kind>:<mongo _id hex>` and
|
||||
// is what the 90-day no-repeat rule dedupes on.
|
||||
type VaniPick struct {
|
||||
Day time.Time
|
||||
Kind string
|
||||
RefID string
|
||||
Payload VaniPayload
|
||||
}
|
||||
Reference in New Issue
Block a user