mirror of
https://github.com/kristoferssolo/FOSSDB.git
synced 2025-10-21 17:50:35 +00:00
Fix urls
This commit is contained in:
parent
14ba48a728
commit
3ba83cdc8e
@ -20,8 +20,7 @@ from django.urls import include, path
|
||||
urlpatterns = [
|
||||
path("admin/", admin.site.urls),
|
||||
path("", include("main.urls")),
|
||||
path("", include("django.contrib.auth.urls")),
|
||||
path("settings/", include("account.urls")),
|
||||
path("auth/", include("account.urls")),
|
||||
path("<str:owner>/<str:project_name>/", include("fossdb.urls")),
|
||||
]
|
||||
if settings.DEBUG:
|
||||
|
||||
@ -4,7 +4,10 @@
|
||||
{% block meta %}{% endblock %}
|
||||
{% block content %}
|
||||
<div class="py-8 px-32">
|
||||
<div class="flex justify-end">
|
||||
<div class="flex justify-end gap-4">
|
||||
<a href="{% url 'logout' %}">
|
||||
<i class="fa-solid fa-right-from-bracket fa-2xl"></i>
|
||||
</a>
|
||||
<a href="{% url 'settings' %}">
|
||||
<i class="fa-solid fa-gear fa-2xl"></i>
|
||||
</a>
|
||||
|
||||
@ -18,7 +18,7 @@
|
||||
{{ user_form.email }}
|
||||
{{ user_form.first_name }}
|
||||
{{ user_form.last_name }}
|
||||
<button type="submit" class="button bg-skyblue-300 text-gray-500">Update</button>
|
||||
<button type="submit" class="button bg-skyblue-300 text-gray-500">Save</button>
|
||||
</form>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
@ -3,6 +3,9 @@ from django.urls import path
|
||||
from . import views
|
||||
|
||||
urlpatterns = [
|
||||
path("profile/", views.ProfileUpdateView.as_view(), name="settings"),
|
||||
path("security/", views.PasswordChangeView.as_view(), name="change_password"),
|
||||
path("signup/", views.signup_view, name="signup"),
|
||||
path("login/", views.login_view, name="login"),
|
||||
path("logout/", views.LogoutView.as_view(), name="logout"),
|
||||
path("settings/", views.ProfileUpdateView.as_view(), name="settings"),
|
||||
path("settings/security/", views.PasswordChangeView.as_view(), name="change_password"),
|
||||
]
|
||||
|
||||
@ -1,9 +1,9 @@
|
||||
from django.contrib import messages
|
||||
from django.contrib.auth import authenticate, login, update_session_auth_hash
|
||||
from django.contrib.auth import authenticate, login, logout, update_session_auth_hash
|
||||
from django.contrib.auth.forms import PasswordChangeForm
|
||||
from django.contrib.auth.mixins import LoginRequiredMixin
|
||||
from django.shortcuts import redirect, render
|
||||
from django.views.generic import ListView, TemplateView
|
||||
from django.views.generic import ListView, TemplateView, View
|
||||
|
||||
from fossdb.models import Project
|
||||
|
||||
|
||||
@ -1,6 +1,5 @@
|
||||
from account.views import login_view, ProfileProjectListView, signup_view
|
||||
from account.views import ProfileProjectListView
|
||||
from django.urls import path
|
||||
|
||||
from fossdb.views import ProjectCreateView, ProjectListView, SearchResultsListView
|
||||
|
||||
from . import views
|
||||
@ -14,7 +13,5 @@ urlpatterns = [
|
||||
path("dashboard/", views.dashboard, name="dashboard"),
|
||||
path("news/", views.news, name="news"),
|
||||
path("help/", views.help, name="help"),
|
||||
path("signup/", signup_view, name="signup"),
|
||||
path("login/", login_view, name="login"),
|
||||
path("<str:username>/", ProfileProjectListView.as_view(), name="profile"),
|
||||
]
|
||||
|
||||
Loading…
Reference in New Issue
Block a user