Skip to content

add template #9

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 9, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
76 changes: 76 additions & 0 deletions pythonkr_backend/pythonkr/templates/pao/pao_base.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
{% load static %}
{% load wagtailcore_tags %}
{% load wagtailimages_tags %}
{% wagtail_site as current_site %}
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>{% block title %}Python Asia{% endblock title %}</title>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap/5.3.2/css/bootstrap.min.css">
<script defer src="https://cdnjs.cloudflare.com/ajax/libs/alpinejs/3.13.5/cdn.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/bootstrap/5.3.2/js/bootstrap.bundle.min.js"></script>
<style>
html, body {
height: 100%;
margin: 0;
}
body {
padding-top: 40px;
display: flex;
flex-direction: column;
}
main {
flex: 1;
}
footer {
background-color: #f8f9fa;
margin-bottom: 20px;
}
</style>
</head>
<body>
<!-- Navigation -->
<nav class="navbar navbar-expand-lg navbar-light bg-light fixed-top">
<div class="container">
<a class="navbar-brand" href="{% pageurl current_site.root_page %}">
<img src="{% static 'pao/01-Main2.png' %}" alt="Python Asia Organization Logo"
height="80"/>
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarNav">
<ul class="navbar-nav ms-auto">
{% for menu_page in current_site.root_page.get_children.live.in_menu %}
<li class="nav-item"><a class="nav-link" href="{% pageurl menu_page %}">{{menu_page.title}}</a></li>
{% endfor %}
</ul>
</div>
</div>
</nav>

<!-- Main Content -->
<main class="container mt-5 pt-5">
{% block content %}{% endblock content %}
</main>

<!-- Footer -->
<footer class="sponsor-footer mt-5">
<div class="container text-center">
<h4 class="text-center mb-4">Our Sponsors</h4>
<div class="row justify-content-center">
{% for sponsor in sponsors %}
<div class="col-md-3 col-6 text-center mb-3">
<img src="{{ sponsor.logo }}" alt="{{ sponsor.name }}" class="img-fluid" style="max-height: 60px;">
</div>
{% endfor %}
</div>
</div>
{% if looking_for_sponsors %}
<h4 class="text-center mb-4">looking for sponsors!</h4>
{% endif %}
</footer>
</body>
</html>
22 changes: 22 additions & 0 deletions pythonkr_backend/pythonkr/templates/pao/pao_communites.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{% extends 'pao/pao_base.html' %}
{% load wagtailcore_tags %}

{% block title %}Home - Python Asia - {{ page.title }}{% endblock %}

{% block content %}
<div>
<h2 class="mb-4">{{ page.title }} of Python Asia</h2>
{% for community in page.get_children.live %}
<a href="{% pageurl community %}" class="list-group-item list-group-item-action">
<div class="d-flex w-100 justify-content-between">
<h5 class="mb-1">{{ community.title }}</h5>
<small class="text-muted">{{ community.country }}</small>
</div>
<p class="mb-1">{{ community.content | richtext }}</p>
<small class="text-muted">details</small>
</a>
{% empty %}
Sorry there is no {{ page.title }}
{% endfor %}
</div>
{% endblock %}
10 changes: 10 additions & 0 deletions pythonkr_backend/pythonkr/templates/pao/pao_event.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{% extends 'pao/pao_base.html' %}
{% load wagtailcore_tags %}

{% block title %}Home - Python Asia - {{ page.title }}{% endblock %}

{% block content %}
{{ page.title }}
{{ page.event_date }}
{{ page.content|richtext }}
{% endblock %}
23 changes: 23 additions & 0 deletions pythonkr_backend/pythonkr/templates/pao/pao_events.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{% extends 'pao/pao_base.html' %}
{% load wagtailcore_tags %}

{% block title %}Home - Python Asia - {{ page.title }}{% endblock %}

