code = $modalite->code . $typeMention; $this->modalite = $modalite; $this->typeMention = $typeMention; $this->famillesActe = array(); $this->cdcIsValid = false; $this->nbActesTotal = 0; } /** * @return string */ public function getCode() { return $this->code; } /** * @return Modalite */ public function getModalite() { return $this->modalite; } /** * @return string */ public function getTypeMention() { return $this->typeMention; } /** * @param $iCTI_connexion * * @return array */ public function getFamillesActes($iCTI_connexion) { if (!$this->famillesActe) {$famillesActe = array(); $modaliteCode = $this->modalite->getCode(); $sql = <<typeMention' ORDER BY 1 ; SQL; $result = $iCTI_connexion->query($sql); while ($row = $iCTI_connexion->fetchAssoc($result)) { $famillesActe[$row['code']] = $row['oid']; } $this->famillesActe = $famillesActe; } return $this->famillesActe; } public function getNbActes($iCTI_connexion, $year) { $count = 0; $modaliteCode = $this->modalite->getCode(); $sql = <<typeMention' AND EXTRACT('Year' From date_acte) like '$year' ORDER BY 1; SQL; $result = $iCTI_connexion->query($sql); $record = $iCTI_connexion->fetchAssoc($result); if ($record) { $count = $record['count']; } return $count; } /** * @return int */ public function getNbActesTotal() { return $this->nbActesTotal; } /** * @param int $nbActesTotal */ public function setNbActesTotal($nbActesTotal) { $this->nbActesTotal = $nbActesTotal; } /** * @return false */ public function getCdcIsValid() { return $this->cdcIsValid; } /** * @param boolean $cdcIsValid */ public function setCdcIsValid($cdcIsValid) { $this->cdcIsValid = $cdcIsValid; } }