Updated basically the rest of the pages.
This commit is contained in:
parent
13dd59aa8f
commit
3333fec82e
|
@ -1,5 +1,6 @@
|
||||||
package nl.andrewlalis.teaching_assistant_assistant.controllers.students.entity;
|
package nl.andrewlalis.teaching_assistant_assistant.controllers.students.entity;
|
||||||
|
|
||||||
|
import nl.andrewlalis.teaching_assistant_assistant.controllers.UserPageController;
|
||||||
import nl.andrewlalis.teaching_assistant_assistant.model.people.Student;
|
import nl.andrewlalis.teaching_assistant_assistant.model.people.Student;
|
||||||
import nl.andrewlalis.teaching_assistant_assistant.model.repositories.StudentRepository;
|
import nl.andrewlalis.teaching_assistant_assistant.model.repositories.StudentRepository;
|
||||||
import nl.andrewlalis.teaching_assistant_assistant.services.StudentService;
|
import nl.andrewlalis.teaching_assistant_assistant.services.StudentService;
|
||||||
|
@ -16,7 +17,7 @@ import java.util.Optional;
|
||||||
* Controller for editing a student entity.
|
* Controller for editing a student entity.
|
||||||
*/
|
*/
|
||||||
@Controller("/students/{id}/edit")
|
@Controller("/students/{id}/edit")
|
||||||
public class StudentEntityEditController {
|
public class StudentEntityEditController extends UserPageController {
|
||||||
|
|
||||||
private StudentRepository studentRepository;
|
private StudentRepository studentRepository;
|
||||||
private StudentService studentService;
|
private StudentService studentService;
|
||||||
|
|
|
@ -1,24 +1,22 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (~{::title}, ~{::#content}, ~{::#sidebar_content})}">
|
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (title='Import Students From CSV', content=~{::#content})}">
|
||||||
<head>
|
<head>
|
||||||
<title>Import Students via CSV</title>
|
<title>Import Students via CSV</title>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<div id="content">
|
<div id="content" class="row justify-content-center">
|
||||||
<h1>Import Students from CSV File</h1>
|
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
Use this form to import student data from a CSV which has been generated by a Google form. As of right now, the column headers are hard-coded, but in the future it will be possible to dynamically import data from any CSV file by custom header format definitions.
|
Use this form to import student data from a CSV which has been generated by a Google form. As of right now, the column headers are hard-coded, but in the future it will be possible to dynamically import data from any CSV file by custom header format definitions.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<form method="post" action="#" enctype="multipart/form-data" th:action="@{/courses/{code}/import_students(code=${course.getCode()})}">
|
<form method="post" enctype="multipart/form-data" th:action="@{/courses/{code}/import_students(code=${course.getCode()})}">
|
||||||
<div class="page_row">
|
<div class="form-row">
|
||||||
<label for="file_input">File:</label>
|
<label for="file_input">File:</label>
|
||||||
<input id="file_input" type="file" name="file" accept="text/csv"/>
|
<input id="file_input" type="file" name="file" accept="text/csv"/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="page_row">
|
<div class="form-row">
|
||||||
<button type="submit">Submit</button>
|
<button type="submit">Submit</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -26,9 +24,5 @@
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="sidebar_content">
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
|
@ -1,18 +1,33 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (~{::title}, ~{::#content}, ~{::#sidebar})}">
|
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (title='Student Teams for ' + ${course.getCode()}, content=~{::#content}, actions=~{::#actions})}">
|
||||||
<head>
|
|
||||||
<meta charset="UTF-8">
|
|
||||||
<title>Student Teams</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<div id="content">
|
<div id="actions">
|
||||||
<h1>Student Teams for <span th:text="${course.getName()}"></span></h1>
|
<a class="btn btn-primary m-1" th:href="@{/courses/{code}/student_teams/generate_repositories(code=${course.getCode()})}">
|
||||||
|
Generate Repositories
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-primary m-1" th:href="@{/courses/{code}/student_teams/branch_protection_update(code=${course.getCode()})}">
|
||||||
|
Update Branch Protection
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-primary m-1" th:href="@{/courses/{code}/student_teams/export(code=${course.getCode()})}">
|
||||||
|
Export
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-primary m-1" th:href="@{/courses/{code}/student_teams/export_contact_info(code=${course.getCode()})}">
|
||||||
|
Export Team Contact Details
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-primary m-1" th:href="@{/courses/{code}/student_teams/create(code=${course.getCode()})}">
|
||||||
|
Create New Student Team
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-primary m-1" th:href="@{/courses/{code}/student_teams/merge_single_teams(code=${course.getCode()})}">
|
||||||
|
Merge Single Teams
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="content" class="row justify-content-center">
|
||||||
<div th:if="${course.getStudentTeams().isEmpty()}">
|
<div th:if="${course.getStudentTeams().isEmpty()}">
|
||||||
<p>No student teams.</p>
|
<p>No student teams.</p>
|
||||||
</div>
|
</div>
|
||||||
<table>
|
<table class="table">
|
||||||
<tr>
|
<tr>
|
||||||
<th>Team</th>
|
<th>Team</th>
|
||||||
<th>Students</th>
|
<th>Students</th>
|
||||||
|
@ -53,26 +68,5 @@
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="sidebar">
|
|
||||||
<div class="sidebar_block">
|
|
||||||
<a th:href="@{/courses/{code}/student_teams/generate_repositories(code=${course.getCode()})}">Generate Repositories</a>
|
|
||||||
</div>
|
|
||||||
<div class="sidebar_block">
|
|
||||||
<a th:href="@{/courses/{code}/student_teams/branch_protection_update(code=${course.getCode()})}">Update Branch Protection</a>
|
|
||||||
</div>
|
|
||||||
<div class="sidebar_block">
|
|
||||||
<a th:href="@{/courses/{code}/student_teams/export(code=${course.getCode()})}">Export</a>
|
|
||||||
</div>
|
|
||||||
<div class="sidebar_block">
|
|
||||||
<a th:href="@{/courses/{code}/student_teams/export_contact_info(code=${course.getCode()})}">Export Team Contact Details</a>
|
|
||||||
</div>
|
|
||||||
<div class="sidebar_block">
|
|
||||||
<a th:href="@{/courses/{code}/student_teams/create(code=${course.getCode()})}">Create New Student Team</a>
|
|
||||||
</div>
|
|
||||||
<div class="sidebar_block">
|
|
||||||
<a th:href="@{/courses/{code}/student_teams/merge_single_teams(code=${course.getCode()})}">Merge Single Teams</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
|
@ -1,28 +1,19 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (~{::title}, ~{::#content}, ~{::#sidebar})}">
|
<html xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (title='Create Student Team', content=~{::#content})}">
|
||||||
<head>
|
|
||||||
<title>Create Student Team</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<div id="content">
|
<div id="content" class="row justify-content-center">
|
||||||
<h1>Create a New Student Team</h1>
|
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
Creates a new student team for the <span th:text="${course.getName()}"></span> course, without any assigned TA team or student members.
|
Creates a new student team for the <span th:text="${course.getName()}"></span> course, without any assigned TA team or student members.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<form action="#" th:action="@{/courses/{code}/student_teams/create(code=${course.getCode()})}" enctype="application/x-www-form-urlencoded" method="post">
|
<form th:action="@{/courses/{code}/student_teams/create(code=${course.getCode()})}" enctype="application/x-www-form-urlencoded" method="post">
|
||||||
|
|
||||||
<div class="page_row">
|
<div class="form-row">
|
||||||
<button type="submit">Submit</button>
|
<input type="submit" value="Submit" class="btn btn-primary"/>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="sidebar">
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
|
@ -1,14 +1,39 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (~{::title}, ~{::#content}, ~{::#sidebar})}">
|
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (title='Student Team ' + ${student_team.getId()}, content=~{::#content}, actions=~{::#actions})}">
|
||||||
<head>
|
|
||||||
<meta charset="UTF-8">
|
|
||||||
<title>Student Team</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<div id="content">
|
<div id="actions">
|
||||||
<h1>Student Team <span th:text="${student_team.getId()}"></span></h1>
|
<th:block th:if="${student_team.getGithubRepositoryName() == null && student_team.getAssignedTeachingAssistantTeam() != null}">
|
||||||
|
<a
|
||||||
|
class="btn btn-primary m-1"
|
||||||
|
th:href="@{/courses/{code}/student_teams/{id}/generate_repository
|
||||||
|
(code=${student_team.getCourse().getCode()}, id=${student_team.getId()})}"
|
||||||
|
>Generate Repository</a>
|
||||||
|
</th:block>
|
||||||
|
<th:block th:if="${student_team.getGithubRepositoryName() != null}">
|
||||||
|
<a
|
||||||
|
class="btn btn-primary m-1"
|
||||||
|
th:href="@{/courses/{code}/student_teams/{id}/delete_repository
|
||||||
|
(code=${student_team.getCourse().getCode()}, id=${student_team.getAssignedTeachingAssistantTeam().getId()})}"
|
||||||
|
>Archive Repository</a>
|
||||||
|
</th:block>
|
||||||
|
<a
|
||||||
|
class="btn btn-primary m-1"
|
||||||
|
th:href="@{/courses/{code}/student_teams/{id}/add_student(code=${student_team.getCourse().getCode()}, id=${student_team.getId()})}">
|
||||||
|
Add Student To Team
|
||||||
|
</a>
|
||||||
|
<a
|
||||||
|
class="btn btn-primary m-1"
|
||||||
|
th:href="@{/courses/{code}/student_teams/{id}/assign_teaching_assistant_team(code=${student_team.getCourse().getCode()}, id=${student_team.getId()})}">
|
||||||
|
Assign Teaching Assistant Team
|
||||||
|
</a>
|
||||||
|
<a
|
||||||
|
class="btn btn-primary m-1"
|
||||||
|
th:href="@{/courses/{code}/student_teams/{id}/remove(code=${student_team.getCourse().getCode()}, id=${student_team.getId()})}">Remove This Team</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="content" class="row justify-content-center">
|
||||||
<ul>
|
<ul>
|
||||||
<li>
|
<li>
|
||||||
Github Repository:
|
Github Repository:
|
||||||
|
@ -43,39 +68,13 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="sidebar">
|
<div id="sidebar">
|
||||||
<div class="sidebar_block" th:if="${student_team.getGithubRepositoryName() == null && student_team.getAssignedTeachingAssistantTeam() != null}">
|
<div class="sidebar_block" >
|
||||||
<a
|
|
||||||
th:href="@{/courses/{code}/student_teams/{id}/generate_repository
|
|
||||||
(code=${student_team.getCourse().getCode()}, id=${student_team.getId()})}"
|
|
||||||
>Generate Repository</a>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="sidebar_block" th:if="${student_team.getGithubRepositoryName() != null}">
|
<div class="sidebar_block" >
|
||||||
<a
|
|
||||||
th:href="@{/courses/{code}/student_teams/{id}/delete_repository
|
|
||||||
(code=${student_team.getCourse().getCode()}, id=${student_team.getAssignedTeachingAssistantTeam().getId()})}"
|
|
||||||
>Archive Repository</a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="sidebar_block">
|
|
||||||
<a th:href="@{/courses/{code}/student_teams/{id}/add_student(code=${student_team.getCourse().getCode()}, id=${student_team.getId()})}">
|
|
||||||
Add Student To Team
|
|
||||||
</a>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="sidebar_block">
|
|
||||||
<a th:href="@{/courses/{code}/student_teams/{id}/assign_teaching_assistant_team(code=${student_team.getCourse().getCode()}, id=${student_team.getId()})}">
|
|
||||||
Assign Teaching Assistant Team
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="sidebar_block">
|
|
||||||
<a th:href="@{/courses/{code}/student_teams/{id}/remove(code=${student_team.getCourse().getCode()}, id=${student_team.getId()})}">Remove This Team</a>
|
|
||||||
<p>
|
|
||||||
Removes this team permanently, and archives the repository.
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
|
@ -1,28 +1,22 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (~{::title}, ~{::#content}, ~{::#sidebar})}">
|
<html xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (title='Add Student To Team', content=~{::#content})}" lang="en">
|
||||||
<head>
|
|
||||||
<title>Add Student To Team</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<div id="content">
|
<div id="content" class="row justify-content-center">
|
||||||
<h1>Add a Student to Team <span th:text="${student_team.getId()}"></span></h1>
|
|
||||||
|
|
||||||
<form
|
<form
|
||||||
action="#"
|
|
||||||
th:action="@{/courses/{code}/student_teams/{id}/add_student(code=${course.getCode()}, id=${student_team.getId()})}"
|
th:action="@{/courses/{code}/student_teams/{id}/add_student(code=${course.getCode()}, id=${student_team.getId()})}"
|
||||||
enctype="application/x-www-form-urlencoded"
|
enctype="application/x-www-form-urlencoded"
|
||||||
method="post"
|
method="post"
|
||||||
>
|
>
|
||||||
<div class="page_row">
|
<div class="form-row">
|
||||||
<label for="student_select">Select a Student to Add:</label>
|
<label for="student_select">Select a Student to Add:</label>
|
||||||
<select id="student_select" name="student_id" required>
|
<select id="student_select" name="student_id" class="form-control" required>
|
||||||
<option th:each="student: ${eligible_students}" th:value="${student.getId()}" th:text="${student.getFullName()}"></option>
|
<option th:each="student: ${eligible_students}" th:value="${student.getId()}" th:text="${student.getFullName()}"></option>
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="page_row">
|
<div class="form-row">
|
||||||
<button type="submit">Submit</button>
|
<input type="submit" class="btn btn-primary" value="Submit"/>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,22 +1,16 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (~{::title}, ~{::#content}, ~{::#sidebar})}">
|
<html xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (title='Assign Teaching Assistant Team', content=~{::#content})}">
|
||||||
<head>
|
|
||||||
<title>Assign Teaching Assistant Team</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<div id="content">
|
<div id="content" class="row justify-content-center">
|
||||||
<h1>Assign a Teaching Assistant Team to Student Team <span th:text="${student_team.getId()}"></span></h1>
|
|
||||||
|
|
||||||
<form
|
<form
|
||||||
action="#"
|
|
||||||
th:action="@{/courses/{code}/student_teams/{id}/assign_teaching_assistant_team(code=${course.getCode()}, id=${student_team.getId()})}"
|
th:action="@{/courses/{code}/student_teams/{id}/assign_teaching_assistant_team(code=${course.getCode()}, id=${student_team.getId()})}"
|
||||||
enctype="application/x-www-form-urlencoded"
|
enctype="application/x-www-form-urlencoded"
|
||||||
method="post"
|
method="post"
|
||||||
>
|
>
|
||||||
<div class="page_row">
|
<div class="form-row">
|
||||||
<label for="ta_team_select">Select a Team:</label>
|
<label for="ta_team_select">Select a Team:</label>
|
||||||
<select id="ta_team_select" name="teaching_assistant_team_id">
|
<select id="ta_team_select" name="teaching_assistant_team_id" class="form-control">
|
||||||
<option value="-1">None</option>
|
<option value="-1">None</option>
|
||||||
<option
|
<option
|
||||||
th:each="team: ${course.getTeachingAssistantTeams()}" th:value="${team.getId()}"
|
th:each="team: ${course.getTeachingAssistantTeams()}" th:value="${team.getId()}"
|
||||||
|
@ -25,8 +19,8 @@
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="page_row">
|
<div class="form-row">
|
||||||
<button type="submit">Submit</button>
|
<input type="submit" value="Submit" class="btn btn-primary"/>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,16 +1,11 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (~{::title}, ~{::#content}, ~{::#sidebar})}">
|
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (title='Generate Repositories', content=~{::#content})}">
|
||||||
<head>
|
|
||||||
<meta charset="UTF-8">
|
|
||||||
<title>Generate Repositories</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<div id="content">
|
<div id="content" class="row justify-content-center">
|
||||||
<h1>Generate Repositories for all Student Teams in <span th:text="${course.getName()}"></span></h1>
|
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
Be careful, this may take a little while...
|
Generate Repositories for all Student Teams in <span th:text="${course.getName()}"></span>. Be careful, this may take a little while...
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<form
|
<form
|
||||||
|
@ -23,9 +18,5 @@
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="sidebar">
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
|
@ -1,15 +1,16 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (~{::title}, ~{::#content}, ~{::#sidebar})}">
|
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (title='Students in ' + ${course.getCode()}, content=~{::#content}, actions=~{::#actions})}">
|
||||||
<head>
|
|
||||||
<meta charset="UTF-8">
|
|
||||||
<title>Students</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<div id="content">
|
<div id="actions">
|
||||||
<h1>Students in <span th:text="${course.getName()}"></span></h1>
|
<a class="btn btn-primary m-1" th:href="@{/courses/{code}/students/invite_all(code=${course.getCode()})}">
|
||||||
|
Invite All Students To Repository
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
<table>
|
<div id="content">
|
||||||
|
<table class="table table-striped">
|
||||||
<tr>
|
<tr>
|
||||||
<th>Student</th>
|
<th>Student</th>
|
||||||
<th>Student Number</th>
|
<th>Student Number</th>
|
||||||
|
@ -25,11 +26,5 @@
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="sidebar">
|
|
||||||
<div class="sidebar_block">
|
|
||||||
<a th:href="@{/courses/{code}/students/invite_all(code=${course.getCode()})}">Invite All Students To Repository</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
|
@ -8,7 +8,7 @@
|
||||||
|
|
||||||
<div id="content">
|
<div id="content">
|
||||||
<h1>Invite All Students in <span th:text="${course.getName()}"></span> to Repository</h1>
|
<h1>Invite All Students in <span th:text="${course.getName()}"></span> to Repository</h1>
|
||||||
|
<!-- TODO: Upgrade the basic method by which students gain access to the repository. Follow instructions from Github. -->
|
||||||
<p>
|
<p>
|
||||||
Be careful, this may take a little while...
|
Be careful, this may take a little while...
|
||||||
</p>
|
</p>
|
||||||
|
|
|
@ -1,30 +1,53 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (~{::title}, ~{::#content}, ~{::#sidebar})}">
|
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (title='Teaching Assistants for ' + ${course.getCode()}, content=~{::#content}, actions=~{::#actions})}">
|
||||||
<head>
|
|
||||||
<meta charset="UTF-8">
|
|
||||||
<title>Teaching Assistant Teams</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<div id="content">
|
<div id="actions">
|
||||||
<h1>Teaching Assistant Teams for <span th:text="${course.getName()}"></span></h1>
|
<a class="btn btn-primary m-1" th:href="@{/courses/{code}/teaching_assistant_teams/create(code=${course.getCode()})}">
|
||||||
|
Create Teaching Assistant Team
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-primary m-1" th:href="@{/courses/{code}/teaching_assistant_teams/assign_to_student_teams(code=${course.getCode()})}">
|
||||||
|
Assign Teams to Student Teams
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="content" class="row justify-content-center">
|
||||||
<div th:if="${course.getTeachingAssistantTeams().isEmpty()}">
|
<div th:if="${course.getTeachingAssistantTeams().isEmpty()}">
|
||||||
<p>No teaching assistant teams.</p>
|
<p>No teaching assistant teams.</p>
|
||||||
</div>
|
</div>
|
||||||
<table>
|
<table class="table table-striped">
|
||||||
|
<tr>
|
||||||
|
<th>Team</th>
|
||||||
|
<th>Teaching Assistants</th>
|
||||||
|
<th>Github Team</th>
|
||||||
|
<th>Assigned Student Teams</th>
|
||||||
|
<th>Delete</th>
|
||||||
|
</tr>
|
||||||
<tr th:each="taTeam: ${course.getTeachingAssistantTeams()}">
|
<tr th:each="taTeam: ${course.getTeachingAssistantTeams()}">
|
||||||
<td>
|
<td>
|
||||||
<a
|
<a th:href="@{/courses/{code}/teaching_assistant_teams/{team_id}
|
||||||
th:href="@{/courses/{code}/teaching_assistant_teams/{team_id}
|
|
||||||
(code=${course.getCode()}, team_id=${taTeam.getId()})}">
|
(code=${course.getCode()}, team_id=${taTeam.getId()})}">
|
||||||
Teaching Assistant Team <span th:text="${taTeam.getId()}"></span>
|
Teaching Assistant Team <span th:text="${taTeam.getId()}"></span>
|
||||||
</a>
|
</a>
|
||||||
</td>
|
</td>
|
||||||
<td th:each="ta: ${taTeam.getTeachingAssistants()}">
|
<td>
|
||||||
<span th:text="${ta.getFullName()}"></span>
|
<div th:each="ta: ${taTeam.getTeachingAssistants()}">
|
||||||
|
<a th:href="@{/teaching_assistants/{id}(id=${ta.getId()})}" th:text="${ta.getFullName()}"></a><br>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<a
|
||||||
|
th:href="'https://www.github.com/orgs/' + ${course.getGithubOrganizationName()} + '/teams/' + ${taTeam.getGithubTeamName().toLowerCase()}"
|
||||||
|
th:text="${taTeam.getGithubTeamName()}"
|
||||||
|
target="_blank"
|
||||||
|
></a>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<div th:each="studentTeam: ${taTeam.getAssignedStudentTeams()}">
|
||||||
|
<a th:href="@{/courses/{code}/student_teams/{id}(code=${course.getCode()}, id=${studentTeam.getId()})}" th:text="'Student Team ' + ${studentTeam.getId()}"></a>
|
||||||
|
</div>
|
||||||
</td>
|
</td>
|
||||||
<td th:text="${taTeam.getGithubTeamName()}"></td>
|
|
||||||
<td>
|
<td>
|
||||||
<a th:href="@{/courses/{code}/teaching_assistant_teams/{team_id}/delete
|
<a th:href="@{/courses/{code}/teaching_assistant_teams/{team_id}/delete
|
||||||
(code=${course.getCode()}, team_id=${taTeam.getId()})}">
|
(code=${course.getCode()}, team_id=${taTeam.getId()})}">
|
||||||
|
@ -35,14 +58,5 @@
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="sidebar">
|
|
||||||
<div class="sidebar_block">
|
|
||||||
<a th:href="@{/courses/{code}/teaching_assistant_teams/create(code=${course.getCode()})}">Create Teaching Assistant Team</a>
|
|
||||||
</div>
|
|
||||||
<div class="sidebar_block">
|
|
||||||
<a th:href="@{/courses/{code}/teaching_assistant_teams/assign_to_student_teams(code=${course.getCode()})}">Assign Teams to Student Teams</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
|
@ -1,11 +1,8 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (~{::title}, ~{::#content}, ~{::#sidebar})}">
|
<html xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (title='Assign To Student Teams', content=~{::#content})}">
|
||||||
<head>
|
|
||||||
<title>Assign To Student Teams</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<div id="content">
|
<div id="content" class="row justify-content-center">
|
||||||
<form action="#" th:action="@{/courses/{code}/teaching_assistant_teams/assign_to_student_teams(code=${course.getCode()})}" enctype="application/x-www-form-urlencoded" method="post">
|
<form action="#" th:action="@{/courses/{code}/teaching_assistant_teams/assign_to_student_teams(code=${course.getCode()})}" enctype="application/x-www-form-urlencoded" method="post">
|
||||||
<label for="seed_input">Random Seed:</label>
|
<label for="seed_input">Random Seed:</label>
|
||||||
<input id="seed_input" type="number" name="seed" value="0" required/>
|
<input id="seed_input" type="number" name="seed" value="0" required/>
|
||||||
|
@ -13,9 +10,5 @@
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="sidebar">
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
|
@ -1,25 +1,25 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (~{::title}, ~{::#content}, ~{::#sidebar})}">
|
<html xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (title='Create Teaching Assistant Team', content=~{::#content})}">
|
||||||
<head>
|
|
||||||
<title>Create Teaching Assistant Team</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<div id="content">
|
<div id="content" class="row justify-content-center">
|
||||||
<form action="#" th:action="@{/courses/{code}/teaching_assistant_teams(code=${course.getCode()})}" enctype="application/x-www-form-urlencoded" method="post">
|
<div class="col-sm-12 col-md-6">
|
||||||
<label for="ta_team_github_team_name">Github team name:</label>
|
<form action="#" th:action="@{/courses/{code}/teaching_assistant_teams(code=${course.getCode()})}" enctype="application/x-www-form-urlencoded" method="post">
|
||||||
<input id="ta_team_github_team_name" type="text" name="github_team_name"/>
|
<div class="form-row">
|
||||||
|
<label for="ta_team_github_team_name">Github team name:</label>
|
||||||
|
<input id="ta_team_github_team_name" type="text" name="github_team_name" class="form-control"/>
|
||||||
|
</div>
|
||||||
|
|
||||||
<label for="ta_team_member_1">Select the first Team Member:</label>
|
<div class="form-row">
|
||||||
<select id="ta_team_member_1" name="id_1">
|
<label for="ta_team_member_1">Select the first Team Member:</label>
|
||||||
<option th:each="ta: ${course.getTeachingAssistants()}" th:value="${ta.getId()}" th:text="${ta.getFullName()}"></option>
|
<select id="ta_team_member_1" name="id_1" class="form-control">
|
||||||
</select>
|
<option th:each="ta: ${course.getTeachingAssistants()}" th:value="${ta.getId()}" th:text="${ta.getFullName()}"></option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
|
||||||
<button type="submit">Submit</button>
|
<input type="submit" value="Submit" class="btn btn-primary"/>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="sidebar">
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
|
@ -1,13 +1,11 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (~{::title}, ~{::#content}, ~{::#sidebar})}">
|
<html xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (title='Teaching Assistant Team ' + ${teachingAssistantTeam.getId()}, content=~{::#content})}">
|
||||||
<head>
|
<head>
|
||||||
<title>Teaching Assistant Team</title>
|
<title>Teaching Assistant Team</title>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<div id="content">
|
<div id="content" class="row justify-content-center">
|
||||||
<h1>Teaching Assistant Team <span th:text="${teachingAssistantTeam.getId()}"></span> for <span th:text="${course.getName()}"></span></h1>
|
|
||||||
|
|
||||||
<ul>
|
<ul>
|
||||||
<li>
|
<li>
|
||||||
Github Team Name: <code th:text="${teachingAssistantTeam.getGithubTeamName()}"></code>
|
Github Team Name: <code th:text="${teachingAssistantTeam.getGithubTeamName()}"></code>
|
||||||
|
@ -35,9 +33,5 @@
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="sidebar">
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
|
@ -1,14 +1,18 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (~{::title}, ~{::#content}, ~{::#sidebar})}">
|
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (title='Teaching Assistants for ' + ${course.getCode()}, content=~{::#content}, actions=~{::#actions})}">
|
||||||
<head>
|
|
||||||
<title>Teaching Assistants</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<div id="content">
|
<div id="actions">
|
||||||
<h1>Teaching Assistants for <span th:text="${course.getName()}"></span></h1>
|
<a class="btn btn-primary m-1" th:href="@{/courses/{code}/teaching_assistants/create(code=${course.getCode()})}">Add Teaching Assistant</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
<table>
|
<div id="content">
|
||||||
|
<table class="table table-striped">
|
||||||
|
<tr>
|
||||||
|
<th>Teaching Assistant</th>
|
||||||
|
<th>Email</th>
|
||||||
|
<th>Id</th>
|
||||||
|
</tr>
|
||||||
<tr th:each="teachingAssistant: ${course.getTeachingAssistants()}">
|
<tr th:each="teachingAssistant: ${course.getTeachingAssistants()}">
|
||||||
<td>
|
<td>
|
||||||
<a th:href="@{/teaching_assistants/{id}(id=${teachingAssistant.getId()})}"><span th:text="${teachingAssistant.getFullName()}"></span></a>
|
<a th:href="@{/teaching_assistants/{id}(id=${teachingAssistant.getId()})}"><span th:text="${teachingAssistant.getFullName()}"></span></a>
|
||||||
|
@ -19,11 +23,5 @@
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="sidebar">
|
|
||||||
<div class="sidebar_block">
|
|
||||||
<a th:href="@{/courses/{code}/teaching_assistants/create(code=${course.getCode()})}">Add Teaching Assistant</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
|
@ -1,53 +1,44 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (~{::title}, ~{::#content}, ~{::#sidebar})}">
|
<html lang="en" xmlns:th="http://www.thymeleaf.org" th:replace="~{layouts/basic_page :: layout (title='Edit Student', content=~{::#content})}">
|
||||||
<head>
|
|
||||||
<title>Edit Student</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<div id="content">
|
<div id="content" class="row justify-content-center">
|
||||||
<h1>Edit Student: <span th:text="${student.getFullName()}"></span></h1>
|
<div class="col-sm-12 col-md-6">
|
||||||
|
<form
|
||||||
|
th:action="@{/students/{id}/edit(id=${student.getId()})}" th:object="${student}"
|
||||||
|
method="post"
|
||||||
|
>
|
||||||
|
|
||||||
<form
|
<div class="form-row">
|
||||||
action="#"
|
<label for="first_name_input">First Name:</label>
|
||||||
th:action="@{/students/{id}/edit(id=${student.getId()})}" th:object="${student}"
|
<input id="first_name_input" type="text" th:field="*{firstName}" required />
|
||||||
method="post"
|
</div>
|
||||||
>
|
|
||||||
|
|
||||||
<div class="page_row">
|
<div class="form-row">
|
||||||
<label for="first_name_input">First Name:</label>
|
<label for="last_name_input">Last Name:</label>
|
||||||
<input id="first_name_input" type="text" th:field="*{firstName}" required />
|
<input id="last_name_input" type="text" th:field="*{lastName}" required />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="page_row">
|
<div class="form-row">
|
||||||
<label for="last_name_input">Last Name:</label>
|
<label for="email_input">Email Address:</label>
|
||||||
<input id="last_name_input" type="text" th:field="*{lastName}" required />
|
<input id="email_input" type="email" th:field="*{emailAddress}" required />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="page_row">
|
<div class="form-row">
|
||||||
<label for="email_input">Email Address:</label>
|
<label for="github_username_input">Github Username:</label>
|
||||||
<input id="email_input" type="email" th:field="*{emailAddress}" required />
|
<input id="github_username_input" type="text" th:field="*{githubUsername}" required />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="page_row">
|
<div class="form-row">
|
||||||
<label for="github_username_input">Github Username:</label>
|
<label for="student_number_input">Student Number:</label>
|
||||||
<input id="github_username_input" type="text" th:field="*{githubUsername}" required />
|
<input id="student_number_input" type="number" th:field="*{studentNumber}" required />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="page_row">
|
|
||||||
<label for="student_number_input">Student Number:</label>
|
|
||||||
<input id="student_number_input" type="number" th:field="*{studentNumber}" required />
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="page_row">
|
|
||||||
<button type="submit">Submit</button>
|
|
||||||
</div>
|
|
||||||
</form>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div id="sidebar">
|
|
||||||
|
|
||||||
|
<div class="form-row">
|
||||||
|
<button type="submit">Submit</button>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
|
|
Loading…
Reference in New Issue