db

package
v0.0.0-...-01500c1 Latest Latest
Warning

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

Go to latest
Published: Jun 3, 2016 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AcademicGrade

type AcademicGrade struct {
	Average GradeType
	Rank    RankType
}

type ApplicationForm

type ApplicationForm struct {
	Id        bson.ObjectId `bson:"_id,omitempty"`
	OwnerId   bson.ObjectId
	Timestamp time.Time

	//Basic Data
	Name        string
	School      string
	Department  string
	SchoolGrade string
	Birthday    time.Time
	FormalId    string
	Phone       string
	Email       string
	Address     string

	//Academic Data
	Topic          public.TopicId
	Teacher        string
	ResearchArea   string
	ClassHistories []StudiedClass
	RelatedSkills  string
	AcademicGrade  AcademicGrade
	LangAbilities  []LanguageAbility

	//Extras
	ResearchPlan    string   //File
	Recommendations []string //Recomm entity hashes
	Transcript      string   //File
	Others          string   //File
}

type BulletinNote

type BulletinNote struct {
	Id bson.ObjectId `bson:"_id,omitempty"`

	Title     string ""
	Content   string ""
	TimeStamp time.Time
}

type GMInfo

type GMInfo struct {
	Id     bson.ObjectId `bson:"_id,omitempty"`
	UserId bson.ObjectId
}

type GradeType

type GradeType float64

type LanguageAbility

type LanguageAbility struct {
	Name string

	//Good: 0
	//Average: 1
	//Bad: 2
	Listening uint
	Speaking  uint
	Reading   uint
	Writing   uint
}

type RankType

type RankType int32

type Recomm

type Recomm struct {
	Id bson.ObjectId `bson:"_id,omitempty"`

	Hash        string
	Submitted   bool
	ApplyUser   public.BasicUser
	Recommender public.BasicUser

	Content    string ""
	Attachment string "" //File
}

type RecommEntity

type RecommEntity struct {
	Id   bson.ObjectId `bson:"_id,omitempty"`
	Hash string        `bson:",omitempty"`

	ApplyUser   public.BasicUser
	Topic       string        `bson:",omitempty"`
	Recommender bson.ObjectId `bson:",omitempty"`

	LastModified time.Time
	Content      string                 `bson:",omitempty"`
	Attachment   public.FileStoragePath `bson:",omitempty"`
}

type ReviewResult

type ReviewResult struct {
	Id bson.ObjectId `bson:"_id,omitempty"`

	Topic         public.TopicId
	ApplicationId bson.ObjectId
	ReviewerId    bson.ObjectId

	//Score Data
	ResearchArea public.ReviewScore
	Classes      public.ReviewScore
	Skills       public.ReviewScore
	Grade        public.ReviewScore
	Language     public.ReviewScore
	ResearchPlan public.ReviewScore
	Recomm       public.ReviewScore
	Other        public.ReviewScore
	Overall      public.ReviewScore
}

func (*ReviewResult) CopyFromReviewResponse

func (this *ReviewResult) CopyFromReviewResponse(response public.ReviewResponse)

type Reviewer

type Reviewer struct {
	Id          bson.ObjectId `bson:"_id,omitempty"`
	BaseProfile User

	Permissions []string
	Topics      []public.TopicId
}

type StudiedClass

type StudiedClass struct {
	Name     string
	Semester string
	Grade    string
}

type User

type User struct {
	Id        bson.ObjectId `bson:"_id,omitempty"`
	Email     string
	Username  string
	FormalId  string
	Thumbnail string

	AuthInfo UserAuth

	Permission public.UserPermission `bson:",omitempty"`
}

type UserAuth

type UserAuth struct {
	BcryptCost int
	BcyptHash  string
}

Jump to

Keyboard shortcuts

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