. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . AnonSec Shell
AnonSec Shell
Server IP : 213.186.33.4  /  Your IP : 216.73.216.146   [ Reverse IP ]
Web Server : Apache
System : Linux webm002.cluster103.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 : dealkatnwc ( 662330)
PHP Version : 7.0.33
Disable Function : _dyuweyrj4,_dyuweyrj4r,dl
Domains : 2 Domains
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /home/dealkatnwc/www/GDEAL/pages/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     [ BACKUP SHELL ]     [ JUMPING ]     [ MASS DEFACE ]     [ SCAN ROOT ]     [ SYMLINK ]     

Current File : /home/dealkatnwc/www/GDEAL/pages/facture.php
<?php
include 'class/coupon.class.php';

?>
<!DOCTYPE html>
<html lang="en">

<head>
    <?php include 'header.php';?>
</head>

<body>

    <div id="wrapper">
<?php include 'menu.php'; ?>
<?php if (!(he_can('FACTURE'))) {echo "<script>location.href = '403.php';</script>";}?>

<?php 
$managerCou = new CouponManager($db);




//////////////////  traitement  des action sur les coupons



	
    $listeDeal = $managerCou->getListDeal(); 		   
	// var_dump($listeDeal);
?>

        <!-- Page Content -->
        <div id="page-wrapper">
            <div class="container-fluid">
                <div class="row">
                    <div class="col-lg-12">
					<p align="right"  class="visible-print"><img src='images/dealka-logo.png' style='width: 30%'></p>
                        <h1 class="page-header">Facture</h1>					
                    </div>
                    <!-- /.col-lg-12 -->
                </div>
                <!-- /.row -->

<?php
$class1 ="active";$class2 ="hidden";
if (isset($_POST['action'])){if ($_POST['action'] == 'Calculer'){$class1 ="";$class2 ="active";}}
?>				
<ul class="nav nav-tabs hidden-print" role="tablist">
    <li role="presentation" class="<?php echo $class1;?>"><a href="#calc" aria-controls="calc" role="tab" data-toggle="tab">Paramétres</a></li>
    <li role="presentation" class="<?php echo $class2;?>"><a href="#res" aria-controls="res" role="tab" data-toggle="tab">Récap</a></li>
</ul>

