Ignore:
Timestamp:
May 12, 2012, 8:39:25 PM (9 years ago)
Author:
teymour
Message:

Ajout d'un champ pour les amendements multiples (+correction bug rectifié)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpc/trunk/project/lib/model/doctrine/Amendement.class.php

    r2672 r2674  
    126126    $numeros = $this->numero;
    127127    $lettre = $this->getLettreLoi();
    128     $ident = $this->getTags(array('is_triple' => true,
     128    if ($this->nb_multiples > 1) {
     129      $ident = $this->getTags(array('is_triple' => true,
    129130          'namespace' => 'loi',
    130131          'key' => 'amendement',
    131132          'return'    => 'value'));
    132     if (count($ident) > 1 && $lettre != "") {
    133133      sort($ident);
    134       if ($lettre) foreach ($ident as $iden) $iden .= $lettre;
     134      foreach ($ident as $iden) if (preg_match('/'.$lettre.'/', $iden)) $iden.= $lettre;
    135135      $numeros = implode(', ', $ident);
    136136      $pluriel = "s";
Note: See TracChangeset for help on using the changeset viewer.