rework
This commit is contained in:
parent
e62df2e9fc
commit
1912b5baf0
39 changed files with 8489 additions and 476 deletions
8
server/graphql/mutation.graphql
Normal file
8
server/graphql/mutation.graphql
Normal file
|
@ -0,0 +1,8 @@
|
|||
type Mutation {
|
||||
uploadFile(dir: String!, file: Upload!): Boolean!
|
||||
dedupeStorage: Int!
|
||||
}
|
||||
|
||||
type Task {
|
||||
id: ID!
|
||||
}
|
9
server/graphql/query.graphql
Normal file
9
server/graphql/query.graphql
Normal file
|
@ -0,0 +1,9 @@
|
|||
type Query {
|
||||
plugins: [Plugin!]!
|
||||
fsEntry(path: String!): FsEntry
|
||||
}
|
||||
|
||||
type Plugin {
|
||||
name: String!
|
||||
endpountSubPath: String
|
||||
}
|
13
server/graphql/schema.graphql
Normal file
13
server/graphql/schema.graphql
Normal file
|
@ -0,0 +1,13 @@
|
|||
# directive @oneOf on INPUT_OBJECT | FIELD_DEFINITION
|
||||
directive @resolver on INPUT_FIELD_DEFINITION | FIELD_DEFINITION
|
||||
|
||||
directive @stream on FIELD_DEFINITION
|
||||
|
||||
scalar DateTime
|
||||
scalar Upload
|
||||
scalar UInt
|
||||
|
||||
type Schema {
|
||||
query: Query
|
||||
mutation: Mutation
|
||||
}
|
3
server/graphql/subscription.graphql
Normal file
3
server/graphql/subscription.graphql
Normal file
|
@ -0,0 +1,3 @@
|
|||
type Subscription {
|
||||
taskProgress(taskID: ID!): Progress
|
||||
}
|
31
server/graphql/types/filters.graphql
Normal file
31
server/graphql/types/filters.graphql
Normal file
|
@ -0,0 +1,31 @@
|
|||
input Pagination {
|
||||
offset: Int!
|
||||
limit: Int!
|
||||
}
|
||||
|
||||
input StringFilter @oneOf {
|
||||
eq: String
|
||||
substr: String
|
||||
in: [String!]
|
||||
}
|
||||
|
||||
input IntFilter @oneOf {
|
||||
eq: Int
|
||||
gt: Int
|
||||
lt: Int
|
||||
gte: Int
|
||||
lte: Int
|
||||
in: [Int!]
|
||||
}
|
||||
|
||||
input DateTimeFilter @oneOf {
|
||||
eq: DateTime
|
||||
gt: DateTime
|
||||
lt: DateTime
|
||||
gte: DateTime
|
||||
lte: DateTime
|
||||
}
|
||||
|
||||
input BooleanFilter @oneOf {
|
||||
eq: Boolean
|
||||
}
|
35
server/graphql/types/fs.graphql
Normal file
35
server/graphql/types/fs.graphql
Normal file
|
@ -0,0 +1,35 @@
|
|||
interface FsEntry {
|
||||
name: String!
|
||||
}
|
||||
|
||||
interface Dir implements FsEntry {
|
||||
name: String!
|
||||
entries: [FsEntry!]!
|
||||
}
|
||||
|
||||
interface File implements FsEntry {
|
||||
name: String!
|
||||
size: Int!
|
||||
}
|
||||
|
||||
type SimpleDir implements Dir & FsEntry {
|
||||
name: String!
|
||||
entries: [FsEntry!]! @resolver
|
||||
}
|
||||
|
||||
type SimpleFile implements File & FsEntry {
|
||||
name: String!
|
||||
size: Int!
|
||||
}
|
||||
|
||||
type ResolverFS implements Dir & FsEntry {
|
||||
name: String!
|
||||
entries: [FsEntry!]! @resolver
|
||||
}
|
||||
|
||||
# type ArchiveFS implements Dir & FsEntry {
|
||||
# name: String!
|
||||
# entries: [FsEntry!]! @resolver
|
||||
|
||||
# size: Int!
|
||||
# }
|
4
server/graphql/types/progress.graphql
Normal file
4
server/graphql/types/progress.graphql
Normal file
|
@ -0,0 +1,4 @@
|
|||
interface Progress {
|
||||
current: Int!
|
||||
total: Int!
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue