Commit e277621cf328cb18b088b3011a3275bbb8bedec4
1 parent
a1f22d43
Exists in
master
and in
5 other branches
Fixing course public bug
Showing
2 changed files
with
21 additions
and
1 deletions
Show diff stats
@@ -0,0 +1,20 @@ | @@ -0,0 +1,20 @@ | ||
1 | +# -*- coding: utf-8 -*- | ||
2 | +# Generated by Django 1.10 on 2016-10-24 17:28 | ||
3 | +from __future__ import unicode_literals | ||
4 | + | ||
5 | +from django.db import migrations, models | ||
6 | + | ||
7 | + | ||
8 | +class Migration(migrations.Migration): | ||
9 | + | ||
10 | + dependencies = [ | ||
11 | + ('courses', '0001_initial'), | ||
12 | + ] | ||
13 | + | ||
14 | + operations = [ | ||
15 | + migrations.AlterField( | ||
16 | + model_name='course', | ||
17 | + name='public', | ||
18 | + field=models.BooleanField(default=False, verbose_name='Public'), | ||
19 | + ), | ||
20 | + ] |
courses/models.py
@@ -50,7 +50,7 @@ class Course(models.Model): | @@ -50,7 +50,7 @@ class Course(models.Model): | ||
50 | category = models.ForeignKey(CourseCategory, verbose_name = _('Category'), related_name='course_category') | 50 | category = models.ForeignKey(CourseCategory, verbose_name = _('Category'), related_name='course_category') |
51 | professors = models.ManyToManyField(User,verbose_name=_('Professors'), related_name='courses_professors') | 51 | professors = models.ManyToManyField(User,verbose_name=_('Professors'), related_name='courses_professors') |
52 | students = models.ManyToManyField(User,verbose_name=_('Students'), related_name='courses_student', blank = True) | 52 | students = models.ManyToManyField(User,verbose_name=_('Students'), related_name='courses_student', blank = True) |
53 | - public = models.BooleanField(_('Public')) | 53 | + public = models.BooleanField(_('Public'), default=False) |
54 | 54 | ||
55 | class Meta: | 55 | class Meta: |
56 | ordering = ('create_date','name') | 56 | ordering = ('create_date','name') |