Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
midterm_robo_mommy
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Raul Jarod Conanan
midterm_robo_mommy
Commits
207e7450
Commit
207e7450
authored
Mar 04, 2023
by
Lance Dominic B. Santuyo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed model relations
parent
f74a47a4
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
models.py
widget_robo_mommy/Assignments/models.py
+5
-5
No files found.
widget_robo_mommy/Assignments/models.py
View file @
207e7450
from
django.db
import
models
class
Course
(
models
.
Model
):
code
=
models
.
CharField
(
max_length
=
10
,
blank
=
True
,
null
=
True
)
title
=
models
.
CharField
(
max_length
=
255
,
blank
=
True
,
null
=
True
)
section
=
models
.
CharField
(
max_length
=
3
,
blank
=
True
,
null
=
True
)
class
Assignment
(
models
.
Model
):
name
=
models
.
CharField
(
max_length
=
255
,
blank
=
True
,
null
=
True
)
description
=
models
.
TextField
(
blank
=
True
,
null
=
True
)
...
...
@@ -10,8 +15,3 @@ class Assignment(models.Model):
def
save
(
self
,
*
args
,
**
kwargs
):
self
.
passing_score
=
int
(
self
.
perfect_score
*
0.60
)
super
(
Assignment
,
self
)
.
save
(
*
args
,
**
kwargs
)
class
Course
(
models
.
Model
):
code
=
models
.
CharField
(
max_length
=
10
,
blank
=
True
,
null
=
True
)
title
=
models
.
CharField
(
max_length
=
255
,
blank
=
True
,
null
=
True
)
section
=
models
.
CharField
(
max_length
=
3
,
blank
=
True
,
null
=
True
)
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment