api

package
v0.0.0-...-073df37 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetScheduleGroups

func GetScheduleGroups(schedule []Day, startDate time.Time, endDate time.Time) error

func SortKeyValue

func SortKeyValue(entries []KeyValue)

Types

type Class

type Class struct {
	StudyTime  string `json:"study_time"`
	Begin      string `json:"study_time_begin"`
	End        string `json:"study_time_end"`
	Discipline string `json:"discipline"`
	Type       string `json:"study_type"`
	Cabinet    string `json:"cabinet"`
	WeekDay    string `json:"week_day"`
	FullDate   string `json:"full_date"`
	Employee   string `json:"employee"`
	Groups     string `json:"study_group"`
	Subgroup   string `json:"study_subgroup"`
}

type Day

type Day struct {
	MessageIds []int
	WeekDay    string
	Date       string
	Classes    []Class
}

func GetEmployeeSchedule

func GetEmployeeSchedule(employee KeyValue, startDate time.Time, endDate time.Time) ([]Day, error)

func GetSchedule

func GetSchedule(studyGroup string, startDate time.Time, endDate time.Time) ([]Day, error)

type EmployeesAndChairs

type EmployeesAndChairs struct {
	Employees []KeyValue `json:"employees"`
	Chairs    []KeyValue `json:"chairs"`
}

func GetAllEmployeesAndChairs

func GetAllEmployeesAndChairs() (*EmployeesAndChairs, error)

func GetEmployeesAndChairs

func GetEmployeesAndChairs(faculty string) (*EmployeesAndChairs, error)

type Filters

type Filters struct {
	Faculties      []KeyValue `json:"faculties"`
	EducationForms []KeyValue `json:"educForms"`
	Courses        []KeyValue `json:"courses"`
}

func GetFilters

func GetFilters() (Filters, error)

type KeyValue

type KeyValue struct {
	Key   string `json:"Key"`
	Value string `json:"Value"`
}

func GetEmployeeByName

func GetEmployeeByName(name string) (KeyValue, error)

func GetStudyGroups

func GetStudyGroups(faculty string, educationForm string, course string) ([]KeyValue, error)

Jump to

Keyboard shortcuts

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