1
0
mirror of https://github.com/muety/wakapi.git synced 2023-08-10 21:12:56 +03:00
wakapi/models/view/summary.go

27 lines
532 B
Go
Raw Normal View History

2020-11-06 23:19:54 +03:00
package view
2021-12-16 14:39:41 +03:00
import "github.com/muety/wakapi/models"
2020-11-06 23:19:54 +03:00
type SummaryViewModel struct {
Messages
2021-12-16 14:39:41 +03:00
*models.Summary
*models.SummaryParams
User *models.User
AvatarURL string
EditorColors map[string]string
2021-12-16 14:39:41 +03:00
LanguageColors map[string]string
OSColors map[string]string
2021-12-16 14:39:41 +03:00
ApiKey string
RawQuery string
2020-11-06 23:19:54 +03:00
}
func (s *SummaryViewModel) WithSuccess(m string) *SummaryViewModel {
s.SetSuccess(m)
2020-11-06 23:19:54 +03:00
return s
}
func (s *SummaryViewModel) WithError(m string) *SummaryViewModel {
s.SetError(m)
2020-11-06 23:19:54 +03:00
return s
}