From dad7eceb7a5532be35a2a660e778114904eb2879 Mon Sep 17 00:00:00 2001 From: yuqi88 Date: Tue, 28 Jun 2022 17:06:21 -0700 Subject: [PATCH 1/6] update files in views and template tages --- TFrepo/templatetages_files.md | 16 +++++++--------- TFrepo/views_files.md | 20 +++++++++----------- 2 files changed, 16 insertions(+), 20 deletions(-) diff --git a/TFrepo/templatetages_files.md b/TFrepo/templatetages_files.md index 5b8411f..59291c0 100644 --- a/TFrepo/templatetages_files.md +++ b/TFrepo/templatetages_files.md @@ -1,13 +1,11 @@ # 9. templatetags -This folder handles the logic to display for some tab on the app: Attributes (vector_extras.py), -Projects (projects_extras.py), Teams (teams_extras.py), Peer Evaluations (peer_eval_extras.py). - -Additional functions other than the ones called from the utils folder will be explained below: +Functions within files under this folder accept value(s) or an optional argument, and return a value to be displayed +on the page. * __init__.py * algorithm_extras.py - corresponds to the file under utils folder: teams: algorithm.py -* app_extras.py - functions to run the app including request-related, etc. Also, functions calling the utils folders nav-bar related, setup related, etc. -* peer_eval_extras.py -* project_extras.py -* team_extras.py -* vector_extras.py \ No newline at end of file +* app_extras.py - functions to run the app including request-related, etc. Also, includes functions calling the utils folders nav-bar related, setup related, etc. +* peer_eval_extras.py - getter functions and helper functions to get peer evaluation questions, team, names, summaries of feedback and stats of scores etc. +* project_extras.py - includes a function to get the form under forms folder: project.py +* team_extras.py - includes a form to regenerate team using form defined under forms folder: generate_team.py +* vector_extras.py - includes getter functions to determine attribute types and details. \ No newline at end of file diff --git a/TFrepo/views_files.md b/TFrepo/views_files.md index 2ac522e..12925cd 100644 --- a/TFrepo/views_files.md +++ b/TFrepo/views_files.md @@ -1,20 +1,18 @@ # 12. views -There is one file per that handles the logic for each tab on the app: Section (sections.py), Students (students.py), -Attributes (vector.py), Projects (projects.py), Surveys (survey), Teams (teams.py), -Peer Evaluations (peer_evaluation.py). +In this folder, each file has python functions that takes http requests, load a template from the template folder +, and returns http response with the result of the rendered template. -Additional explanation of the other files are below: * __init__.py * admin.py - specific to the admin interface * course.py - for page that lists courses available to the logged in user (this view is skipped when integrated directly on Canvas) * peer_eval_vector.py - creating attributes specific to peer evaluations * peer_evaluation.py - handles functions related to the peer evaluations page. Including creation, view, deletion of peer evaluations etc. -* projects.py -* question.py - handling question form and associating the answer group for the attribute -* sections.py -* student.py -* survey.py -* teams.py -* vector.py +* projects.py - handles http requests made on the Project page and displays the Project page. +* question.py - handling http requests and displays forms and associating the answer group for an attribute. +* sections.py - handles http requests made on the Section page and displays the Sections page. +* student.py - handles http requests made on the Student page and displays the Student page. +* survey.py - handles http requests made on the Survey page and displays the Survey page. +* teams.py - handles http requests made on the Teams page and displays the Team page. +* vector.py - handles http requests made on the Attribute page and displays the Attribute page. From 29bcec7c1f457305f37ad9106b7f0777ea956937 Mon Sep 17 00:00:00 2001 From: yuqi88 Date: Tue, 28 Jun 2022 17:08:09 -0700 Subject: [PATCH 2/6] add tasks folder --- TFrepo/_index.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/TFrepo/_index.md b/TFrepo/_index.md index 3455c52..0ddaef9 100644 --- a/TFrepo/_index.md +++ b/TFrepo/_index.md @@ -27,7 +27,9 @@ These are migration files for the database that are auto-generated via command l All the database model files. # 6. tasks folder -The files in this folder pertain to any asynchronous data processing tasks needed on the site where we do not want to keep the user waiting. +The files in this folder pertain to any asynchronous data processing tasks needed on the site where we do not want to keep the user waiting. + +See [files](tasks_files.md). # 7. team_generator folder (bowen to do) This folder contains all the team algorithm details. From fe4521ef72b0a19fb4d7494200e546fe1dfe3120 Mon Sep 17 00:00:00 2001 From: yuqi88 Date: Tue, 28 Jun 2022 17:08:16 -0700 Subject: [PATCH 3/6] add tasks folder --- TFrepo/tasks_files.md | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 TFrepo/tasks_files.md diff --git a/TFrepo/tasks_files.md b/TFrepo/tasks_files.md new file mode 100644 index 0000000..7ce00bb --- /dev/null +++ b/TFrepo/tasks_files.md @@ -0,0 +1,6 @@ +# 6. tasks folder + +* __init__.py +* attendance_tasks.py +* import_tasks.py +* team_generation_tasks.py \ No newline at end of file From 781a0159bdbe8b09f5ee08984e5d82447aa804fd Mon Sep 17 00:00:00 2001 From: yuqi88 Date: Tue, 28 Jun 2022 19:19:16 -0700 Subject: [PATCH 4/6] finish 6. tasks --- TFrepo/tasks_files.md | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/TFrepo/tasks_files.md b/TFrepo/tasks_files.md index 7ce00bb..6a7f78e 100644 --- a/TFrepo/tasks_files.md +++ b/TFrepo/tasks_files.md @@ -1,6 +1,8 @@ # 6. tasks folder +Related to transaction with the database. * __init__.py -* attendance_tasks.py -* import_tasks.py -* team_generation_tasks.py \ No newline at end of file +* attendance_tasks.py - updates the database of setting course attendance status to false. +* import_tasks.py - updates the database of teams info including team names, ids, members' Canvas info. +* team_generation_tasks.py - related to saving data between Canvas and the database. Data such as + course info, students, roles, students' enrollment status, and team sets on both end. \ No newline at end of file From 50ac7c64a4c61bd5f2b2aa86a6ac0e1ae6663be2 Mon Sep 17 00:00:00 2001 From: yuqi88 Date: Tue, 28 Jun 2022 19:29:25 -0700 Subject: [PATCH 5/6] add models files --- TFrepo/models_files.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 TFrepo/models_files.md diff --git a/TFrepo/models_files.md b/TFrepo/models_files.md new file mode 100644 index 0000000..d4459f4 --- /dev/null +++ b/TFrepo/models_files.md @@ -0,0 +1,19 @@ +# 5. models folder + +* __init__.py +* attendance.py +* canvas_course.py +* canvas_group.py +* canvas_user.py +* canvas_onboard.py +* generated_group.py +* group_settings.py +* information_log.py +* peer_eval_vector.py +* peer_evaluation.py\ +* project.py +* question.py +* survey.py +* vector.py +* vector_quiz_question.py +* vector_response.py \ No newline at end of file From dd33cd793d6ab397756917f7c843ad2d63c22203 Mon Sep 17 00:00:00 2001 From: yuqi88 Date: Tue, 12 Jul 2022 11:28:04 -0700 Subject: [PATCH 6/6] add forms file --- TFrepo/_index.md | 2 ++ TFrepo/forms_files.md | 61 +++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 63 insertions(+) create mode 100644 TFrepo/forms_files.md diff --git a/TFrepo/_index.md b/TFrepo/_index.md index 0ddaef9..40b50b0 100644 --- a/TFrepo/_index.md +++ b/TFrepo/_index.md @@ -17,6 +17,8 @@ This folder has files that relates to the fake data made for testing purposes. F # 2. forms folder All the forms on the website that requires any UI or logic customization. +See [files](forms_files.md). + # 3. management folder When you want to make a terminal command, the files are done here. All of these commands can only be run with system administrator access. diff --git a/TFrepo/forms_files.md b/TFrepo/forms_files.md new file mode 100644 index 0000000..21d32a4 --- /dev/null +++ b/TFrepo/forms_files.md @@ -0,0 +1,61 @@ +# 2. forms folder + +## Top level files +* __init__.py +* base.py - a template form used for other forms in this forms folder. +* generate_team.py - forms used to generate new teams + (1) GeneratedGroupSetSetupForm - used to generate teams on the Teams page in the List of Team Sets section (step 1/2). Form seen after pressing the button Generate Teams. + (2) NewTeamSizeOptionForm - used to generate teams (step 2/2) with details on tweaking the algorithm chosen from the previous step. + (3) NewBlacklistOptionForm - used to generate teams (step 2/2) with details about including Enemies Preference into the algorithm chosen from the previous step. + (4) NewWeightOptionForm - used to generate teams (step 2/2) with details about the weights depending on the algorithm chosen. + (5) NewDiversityOptionForm - used to generate teams (step 2/2) with details on tweaking the chosen algorithm (weight algorithm & social algorithm). + (6) NewPeerEvaluationOptionForm - Not in use. + (7) NewPriorityOptionForm - used to generate teams (step 2/2) with details on tweaking the chosen algorithm (priority algorithm). + (8) RegenerateGroupsForm - used to take the input of a list of teams that the user may lock for regenerating groups. + +* gradebook_graph.py - Not in use. +* label_value.py - responsible for taking in peer evaluation attributes. + Form is used in (step 2/2) after clicking button Create New Peer Evaluation Attribute on the Peer Evaluation page and . + (step 2/2) of creating a new attribute in the Attribute page. +* new_answer_group.py - the section where a newly created answer group is asked within Create New Attribute step 2/2. +* new_question.py - represents the questions asked for Create New Attribute step 2/2. +* new_section.py - used to ask the name of a new section within Create New Section or Edit section. +* peer_eval.py - used to create new peer evaluations. Access form by the Create New Peer Evaluation on the Peer Evaluation page. +* peer_eval_vector.py - forms related to peer evaluation attributes. + (1) PeerEvalVectorJunctionForm - the last section to create new peer evaluations. Access form by the Create New Peer Evaluation on the Peer Evaluation page. + (2) SelectPeerEvalVectorForm - Not in use. + (3) PeerEvalVectorForm - used to create new peer evaluation attributes. Access form by the button Create New Peer Evaluation Attribute in step 2/2. + (4) PeerEvalMultipleChoiceVectorForm - maps to the PeerEvalMultipleChoiceVector model. + (5) PeerEvalCheckboxVectorForm - maps to the PeerEvalCheckboxVector model. + (6) PeerEvalTextInputVectorForm - maps to the PeerEvalTextInputVector model. +* project.py +* (1) ProjectSetForm - used to create new project sets. Accessed by the button Create New Project Set. +* (2) ProjectForm - used to create new project. Accessed by the button Edit on selected project set and the button to Add New Project. +* (3) ProjectRequirementForm - used to create new project. Accessed by the button Edit on selected project set and the button to Add New Project. +* (4) ProjectDuplicateForm - used to ask how many projects the user would like to duplicate from a selected project. Accessed by the button Duplicate on a selected project (Edit on a selected project set). + +* survey.py - used to create new surveys. +* vector.py - related to creating surveys and attributes. + (1) SelectSurveyVectorForm - Not in use. + (2) SurveyVectorJunctionForm - used to create new surveys. + (3) SurveyVectorForm - a template form used for other forms in this file. + (4) SurveyPreferenceVectorForm - used to define VECTOR_TYPES (attriubte types). Form accessed by step 1/2 of creating a new attribute. + (5) SurveyBlacklistVectorForm - used to define VECTOR_TYPES (attriubte types). Form accessed by step 1/2 of creating a new attribute. + (6) SurveyComplexMultipartVectorForm - used to define VECTOR_TYPES (attriubte types). Form accessed by step 1/2 of creating a new attribute. + (7) SurveyMultipleChoiceVectorForm - used to define VECTOR_TYPES (attriubte types). Form accessed by step 1/2 of creating a new attribute. + (8) SurveyCheckboxVectorForm - used to define VECTOR_TYPES (attriubte types). Form accessed by step 1/2 of creating a new attribute. + +## forms: fields +* __init__.py +* custom_form_field.py - form field templates used in other files in the form folder. + +## forms: formsets +* __init__.py +* peer_eval_vector.py - customize forsets for peer evaluation attribute forms. +* project.py - customize forsets for project forms. +* util.py - a formset template used in other files in the folder. +* vector.py - customize forsets for attribute forms. + +## forms: widgets +* __init__.py +* integer_select.py - customize widgets. \ No newline at end of file