controller

package
Version: v0.0.0-...-f2f702e Latest Latest
Warning

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

Go to latest
Published: Aug 19, 2019 License: GPL-3.0 Imports: 29 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AdminAssignmentCreateGET

func AdminAssignmentCreateGET(w http.ResponseWriter, r *http.Request)

AdminAssignmentCreateGET handles GET-request from /admin/assigment/create

func AdminAssignmentCreatePOST

func AdminAssignmentCreatePOST(w http.ResponseWriter, r *http.Request)

AdminAssignmentCreatePOST handles POST-request from /admin/assigment/create

func AdminAssignmentGET

func AdminAssignmentGET(w http.ResponseWriter, r *http.Request)

AdminAssignmentGET handles GET-request at /admin/assignment

func AdminAssignmentGetReportGET

func AdminAssignmentGetReportGET(w http.ResponseWriter, r *http.Request)

AdminAssignmentGetReportGET handles GET-request to /admin/assignment/{id}/report

func AdminAssignmentReviewGET

func AdminAssignmentReviewGET(w http.ResponseWriter, r *http.Request)

AdminAssignmentReviewGET handles request to /admin/assignment/{id}/review

func AdminAssignmentReviewsUpdateGET

func AdminAssignmentReviewsUpdateGET(w http.ResponseWriter, r *http.Request)

AdminAssignmentReviewsUpdateGET handles GET-requests

to /admin/assignment/{assignmentID:[0-9]+}/review/{targetID:[0-9]+}/{reviewerID:[0-9]+}/update

func AdminAssignmentReviewsUpdatePOST

func AdminAssignmentReviewsUpdatePOST(w http.ResponseWriter, r *http.Request)

AdminAssignmentReviewsUpdatePOST handles POST-requests

to /admin/assignment/{assignmentID:[0-9]+}/review/{targetID:[0-9]+}/{reviewerID:[0-9]+}/update

func AdminAssignmentSingleReviewGET

func AdminAssignmentSingleReviewGET(w http.ResponseWriter, r *http.Request)

AdminAssignmentSingleReviewGET handles request to /admin/assignment/{id}/review/{id}

func AdminAssignmentSingleReviewsDoneGET

func AdminAssignmentSingleReviewsDoneGET(w http.ResponseWriter, r *http.Request)

AdminAssignmentSingleReviewsDoneGET handles GET-request to /admin/assignment/{id}/reviews_done/{id}

func AdminAssignmentSingleSubmissionGET

func AdminAssignmentSingleSubmissionGET(w http.ResponseWriter, r *http.Request)

AdminAssignmentSingleSubmissionGET handles GET-request at /admin/assignment/{id}/submission/{id}

func AdminAssignmentSubmissionCreateGET

func AdminAssignmentSubmissionCreateGET(w http.ResponseWriter, r *http.Request)

AdminAssignmentSubmissionCreateGET func

func AdminAssignmentSubmissionCreatePOST

func AdminAssignmentSubmissionCreatePOST(w http.ResponseWriter, r *http.Request)

AdminAssignmentSubmissionCreatePOST func

func AdminAssignmentSubmissionDELETE

func AdminAssignmentSubmissionDELETE(w http.ResponseWriter, r *http.Request)

AdminAssignmentSubmissionDELETE func

func AdminAssignmentSubmissionUpdateGET

func AdminAssignmentSubmissionUpdateGET(w http.ResponseWriter, r *http.Request)

AdminAssignmentSubmissionUpdateGET func

func AdminAssignmentSubmissionUpdatePOST

func AdminAssignmentSubmissionUpdatePOST(w http.ResponseWriter, r *http.Request)

AdminAssignmentSubmissionUpdatePOST func

func AdminAssignmentSubmissionsGET

func AdminAssignmentSubmissionsGET(w http.ResponseWriter, r *http.Request)

AdminAssignmentSubmissionsGET servers list of all users in course to admin /admin/assignment/{id}/submissions

func AdminChangePassGET

func AdminChangePassGET(w http.ResponseWriter, r *http.Request)

AdminChangePassGET serves the change password for students page and changes password if it's variables in the url

func AdminCourseAllAssignments

func AdminCourseAllAssignments(w http.ResponseWriter, r *http.Request)

AdminCourseAllAssignments handles GET-request @ /course/{id:[0-9]+}/assignments

