You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
16 lines
418 B
16 lines
418 B
# coding=utf-8
|
|
import datetime
|
|
import os
|
|
import django
|
|
import sys
|
|
|
|
|
|
sys.path.append("/var/www/projects/codemy/")
|
|
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "lms.settings")
|
|
django.setup()
|
|
from management.models import Comment
|
|
|
|
errors = []
|
|
for comment in Comment.objects.filter(date__gte=datetime.datetime.strptime('08.11.2016', '%d.%m.%Y')).exclude(text=None):
|
|
comment.bbtext = comment.text
|
|
comment.save()
|
|
|