cleanups
This commit is contained in:
@@ -1,3 +0,0 @@
|
||||
# from django.contrib import admin
|
||||
|
||||
# Register your models here.
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
# from django.db import models
|
||||
|
||||
# Create your models here.
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
# from django.test import TestCase
|
||||
|
||||
# Create your tests here.
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
# from django.test import TestCase
|
||||
|
||||
# Create your tests here.
|
||||
|
||||
@@ -1,12 +1,3 @@
|
||||
"""
|
||||
ASGI config for fet2020 project.
|
||||
|
||||
It exposes the ASGI callable as a module-level variable named ``application``.
|
||||
|
||||
For more information on this file, see
|
||||
https://docs.djangoproject.com/en/3.0/howto/deployment/asgi/
|
||||
"""
|
||||
|
||||
import os
|
||||
|
||||
from django.core.asgi import get_asgi_application
|
||||
|
||||
@@ -1,16 +1,3 @@
|
||||
|
||||
"""
|
||||
Django settings for fet2020 project.
|
||||
|
||||
Generated by 'django-admin startproject' using Django 3.0.5.
|
||||
|
||||
For more information on this file, see
|
||||
https://docs.djangoproject.com/en/3.0/topics/settings/
|
||||
|
||||
For the full list of settings and their values, see
|
||||
https://docs.djangoproject.com/en/3.0/ref/settings/
|
||||
"""
|
||||
|
||||
import os
|
||||
import environ
|
||||
from urllib.parse import urljoin
|
||||
|
||||
@@ -1,18 +1,3 @@
|
||||
"""test1 URL Configuration
|
||||
|
||||
The `urlpatterns` list routes URLs to views. For more information please see:
|
||||
https://docs.djangoproject.com/en/3.0/topics/http/urls/
|
||||
Examples:
|
||||
Function views
|
||||
1. Add an import: from my_app import views
|
||||
2. Add a URL to urlpatterns: path('', views.home, name='home')
|
||||
Class-based views
|
||||
1. Add an import: from other_app.views import Home
|
||||
2. Add a URL to urlpatterns: path('', Home.as_view(), name='home')
|
||||
Including another URLconf
|
||||
1. Import the include() function: from django.urls import include, path
|
||||
2. Add a URL to urlpatterns: path('blog/', include('blog.urls'))
|
||||
"""
|
||||
from django.contrib import admin
|
||||
from django.urls import path, include
|
||||
from django.conf.urls.static import static
|
||||
@@ -20,6 +5,7 @@ from django.conf import settings
|
||||
from django.views.generic import RedirectView
|
||||
from . import views
|
||||
from posts.views import PostViewSet
|
||||
from members.urls import member_urlpatterns, jobs_urlpatterns
|
||||
from members.views import MemberViewSet, JobViewSet, JobGroupViewSet, JobMemberViewSet
|
||||
from rest_framework import routers
|
||||
|
||||
@@ -41,6 +27,8 @@ urlpatterns = [
|
||||
path('ckeditor/', include('ckeditor_uploader.urls')),
|
||||
path('api/', include(router.urls)),
|
||||
path('members/', include('members.urls'), name='members'),
|
||||
path('jobs/', include(jobs_urlpatterns), name='jobs'),
|
||||
path('member/', include(member_urlpatterns), name='member'),
|
||||
path('blackboard/', include('blackboard.urls'), name='blackboard'),
|
||||
path('tasks/', include('tasks.urls'), name='tasks'),
|
||||
] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
|
||||
|
||||
@@ -1,12 +1,3 @@
|
||||
"""
|
||||
WSGI config for fet2020 project.
|
||||
|
||||
It exposes the WSGI callable as a module-level variable named ``application``.
|
||||
|
||||
For more information on this file, see
|
||||
https://docs.djangoproject.com/en/3.0/howto/deployment/wsgi/
|
||||
"""
|
||||
|
||||
import os
|
||||
|
||||
from django.core.wsgi import get_wsgi_application
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
# from django.test import TestCase
|
||||
|
||||
# Create your tests here.
|
||||
|
||||
@@ -6,6 +6,12 @@ from . import views
|
||||
urlpatterns = [
|
||||
path('', views.index, name='members'),
|
||||
path('<str:filter>', views.members_view),
|
||||
path('jobs/<str:slug>', views.jobs_view),
|
||||
path('member/<str:member_name>', views.profile_view, name='member'),
|
||||
]
|
||||
|
||||
member_urlpatterns = [
|
||||
path('<str:member_name>', views.profile_view, name='member'),
|
||||
]
|
||||
|
||||
jobs_urlpatterns = [
|
||||
path('<str:slug>', views.jobs_view, name='jobs'),
|
||||
]
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
# from django.test import TestCase
|
||||
|
||||
# Create your tests here.
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
# from django.test import TestCase
|
||||
|
||||
# Create your tests here.
|
||||
|
||||
@@ -1,7 +0,0 @@
|
||||
{% extends "admin/app_index.html" %}
|
||||
|
||||
{% block sidebar %}
|
||||
<h1>Hello</h1>
|
||||
<ul><li>asdf</li></ul>
|
||||
|
||||
{% endblock %}
|
||||
@@ -1,7 +0,0 @@
|
||||
{% extends "admin/change_list.html" %}
|
||||
|
||||
{% block object-tools-items %}
|
||||
|
||||
{{ block.super }}
|
||||
<li><a href="#">sdf</a></li>
|
||||
{% endblock %}
|
||||
@@ -1,5 +0,0 @@
|
||||
|
||||
{% extends "admin/base_site.html" %}
|
||||
{% block content %}
|
||||
<h1> Preview </h1>
|
||||
{% endblock %}
|
||||
@@ -1,7 +1 @@
|
||||
{% extends "admin/index.html" %}
|
||||
{% block content%}
|
||||
<div style="float:left; width:100%">
|
||||
{{block.super}}
|
||||
Hello
|
||||
</div>
|
||||
{% endblock %}
|
||||
@@ -48,19 +48,19 @@ footer {
|
||||
<div class="top-bar-right">
|
||||
<ul class="dropdown vertical medium-horizontal menu" data-responsive-menu="drilldown medium-dropdown" data-animate-heigt="true">
|
||||
{% if request.user.is_authenticated %}
|
||||
<li class=""><a role="menuitem" style="color: black; background: lightgrey">Hallo {{request.user.username}}</a></li>
|
||||
<li class=""><a href="/admin" style="background: lightgrey;">Admin</a></li>
|
||||
<li class=""><a href="{%url 'tasks'%}" style="background: lightgrey;">Tasks</a></li>
|
||||
<li><a role="menuitem" style="color: black; background: lightgrey">Hallo {{request.user.username}}</a></li>
|
||||
<li><a href="/admin" style="background: lightgrey;">Admin</a></li>
|
||||
<li><a href="{%url 'tasks'%}" style="background: lightgrey;">Tasks</a></li>
|
||||
{% endif %}
|
||||
<li class=""><a href="{% url 'posts.index' %}">Aktuelles</a></li>
|
||||
<li><a href="{% url 'posts.index' %}">Aktuelles</a></li>
|
||||
<!-- show active members first -->
|
||||
<li class=""><a href="{% url 'members'%}A">Fachschaft</a></li>
|
||||
<li class=""><a href="/fotos/">Fotos</a></li>
|
||||
<li class=""><a href="/blackboard">Blackboard</a></li>
|
||||
<li><a href="{% url 'members'%}A">Fachschaft</a></li>
|
||||
<li><a href="/fotos/">Fotos</a></li>
|
||||
<li><a href="/blackboard">Blackboard</a></li>
|
||||
{% if request.user.is_authenticated %}
|
||||
<li class=""><a href="{%url 'logout'%}">Logout</a></li>
|
||||
<li><a href="{%url 'logout'%}">Logout</a></li>
|
||||
{% else %}
|
||||
<li class=""><a href="{%url 'login'%}">Login</a></li>
|
||||
<li><a href="{%url 'login'%}">Login</a></li>
|
||||
{% endif %}
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
|
||||
{% for job in pinned_job_groups %}
|
||||
<div class="cell large-2 medium-4 small-6">
|
||||
<a class="button expanded {% if job.slug in request.path %} active {% endif %}" href="/members/jobs/{{job.slug}}">
|
||||
<a class="button expanded {% if job.slug in request.path %} active {% endif %}" href="{% url 'jobs' job.slug %}">
|
||||
{{job.name}}
|
||||
</a>
|
||||
</div>
|
||||
@@ -32,7 +32,7 @@
|
||||
|
||||
{% for job in unpinned_job_groups %}
|
||||
<div class="cell large-2 medium-4 small-6">
|
||||
<a class="button expanded {% if job.slug in request.path %} active {% endif %}" href="/members/jobs/{{job.slug}}">
|
||||
<a class="button expanded {% if job.slug in request.path %} active {% endif %}" href="{% url 'jobs' job.slug %}">
|
||||
{{ job.name|softhyphen|safe }}
|
||||
</a>
|
||||
</div>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{# only thumb and name of member #}
|
||||
<a class="thumbnail member-thumb" href="/members/member/{{member.nickname}}" style="width:150px;height:150px">
|
||||
<a class="thumbnail member-thumb" href="{% url 'member' member.nickname %}" style="width:150px;height:150px">
|
||||
<img src="{{member.image.thumb.url}}" alt="" />
|
||||
<div class="thumb-layer">
|
||||
<div>
|
||||
|
||||
Reference in New Issue
Block a user