0.5.7-shouts-admin
All checks were successful
Deploy on push / deploy (push) Successful in 5s

This commit is contained in:
2025-06-28 13:47:08 +03:00
parent 7c11c9875f
commit c48f5f9368
7 changed files with 829 additions and 11 deletions

View File

@@ -56,11 +56,67 @@ type OperationResult {
error: String
}
# Типы для управления публикациями (Shout)
type AdminShoutInfo {
id: Int!
title: String!
slug: String!
body: String!
lead: String
subtitle: String
layout: String!
lang: String!
cover: String
cover_caption: String
media: [MediaItem]
seo: String
created_at: Int!
updated_at: Int
published_at: Int
featured_at: Int
deleted_at: Int
created_by: Author!
updated_by: Author
deleted_by: Author
community: Community!
authors: [Author]
topics: [Topic]
version_of: Int
draft: Int
stat: Stat
}
# Тип для пагинированного ответа публикаций
type AdminShoutListResponse {
shouts: [AdminShoutInfo!]!
total: Int!
page: Int!
perPage: Int!
totalPages: Int!
}
input AdminShoutUpdateInput {
id: Int!
title: String
body: String
lead: String
subtitle: String
cover: String
cover_caption: String
media: [MediaItemInput]
seo: String
published_at: Int
featured_at: Int
deleted_at: Int
}
extend type Query {
getEnvVariables: [EnvSection!]!
# Запросы для управления пользователями
adminGetUsers(limit: Int, offset: Int, search: String): AdminUserListResponse!
adminGetRoles: [Role!]!
# Запросы для управления публикациями
adminGetShouts(limit: Int, offset: Int, search: String, status: String): AdminShoutListResponse!
}
extend type Mutation {
@@ -69,4 +125,8 @@ extend type Mutation {
# Мутации для управления пользователями
adminUpdateUser(user: AdminUserUpdateInput!): OperationResult!
# Мутации для управления публикациями
adminUpdateShout(shout: AdminShoutUpdateInput!): OperationResult!
adminDeleteShout(id: Int!): OperationResult!
adminRestoreShout(id: Int!): OperationResult!
}