Metadata-Version: 2.3
Name: aa-student
Version: 0.1.0
Summary: aa-student plugin app for Alliance Auth.
Author-email: Bates Larsson <bateslarsson@gmail.com>
Requires-Python: >=3.8
Description-Content-Type: text/markdown
Classifier: Environment :: Web Environment
Classifier: Framework :: Django
Classifier: Framework :: Django :: 4.0
Classifier: Framework :: Django :: 4.2
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Topic :: Internet :: WWW/HTTP
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
Requires-Dist: allianceauth>=3
Project-URL: Documentation, https://github.com/EVE-University/aa-student
Project-URL: Homepage, https://github.com/EVE-University/aa-student
Project-URL: Source, https://github.com/EVE-University/aa-student
Project-URL: Tracker, https://github.com/EVE-University/aa-student/issues


# **EVE Uni Student Plugin for Alliance Auth**

This is a plugin app for Alliance Auth designed to assist with managing member student titles within EVE University.

---

## **Features**
- Automatically manages student titles based on configurable eligibility criteria.
- Periodically cleans up old member entries using Celery.

---

## **Installation**

1. **Add the app to your `INSTALLED_APPS`:**
   Add the `student` app to the `INSTALLED_APPS` section in your `settings.py` file:
   ```python
   INSTALLED_APPS += [
       'student',
   ]
   ```

2. **Apply migrations and collect static files:**
   Run the following commands in your terminal:
   ```bash
   python manage.py migrate
   python manage.py collectstatic
   ```

---

## **Configuration**

### **Student Eligibility Days**
Set the number of days a member must wait before being eligible for the student title. Add the following to your `settings.py`:
```python
STUDENTDAYS = 14
```
By default, this is set to **14 days**.


Set the number of people visible in the student page. Add the following to your `settings.py`:
```python
STUDENTLIMIT = 50
```
By default, this is set to **50 people**.


---

## **Celery Integration**

### **Schedule Automatic Cleanup**
To enable periodic cleanup of ineligible members, add the following task to your Celery schedule in `settings.py`:
```python
from celery.schedules import crontab

CELERYBEAT_SCHEDULE["delete_excluded_members"] = {
    "task": "student.tasks.delete_excluded_members",
    "schedule": crontab(minute=0, hour=0),  # Runs daily at midnight
}
```

Ensure your Celery worker and beat services are running.

