data

package
v0.0.0-...-c89a2db Latest Latest
Warning

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

Go to latest
Published: Jul 2, 2019 License: MIT Imports: 1 Imported by: 2

Documentation

Overview

common data struct

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CommentArg

type CommentArg struct {
	ProblemID  int
	Content    string `json:"content" binding:"required"`
	ForComment int    `json:"for_comment" binding:"exists,min=0"`
	ToID       int    `json:"to_id" binding:"exists,min=0"`
}

type ContestInviteData

type ContestInviteData struct {
	ID          string `json:"id"`
	ContestID   int    `json:"contest_id"`
	Password    string `json:"password,omitempty" binding:"max=30"`
	AllowGroups []int  `json:"allow_groups"`
}

type ContestWrap

type ContestWrap struct {
	model.Contest
	NeedPassword bool   `json:"need_password"`
	Password     string `json:"-"`
}

type GroupInviteData

type GroupInviteData struct {
	ID       string `json:"id"`
	GroupID  int    `json:"group_id"`
	Password string `json:"password,omitempty" binding:"max=30"`
	Timeout  int    `json:"timeout" binding:"required,min=3600,max=2592000"` // second , max = 30 day,min = a hour
}

type GroupWrap

type GroupWrap struct {
	model.Group
	NeedPassword bool   `json:"need_password"`
	Password     string `json:"-"`
}

type SubmitArg

type SubmitArg struct {
	ProblemID  int
	SourceCode string `json:"source_code" binding:"required"`
	Language   int    `json:"language" binding:"exists,oneof=0 1 2 3"`
}

Jump to

Keyboard shortcuts

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