model

package
v0.0.0-...-4aec9fb Latest Latest
Warning

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

Go to latest
Published: Jun 27, 2019 License: MIT Imports: 2 Imported by: 17

Documentation

Index

Constants

View Source
const (
	DealStateUnderway   = "underway"
	DealStateRecConfirm = "recConfirm"
	DealStatePubConfirm = "pubConfirm"
)
View Source
const (
	ReviewStatePassed   = "passed"
	ReviewStateFailed   = "failed"
	ReviewStateUnderway = "underway"
)
View Source
const (
	TaskStateNonReleased  = "non-released"
	TaskStateReleased     = "released"
	TaskStateClosed       = "closed"
	TaskKindQuestionnaire = "questionnaire"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Admin

type Admin struct {
	Name     string `json:"name"`
	Password string `json:"password"`
}

Admin 管理员

type Charge

type Charge struct {
	Id        string    `json:"id" xorm:"<-"`
	UserId    string    `json:"userId" xorm:"userId"`
	Amount    float64   `json:"amount" xorm:"amount"`
	Timestamp time.Time `json:"timestamp" xorm:"timestamp"`
}

type Comment

type Comment struct {
	Id         string    `json:"id" xorm:"<-"`
	TaskId     string    `json:"taskId" xorm:"taskId"`
	UserId     string    `json:"userId" xorm:"userId"`
	Timestamp  time.Time `json:"timestamp" xorm:"timestamp"`
	Content    string    `json:"content" xorm:"content"`
	Stars      int       `json:"stars" xorm:"stars"`
	Stargazers []string  `json:"stargazers" xorm:"stargazers"`
}

type Deal

type Deal struct {
	Id        string    `json:"id" xorm:"<-"`
	TaskId    string    `json:"taskId" xorm:"taskId"`
	Publisher string    `json:"publisher" xorm:"publisher"`
	Recipient string    `json:"recipient" xorm:"recipient"`
	Since     time.Time `json:"since" xorm:"since"`
	Until     time.Time `json:"until" xorm:"until"`
	Reward    float64   `json:"reward" xorm:"reward"`
	State     string    `json:"state" xorm:"state"`
}

type Enterprise

type Enterprise struct {
	Name     string `json:"name"`
	Password string `json:"password"`
}

Admin 管理员

type Qtnr

type Qtnr struct {
	Task
	Qtnr *Questionnaire `json:"qtnr"`
}

type Questionnaire

type Questionnaire struct {
	TaskId        string          `json:"taskId" xorm:"taskId"`
	Query         []query         `json:"query" xorm:"query"`
	SingleChoice  []singleChoice  `json:"singleChoice" xorm:"singleChoice"`
	MutipleChoice []mutipleChoice `json:"mutipleChoice" xorm:"mutipleChoice"`
}

type Review

type Review struct {
	Id     string `json:"id" xorm:"<-"`
	TaskId string `json:"taskId" xorm:"taskId"`
	Name   string `json:"name" xorm:"name"`
	State  string `json:"state" xorm:"state"`
}

type Task

type Task struct {
	Id        string `json:"id" xorm:"<-"`
	Kind      string `json:"kind"`
	Title     string `json:"title"`
	Publisher string `json:"publisher"`
	// Recipient       string    `json:"recipient"`
	Restrain string    `json:"restrain"`
	Pubdate  time.Time `json:"pubdate"`
	Cutoff   time.Time `json:"cutoff"`
	// Enddate         time.Time `json:"enddate"`
	Reward float64 `json:"reward"`
	// RecipientFinish bool      `json:"recipientFinish" xorm:"recipientFinish"`
	// ConfirmFinish   bool      `json:"confirmFinish" xorm:"confirmFinish"`
	State string `json:"state"`
}

type Token

type Token struct {
	Id    string `json:"id"`
	Token string `json:"token"`
}

Token

type User

type User struct {
	Id                  string  `json:"id"`
	SId                 string  `json:"sId" xorm:"sId"`
	Name                string  `json:"name"`
	Introduction        string  `json:"introduction"`
	Balance             float64 `json:"balance"`
	Icon                string  `json:"icon"`
	Phone               string  `json:"phone"`
	CreditScore         int     `json:"creditScore" xorm:"creditScore"`
	Email               string  `json:"email"`
	CertifiedPic        string  `json:"certifiedPic" xorm:"certifiedPic"`
	CertificationStatus int     `json:"certificationStatus" xorm:"certificationStatus"`
}

type Wrapper

type Wrapper struct {
	Kind string          `json:"kind"`
	Raw  json.RawMessage `json:"raw"`
}

Jump to

Keyboard shortcuts

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