-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #291 from kenanwright1988/calendar_for_registrants
Calendar for registrants
- Loading branch information
Showing
17 changed files
with
1,161 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,3 +15,5 @@ venv/ | |
MYNOTES.md | ||
staticfiles | ||
data/ | ||
todo.txt | ||
node_modules/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Generated by Django 3.1.13 on 2024-10-04 15:52 | ||
|
||
from django.db import migrations, models | ||
import django.db.models.deletion | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('hackathon', '0053_auto_20240912_1527'), | ||
] | ||
|
||
operations = [ | ||
migrations.CreateModel( | ||
name='Event', | ||
fields=[ | ||
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), | ||
('title', models.CharField(max_length=200)), | ||
('start', models.DateTimeField()), | ||
('end', models.DateTimeField()), | ||
('body', models.TextField(default='', max_length=500)), | ||
('isReadOnly', models.BooleanField(default=True)), | ||
('webinar_link', models.URLField(blank=True, null=True)), | ||
('webinar_code', models.CharField(blank=True, max_length=50, null=True)), | ||
('hackathon', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='events', to='hackathon.hackathon')), | ||
], | ||
), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# Generated by Django 3.1.13 on 2024-10-08 13:58 | ||
|
||
from django.db import migrations | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('hackathon', '0054_event'), | ||
] | ||
|
||
operations = [ | ||
migrations.RemoveField( | ||
model_name='event', | ||
name='isReadOnly', | ||
), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
{% extends "base.html" %} | ||
{% load static %} | ||
{% load crispy_forms_tags %} | ||
|
||
{% block css %} | ||
<!-- XDSoft DateTimePicker --> | ||
<link rel="stylesheet" | ||
href="https://cdnjs.cloudflare.com/ajax/libs/jquery-datetimepicker/2.5.20/jquery.datetimepicker.min.css" | ||
integrity="sha256-DOS9W6NR+NFe1fUhEE0PGKY/fubbUCnOfTje2JMDw3Y=" crossorigin="anonymous"/> | ||
{% endblock %} | ||
|
||
{% block content %} | ||
|
||
<section class="h-100"> | ||
<div class="row mb-3"> | ||
<div class="col-12"> | ||
{% if event %} | ||
<h1>Edit Event</h1> | ||
{% else %} | ||
<h1>Create Event</h1> | ||
{% endif %} | ||
</div> | ||
</div> | ||
|
||
<form method="POST"> | ||
{% csrf_token %} | ||
<div class="row"> | ||
<div class="col-12"> | ||
{{ form.title|as_crispy_field }} | ||
</div> | ||
<div class="col-12" > | ||
{{ form.start|as_crispy_field }} | ||
</div> | ||
<div class="col-12" id="webinar_end_date"> | ||
{{ form.end|as_crispy_field }} | ||
</div> | ||
<div class="col-12"> | ||
{{ form.body|as_crispy_field }} | ||
</div> | ||
<div class="col-12"> | ||
{{ form.webinar_link|as_crispy_field }} | ||
</div> | ||
<div class="col-12"> | ||
{{ form.webinar_code|as_crispy_field }} | ||
</div> | ||
<div class="col-12"> | ||
<button type="submit" class="btn btn-primary">Save</button> | ||
</div> | ||
</div> | ||
</form> | ||
</section> | ||
|
||
{% endblock %} | ||
|
||
{% block js %} | ||
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-datetimepicker/2.5.20/jquery.datetimepicker.full.min.js" | ||
integrity="sha256-FEqEelWI3WouFOo2VWP/uJfs1y8KJ++FLh2Lbqc8SJk=" crossorigin="anonymous"> | ||
</script> | ||
<script src="{% static 'js/datetimepicker.js' %}"></script> | ||
{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
{% extends "base.html" %} | ||
|
||
{% block content %} | ||
<h2>{{ hackathon.display_name }} - Webinars</h2> | ||
{% if events %} | ||
<div class="card"> | ||
<div class="card-body"> | ||
<ul class="list-group"> | ||
{% for event in events %} | ||
<li class="list-group-item d-flex justify-content-between align-items-center"> | ||
<div> | ||
<h5> {{ hackathon.display_name }} {{ event.title }}</h5> | ||
<p>{{ event.start }}</p> | ||
<p><a href="{{ event.webinar_link }}" target="_blank">Webinar Link </a></p> | ||
<p>{{ event.body | safe }}</p> | ||
</div> | ||
<div> | ||
<a href="{% url 'hackathon:change_event' hackathon.id event.id %}" class="btn btn-primary btn-sm">Edit</a> | ||
<a href="{% url 'hackathon:delete_event' hackathon.id event.id %}" class="btn btn-danger btn-sm" onclick="return confirm('Are you sure you want to delete this event?');">Delete</a> | ||
</div> | ||
</li> | ||
{% endfor %} | ||
</ul> | ||
</div> | ||
</div> | ||
{% else %} | ||
<p>No events found. <a href="{% url 'hackathon:change_event' hackathon.id %}">Add an event</a></p> | ||
{% endif %} | ||
<a href="{% url 'hackathon:change_event' hackathon.id %}" class="btn btn-primary mt-3">Add Event</a> | ||
{% endblock %} |
Oops, something went wrong.