I use the manual accounts for all students and teachers imported from my university academic information system with their class that already enrolled. So they can login with their Student/Teacher ID registered in university academic information system as Moodle username.
Then, I want to connect all the manual accounts that has been saved in Moodle to LDAP authentication, which is using Student University Email as the LDAP Username.
Everytime student / teacher login with LDAP account, Moodle created a new account with username = email. So when they are login, there is no course enrolled.
Do anyone know how to prevent this? How do I map the username in ldap with email field in manual accounts?