MCPcopy Create free account
hub / github.com/TruthHun/BookStack / Lists

Method Lists

models/banner.go:26–32  ·  view source on GitHub ↗
(t string)

Source from the content-addressed store, hash-verified

24}
25
26func (m *Banner) Lists(t string) (banners []Banner, err error) {
27 _, err = orm.NewOrm().QueryTable(m).Filter("type", t).Filter("status", true).OrderBy("-sort", "-id").All(&banners)
28 if err == orm.ErrNoRows {
29 err = nil
30 }
31 return
32}
33
34func (m *Banner) All() (banners []Banner, err error) {
35 _, err = orm.NewOrm().QueryTable(m).OrderBy("-sort", "-status").All(&banners)

Callers

nothing calls this directly

Calls 1

AllMethod · 0.45

Tested by

no test coverage detected