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
03372882
Commit
03372882
authored
4 years ago
by
Dominik Seeger
Browse files
Options
Downloads
Patches
Plain Diff
added modified timestamp to feedback
parent
1e7ae034
No related branches found
No related tags found
1 merge request
!239
Resolve "Include last modified in feedback history"
Pipeline
#131137
passed
4 years ago
Stage: build
Stage: test
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
core/migrations/0004_feedback_modified.py
+18
-0
18 additions, 0 deletions
core/migrations/0004_feedback_modified.py
core/models/feedback.py
+3
-0
3 additions, 0 deletions
core/models/feedback.py
core/serializers/feedback.py
+2
-2
2 additions, 2 deletions
core/serializers/feedback.py
with
23 additions
and
2 deletions
core/migrations/0004_feedback_modified.py
0 → 100644
+
18
−
0
View file @
03372882
# Generated by Django 2.1.14 on 2020-04-14 18:38
from
django.db
import
migrations
,
models
class
Migration
(
migrations
.
Migration
):
dependencies
=
[
(
'
core
'
,
'
0003_auto_20191203_1445
'
),
]
operations
=
[
migrations
.
AddField
(
model_name
=
'
feedback
'
,
name
=
'
modified
'
,
field
=
models
.
DateTimeField
(
auto_now
=
True
),
),
]
This diff is collapsed.
Click to expand it.
core/models/feedback.py
+
3
−
0
View file @
03372882
...
...
@@ -20,6 +20,8 @@ class Feedback(models.Model):
accepted.
created : DateTimeField
When the feedback was initially created
modified: DateTimeField
Timestamp indicating the last time the feedback was saved
of_submission : OneToOneField
The submission this feedback belongs to. It finally determines how many
points a student receives for his submission.
...
...
@@ -30,6 +32,7 @@ class Feedback(models.Model):
"""
score
=
models
.
DecimalField
(
max_digits
=
5
,
decimal_places
=
2
,
default
=
0
)
created
=
models
.
DateTimeField
(
auto_now_add
=
True
)
modified
=
models
.
DateTimeField
(
auto_now
=
True
)
is_final
=
models
.
BooleanField
(
default
=
False
)
final_by_reviewer
=
models
.
BooleanField
(
default
=
False
)
...
...
This diff is collapsed.
Click to expand it.
core/serializers/feedback.py
+
2
−
2
View file @
03372882
...
...
@@ -210,7 +210,7 @@ class FeedbackSerializer(DynamicFieldsModelSerializer):
class
Meta
:
model
=
Feedback
fields
=
(
'
pk
'
,
'
of_submission
'
,
'
is_final
'
,
'
score
'
,
'
feedback_lines
'
,
'
created
'
,
'
of_submission_type
'
,
'
feedback_stage_for_user
'
,
'
labels
'
)
'
created
'
,
'
modified
'
,
'
of_submission_type
'
,
'
feedback_stage_for_user
'
,
'
labels
'
)
class
FeedbackWithStudentSerializer
(
FeedbackSerializer
):
...
...
@@ -219,7 +219,7 @@ class FeedbackWithStudentSerializer(FeedbackSerializer):
class
Meta
:
model
=
Feedback
fields
=
(
'
pk
'
,
'
of_submission
'
,
'
is_final
'
,
'
score
'
,
'
feedback_lines
'
,
'
of_student
'
,
'
created
'
,
'
of_submission_type
'
,
'
feedback_stage_for_user
'
,
'
labels
'
)
'
created
'
,
'
modified
'
,
'
of_submission_type
'
,
'
feedback_stage_for_user
'
,
'
labels
'
)
class
VisibleCommentFeedbackSerializer
(
FeedbackSerializer
):
...
...
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