feat: add event notes with pending state, 5-min TTL, cancel, and /note command
This commit is contained in:
@@ -570,6 +570,12 @@ func (s *Store) EventsForDayByDate(userID int64, date string) ([]Event, error) {
|
||||
return events, rows.Err()
|
||||
}
|
||||
|
||||
// SetEventNote updates the note for an event.
|
||||
func (s *Store) SetEventNote(eventID int64, note string) error {
|
||||
_, err := s.db.Exec("UPDATE events SET note=? WHERE id=?", note, eventID)
|
||||
return err
|
||||
}
|
||||
|
||||
// EventsForDayByDayID returns all events for a day record, ordered by occurrence.
|
||||
func (s *Store) EventsForDayByDayID(dayID int64) ([]Event, error) {
|
||||
rows, err := s.db.Query(`
|
||||
|
||||
Reference in New Issue
Block a user