Browse Source

ajustando script de sincronizacao com LDAP

diagnosticos
Felipe Vieira 13 years ago
parent
commit
1f21cbad47
  1. 2
      sigi/apps/servidores/management/commands/sync_ldap.py

2
sigi/apps/servidores/management/commands/sync_ldap.py

@ -57,7 +57,7 @@ class Command(BaseCommand):
except: email = '' except: email = ''
try: first_name = ldap_user[1]['givenName'][0] try: first_name = ldap_user[1]['givenName'][0]
except: first_name = username except: first_name = username
try: last_name = ldap_user[1]['sn'][0] try: last_name = ldap_user[1]['sn'][0][:30]
except: last_name = '' except: last_name = ''
try: user = User.objects.get(username=username) try: user = User.objects.get(username=username)
except User.DoesNotExist: except User.DoesNotExist:

Loading…
Cancel
Save