Exemplo n.º 1
0
													</div>
												</li>
												<hr>
												<?php 
        }
        ?>
											</ul>
										</div>
									</div>
									<div class="tab-pane" id="tab_1_3">
										<div class="scroller" data-height="290px" data-always-visible="1" data-rail-visible1="1">
											<ul class="feeds">
												<?php 
        $notesClient = $notesClientsManager->getNotes();
        foreach ($notesClient as $notes) {
            $contrat = $contratManager->getContratByCode($notes->codeContrat());
            $projetName = $projetManager->getProjetById($notes->idProjet())->nom();
            $client = $clientManager->getClientById($contrat->idClient());
            if (str_word_count($notes->note()) > 0) {
                ?>
												<li>
													<div class="col1">
														<div class="cont">
															<div class="cont-col1">
																<div class="label label-success">								
																	<i class="icon-bell"></i>
																</div>
															</div>
															<div class="cont-col2">
																<div class="desc">	
																	<strong>Note</strong> : <?php 
spl_autoload_register("classLoad");
include '../config.php';
//classes loading end
session_start();
if (isset($_SESSION['userMerlaTrav']) and $_SESSION['userMerlaTrav']->profil() == "admin") {
    //classes managers
    $idProjet = 0;
    $projetManager = new ProjetManager($pdo);
    $clientManager = new ClientManager($pdo);
    $contratManager = new ContratManager($pdo);
    $operationManager = new OperationManager($pdo);
    $contratCasLibreManager = new ContratCasLibreManager($pdo);
    $reglementPrevuManager = new ReglementPrevuManager($pdo);
    if (isset($_GET['codeContrat']) and (bool) $contratManager->getCodeContrat($_GET['codeContrat'])) {
        $codeContrat = $_GET['codeContrat'];
        $contrat = $contratManager->getContratByCode($codeContrat);
        $projet = $projetManager->getProjetById($contrat->idProjet());
        $client = $clientManager->getClientById($contrat->idClient());
        $sommeOperations = $operationManager->sommeOperations($contrat->id());
        $biens = "";
        $typeBien = "";
        $niveau = "";
        if ($contrat->typeBien() == "appartement") {
            $appartementManager = new AppartementManager($pdo);
            $biens = $appartementManager->getAppartementById($contrat->idBien());
            $typeBien = "Appartement";
            $niveau = $biens->niveau();
        } else {
            if ($contrat->typeBien() == "localCommercial") {
                $locauxManager = new LocauxManager($pdo);
                $biens = $locauxManager->getLocauxById($contrat->idBien());
Exemplo n.º 3
0
                             <strong>Liste des réglements en retards</strong>
                             <table class="table table-striped table-bordered table-hover">
                                 <thead>
                                     <tr>
                                         <th style="width: 20%">Client</th>
                                         <th style="width: 10%">Téléphone</th>
                                         <th style="width: 20%">Projet</th>
                                         <th style="width: 20%">Bien</th>
                                         <th style="width: 20%">Date Prévu de réglement</th>
                                         <th style="width: 10%">Status</th>
                                     </tr>
                                 </thead>
                                 <tbody>
                                     <?php 
 foreach ($reglementsPrevusEnRetards as $element) {
     $contrat = $contratManager->getContratByCode($element->codeContrat());
     $client = $clientManager->getClientById($contrat->idClient());
     $projet = $projetManager->getProjetById($contrat->idProjet());
     $bien = "";
     $typeBien = "";
     //if the property is a "Local commercial" we don't need to mention niveau attribute
     $niveau = "";
     if ($contrat->typeBien() == "appartement") {
         $appartementManager = new AppartementManager($pdo);
         $bien = $appartementManager->getAppartementById($contrat->idBien());
         $niveau = $bien->niveau();
         $typeBien = "Appartement";
     } else {
         if ($contrat->typeBien() == "localCommercial") {
             $locauxManager = new LocauxManager($pdo);
             $bien = $locauxManager->getLocauxById($contrat->idBien());
Exemplo n.º 4
0
                                     <tr>
                                         <th>Actions</th>
                                         <th>Commissionnaire</th>
                                         <th>Description</th>
                                         <th>Montant</th>
                                         <th>Projet</th>
                                         <th>Bien</th>
                                         <th>Date</th>
                                         <th>état</th>
                                     </tr>
                                 </thead>
                                 <tbody>
                                     <?php 
 foreach ($commissions as $commission) {
     //get projet, bien and client informations
     $contrat = $contratManager->getContratByCode($commission->codeContrat());
     $projet = $projetManager->getProjetById($contrat->idProjet());
     $typeBien = $contrat->typeBien();
     $bien = "";
     if ($typeBien == "localCommercial") {
         $locauxManager = new LocauxManager($pdo);
         $bien = $locauxManager->getLocauxById($contrat->idBien());
     } else {
         $appartementManager = new AppartementManager($pdo);
         $bien = $appartementManager->getAppartementById($contrat->idBien());
     }
     $etatButton = "red";
     if ($commission->etat() == "V") {
         $etatButton = "green";
     }
     ?>