Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
MOOC packages by hacklab
django-courses
Commits
2581dc61
Commit
2581dc61
authored
Sep 22, 2020
by
Laury Bueno
Browse files
[Courses] Add "course_load" field to Course model
parent
84414fba
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
1 deletion
+23
-1
courses/migrations/0017_course_course_load.py
courses/migrations/0017_course_course_load.py
+18
-0
courses/models.py
courses/models.py
+5
-1
No files found.
courses/migrations/0017_course_course_load.py
0 → 100644
View file @
2581dc61
# Generated by Django 2.2.16 on 2020-09-22 14:09
from
django.db
import
migrations
,
models
class
Migration
(
migrations
.
Migration
):
dependencies
=
[
(
'courses'
,
'0016_class_certificate_template'
),
]
operations
=
[
migrations
.
AddField
(
model_name
=
'course'
,
name
=
'course_load'
,
field
=
models
.
IntegerField
(
null
=
True
,
verbose_name
=
'Course Load'
),
),
]
courses/models.py
View file @
2581dc61
...
...
@@ -70,6 +70,10 @@ class Course(models.Model):
_
(
'Workload'
),
blank
=
True
,
)
course_load
=
models
.
IntegerField
(
_
(
'Course Load'
),
null
=
True
,
)
pronatec
=
models
.
TextField
(
_
(
'Pronatec'
),
blank
=
True
,
...
...
@@ -343,7 +347,7 @@ class CourseStudent(models.Model):
def
_activities_and_course_finished
(
self
):
"""
This method verifies if the user made all discussion activities
This method verifies if the user made all discussion activities
AND has the perent progress
"""
from
courses_learning_objects.models
import
LearningObject
,
Answer
...
...
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