|
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 (0705) : /home/logmcpe/www/mcg/pages/ |
| [ Home ] | [ C0mmand ] | [ Upload File ] |
|---|
<?php
if($_POST['rowid']) {
include 'includes/config_tmcpro.php' ;
include 'includes/stable_functions_tmcpro.php' ;
$prestation_id = $_POST['rowid'];
$client_id=$_SESSION["client_id"] ;
// echo "==> $prestation_id <br/> " ;
$prest = dbi_fetch_row(dbi_query(" SELECT * FROM `prestation` WHERE `prestation_id` = $prestation_id ")) ;
// echo int2date($prest['prestation_date_deb']) ;
// echo int2date_autre_format($prest['prestation_date_deb']) ;
$prestation_date_deb =int2date_autre_format($prest['prestation_date_deb']) ;
$prestation_date_fin =int2date_autre_format($prest['prestation_date_fin']) ;
// echo "===> ".$prest['prestation_semaine']."<br/>" ;
// echo int2heure($prest['prestation_heurd']) ;
$prestation_heurf=addDuree($prest['prestation_heurd'], $prest['prestation_duree']) ;
// $prestation_heurf=int2heure($prestation_heurf) ;
?>
<?php
}
?>
<div class="modal-header task-single-header" data-task-single-id="5" data-status="4">
<h4 class="modal-title">Modifier Prestation <?php echo $prestationid ;?></h4>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">×</span>
</button>
</div>
<div class="modal-body">
<form action="" method="POST">
<div class="card-body">
<!-- ///////Ligne société & Catégorie -->
<!-- ///////Ligne -->
<div class="form-row">
<div class="form-group col-md-4">
<label>Date de Début (start)</label>
<div class="input-group">
<div class="input-group-prepend">
<span class="input-group-text"><i class="far fa-calendar-alt"></i></span>
</div>
<input type="date" class="form-control" id="start" name="start" value="<?php echo $prestation_date_deb ; ?>" placeholder="jj/mm/aaaa">
<!-- <input type="text" class="form-control" data-inputmask-alias="datetime" data-inputmask-inputformat="dd/mm/yyyy" data-mask name="start" placeholder="jj/mm/aaaa"> -->
</div>
</div>
<div class="form-group col-md-4">
<label>Date fin</label>
<select class="form-control" name="prestation_fin" id="salarie_mutuelle" value="<?=$q['salarie_mutuelle'] ; ?>">
<option value="-1" selected="<?php if($q['salarie_mutuelle']== NULL ) { echo 'selected' ;} ?> " disabled="disabled">-Date fin-</option>
<option value="1" <?php if($q['salarie_mutuelle']=='0') echo 'SELECTED'; ?> >Oui</option>
<option value="2" <?php if($q['salarie_mutuelle']=='1') echo 'SELECTED'; ?> > Non</option>
</select>
</div>
<div class="form-group col-md-4">
<label>Date de fin (end) </label>
<div class="input-group">
<div class="input-group-prepend">
<span class="input-group-text"><i class="far fa-calendar-alt"></i></span>
</div>
<input type="date" class="form-control" id="end" name="end" value="<?php echo $prestation_date_fin ; ?>" disabled>
<!-- <input type="text" class="form-control" data-inputmask-alias="datetime" data-inputmask-inputformat="dd/mm/yyyy" data-mask name="end" placeholder="jj/mm/aaaa"> -->
</div>
</div>
<div class="form-group col-md-4">
<label>Semaine entre deux prestation </label>
<div class="input-group">
<div class="input-group-prepend">
<span class="input-group-text"><i class="far fa-calendar-alt"></i></span>
</div>
<!-- <input type="text" class="form-control" name="number" placeholder="jj/mm/aaaa"> -->
<select class="form-control" name="num" id="num">
<option value="-1" selected="selected" disabled="disabled">-Nombre semaine-</option>
<?php
for($i=1 ; $i<=12 ; $i++ )
{
// echo "==$i===>".$prest['prestation_semaine']."<br/>" ;
// exit() ;
?>
<option value="<?php echo $i ; ?> "<?php if($prest['prestation_semaine'] == $i) echo 'SELECTED'; ?> > <?php echo $i ;?> </option>
<?php
}
?>
</select>
</div>
</div>
<div class="form-group col-md-2">
<label for="inputAddresse">Heure Début</label>
<input type="time" id="appt" min="05:00" max="22:00" class="form-control" name="prestation_jour_heurd" value= "<?php echo int2heure($prest['prestation_heurd']) ; ?>" required>
</div>
<div class="form-group col-md-2">
<label for="inputsociete">Heure fin</label>
<input type="time" id="appt" min="05:00" max="22:00" class="form-control" value= "<?php echo int2heure($prestation_heurf) ; ?>" name="prestation_jour_heurf" required>
</div>
<div class="form-group col-md-4"><!-- Liste déroulante jour -->
<label>Jour de prestation</label>
<select class="form-control" name="day" id="day">
<option value="-1" selected="selected" disabled="disabled">-Jour-</option>
<option value="1" <?php if($prest['prestation_jour'] == 1) echo 'SELECTED'; ?> > lundi </option>
<option value="2" <?php if($prest['prestation_jour'] == 2) echo 'SELECTED'; ?> > mardi </option>
<option value="3" <?php if($prest['prestation_jour'] == 3) echo 'SELECTED'; ?> >mercredi </option>
<option value="4" <?php if($prest['prestation_jour'] == 4) echo 'SELECTED'; ?> >jeudi </option>
<option value="5" <?php if($prest['prestation_jour'] == 5) echo 'SELECTED'; ?> > vendredi </option>
<option value="6" <?php if($prest['prestation_jour'] == 6) echo 'SELECTED'; ?> >samdei </option>
<option value="7" <?php if($prest['prestation_jour'] == 7) echo 'SELECTED'; ?> >dimanche </option>
</select>
</div>
<?php
// $list($salarie_nom, $salarie_prenom) = dbi_fetch_row(dbi_query("SELECT salarie_nom , salarie_prenom FROM salarie WHERE salarie_id = ".$prest['salarie_id'])) ;
// $nom = $salarie_nom." ".$salarie_prenom ;
$req =dbi_query("SELECT * FROM salarie WHERE 1") ;
?>
<div class="form-group col-md-4"><!-- Liste déroulante jour -->
<label>Salarier </label>
<select class="form-control" name="salarie_id">
<option value="-1" selected="selected" disabled="disabled">-Salarier-</option>
<?php
while( $sal=dbi_fetch_row($req))
{
?>
<option value="<?php echo $sal['salarie_id'] ; ?>" <?php if($prest['salarie_id'] == $sal['salarie_id']) echo 'SELECTED'; ?> ><?php echo $sal['salarie_nom']." ".$sal['salarie_prenom']; ?></option>
<?php
}
?>
</select>
</div>
<?php
$req1 =dbi_query("SELECT * FROM chantier WHERE `client_id` = $client_id and chantier_type_id = 1") ;
?>
<div class="form-group col-md-4"><!-- Liste déroulante jour -->
<label> Chantier </label>
<select class="form-control" name="chantier_ID">
<option value="-1" selected="selected" disabled="disabled">-Chantier-</option>
<?php
while( $chant=dbi_fetch_row($req1))
{
echo "==> ".$prest['chantier_id']."<br/>" ;
?>
<option value="<?php echo $chant['chantier_ID'] ; ?>" <?php if($prest['chantier_id'] == $chant['chantier_ID']) echo 'SELECTED'; ?> ><?php echo $chant['chantier_designation']; ?></option>
<?php
}
?>
</select>
</div>
<div class="form-group col-md-2">
<label for="inputsociete">Taux</label>
<input type="text" class="form-control" name="prestation_taux" value="<?php echo $prest['prestation_taux'] ;?>" required>
</div>
<div class="form-group col-md-4">
<label style="color:red">Date d’application</label>
<div class="input-group">
<div class="input-group-prepend">
<span class="input-group-text"><i class="far fa-calendar-alt"></i></span>
</div>
<input type="date" class="form-control" id="start" name="date_application" value="<?php echo $prestation_date_deb ; ?>" placeholder="jj/mm/aaaa">
<!-- <input type="text" class="form-control" data-inputmask-alias="datetime" data-inputmask-inputformat="dd/mm/yyyy" data-mask name="start" placeholder="jj/mm/aaaa"> -->
</div>
</div>
</div>
<input type="hidden" name="prestation_id" value="<?php echo $prestation_id ; ?>">
<input type="hidden" name="prestation_ref" value="<?php echo $prest['prestation_ref'] ; ?>">
<input type="hidden" name="modifier" value="modifier">
</div>
<div class="modal-footer justify-content-between">
<button type="submit" name="Modifier" class="btn btn-primary">Modifier</button>
<button type="button" class="btn btn-primary" data-dismiss="modal">Fermer</button>
</form>
</div>
</div>
