Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
125bce7
First commit hacker-news
CodeMaxx May 5, 2016
c143006
Added some static files and urlpatterns
CodeMaxx May 5, 2016
34977c3
Made Editors Front-end,front-end of /doc/
arunabh98 May 4, 2016
6e47f51
Make admin.py
arunabh98 May 5, 2016
74cea4f
Change FilePathField to FileField, Doc upload properly working
arunabh98 May 5, 2016
599a615
Dark theme for front end
arunabh98 May 5, 2016
4f89553
First commit hacker-news
CodeMaxx May 5, 2016
27a1fdd
Added some static files and urlpatterns
CodeMaxx May 5, 2016
ccbcd9e
Front End of Form for link upload
arunabh98 May 6, 2016
1ac5b6d
Register News model on admin
arunabh98 May 6, 2016
1991091
News.html is able to display uploaded links
arunabh98 May 6, 2016
ff7d686
Use local bootstrap,upvote, downvote for links
arunabh98 May 6, 2016
52de0fc
Add description field, Add comments class
arunabh98 May 7, 2016
2793e89
Add Comments Feature
arunabh98 May 7, 2016
b501917
Add Date Field to News Model
arunabh98 May 7, 2016
427a6e9
First sso login commit
CodeMaxx May 7, 2016
1b67b5e
Remove infinite merge conflicts
CodeMaxx May 7, 2016
1130383
Got rid of errors
CodeMaxx May 7, 2016
962b631
Add Reply to Comments Feature
arunabh98 May 7, 2016
2913309
Profile page added
CodeMaxx May 7, 2016
1550e22
Code quality improvements, display replies to comments
arunabh98 May 8, 2016
d319f4b
Remove useless migrations and merge conflicts
arunabh98 May 8, 2016
fde798d
Remove bug
CodeMaxx May 8, 2016
958bf8a
Merge branch 'hacker-news' of https://github.com/CodeMaxx/oksp into h…
CodeMaxx May 8, 2016
0f33115
Random;y arranged login code
CodeMaxx May 8, 2016
98b57b7
Login completely working
CodeMaxx May 12, 2016
aaec6f1
Remove some unnecessary stuff
CodeMaxx May 13, 2016
a1004c1
pep8 fixes
CodeMaxx May 13, 2016
7d06059
Some updates to upvotes
CodeMaxx Aug 1, 2016
ce4dd7a
Added some migrations
CodeMaxx Aug 2, 2016
0940232
Added login button
CodeMaxx Sep 12, 2016
9108790
start frontend for hacker news
arunabh98 Sep 12, 2016
0da22c2
Updated for tags. Trying to show tags in page
CodeMaxx Sep 13, 2016
7d8a8f9
further progress on frontend
arunabh98 Sep 14, 2016
be06eae
Merge with hackernews
CodeMaxx Oct 20, 2016
01d6ee7
Added vote images. Fixed backend and UI bugs
CodeMaxx Oct 20, 2016
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -146,3 +146,6 @@ staticfiles/*
oksp/settings/conf.py

docupload/docs/*

#PyCharm local config
.idea/*
3 changes: 0 additions & 3 deletions docupload/models.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
from django.db import models


# Create your models here.

class Documentation(models.Model):
'''
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

o.O ? Be careful what you push!

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why keep this line? Intentionally delete kiya hai

Documentation: Model class which holds details of uploaded documentation file
Expand Down
Empty file added hacker_news/__init__.py
Empty file.
3 changes: 3 additions & 0 deletions hacker_news/admin.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
from django.contrib import admin

# Register your models here.
5 changes: 5 additions & 0 deletions hacker_news/apps.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
from django.apps import AppConfig


class HackerNewsConfig(AppConfig):
name = 'hacker_news'
23 changes: 23 additions & 0 deletions hacker_news/migrations/0001_initial.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.9.5 on 2016-05-05 12:16
from __future__ import unicode_literals

from django.db import migrations, models


class Migration(migrations.Migration):

initial = True

dependencies = [
]

operations = [
migrations.CreateModel(
name='News',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('title', models.CharField(max_length=300)),
],
),
]
Empty file.
11 changes: 11 additions & 0 deletions hacker_news/models.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
from django.db import models

class News(models.Model):
'''
News: Model class which holds all the shared links
'''

title = models.CharField(max_length=300)
link = models.URLField
comments = models.IntegerField
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where is comment model? Are we not supporting comments as of now?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And also include absolute url for the news.

upvotes = models.IntegerField
3 changes: 3 additions & 0 deletions hacker_news/tests.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
from django.test import TestCase

# Create your tests here.
7 changes: 7 additions & 0 deletions hacker_news/urls.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from django.conf.urls import url

from hacker_news.views import NewsListView

urlpatterns = [
url(r'^$', NewsListView.as_view(), name='news_list'),
]
10 changes: 10 additions & 0 deletions hacker_news/views.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
from django.shortcuts import render
from django.views.generic import ListView

from hacker_news.models import News


class NewsListView(ListView):
queryset = News.objects.order_by("-date")[:10]
template_name = 'hacker-news/news.html'
context_object_name = 'news'
1 change: 1 addition & 0 deletions oksp/settings/base_settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
# Application definition

INSTALLED_APPS = [
'hacker_news',
'docupload.apps.DocuploadConfig',
'django.contrib.admin',
'django.contrib.auth',
Expand Down
21 changes: 0 additions & 21 deletions oksp/settings/conf.sample.py

This file was deleted.

1 change: 1 addition & 0 deletions oksp/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,5 @@
urlpatterns = [
url(r'^doc/', include('docupload.urls', namespace='docupload')),
url(r'^admin/', admin.site.urls),
url(r'^hacker-news/', include('hacker_news.urls', namespace='hacker-news')),
]