Example #1
0
<?php

// On ouvre la mission
$data = new Mission($_GET['mission']);
// On vérifie que la mission a bien été ouverte
if ($data->err) {
    Core::goPage('porte', true);
}
// On récupère tous les items de la rue et la rue en question et la ville concernée
$rue = Maps::streetData($_GET['rue']);
$ville = Maps::cityData($rue['city']);
$items = $data->items($_GET['rue']);
if (!$items) {
    Core::goPage('reporting', array('mission' => $_GET['mission']), true);
}
// typologie
$typologie = $data->get('mission_type') == 'porte' ? 'porte' : 'boite';
// On charge le header
Core::loadHeader();
?>
<a href="<?php 
Core::goPage('reporting', array('mission' => $data->get('mission_hash')));
?>
" class="nostyle"><button class="gris" style="float: right; margin-top: 0em;">Retour à la mission</button></a>	
<h2 id="titre-mission" class="titre" data-mission="<?php 
echo $data->get('mission_hash');
?>
">Mission &laquo;&nbsp;<?php 
echo $data->get('mission_nom');
?>
&nbsp;&raquo;</h2>
Example #2
0
<?php

/**
 * Modification de l'immeuble d'habitation d'un contact
 *
 * PHP version 5
 *
 * @category Ajax
 * @package  LeQG
 * @author   Damien Senger <*****@*****.**>
 * @license  https://www.gnu.org/licenses/gpl-3.0.html GNU General Public License 3.0
 * @link     http://leqg.info
 */
$street = Maps::streetData($_POST['rue']);
$building = Maps::buildingNew($_POST['immeuble'], $street['id']);
$zipcode = Maps::zipcodeDetect($street['id']);
$city = Maps::cityData($street['city']);
$address = Maps::addressNew($_POST['fiche'], $city['id'], $zipcode, $street['id'], $building);
$data = new People($_POST['fiche']);
$postal = $data->postal_address();
echo $postal['reel'];
<?php

/**
 * Mise à jour de l'immeuble associé à un contact
 *
 * PHP version 5
 *
 * @category Ajax
 * @package  LeQG
 * @author   Damien Senger <*****@*****.**>
 * @license  https://www.gnu.org/licenses/gpl-3.0.html GNU General Public License 3.0
 * @link     http://leqg.info
 */
$building = Maps::buildingData($_POST['immeuble']);
$street = Maps::streetData($building['street']);
$zipcode = Maps::zipcodeDetect($street['id']);
$city = Maps::cityData($street['city']);
$address = Maps::addressNew($_POST['contact'], $city['id'], $zipcode, $street['id'], $building['id']);
$data = new People($_POST['contact']);
$postal = $data->postal_address();
echo $postal['reel'];