gestioCOF/bda/__init__.py

11 lines
286 B
Python
Raw Normal View History

2017-06-02 18:25:04 +02:00
from django.contrib.auth.models import User
def get_generic_user():
generic, created = User.objects.get_or_create(username="bda_generic")
if created:
generic.email = "bda@ens.fr"
generic.first_name = "Bureau des Arts"
generic.save()
return generic