Your IP : 216.73.216.65


Current Path : /home/ataenra/www/ATA/INTRANET/MesSav/
Upload File :
Current File : /home/ataenra/www/ATA/INTRANET/MesSav/MES.php

<?php

//recup form6
if(isset($_POST['Plani']) && (isset($_POST['ID'] ))){$ID=$_POST['ID'];require "Tmes.php";}




?>

<!-- -------------------TABLEAU N°2 -----------------------------------------------> 
<div class="container1">

<div class="table-responsive">
    <h6 class="btn-lg btn-warning"> MES EN COURS </h6>
    <div style="overflow-x: hidden; overflow-y: scroll; width: 100%; height: 600px;">
    <table class='table table-hover table-bordered table-condensed'>
        <thead>
        <tr>
        <th>ID ATA</th>
        <th>Fabricant</th>
        <th>Reference</th>
        <th>Date de Soumission</th>
        <th>Date d'intervention prévue</th>
        <th>Installateur</th>
        <th>Client Final / Coordonnées</th>
        <th>BC</th>
        <th>Etat</th>
        <th>Action</th>
        </tr>
        </thead>

        <?php while ($R2 = $list2->fetch(PDO::FETCH_OBJ)) {?>

        <tr>
        <td><?php echo "MES.".$R2->ID_Mes.""; ?></td>
        <td><?php echo $R2->Fabricant; ?></td>
        <td><?php echo $R2->RefF; ?></td>
        <td><?php $dateS1 = $R2->DateS; $DS1 = new DateTime($dateS1); ?>
            <?php echo $DS1->Format('d-m-Y'); ?></td>
        <td><?php if($R2->DateP != null){$dateP1 = $R2->DateP; $DS2 = new DateTime($dateP1); echo $DS2->Format('d-m-Y');}
                  if($R2->DateP == null){echo "En attente Client";} ?></td>   
        <td><?php echo "".$R2->RaisonS." / ".$R2->TelI." / ".$R2->EmailI.""; ?></td> 
        <td><?php echo "".$R2->NomC." - ".$R2->AdresseC." ".$R2->CPC." ".$R2->VilleC." / ".$R2->TelC." - ".$R2->EmailC."" ; ?></td>
        
        <td><?php echo '<a class="btn btn-secondary" href="./ATA/FICHIERS/MES/'.$R2->ID_Mes.'/BC/MES.BC.'.$R2->ID_Mes.'.pdf" download="">Bon de commande</a>';?></td>

        <td><?php if($R2->Etat=="Soumis"){echo '<a class="btn btn-info">En controle par ATA</a>';} ?>
            <?php if($R2->Etat=="Valide"){echo '<a class="btn btn-warning">Contact client en cours</a>';} ?>
            <?php if(($com == "Di4lz" || $com == "Adrien" || $com == "Thomas")&($R2->MailC =="Oui")&($R2->Etat=="Valide")){echo '<a class="btn btn-success" >Mail Envoyé</a>';} ?>
            <?php if($R2->Etat=="Planifie"){$Plani1 = $R2->DateP; $dateTime4 = new DateTime($Plani1);echo '<a class="btn btn-info">Planifié le '.$dateTime4->format('d-m-Y').'</a>';} ?>
            <?php if($R2->Etat=="En cours" || $R2->Etat=="MES" ){echo '<a class="btn btn-info">En cours</a>'; } ?>
            <?php if($R2->Etat=="Erreur"){echo '<a class="btn btn-danger">Non conforme</a>'; echo '<a class="btn btn-danger">RAPPORT</a>'; } ?>
            <?php if($R2->Etat=="Termine"){echo '<a class="btn btn-info">Termine</a>';} ?></td>
        <td>
            <?php if(($com == "Di4lz" || $com == "Adrien" || $com == "Thomas")&($R2->Etat=="Soumis")){echo '<a class="btn btn-warning" href="./ATA/INTRANET/MesSav/MesValid.php?ID='.$R2->ID_Mes.'">Validation</a>';}
                  if(($com == "Di4lz" || $com == "Adrien" || $com == "Thomas")&($R2->MailC !="Oui")&($R2->Etat=="Valide")){echo '<a class="btn btn-warning" href="./ATA/INTRANET/MesSav/mail.php?ID='.$R2->ID_Mes.'">Mail Client</a>';}
                  if(($com == "Di4lz" || $com == "Adrien" || $com == "Thomas")&($R2->Etat=="Valide")){echo '<a class="btn btn-warning" href="./index.php/hmes?ID='.$R2->ID_Mes.'&F=Plani">Planifier</a>';}  
                  
                  
                  
                  ?>
        </td>
                                
        </tr>
    <?php } ?>
        
    </table>   
    </div>
</div>
</div>