timespan

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 30, 2021 License: GPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ResolverForTimeSpan

type ResolverForTimeSpan struct {
	DB *gorm.DB
}

ResolverForTimeSpan resolves time span specific things.

func (*ResolverForTimeSpan) CopyTimeSpan

func (r *ResolverForTimeSpan) CopyTimeSpan(ctx context.Context, id int, start model.Time, end *model.Time) (*gqlmodel.TimeSpan, error)

CopyTimeSpan copies a time span.

func (*ResolverForTimeSpan) CreateTimeSpan

func (r *ResolverForTimeSpan) CreateTimeSpan(ctx context.Context, start model.Time, end *model.Time, tags []*gqlmodel.InputTimeSpanTag, note string) (*gqlmodel.TimeSpan, error)

CreateTimeSpan creates a time span

func (*ResolverForTimeSpan) RemoveTimeSpan

func (r *ResolverForTimeSpan) RemoveTimeSpan(ctx context.Context, id int) (*gqlmodel.TimeSpan, error)

RemoveTimeSpan removes a timespan.

func (*ResolverForTimeSpan) ReplaceTimeSpanTags

func (r *ResolverForTimeSpan) ReplaceTimeSpanTags(ctx context.Context, fromExternal gqlmodel.InputTimeSpanTag, toExternal gqlmodel.InputTimeSpanTag, opt gqlmodel.InputReplaceOptions) (*bool, error)

ReplaceTimeSpanTags replaces time span tags.

func (*ResolverForTimeSpan) StopTimeSpan

func (r *ResolverForTimeSpan) StopTimeSpan(ctx context.Context, id int, end model.Time) (*gqlmodel.TimeSpan, error)

StopTimeSpan sets an end date to an existing time span.

func (*ResolverForTimeSpan) SuggestTagValue

func (r *ResolverForTimeSpan) SuggestTagValue(ctx context.Context, key string, query string) ([]string, error)

SuggestTagValue suggests a tag value.

func (*ResolverForTimeSpan) TimeSpans

func (r *ResolverForTimeSpan) TimeSpans(ctx context.Context, fromInclusive *model.Time, toInclusive *model.Time, cursor *gqlmodel.InputCursor) (*gqlmodel.PagedTimeSpans, error)

TimeSpans returns all time spans for a user

func (*ResolverForTimeSpan) Timers

Timers returns all running timers for a user

func (*ResolverForTimeSpan) UpdateTimeSpan

func (r *ResolverForTimeSpan) UpdateTimeSpan(ctx context.Context, id int, start model.Time, end *model.Time, tags []*gqlmodel.InputTimeSpanTag, oldStart *model.Time, note string) (*gqlmodel.TimeSpan, error)

UpdateTimeSpan update a time span

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL