Subversion Repositories eFlore/Projets.eflore-projets

Compare Revisions

Ignore whitespace Rev 1013 → Rev 1014

/trunk/services/modules/0.1/sophy/Cartes.php
20,6 → 20,7
const MIME_TEXT = 'text/plain';
const MIME_PNG = 'image/png';
const MIME_JSON = 'application/json';
private $types_cartes_autorises = array('flore-probable');
62,8 → 63,8
$resultat = new ResultatService();
$url = sprintf(Config::get('chemin_cartes_tpl'), $num_fournier);
$resultat->corps = ($this->format_retour == self::MIME_PNG) ? self::getCartePng($url) : $url;
$resultat->mime = ($this->format_retour == self::MIME_PNG) ? self::MIME_PNG : self::MIME_TEXT;
$resultat->corps = ($this->format_retour == self::MIME_PNG) ? self::getCartePng($url) : array('binaire.href' => $url);
$resultat->mime = ($this->format_retour == self::MIME_PNG) ? self::MIME_PNG : self::MIME_JSON;
 
return $resultat;
}