Metadata-Version: 2.4
Name: django-mz-users
Version: 0.1.0a1
Summary: Custom user model and user management for Django projects of the django-mz family
Keywords: django,users,user-model,auth,accounts
Author: Miroslav Zvolský
Author-email: Miroslav Zvolský <zvolsky@seznam.cz>
License-Expression: MIT
License-File: LICENSE
Classifier: Development Status :: 3 - Alpha
Classifier: Framework :: Django
Classifier: Framework :: Django :: 5.2
Classifier: Framework :: Django :: 6.0
Classifier: Intended Audience :: Developers
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Software Development :: Libraries
Requires-Dist: django>=5.2
Requires-Python: >=3.12
Description-Content-Type: text/markdown

# django-mz-users

The user model and user management for Django projects of the **django-mz** family (projects whose admin drives
an API and a Vue frontend). It is a small, plain Django app that any project can use.

> Status: alpha (0.1.0a1). The API may change before 1.0.

## Why a custom user model from the start

Django recommends a custom user model for every new project: switching `AUTH_USER_MODEL` later, on a live
database, is hard. `mz_users.User` is Django's standard user (`AbstractUser`) in its own app, so projects can share
it and extend it later without that switch.

## Installation

```console
pip install django-mz-users
```

```python
INSTALLED_APPS = [..., 'django.contrib.auth', 'mz_users', ...]
AUTH_USER_MODEL = 'mz_users.User'
```

Set it before the first `migrate` of the project. The app label is `mz_users` (table `mz_users_user`).

## What is included

- `mz_users.User` – the user model (`AbstractUser`), Czech labels included
- admin registration with Django's `UserAdmin`: the new-user form asks for the password twice

Planned: self-registration, password reset by e-mail and other user management, as API views for the frontend.

## Development

```console
uv run --package django-mz-users pytest
```

## License

MIT
