MCPcopy Index your code
hub / github.com/TruthHun/BookStack / LastReading

Method LastReading

models/read_record.go:192–195  ·  view source on GitHub ↗

查询用户最后的一条阅读记录

(uid int, cols ...string)

Source from the content-addressed store, hash-verified

190
191// 查询用户最后的一条阅读记录
192func (this *ReadRecord) LastReading(uid int, cols ...string) (r ReadRecord) {
193 orm.NewOrm().QueryTable(this).Filter("uid", uid).OrderBy("-id").One(&r)
194 return
195}
196
197func (this *ReadRecord) HistoryReadBook(uid, page, size int) (books []Book) {
198 // 由于md_books 没有 created_at 这个字段,所以这里将这个字段映射到version里面...

Callers 1

calcReadingTimeMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected