UNPKG
waibu-db
Version:
latest (2.28.1)
2.28.1
2.28.0
2.27.1
2.27.0
2.26.4
2.26.3
2.26.2
2.26.1
2.26.0
2.25.2
2.25.1
2.25.0
2.24.1
2.24.0
2.23.1
2.23.0
2.22.0
2.21.3
2.21.2
2.21.1
2.21.0
2.20.1
2.20.0
2.19.0
2.18.4
2.18.3
2.18.2
2.18.1
2.18.0
2.17.2
2.17.1
2.17.0
2.16.3
2.16.2
2.16.1
2.16.0
2.15.0
2.14.0
2.13.0
2.12.6
2.12.5
2.12.4
2.12.2
2.12.1
2.12.0
2.11.0
2.10.3
2.10.2
2.10.1
2.10.0
2.9.0
2.8.2
2.8.1
2.8.0
2.7.1
2.7.0
2.6.1
2.6.0
2.5.0
2.4.0
2.3.3
2.3.2
2.3.1
2.3.0
2.2.2
2.2.1
2.2.0
2.1.7
2.1.6
2.1.5
2.1.4
2.1.3
2.1.2
2.1.1
2.1.0
2.0.1
2.0.0
1.2.12
1.2.11
1.2.10
1.2.9
1.2.8
1.2.7
1.2.6
1.2.5
1.2.4
1.2.3
1.2.2
1.2.1
1.2.0
1.1.24
1.1.23
1.1.22
1.1.21
1.1.20
1.1.19
1.1.18
1.1.17
1.1.16
1.1.15
1.1.14
1.1.13
1.1.12
1.1.11
1.1.10
1.1.9
1.1.8
1.1.7
1.1.6
1.1.5
1.1.4
1.1.3
1.1.2
1.1.1
1.1.0
1.0.19
1.0.18
1.0.17
1.0.16
1.0.15
1.0.14
1.0.13
1.0.12
1.0.11
1.0.10
1.0.9
1.0.8
1.0.7
1.0.6
1.0.5
1.0.4
1.0.3
1.0.2
1.0.1
DB Helper
github.com/ardhi/waibu-db
ardhi/waibu-db
waibu-db
/
lib
/
crud
/
helper
/
attachment-handler.js
8 lines
(6 loc)
•
239 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
async
function
attachmentHandler
(
{ schema, id }
) {
const
{ listAttachments } =
this
.
app
.
dobo
if
(!schema.
view
.
attachment
)
return
[]
return
await
listAttachments
({
model
: schema.
name
, id }) }
export
default
attachmentHandler