@@ -58,6 +58,10 @@ func (r *mutationResolver) ImportLog(ctx context.Context, input graphcore.LogImp
|
||||
return r.s.Logs.Import(ctx, input.Importer, date, tz, input.ChannelName, input.Data)
|
||||
}
|
||||
|
||||
func (r *mutationResolver) SplitLog(ctx context.Context, input graphcore.LogSplitInput) (*models.Log, error) {
|
||||
return r.s.Logs.SplitLog(ctx, input.LogID, input.StartPostID)
|
||||
}
|
||||
|
||||
func (r *mutationResolver) EditLog(ctx context.Context, input graphcore.LogEditInput) (*models.Log, error) {
|
||||
update := models.LogUpdate{
|
||||
Open: input.Open,
|
||||
|
||||
@@ -117,6 +117,9 @@ type Mutation {
|
||||
# Import a log
|
||||
importLog(input: LogImportInput!): [Log!]!
|
||||
|
||||
# Split a log
|
||||
splitLog(input: LogSplitInput!): Log!
|
||||
|
||||
# Edit a log
|
||||
editLog(input: LogEditInput!): Log!
|
||||
|
||||
|
||||
@@ -122,6 +122,17 @@ input LogImportInput {
|
||||
data: String!
|
||||
}
|
||||
|
||||
"""
|
||||
Input for splitLog mutation.
|
||||
"""
|
||||
input LogSplitInput {
|
||||
"Log ID"
|
||||
logId: String!
|
||||
|
||||
"After Post ID"
|
||||
startPostId: String!
|
||||
}
|
||||
|
||||
enum LogImporter {
|
||||
"""
|
||||
mIRC-like: This importer parses logs that copied from mIRC posts without spaces.
|
||||
|
||||
Reference in New Issue
Block a user