feat: admin list pages + editor media ui imrprovements
This commit is contained in:
@@ -28,6 +28,21 @@ module.exports = {
|
||||
}
|
||||
}
|
||||
},
|
||||
async list (obj, args, context, info) {
|
||||
return WIKI.models.pages.query().column([
|
||||
'id',
|
||||
'path',
|
||||
{ locale: 'localeCode' },
|
||||
'title',
|
||||
'description',
|
||||
'isPublished',
|
||||
'isPrivate',
|
||||
'privateNS',
|
||||
'contentType',
|
||||
'createdAt',
|
||||
'updatedAt'
|
||||
])
|
||||
}
|
||||
},
|
||||
PageMutation: {
|
||||
async create(obj, args, context) {
|
||||
|
@@ -26,6 +26,8 @@ type PageQuery {
|
||||
path: String
|
||||
locale: String
|
||||
): PageSearchResponse! @auth(requires: ["manage:system", "read:pages"])
|
||||
|
||||
list: [PageListItem!]! @auth(requires: ["manage:system"])
|
||||
}
|
||||
|
||||
# -----------------------------------------------
|
||||
@@ -108,3 +110,17 @@ type PageSearchResult {
|
||||
path: String!
|
||||
locale: String!
|
||||
}
|
||||
|
||||
type PageListItem {
|
||||
id: Int!
|
||||
path: String!
|
||||
locale: String!
|
||||
title: String
|
||||
description: String
|
||||
contentType: String!
|
||||
isPublished: Boolean!
|
||||
isPrivate: Boolean!
|
||||
privateNS: String
|
||||
createdAt: Date!
|
||||
updatedAt: Date!
|
||||
}
|
||||
|
Reference in New Issue
Block a user