Overview
Comment:Le champ ID ne peut pas être supprimé, donc pas besoin de vérifier qu'il n'a pas été supprimé
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 52d5f95d59b3bce28ebfdd6dcb614588216be431
User & Date: bohwaz on 2015-02-24 03:33:19
Other Links: manifest | tags
Context
2015-02-25
03:35
Refonte de l'éditeur du wiki avec prévisualisation, l'insertion de fichier suivra check-in: ff34dde8e3 user: bohwaz tags: trunk
2015-02-24
03:33
Le champ ID ne peut pas être supprimé, donc pas besoin de vérifier qu'il n'a pas été supprimé check-in: 52d5f95d59 user: bohwaz tags: trunk
2015-02-20
06:45
Vérification de la présence des fichiers avant envoi check-in: 0acb6d101e user: bohwaz tags: trunk
Changes

Modified src/include/lib/Garradin/Membres/Champs.php from [54cfaf6650] to [012e73e8f5].

339
340
341
342
343
344
345
346


347
348
349
350
351
352


353
354
355
356
357
358
359
        if (!array_key_exists('passe', $champs))
        {
            throw new UserException('Le champ Mot de passe ne peut être supprimé des fiches membres.');
        }

        $config = Config::getInstance();

        if (!array_key_exists($config->get('champ_identite'), $champs))


        {
            throw new UserException('Le champ '.$config->get('champ_identite')
                .' est défini comme identité des membres et ne peut donc être supprimé des fiches membres.');
        }

        if (!array_key_exists($config->get('champ_identifiant'), $champs))


        {
            throw new UserException('Le champ '.$config->get('champ_identifiant')
                .' est défini comme identifiant à la connexion et ne peut donc être supprimé des fiches membres.');
        }

        foreach ($champs as $name=>&$config)
        {







|
>
>





|
>
>







339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
        if (!array_key_exists('passe', $champs))
        {
            throw new UserException('Le champ Mot de passe ne peut être supprimé des fiches membres.');
        }

        $config = Config::getInstance();

        $identite = $config->get('champ_identite');

        if ($identite != 'id' && !array_key_exists($identite, $champs))
        {
            throw new UserException('Le champ '.$config->get('champ_identite')
                .' est défini comme identité des membres et ne peut donc être supprimé des fiches membres.');
        }

        $identifiant = $config->get('champ_identifiant');

        if ($identifiant != 'id' && !array_key_exists($identifiant, $champs))
        {
            throw new UserException('Le champ '.$config->get('champ_identifiant')
                .' est défini comme identifiant à la connexion et ne peut donc être supprimé des fiches membres.');
        }

        foreach ($champs as $name=>&$config)
        {