Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
midterm_gitgud
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Neal Luigi D. Rodriguez
midterm_gitgud
Commits
49de88d0
Commit
49de88d0
authored
May 13, 2023
by
Eury See
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed extends base.html for forum templates.
parent
a21d3721
Changes
11
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
59 additions
and
5 deletions
+59
-5
.DS_Store
widget_gitgud/.DS_Store
+0
-0
.DS_Store
widget_gitgud/Forum/.DS_Store
+0
-0
.DS_Store
widget_gitgud/Forum/templates/.DS_Store
+0
-0
forum.html
widget_gitgud/Forum/templates/Forum/forum.html
+44
-0
forum.html
widget_gitgud/Forum/templates/forum.html
+3
-0
forumpost-add.html
widget_gitgud/Forum/templates/forumpost-add.html
+4
-1
forumpost-details.html
widget_gitgud/Forum/templates/forumpost-details.html
+4
-1
forumpost-edit.html
widget_gitgud/Forum/templates/forumpost-edit.html
+3
-1
views.py
widget_gitgud/Forum/views.py
+1
-1
base.html
widget_gitgud/template/base.html
+0
-0
settings.py
widget_gitgud/widget_gitgud/settings.py
+0
-1
No files found.
widget_gitgud/.DS_Store
View file @
49de88d0
No preview for this file type
widget_gitgud/Forum/.DS_Store
View file @
49de88d0
No preview for this file type
widget_gitgud/Forum/templates/.DS_Store
View file @
49de88d0
No preview for this file type
widget_gitgud/Forum/templates/Forum/forum.html
0 → 100644
View file @
49de88d0
{% extends 'base.html' %}
{% load static %}
{% block title %}Widget's Forum{% endblock %}
{% block styles %}
<style>
body
{
background-color
:
rgb
(
253
,
222
,
207
);
font-family
:
Georgia
,
serif
;
font-size
:
16px
;
color
:
rgb
(
206
,
132
,
100
);
}
</style>
{% endblock %}
{% block content %}
<div
style=
"text-align: center;"
>
<h1>
Welcome to Widget's Forum
</h1>
</div>
<p1>
Forum posts:
</p1>
{% for post in posts %}
<li><a
href=
"{% url 'Forum:forumpost-details' pk=post.pk %}"
>
{{ post.title }} by {{ post.author }}
</a></li>
{% endfor %}
<br>
<button
type=
"submit"
>
<a
href=
"{% url 'Forum:forumpost-add' %}"
>
New Post
</a>
</button>
<br>
<br>
<a
href=
"http://127.0.0.1:8000/Dashboard/dashboard"
>
Dashboard
</a>
<br>
<a
href=
"http://127.0.0.1:8000/Announcements/announcements"
>
Announcements
</a>
<br>
<a
href=
"http://127.0.0.1:8000/Assignments/assignments"
>
Assignments
</a>
<br>
<a
href=
"http://127.0.0.1:8000/widgetcalendar/calendar"
>
Calendar
</a>
{% endblock %}
\ No newline at end of file
widget_gitgud/Forum/templates/forum.html
View file @
49de88d0
{% extends 'base.html' %}
{% load static %}
<title>
{% block title %}Widget's Forum{% endblock %}
</title>
{% block styles %}
...
...
widget_gitgud/Forum/templates/forumpost-add.html
View file @
49de88d0
<title>
{% block title %} Add Post {% endblock %}
</title>
{% extends 'base.html' %}
{% load static %}
{% block title %} Add Post {% endblock %}
{% block styles %}
<style>
...
...
widget_gitgud/Forum/templates/forumpost-details.html
View file @
49de88d0
<title>
{% block title %} {{object.title}} {% endblock %}
</title>
{% extends 'base.html' %}
{% load static %}
{% block title %} {{object.title}} {% endblock %}
{% block styles %}
<style>
...
...
widget_gitgud/Forum/templates/forumpost-edit.html
View file @
49de88d0
<title>
{% block title %} Edit Post {% endblock %}
</title>
{% extends 'base.html' %}
{% load static %}
{% block title %} Edit Post {% endblock %}
{% block styles %}
<style>
body
{
...
...
widget_gitgud/Forum/views.py
View file @
49de88d0
...
...
@@ -49,4 +49,4 @@ class AddForumPostView(CreateView):
class
EditForumPostView
(
UpdateView
):
model
=
ForumPost
fields
=
[
'title'
,
'body'
,
'author'
]
template_name
=
'forumpost-edit.html'
template_name
=
'forumpost-edit.html'
\ No newline at end of file
widget_gitgud/template
s
/base.html
→
widget_gitgud/template/base.html
View file @
49de88d0
File moved
widget_gitgud/widget_gitgud/settings.py
View file @
49de88d0
...
...
@@ -62,7 +62,6 @@ TEMPLATES = [
{
'BACKEND'
:
'django.template.backends.django.DjangoTemplates'
,
'DIRS'
:
[
os
.
path
.
join
(
BASE_DIR
,
'template'
)],
'DIRS'
:
[],
'APP_DIRS'
:
True
,
'OPTIONS'
:
{
'context_processors'
:
[
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment