Skip to content
This repository was archived by the owner on Sep 3, 2020. It is now read-only.

Commit ca85104

Browse files
author
Arjun
committed
v3
- Comment Answers - Markdown for Answer - Profile Page for Users - Points for User Activity - Bug Fixes
1 parent 6bf170b commit ca85104

27 files changed

+251
-11
lines changed

db.sqlite3

16 KB
Binary file not shown.

profile_images/me.jpg

170 KB
Loading

qa/admin.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
from django.contrib import admin
22
from qa.models import *
3+
from django_markdown.admin import MarkdownModelAdmin
34

45
admin.site.register(Question)
5-
admin.site.register(Answer)
6+
admin.site.register(Answer, MarkdownModelAdmin)
7+
admin.site.register(Comment)
68
admin.site.register(Tag)
79
admin.site.register(UserProfile)

qa/admin.pyc

110 Bytes
Binary file not shown.

qa/migrations/0009_comment.py

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# -*- coding: utf-8 -*-
2+
from __future__ import unicode_literals
3+
4+
from django.db import models, migrations
5+
6+
7+
class Migration(migrations.Migration):
8+
9+
dependencies = [
10+
('qa', '0008_answer_votes'),
11+
]
12+
13+
operations = [
14+
migrations.CreateModel(
15+
name='Comment',
16+
fields=[
17+
('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
18+
('comment_text', models.CharField(max_length=200)),
19+
('pub_date', models.DateTimeField(verbose_name=b'date published')),
20+
('answer', models.ForeignKey(to='qa.Answer')),
21+
('user_data', models.ForeignKey(to='qa.UserProfile')),
22+
],
23+
options={
24+
},
25+
bases=(models.Model,),
26+
),
27+
]

qa/migrations/0009_comment.pyc

1.16 KB
Binary file not shown.
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# -*- coding: utf-8 -*-
2+
from __future__ import unicode_literals
3+
4+
from django.db import models, migrations
5+
6+
7+
class Migration(migrations.Migration):
8+
9+
dependencies = [
10+
('qa', '0009_comment'),
11+
]
12+
13+
operations = [
14+
migrations.AddField(
15+
model_name='userprofile',
16+
name='points',
17+
field=models.IntegerField(default=0),
18+
preserve_default=True,
19+
),
20+
]
844 Bytes
Binary file not shown.
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# -*- coding: utf-8 -*-
2+
from __future__ import unicode_literals
3+
4+
from django.db import models, migrations
5+
6+
7+
class Migration(migrations.Migration):
8+
9+
dependencies = [
10+
('qa', '0010_userprofile_points'),
11+
]
12+
13+
operations = [
14+
migrations.AddField(
15+
model_name='question',
16+
name='views',
17+
field=models.IntegerField(default=0),
18+
preserve_default=True,
19+
),
20+
]
854 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)