self.home_ou = self.get_home_ou()
self.first_given_name = self._simple_map('givenName')
if not self.first_given_name:
- self.first_given_name('LDAP_NULL')
+ self.first_given_name = 'LDAP_NULL'
print >> sys.stderr, 'No givenName for %s' % (self.usrname)
self.lang_pref = self._simple_map('preferredLanguage')
print >> sys.stderr, 'No lulColleagueId for %s' % (self.ldap_atts)
return 2, 'NO_COLLEAGUE_ID'
- ident_value = self.ldap_atts['lulColleagueId'][0].strip().lower()
- if len(ident_value) != 7:
- print >> sys.stderr, 'Datatel number not 7 chars for %s (%s)' % (
- self.usrname, ident_value
+ ident_value = self._simple_map('lulColleagueId')
+ if ident_value is None:
+ print >> sys.stderr, 'No Datatel number for %s (%s)' % (
+ self.usrname
)
- if len(ident_value) == 6:
- ident_value = '0%s' % ident_value
- elif len(ident_value) == 5:
- ident_value = '00%s' % ident_value
+ else:
+ ident_value = ident_value.lower()
+ if len(ident_value) != 7:
+ print >> sys.stderr, 'Datatel number not 7 chars for %s (%s)' % (
+ self.usrname, ident_value
+ )
+ if len(ident_value) == 6:
+ ident_value = '0%s' % ident_value
+ elif len(ident_value) == 5:
+ ident_value = '00%s' % ident_value
return 2, ident_value
'student': 113,
'gr': 112,
'al': 114,
+ 'alumni': 114,
'faculty': 111,
'staff': 115,
'thorneloe': 115,