func AdminCourseGET

func AdminCourseGET(w http.ResponseWriter, r *http.Request)

AdminCourseGET handles GET-request at /admin/course

func AdminCreateCourseGET

func AdminCreateCourseGET(w http.ResponseWriter, r *http.Request)

AdminCreateCourseGET handles GET-request at /admin/course/create

func AdminCreateCoursePOST

func AdminCreateCoursePOST(w http.ResponseWriter, r *http.Request)

AdminCreateCoursePOST handles POST-request at /admin/course/create Inserts a new course to the database

func AdminEmailCourseGET

func AdminEmailCourseGET(w http.ResponseWriter, r *http.Request)

AdminEmailCourseGET handles GET-request @ /course/email/{id:[0-9]+}

func AdminEmailCoursePOST

func AdminEmailCoursePOST(w http.ResponseWriter, r *http.Request)

AdminEmailCoursePOST handles POST-request @ /course/email/{id:[0-9]+}

func AdminFaqEditGET

func AdminFaqEditGET(w http.ResponseWriter, r *http.Request)

AdminFaqEditGET returns the edit view for the faq

func AdminFaqGET

func AdminFaqGET(w http.ResponseWriter, r *http.Request)

AdminFaqGET handles GET-request at admin/faq/index

func AdminFaqNewGET

func AdminFaqNewGET(w http.ResponseWriter, r *http.Request)

AdminFaqNewGET creates new faq and serves it to user

func AdminFaqUpdatePOST

func AdminFaqUpdatePOST(w http.ResponseWriter, r *http.Request)

AdminFaqUpdatePOST handles the edited markdown faq

func AdminGET

func AdminGET(w http.ResponseWriter, r *http.Request)

AdminGET handles GET-request at /admin

func AdminGetUsersPOST

func AdminGetUsersPOST(w http.ResponseWriter, r *http.Request)

AdminGetUsersPOST serves the same page as above, but with the list of all students in a course

func AdminLogsGet

func AdminLogsGet(w http.ResponseWriter, r *http.Request)

AdminLogsGet serves the logs page

func AdminReviewCreateGET

func AdminReviewCreateGET(w http.ResponseWriter, r *http.Request)

AdminReviewCreateGET handles GET-requests @ /admin/review/create

func AdminReviewCreatePOST

func AdminReviewCreatePOST(w http.ResponseWriter, r *http.Request)

AdminReviewCreatePOST handles POST-requests @ /admin/review/create

func AdminReviewDELETE

func AdminReviewDELETE(w http.ResponseWriter, r *http.Request)

AdminReviewDELETE handles DELETE-request @ /admin/review/delete

func AdminReviewGET

func AdminReviewGET(w http.ResponseWriter, r *http.Request)

AdminReviewGET handles GET-requests @ /admin/review

func AdminReviewUpdateGET

func AdminReviewUpdateGET(w http.ResponseWriter, r *http.Request)

AdminReviewUpdateGET handles GET-requests @ /admin/review/update/{id:[0-9]+}

func AdminReviewUpdatePOST

func AdminReviewUpdatePOST(w http.ResponseWriter, r *http.Request)

AdminReviewUpdatePOST handles POST-requests @ /admin/review/update

func AdminReviewUpdateUsedPOST

func AdminReviewUpdateUsedPOST(w http.ResponseWriter, r *http.Request)

AdminReviewUpdateUsedPOST func

func AdminReviewUpdateWeightsGET

func AdminReviewUpdateWeightsGET(w http.ResponseWriter, r *http.Request)

AdminReviewUpdateWeightsGET func

func AdminReviewUpdateWeightsPOST

func AdminReviewUpdateWeightsPOST(w http.ResponseWriter, r *http.Request)

AdminReviewUpdateWeightsPOST func

func AdminSettingsGET

func AdminSettingsGET(w http.ResponseWriter, r *http.Request)

AdminSettingsGET handles GET-request at admin/setting

func AdminSettingsImportGET

func AdminSettingsImportGET(w http.ResponseWriter, r *http.Request)

AdminSettingsImportGET handles GET-request at admin/setting/import

func AdminSettingsImportPOST

func AdminSettingsImportPOST(w http.ResponseWriter, r *http.Request)

