Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
grady
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jan Maximilian Michal
grady
Commits
614eb259
Commit
614eb259
authored
8 years ago
by
Jan Maximilian Michal
Browse files
Options
Downloads
Patches
Plain Diff
removed headline from tutor startpage
parent
118fe72c
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
core/templates/core/tutor_startpage.html
+9
-17
9 additions, 17 deletions
core/templates/core/tutor_startpage.html
core/views.py
+4
-1
4 additions, 1 deletion
core/views.py
with
13 additions
and
18 deletions
core/templates/core/tutor_startpage.html
+
9
−
17
View file @
614eb259
...
...
@@ -6,8 +6,8 @@
{% block body_block %}
<div
class=
"row justify-content-center my-
2
"
>
<div
class=
"col-
3
"
>
<div
class=
"row justify-content-center my-
3
"
>
<div
class=
"col-
4
"
>
{# This is a contol panel where new work can be requested #}
<div
class=
"card"
>
...
...
@@ -15,15 +15,21 @@
<table
class=
"table"
>
<thead>
<th>
Name
</th>
<th>
Progress
</th>
<th></th>
</thead>
<tbody>
{% for submission_type in submission_type_list %}
<tr>
<td
class=
"align-middle"
>
{{ submission_type }}
</td>
<td
class=
"align-middle"
><code>
{{ submission_type.submissions__feedback_list__count }} / {{submission_type.submissions__count}}
</code></td>
<td
class=
"align-middle"
><a
role=
"button"
class=
"btn btn-secondary"
href=
"{% url 'CreateFeedbackForType' submission_type.slug %}"
>
Get
</a></td>
</tr>
{% endfor %}
<tr>
<td><strong>
Your constribution:
</strong></td>
<td
colspan=
"2"
><code>
{% if feedback_list|length > 0 %} {{feedback_list|length}} {% else %} None. Sad. {% endif %}
</code></td>
</tr>
</tbody>
</table>
<div
class=
"card-footer text-muted"
>
...
...
@@ -43,21 +49,8 @@
</div>
<div
class=
"col-5"
>
{# The custom header message #}
<div
class=
"row my-2 page-header"
>
{% if feedback_list|length == 0 %}
<h2>
You havn't provided any feedback yet. Sad. Get to work!
</h2>
{% else %}
{% if feedback_list|length == 1 %}
<h2>
So far you have provieded one constribution
</h2>
{% else %}
<h2>
So far you have provided {{feedback_list|length}} constributions
</h2>
{% endif %}
</div>
{# The big table where the tutor can see what s/he actually did #}
<div
class=
"row justify-content-center
my-2
"
>
<div
class=
"row justify-content-center"
>
<table
class=
"table"
>
<thead>
<tr>
...
...
@@ -83,7 +76,6 @@
{% endfor %}
</tbody>
</table>
{% endif %}
</div>
</div>
</div>
...
...
This diff is collapsed.
Click to expand it.
core/views.py
+
4
−
1
View file @
614eb259
...
...
@@ -83,7 +83,10 @@ def user_home(request):
@group_required
(
'
Tutors
'
)
def
tutor_view
(
request
):
context
=
{
'
submission_type_list
'
:
SubmissionType
.
objects
.
all
(),
'
submission_type_list
'
:
SubmissionType
.
objects
.
annotate
(
Count
(
'
submissions__feedback_list
'
)).
annotate
(
Count
(
'
submissions
'
)
).
all
(),
'
feedback_list
'
:
Feedback
.
objects
.
filter
(
of_tutor
=
request
.
user
),
}
return
render
(
request
,
'
core/tutor_startpage.html
'
,
context
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment