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

Method FindListByDocumentId

models/attachment.go:76–80  ·  view source on GitHub ↗
(docId int)

Source from the content-addressed store, hash-verified

74}
75
76func (m *Attachment) FindListByDocumentId(docId int) (attaches []*Attachment, err error) {
77 o := orm.NewOrm()
78 _, err = o.QueryTable(m.TableNameWithPrefix()).Filter("document_id", docId).OrderBy("-attachment_id").All(&attaches)
79 return
80}
81
82//分页查询附件
83func (m *Attachment) FindToPager(pageIndex, pageSize int) (attachList []*AttachmentResult, totalCount int64, err error) {

Callers 2

ReadMethod · 0.80
ContentMethod · 0.80

Calls 2

TableNameWithPrefixMethod · 0.95
AllMethod · 0.45

Tested by

no test coverage detected