<div class="tab-content">
	<div role="tabpanel" class="tab-pane fade in <?php echo $class1;?>" id="calc">
				<div class="row hidden-print">
                <div class="col-lg-12">
                    <div class="panel panel-default">
                        <div class="panel-heading">
                        </div>
                        <div class="panel-body">
						
                                <table class="table table-striped">
									<form name='frm' id='frm' action='' method='post'>
									<input type='hidden' name='action' value='Calculer'>
									<?php

									?>
                                    <tbody>
										<tr>
                                            <th width='25%'>DEAL  <span class="asteriskField">*</span></th>
                                            <td >
											
											<?php 
											echo "	
												<select style='width: 90%;' id='id_post' name='id_post' 
												onchange=\"document.getElementById('infod').innerHTML = document.getElementById('infodeal'+this.options[this.selectedIndex].value).innerHTML;\" 
												required><option value='' selected>Veuillez choisir un deal</option>";	
												foreach ($listeDeal as $deal)
												{echo "<option  value='".$deal['id']."' > ".$deal['id'].' - '.substr($deal['titre'],0,75)."...</option>";}
												echo "</select>";
											    
													foreach ($listeDeal as $deal)
													   {echo "<div id='infodeal".$deal['id']."' class='well well-sm' style='width: 90%;display:none;'>".$deal['titre']."<br>
													   Prix : <b>".$deal['prix_promo']."</b><sup>Dt.</sup> au lieu de <b><s>".$deal['prix_reel']."</s></b><sup>Dt.</sup> (<b>".$deal['nba']."</b> Ventes Affichés)<br>
													   Partenaire : <b>".$deal['p_nom']."</b><br>
													   <a class='btn btn-info  btn-xs' href='".$home."/?p=".$deal['id']."' target='_blanc'><i class='fas fa-eye' style='color:#fff;' ></i>&nbsp;<b>VOIR LE DEAL</b></a>
													   </div>";}
													echo "<div style='width: 90%;' id='infod' class='well well-sm'> <font color='red'>Veuillez choisir un deal</font></div>";
											?>
											</td>
                                        </tr>	
										<tr>
                                            <th>Rémunération <small>par coupon</small> <span class="asteriskField">*</span> </th>
                                            <td><?php echo "<div class='form-group input-group'><input type='number' class='form-control' id='remuneration' name='remuneration' pattern='^[0-9.,]{1,70}$' placeholder='Rémunération' title='La rémunération doit être composer des chiffres' required><span class='input-group-addon'> Millimes</span></div>";?></td>
                                        </tr>
										<tr>
                                            <th>Nombre de coupon</small> <span class="asteriskField">*</span> </th>
                                            <td><?php echo "<div class='form-group input-group'><input type='number' class='form-control' id='nbcoupon' name='nbcoupon' pattern='^[0-9-]{1,70}$' placeholder='Rémunération' title='Nombre de coupon (-1  si vous voulez par defaut)' value='-1' required><span class='input-group-addon'> Coupons</span></div>";?></td>
                                        </tr>	
										<tr>
                                            <th>Au nom de </small></th>
                                            <td><?php echo "<div class='form-group input-group'><span class='input-group-addon'> M./Mme/Mlle</span><input type='text' class='form-control' id='nom' name='nom' placeholder='Nom & Prénom' title='au nom de :' value='' ></div>";?></td>
                                        </tr>										
										<tr>
                                            <th></th>
                                            <td>
											<button type="submit" class="btn btn-lg btn-primary btn-block"><i class="fas fa-calculator"></i> caluler</button>
											
											</td>
                                        </tr>
                                    </tbody>
                                    </form>
                                </table>
                        </div>
                          <!-- /.table-responsive -->
                        </div>
        
                    </div>
                </div>
      </div>
	  <div role="tabpanel" class="tab-pane fade in <?php echo $class2;?>" id="res">
				<?php
				if (isset($_POST['action']))
					{
						if ($_POST['action'] == 'Calculer')
						{
						  echo "<script>document.getElementById('id_post').value = ".$_POST['id_post'].";
								document.getElementById('infod').innerHTML = document.getElementById('infodeal'+".$_POST['id_post'].").innerHTML;</script>";
						  echo "<script>document.getElementById('remuneration').value = ".$_POST['remuneration'].";</script>";
						  echo "<script>document.getElementById('nbcoupon').value = ".$_POST['nbcoupon'].";</script>";
						  echo "<script>document.getElementById('nom').value = '".$_POST['nom']."';</script>";

						  $res = $managerCou->calcule($_POST['id_post']);
						  $tab_etat_cp = array(2,3,4,5);
						  if($_POST['nbcoupon']>0)
						  {
							unset($res['etat']);
							unset($tab_etat_cp);
							$res['etat'][999] = $_POST['nbcoupon'];
							$res['vente'] = $_POST['nbcoupon'];
							$coupon_code [999] = 'Totale vendu';
							$tab_etat_cp = array(999);
						  }
						  // var_dump($res);
				?>
				<div class="row">
                <div class="col-lg-12">
                    <div class="panel panel-default">
                        <div class="panel-heading">
                            <h3>Récap Deal : <?php echo $_POST['id_post']?> <small><p class="text-right">Le <?php echo date('d/m/Y');?></p></small></h3>
                        </div>
                        <div class="panel-body">
						<div class="col-md-6 col-xs-12">
                           <table class="table table-bordered">
							<tbody>
						      <tr><th>DEAL</th><td colspan="3"><?php echo $res['titre']; ?></td></tr>
						      <tr><th>PARTENAIRE</th><td colspan="3"><?php echo $res['p_nom']; ?></td></tr>
						      <tr><th>PRIX DE VENTE</th><td ><?php echo flous($res['prix_promo']); ?></td><th>Nb Coupons</th><td ><?php echo $res['vente']; ?></td></tr>
						    <tbody>
						   </table>
						   <p class="text-center hidden-print">
						   <?php
								echo  "<a type='button' href='javascript:window.print()' target='_blanc' class='btn btn-info'><i class='fas fa-print'></i> Imprimer</a>";
							?>
							</p>
						</div>
						<div class="col-md-6 col-xs-12">
                           <table class="table table-bordered .table-condensed">
							<tbody>
						      <tr><th>TYPE</th><th>Rémunération</th><th>Qte.</th><th>TOTALE</th></tr>
						      <?php
							  $totale = 0;
							  for($j=0;$j<count($tab_etat_cp);$j++)
								{$i= $tab_etat_cp[$j];
								$t= $res['etat'][$i] * $_POST['remuneration'];
							    $totale += $t;
								echo '<tr><th>'.str_replace('$','', $coupon_code[$i]).'</th><td>'.flous($_POST['remuneration']).' Dt.</td><td>'.$res['etat'][$i].'</td><td>'.flous($t).' </td></tr>';
								}
							  ?>
							  <tr><th colspan="3" class="text-right">TOTALE</th><td><b><?php echo flous($totale); ?></b> <sup>Dt. </sup></td></tr>
						    <tbody>
						   </table>
						</div>
					</div>
						<div class="col-md-12 col-xs-12 visible-print">
						<br>
						<?php $nom = "..........................................................."; 
						if(strlen($_POST['nom']) > 0) $nom = "&nbsp;<b>".$_POST['nom']."</b>"; ?>
							Je soussigné(e) M./Mme/Mlle <?php echo $nom;?>, 
						<br>Je représente <b><?php echo $res['p_nom']; ?></b>, 
						<br>Je certifie avoir reçu la somme de <b><?php echo flous($totale); ?></b> de la part de <b>DEALKA.tn</b> . 
							<br><br><br><p align="right"><b>Signature</b>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p>
						</div>

						
					</div>	
					<footer  class="visible-print" style='    position: fixed;bottom: 0;align: "center";'><hr> <b>Dealka.tn</b> | 00 216 96 46 56 66 | B2- 12 rue Ali Chehimi (en face de terrain de basket), Hammam-lif</footer>
				</div>
				</div>

				
				<?php		  		  
					   }
					}
				?>				
				
	</div>				
</div>				
				
				
				
				
				
            </div>
            <!-- /.container-fluid -->
        </div>
        <!-- /#page-wrapper -->

    </div>
    <!-- /#wrapper -->

    <!-- jQuery -->
    <script src="../bower_components/jquery/dist/jquery.min.js"></script>

    <!-- Bootstrap Core JavaScript -->
    <script src="../bower_components/bootstrap/dist/js/bootstrap.min.js"></script>

    <!-- Metis Menu Plugin JavaScript -->
    <script src="../bower_components/metisMenu/dist/metisMenu.min.js"></script>

    <!-- Custom Theme JavaScript -->
    <script src="../dist/js/sb-admin-2.js"></script>

</body>

</html>

Anon7 - 2022
AnonSec Team