{% block content %}
<div class="container my-5">
<h1 class="mb-4">Python Asia Events</h1>
<div class="list-group">
{% for event in page.get_children.live %}
<a href="{% pageurl event %}" class="list-group-item list-group-item-action">
<div class="d-flex w-100 justify-content-between">
<h5 class="mb-1">{{ event.title }}</h5>
<small class="text-muted">{{ event.event_date }}</small>
</div>
<p class="mb-1">{{ event.content | richtext }}</p>
<small class="text-muted">details</small>
</a>
{% empty %}
Sorry there is no Events
{% endfor %}
</div>
{% endblock %}
8 changes: 8 additions & 0 deletions pythonkr_backend/pythonkr/templates/pao/pao_home copy.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{% extends 'pao/pao_base.html' %}
{% load wagtailcore_tags %}

{% block title %}Home - Python Asia - {{ page.title }}{% endblock %}

{% block content %}
{{ page.body|richtext }}
{% endblock %}
8 changes: 8 additions & 0 deletions pythonkr_backend/pythonkr/templates/pao/pao_home.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{% extends 'pao/pao_base.html' %}
{% load wagtailcore_tags %}

{% block title %}Home - Python Asia - {{ page.title }}{% endblock %}

{% block content %}
{{ page.body|richtext }}
{% endblock %}
8 changes: 8 additions & 0 deletions pythonkr_backend/pythonkr/templates/pao/pao_markdown_doc.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{% extends 'pao/pao_base.html' %}
{% load wagtailcore_tags %}

{% block title %}Home - Python Asia - {{ page.title }}{% endblock %}

{% block content %}
{{ page.content|richtext }}
{% endblock %}
8 changes: 8 additions & 0 deletions pythonkr_backend/pythonkr/templates/pao/pao_page.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{% extends 'pao/pao_base.html' %}
{% load wagtailcore_tags %}

{% block title %}Home - Python Asia - {{ page.title }}{% endblock %}

{% block content %}
{{ page.body|richtext }}
{% endblock %}
21 changes: 21 additions & 0 deletions pythonkr_backend/pythonkr/templates/pao/pao_people.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{% extends 'pao/pao_base.html' %}
{% load wagtailcore_tags %}

{% block title %}Home - Python Asia - {{ page.title }}{% endblock %}

{% block content %}
<h2 class="mb-4">People of Python Asia</h2>
{% for person in page.get_children.live %}
<a href="{% pageurl person %}" class="list-group-item list-group-item-action">
<div class="d-flex w-100 justify-content-between">
<h5 class="mb-1">{{ person.title }}</h5>
<small class="text-muted">{{ person.country }}</small>
</div>
<p class="mb-1">{{ person.content | richtext }}</p>
<small class="text-muted">details</small>
</a>
{% empty %}
Sorry there is no People
{% endfor %}
</div>
{% endblock %}
11 changes: 11 additions & 0 deletions pythonkr_backend/pythonkr/templates/pao/pao_person.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{% extends 'pao/pao_base.html' %}
{% load wagtailcore_tags %}

{% block title %}Home - Python Asia - {{ page.title }}{% endblock %}

{% block content %}
{{ page.name }}
{{ page.year }}
{{ page.position }}
{{ page.country }}
{% endblock %}
15 changes: 15 additions & 0 deletions pythonkr_backend/pythonkr/templates/pao/pao_sponsor.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{% extends 'pao/pao_base.html' %}
{% load wagtailcore_tags %}
{% load wagtailimages_tags %}

{% block title %}Home - Python Asia - {{ page.title }}{% endblock title %}

{% block content %}
{{ page.body|richtext }}

{{ page.title }}
{% image page.image original %}
{{ page.year }}
{{ page.sponsor_type }}
{{ page.description }}
{% endblock %}
23 changes: 23 additions & 0 deletions pythonkr_backend/pythonkr/templates/pao/pao_sponsors.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{% extends 'pao/pao_base.html' %}
{% load wagtailcore_tags %}
{% load wagtailimages_tags %}

{% block title %}Home - Python Asia - {{ page.title }}{% endblock %}

{% block content %}
<h2 class="mb-4">Sponsors of Python Asia</h2>
{% for sponsor in page.get_children.live %}
<div class="row">
<div class="col-md-4 mb-4">
<div class="card">
<div class="card-body">
<h5 class="card-title" x-text="sponsior.name">{{ sponsor.title }}</h5>
{% image sponsor.image original %}
</div>
</div>
</div>
{% empty %}
Sorry there is no Sponsors
{% endfor %}
</div>
{% endblock %}