AdminSettingsImportPOST handles POST-request at admin/setting/import

func AdminSettingsPOST

func AdminSettingsPOST(w http.ResponseWriter, r *http.Request)

AdminSettingsPOST handles POST-request at admin/setting

func AdminSingleAssignmentGET

func AdminSingleAssignmentGET(w http.ResponseWriter, r *http.Request)

AdminSingleAssignmentGET handles GET-request at admin/assignment/{id}

func AdminSubmissionCreateGET

func AdminSubmissionCreateGET(w http.ResponseWriter, r *http.Request)

AdminSubmissionCreateGET handles GET-request to /admin/submission/create

func AdminSubmissionCreatePOST

func AdminSubmissionCreatePOST(w http.ResponseWriter, r *http.Request)

AdminSubmissionCreatePOST handles POST-request to /admin/submission/create

func AdminSubmissionDELETE

func AdminSubmissionDELETE(w http.ResponseWriter, r *http.Request)

AdminSubmissionDELETE handles DELETE-request @ /admin/submission/delete

func AdminSubmissionGET

func AdminSubmissionGET(w http.ResponseWriter, r *http.Request)

AdminSubmissionGET handles GET-request to /admin/submission

func AdminSubmissionUpdateGET

func AdminSubmissionUpdateGET(w http.ResponseWriter, r *http.Request)

AdminSubmissionUpdateGET handles GET-request @ /admin/submission/update/{id:[0-9]+}

func AdminSubmissionUpdatePOST

func AdminSubmissionUpdatePOST(w http.ResponseWriter, r *http.Request)

AdminSubmissionUpdatePOST handles POST-request @ /admin/submission/update

func AdminSubmissionUpdateUsedPOST

func AdminSubmissionUpdateUsedPOST(w http.ResponseWriter, r *http.Request)

AdminSubmissionUpdateUsedPOST func

func AdminSubmissionUpdateWeightsGET

func AdminSubmissionUpdateWeightsGET(w http.ResponseWriter, r *http.Request)

AdminSubmissionUpdateWeightsGET func

func AdminSubmissionUpdateWeightsPOST

func AdminSubmissionUpdateWeightsPOST(w http.ResponseWriter, r *http.Request)

AdminSubmissionUpdateWeightsPOST func

func AdminUpdateAssignmentGET

func AdminUpdateAssignmentGET(w http.ResponseWriter, r *http.Request)

AdminUpdateAssignmentGET handles GET-request at /admin/assignment/update/{id}

func AdminUpdateAssignmentPOST

func AdminUpdateAssignmentPOST(w http.ResponseWriter, r *http.Request)

AdminUpdateAssignmentPOST handles POST-request at /admin/assignment/update

func AdminUpdateCourseGET

func AdminUpdateCourseGET(w http.ResponseWriter, r *http.Request)

AdminUpdateCourseGET handles GET-request at /admin/course/update/{id}

func AdminUpdateCoursePOST

func AdminUpdateCoursePOST(w http.ResponseWriter, r *http.Request)

AdminUpdateCoursePOST handles POST-request at /admin/course/update

func AssignmentAutoGET

func AssignmentAutoGET(w http.ResponseWriter, r *http.Request)

AssignmentAutoGET serves the auto validation page to user

func AssignmentGET

func AssignmentGET(w http.ResponseWriter, r *http.Request)

AssignmentGET serves assignment page to users

func AssignmentGroupCreateGET

func AssignmentGroupCreateGET(w http.ResponseWriter, r *http.Request)

AssignmentGroupCreateGET handles GET-requests @ /assignment/group/create

func AssignmentGroupCreatePOST

func AssignmentGroupCreatePOST(w http.ResponseWriter, r *http.Request)

AssignmentGroupCreatePOST handles POST-requests @ /assignment/group/create

func AssignmentGroupJoinGET

func AssignmentGroupJoinGET(w http.ResponseWriter, r *http.Request)

AssignmentGroupJoinGET handles GET-requests @ /assignment/{aid}/join_group/{gid}

func AssignmentGroupLeaveGET

func AssignmentGroupLeaveGET(w http.ResponseWriter, r *http.Request)

AssignmentGroupLeaveGET handles GET-requests @ /assignment/{aid}/leave_group

func AssignmentPeerGET

func AssignmentPeerGET(w http.ResponseWriter, r *http.Request)

