Skip to content

Commit 7e48411

Browse files
committed
Kagne ready to deploy
1 parent 42d1b42 commit 7e48411

File tree

8 files changed

+53
-21
lines changed

8 files changed

+53
-21
lines changed

Procfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
web: gunicorn kcc.wsgi

classes/static/classes/css/templatemo-style.css

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1011,6 +1011,7 @@ header {
10111011
padding-right: 15px;
10121012
}
10131013

1014+
10141015
#video {
10151016
padding-left: 15px;
10161017
padding-right: 15px;
3 MB
Loading
9.11 KB
Loading

classes/templates/index.html

Lines changed: 30 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,13 @@
1818
<link rel="stylesheet" href="{% static 'classes/css/templatemo-style.css' %}">
1919

2020
<link href="https://fonts.googleapis.com/css?family=Open+Sans:300,400,600,700,800" rel="stylesheet">
21-
2221
<script src="{% static 'classes/js/vendor/modernizr-2.8.3-respond-1.4.2.min.js' %}"></script>
22+
2323
</head>
2424

2525
<body>
2626

2727

28-
2928
<header class="nav-down responsive-nav hidden-lg hidden-md">
3029
<button type="button" id="nav-toggle" class="navbar-toggle" data-toggle="collapse" data-target="#main-nav">
3130
<span class="sr-only">Toggle navigation</span>
@@ -128,13 +127,14 @@
128127
<h1>Kagne Coaching Classes</h1>
129128

130129
<div class="white-button button">
131-
<a href="result">Discover More</a>
130+
<a href="#projects">Discover More</a>
132131
</div>
133132
</div>
134133
</div>
135134
</div>
136135
</div>
137136
<!-- // Item -->
137+
138138
<!-- Item -->
139139
<div class="item item-2">
140140
<div class="img-fill">
@@ -166,14 +166,40 @@ <h1>Kagne Coaching Classes</h1>
166166
</div>
167167
</div>
168168
</div>
169-
<!-- // Item -->
169+
<!-- // Item -->
170170
</div>
171171
</div>
172172

173173

174174
<div class="page-content">
175175

176176
{% comment %} {% endcomment %}
177+
178+
<section id="projects" class="content-section">
179+
<div class="section-heading">
180+
<h1>New<br><em>Alerts</em></h1>
181+
<p>We are pioneer and one of the determined coaching institute in kandhar.
182+
<br>With an impressive track record molding over 50 NMMS scholarship holders.
183+
</p>
184+
</div>
185+
186+
<div class="section-content">
187+
{% for notification in notifications %}
188+
189+
<div class="alert alert-warning alert-outline-coloured alert-dismissible" role="alert">
190+
<button type="button" class="close" data-dismiss="alert" aria-label="Close">
191+
<span aria-hidden="true">&times;</span>
192+
</button>
193+
<div class="alert-message">
194+
<strong>{{notification.title}}</strong>
195+
{{notification.description}}
196+
</div>
197+
</div>
198+
199+
{% endfor %}
200+
</div>
201+
</section>
202+
177203

178204
<section id="projects" class="content-section">
179205
<div class="section-heading">

classes/templates/results.html

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@ <h5 class="mb-3"><a href="/">Home</a></h5>
8686
<td>{{result.std}}/{{result.medium}}</td>
8787
<td>{{result.created_at}}</td>
8888
<td><a href="/media/{{result.file}}" download>download</a></td>
89+
<td><a href="https://drive.google.com/file/d/1bo_jXd3GGRGzks_jCQ2zH5yvlPsXLim6/view?usp=sharing" >download</a></td>
8990
</tr>
9091
{% endfor %}
9192
</tbody>
@@ -94,6 +95,7 @@ <h5 class="mb-3"><a href="/">Home</a></h5>
9495
</div>
9596
</div>
9697
</div>
98+
9799
</main>
98100
</body>
99101
</html>

classes/views.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,18 @@
11
from django.contrib import messages
22
from django.shortcuts import render
33
from django.http.response import HttpResponse, HttpResponseRedirect
4-
from classes.models import Course, Guest, Result
4+
from classes.models import Course, Guest, Notification, Result
55

66

77
# Create your views here.
88
def index(request):
99
courses = Course.objects.all()
1010
stds = Result.std_choices
11+
notifications = Notification.objects.all()
1112
context = {
1213
"courses" : courses,
13-
"stds" : stds
14+
"stds" : stds,
15+
"notifications" : notifications
1416
}
1517
return render(request,'index.html',context)
1618

kcc/settings.py

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
# SECURITY WARNING: don't run with debug turned on in production!
2727
DEBUG = False
2828

29-
ALLOWED_HOSTS = ['34.201.107.68','kagnecoachingclasses.com']
29+
ALLOWED_HOSTS = ['','kagnecoachingclasses.com']
3030

3131

3232
# Application definition
@@ -76,24 +76,24 @@
7676
# Database
7777
# https://docs.djangoproject.com/en/3.2/ref/settings/#databases
7878

79-
DATABASES = {
80-
'default': {
81-
'ENGINE': 'django.db.backends.sqlite3',
82-
'NAME': BASE_DIR / 'db.sqlite3',
83-
}
84-
}
85-
8679
# DATABASES = {
87-
# 'default': {
88-
# 'ENGINE': 'django.db.backends.postgresql',
89-
# 'NAME': 'd7kqdhblj57uhv',
90-
# 'USER': 'cuvcgcirsorlqx',
91-
# 'PASSWORD': '2aba5a68ed31983655bdecd0e220f49cc08e254f122a375a5a130231745b2cfe',
92-
# 'HOST': 'ec2-52-72-252-211.compute-1.amazonaws.com',
93-
# 'PORT': '5432',
80+
# 'default': {
81+
# 'ENGINE': 'django.db.backends.sqlite3',
82+
# 'NAME': BASE_DIR / 'db.sqlite3',
9483
# }
9584
# }
9685

86+
DATABASES = {
87+
'default': {
88+
'ENGINE': 'django.db.backends.postgresql',
89+
'NAME': 'd7kqdhblj57uhv',
90+
'USER': 'cuvcgcirsorlqx',
91+
'PASSWORD': '2aba5a68ed31983655bdecd0e220f49cc08e254f122a375a5a130231745b2cfe',
92+
'HOST': 'ec2-52-72-252-211.compute-1.amazonaws.com',
93+
'PORT': '5432',
94+
}
95+
}
96+
9797

9898
# Password validation
9999
# https://docs.djangoproject.com/en/3.2/ref/settings/#auth-password-validators

0 commit comments

Comments
 (0)