Add IntelliJ IDEA project configuration files

This commit adds IntelliJ IDEA-specific configuration files for the project, including module setup, version control integration, inspection profiles, and workspace settings. These files facilitate development environment configuration for contributors using IntelliJ IDEA.
This commit is contained in:
2025-07-02 11:11:36 +03:00
parent da83ae7afc
commit 0eefaad424
14 changed files with 208 additions and 37 deletions
+26 -2
View File
@@ -1,9 +1,10 @@
from django.contrib.auth import get_user_model
from django.contrib.auth.views import LoginView
from django.shortcuts import render
from django.urls import reverse_lazy
from django.views.generic import TemplateView, FormView
from django.views.generic import TemplateView, FormView, ListView, UpdateView
from accounts.forms import LoginForm
from accounts.forms import LoginForm, RegisterForm
# Create your views here.
@@ -14,4 +15,27 @@ class DepotLoginView(LoginView):
next_page = reverse_lazy('dashboard')
class RegisterView(FormView):
template_name = 'registration/register.html'
form_class = RegisterForm
# model = get_user_model()
success_url = reverse_lazy('dashboard')
def form_valid(self, form):
# Create user from form data
user = form.save(commit=False)
# user.set_password(form.cleaned_data['password'])
user.save()
return super().form_valid(form)
class UserListView(ListView):
template_name = 'registration/register.html'
# form_class = RegisterForm
model = get_user_model()
success_url = reverse_lazy('dashboard')
class UserEditView(UpdateView):
template_name = 'registration/register.html'
form_class = RegisterForm
model = get_user_model()
success_url = reverse_lazy('dashboard')