'admin/postfix/whitelist' => $this->make_hook('postfix_whitelist', AUTH_MDP, 'admin'),
'admin/mx/broken' => $this->make_hook('mx_broken', AUTH_MDP, 'admin'),
'admin/skins' => $this->make_hook('skins', AUTH_MDP, 'admin'),
- 'admin/synchro_ax' => $this->make_hook('synchro_ax', AUTH_MDP, 'admin'),
'admin/user' => $this->make_hook('user', AUTH_MDP, 'admin'),
'admin/add_accounts' => $this->make_hook('add_accounts', AUTH_MDP, 'admin'),
'admin/validate' => $this->make_hook('validate', AUTH_MDP, 'admin'),
return null;
}
- private static function getMatricule($mat)
- {
- $year = intval(substr($mat, 0, 3));
- $rang = intval(substr($mat, 3, 3));
- if ($year > 200) { $year /= 10; };
- if ($year < 96) {
- return null;
- } else {
- return sprintf('%04u%04u', 1900+$year, $rang);
- }
- }
-
private static function formatNewUser($infosLine, $separator, $promo, $size)
{
$infos = explode($separator, $infosLine);
&& ($sex = self::formatSex($page, $infos[3], $line))) {
$name = $infos[1] . ' ' . $infos[0];
$birthDate = self::formatBirthDate($infos[2]);
- $xorgId = self::getMatricule($infos[4]);
+ $xorgId = Profile::getXorgId($infos[4]);
XDB::execute('INSERT INTO profiles (hrpid, xorg_id, ax_id, birthdate_ref, sex)
VALUES ({?}, {?}, {?}, {?})',