AssignmentPeerGET serves the peer review page to users

func AssignmentReviewRequestPOST

func AssignmentReviewRequestPOST(w http.ResponseWriter, r *http.Request)

AssignmentReviewRequestPOST requests a new review to be assigned

func AssignmentSingleGET

func AssignmentSingleGET(w http.ResponseWriter, r *http.Request)

AssignmentSingleGET handles GET-request @ /assignment/{id:[0-9]+}

func AssignmentUploadGET

func AssignmentUploadGET(w http.ResponseWriter, r *http.Request)

AssignmentUploadGET serves the upload page

func AssignmentUploadPOST

func AssignmentUploadPOST(w http.ResponseWriter, r *http.Request)

AssignmentUploadPOST handles POST-request @ /assignment/submission/update

func AssignmentUserSubmissionGET

func AssignmentUserSubmissionGET(w http.ResponseWriter, r *http.Request)

AssignmentUserSubmissionGET serves one user submission to admin and the peer reviews

func AssignmentUserSubmissionPOST

func AssignmentUserSubmissionPOST(w http.ResponseWriter, r *http.Request)

AssignmentUserSubmissionPOST handles POST-request @ /assignment/{id:[0-9]+}/submission/{userid:[0-9]+}

func AssignmentWithdrawGET

func AssignmentWithdrawGET(w http.ResponseWriter, r *http.Request)

AssignmentWithdrawGET handles GET-requests for withdrawing submissions

func ConfirmEmailGET

func ConfirmEmailGET(w http.ResponseWriter, r *http.Request)

ConfirmEmailGET validates new email requests from users

func ConfirmGET

func ConfirmGET(w http.ResponseWriter, r *http.Request)

ConfirmGET validates register requests from users

func CourseGET

func CourseGET(w http.ResponseWriter, r *http.Request)

CourseGET serves class page to users

func CourseListGET

func CourseListGET(w http.ResponseWriter, r *http.Request)

CourseListGET serves class list page to users

func ErrorHandler

func ErrorHandler(w http.ResponseWriter, r *http.Request, status int)

ErrorHandler handles displaying errors for the clients

func ForgottenGET

func ForgottenGET(w http.ResponseWriter, r *http.Request)

ForgottenGET serves the forgotten password page to students

func ForgottenPOST

func ForgottenPOST(w http.ResponseWriter, r *http.Request)

ForgottenPOST checks routes the two different post requests

func IndexGET

func IndexGET(w http.ResponseWriter, r *http.Request)

IndexGET serves homepage to authenticated users, send anonymous to login

func JoinCoursePOST

func JoinCoursePOST(w http.ResponseWriter, r *http.Request)

JoinCoursePOST adds user to course

func LoginGET

func LoginGET(w http.ResponseWriter, r *http.Request)

LoginGET serves login page to users

func LoginPOST

func LoginPOST(w http.ResponseWriter, r *http.Request)

LoginPOST validates login requests

func LogoutGET

func LogoutGET(w http.ResponseWriter, r *http.Request)

LogoutGET logs out logged in users

func MethodNotAllowedHandler

func MethodNotAllowedHandler(w http.ResponseWriter, r *http.Request)

MethodNotAllowedHandler handles 405 errors

func NotFoundHandler

func NotFoundHandler(w http.ResponseWriter, r *http.Request)

NotFoundHandler handles 404 errors

func PrivacyGET

func PrivacyGET(w http.ResponseWriter, r *http.Request)

PrivacyGET serves privay policy page

func RegisterGET

func RegisterGET(w http.ResponseWriter, r *http.Request)

RegisterGET serves register page to users

func RegisterPOST

func RegisterPOST(w http.ResponseWriter, r *http.Request)

RegisterPOST validates register requests from users

func UserGET

func UserGET(w http.ResponseWriter, r *http.Request)

UserGET serves user page to users

func UserUpdatePOST

func UserUpdatePOST(w http.ResponseWriter, r *http.Request)

UserUpdatePOST changes the user information

Types

type Combined

type Combined struct {
	Answer model.Answer
	Field  model.Field
}

Combined holds answer and field

type MergedAnswerField

type MergedAnswerField struct {
	Items []Combined
}

MergedAnswerField is a struct for merging the answer and field array

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL