2022-12-15 20:44:03 +01:00
|
|
|
from marshmallow import fields, Schema, validate
|
|
|
|
|
|
|
|
POINTS = [0, 1, 3, 4]
|
2022-06-12 22:20:10 +02:00
|
|
|
|
|
|
|
|
2022-10-27 16:59:12 +02:00
|
|
|
class ProjectSupervisorSchema(Schema):
|
2022-06-12 22:20:10 +02:00
|
|
|
first_name = fields.Str()
|
|
|
|
last_name = fields.Str()
|
2022-06-13 18:27:30 +02:00
|
|
|
email = fields.Str()
|
2022-06-12 22:20:10 +02:00
|
|
|
available_groups = fields.Integer()
|
|
|
|
|
|
|
|
|
2022-10-27 16:59:12 +02:00
|
|
|
class ProjectSupervisorPaginationSchema(Schema):
|
2022-06-12 22:20:10 +02:00
|
|
|
project_supervisors = fields.List(fields.Nested(ProjectSupervisorSchema))
|
|
|
|
max_pages = fields.Integer()
|
|
|
|
|
|
|
|
|
2022-10-27 16:59:12 +02:00
|
|
|
class ProjectSupervisorQuerySchema(Schema):
|
2022-06-12 22:20:10 +02:00
|
|
|
page = fields.Integer()
|
|
|
|
per_page = fields.Integer()
|
2022-10-27 16:59:12 +02:00
|
|
|
|
|
|
|
|
|
|
|
class TemporaryStudentSchema(Schema):
|
|
|
|
student_index = fields.Integer(required=True)
|
|
|
|
|
|
|
|
|
|
|
|
class MessageSchema(Schema):
|
|
|
|
message = fields.Str()
|
2022-11-12 16:18:07 +01:00
|
|
|
|
|
|
|
|
|
|
|
class ExaminationScheduleSchema(Schema):
|
|
|
|
id = fields.Integer()
|
|
|
|
title = fields.Str()
|
|
|
|
start_date = fields.DateTime()
|
|
|
|
end_date = fields.DateTime()
|
|
|
|
|
|
|
|
|
|
|
|
class ExaminationScheduleListSchema(Schema):
|
|
|
|
examination_schedules = fields.List(fields.Nested(ExaminationScheduleSchema))
|
2022-11-16 20:42:40 +01:00
|
|
|
|
|
|
|
|
2022-11-17 10:21:36 +01:00
|
|
|
class ProjectSupervisorCommitteeSchema(Schema):
|
|
|
|
id = fields.Integer()
|
|
|
|
first_name = fields.Str()
|
|
|
|
last_name = fields.Str()
|
|
|
|
|
|
|
|
|
2022-11-16 20:42:40 +01:00
|
|
|
class TermOfDefenceStudentItemSchema(Schema):
|
|
|
|
id = fields.Integer()
|
|
|
|
start_date = fields.DateTime()
|
|
|
|
end_date = fields.DateTime()
|
2022-11-17 10:21:36 +01:00
|
|
|
members_of_committee = fields.List(fields.Nested(ProjectSupervisorCommitteeSchema))
|
2022-11-16 20:42:40 +01:00
|
|
|
|
|
|
|
|
|
|
|
class TermOfDefenceStudentListSchema(Schema):
|
|
|
|
term_of_defences = fields.List(fields.Nested(TermOfDefenceStudentItemSchema))
|
|
|
|
|
|
|
|
|
|
|
|
class YearGroupStudentSchema(Schema):
|
|
|
|
id = fields.Integer()
|
|
|
|
name = fields.Str()
|
|
|
|
mode = fields.Str()
|
|
|
|
|
|
|
|
|
|
|
|
class YearGroupStudentPaginationSchema(Schema):
|
|
|
|
year_groups = fields.List(fields.Nested(YearGroupStudentSchema))
|
|
|
|
max_pages = fields.Integer()
|
|
|
|
|
|
|
|
|
|
|
|
class YearGroupQueryStudentSchema(Schema):
|
|
|
|
index = fields.Integer(required=True) # it will be removed
|
|
|
|
page = fields.Integer()
|
|
|
|
per_page = fields.Integer()
|
2022-12-15 20:44:03 +01:00
|
|
|
|
|
|
|
|
|
|
|
class StudentIndexQueryTempSchema(Schema):
|
|
|
|
index = fields.Integer(required=True) # it will be removed
|
|
|
|
term = fields.Integer(required=True, validate=validate.OneOf([1, 2]))
|
|
|
|
|
|
|
|
|
|
|
|
class ProjectGradeSheetEditFirstTermSchema(Schema):
|
|
|
|
presentation_required_content_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
presentation_was_compatible_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
presentation_showing_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
presentation_answers_to_questions_from_committee_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
|
|
|
|
documentation_project_vision_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
documentation_requirements_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
documentation_for_clients_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
documentation_for_developers_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
documentation_license_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
|
|
|
|
group_work_regularity_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
group_work_division_of_work_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
group_work_contact_with_client_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
group_work_management_of_risk_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
group_work_work_methodology_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
group_work_management_of_source_code_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
group_work_devops_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
|
|
|
|
products_project_complexity_of_product_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_access_to_application_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_security_issues_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_access_to_test_application_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_acceptance_criteria_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_expected_functionality_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_promises_well_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_has_been_implemented_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_is_useful_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_prototype_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_tests_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_technology_1 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
|
|
|
|
|
|
|
|
class ProjectGradeSheetDetailFirstTermSchema(ProjectGradeSheetEditFirstTermSchema):
|
|
|
|
id = fields.Integer()
|
|
|
|
|
|
|
|
|
|
|
|
class ProjectGradeSheetEditSecondTermSchema(Schema):
|
|
|
|
presentation_required_content_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
presentation_was_compatible_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
presentation_showing_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
presentation_answers_to_questions_from_committee_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
|
|
|
|
documentation_project_vision_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
documentation_requirements_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
documentation_for_clients_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
documentation_for_developers_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
documentation_license_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
|
|
|
|
group_work_regularity_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
group_work_division_of_work_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
group_work_contact_with_client_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
group_work_management_of_risk_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
group_work_work_methodology_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
group_work_management_of_source_code_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
group_work_devops_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
|
|
|
|
products_project_complexity_of_product_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_access_to_application_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_security_issues_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_access_to_test_application_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_acceptance_criteria_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_expected_functionality_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_promises_well_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_has_been_implemented_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_is_useful_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_prototype_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_tests_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
products_project_technology_2 = fields.Integer(validate=validate.OneOf(POINTS))
|
|
|
|
|
|
|
|
|
|
|
|
class ProjectGradeSheetDetailSecondTermSchema(ProjectGradeSheetEditSecondTermSchema):
|
|
|
|
id = fields.Integer()
|