feat: image upload + list root assets (wip)

This commit is contained in:
Nick
2019-05-13 01:15:27 -04:00
parent 89c07a716a
commit 6b886b6e3f
23 changed files with 526 additions and 171 deletions

View File

@@ -17,8 +17,8 @@ extend type Mutation {
type AssetQuery {
list(
root: String
kind: [AssetKind]
): [AssetItem]
kind: AssetKind
): [AssetItem] @auth(requires: ["manage:system", "read:assets"])
}
# -----------------------------------------------
@@ -37,6 +37,20 @@ type AssetMutation {
type AssetItem {
id: Int!
filename: String!
ext: String!
kind: AssetKind!
mime: String!
fileSize: Int!
metadata: String
createdAt: Date!
updatedAt: Date!
folder: AssetFolder
author: User
}
type AssetFolder {
id: Int!
}
enum AssetKind {