Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
K
kszkepzes-backend
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
JetBrains YouTrack
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
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
KSZK
DevTeam
kszkepzes
old
kszkepzes-backend
Commits
c4ca4cbf
Commit
c4ca4cbf
authored
5 years ago
by
Rafael László
Browse files
Options
Downloads
Patches
Plain Diff
small fix
parent
3d95392b
No related branches found
No related tags found
1 merge request
!2
Dev
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/homework/serializers.py
+0
-17
0 additions, 17 deletions
src/homework/serializers.py
with
0 additions
and
17 deletions
src/homework/serializers.py
+
0
−
17
View file @
c4ca4cbf
...
...
@@ -53,14 +53,6 @@ class SolutionSerializer_Student(serializers.ModelSerializer):
raise
serializers
.
ValidationError
(
'
You late.
'
)
return
value
def
validate_accepted
(
self
,
value
):
raise
serializers
.
ValidationError
(
"
You don
'
t have permission to modify accepted!
"
)
def
validate_corrected
(
self
,
value
):
raise
serializers
.
ValidationError
(
"
You don
'
t have permission to modify corrected!
"
)
def
validate_note
(
self
,
value
):
if
value
!=
''
:
raise
serializers
.
ValidationError
(
...
...
@@ -111,15 +103,6 @@ class SolutionSerializer_Staff(serializers.ModelSerializer):
raise
serializers
.
ValidationError
(
'
You late.
'
)
return
value
def
validate_accepted
(
self
,
value
):
return
value
def
validate_corrected
(
self
,
value
):
return
value
def
validate_note
(
self
,
value
):
return
value
def
update
(
self
,
instance
,
validated_data
):
if
instance
.
corrected
is
not
True
and
validated_data
.
get
(
'
corrected
'
,
instance
.
corrected
)
is
True
:
...
...
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