Linux vps-61133.fhnet.fr 4.9.0-19-amd64 #1 SMP Debian 4.9.320-2 (2022-06-30) x86_64
Apache/2.4.25 (Debian)
Server IP : 93.113.207.21 & Your IP : 216.73.216.112
Domains :
Cant Read [ /etc/named.conf ]
User : www-data
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
var /
www /
html /
hermes.bdcloud.fr /
compta /
facture /
Delete
Unzip
Name
Size
Permission
Date
Action
admin
[ DIR ]
drwxr-xr-x
2025-11-08 11:17
class
[ DIR ]
drwxr-xr-x
2025-11-08 11:17
stats
[ DIR ]
drwxr-xr-x
2025-11-08 11:17
tpl
[ DIR ]
drwxr-xr-x
2025-11-08 11:17
card-rec.php
69.21
KB
-rw-r--r--
2020-05-28 20:13
card.php
234.75
KB
-rw-r--r--
2022-02-10 16:28
contact.php
7.51
KB
-rw-r--r--
2020-05-28 20:13
document.php
7.37
KB
-rw-r--r--
2020-05-28 20:13
index.html
0
B
-rw-r--r--
2020-04-18 15:05
info.php
4.72
KB
-rw-r--r--
2020-05-12 15:31
invoicetemplate_list.php
32.46
KB
-rw-r--r--
2020-08-04 12:34
list.php
79.44
KB
-rw-r--r--
2020-11-30 11:10
note.php
5.48
KB
-rw-r--r--
2020-05-12 15:31
prelevement.php
31.88
KB
-rw-r--r--
2020-08-07 16:47
updaterevientprice.php
3.86
KB
-rw-r--r--
2020-11-16 11:02
updateunitprice.php
4.5
KB
-rw-r--r--
2020-11-16 11:18
Save
Rename
<?php require("../../main.inc.php"); $price = str_replace(',','.',$_REQUEST['price']); $lineid = $_REQUEST['lineid']; $facid = $_REQUEST['facid']; $totalunits = $_REQUEST['totalunits']; $dataqty = $_REQUEST['dataqty']; $ext_det1 = $_REQUEST['ext_det1']; $lineqty = $_REQUEST['lineqty']; $reduction = $_REQUEST['reduction']; $current_counter = ((isset($_REQUEST['current_counter']))?$_REQUEST['current_counter']:""); $total_lines = ((isset($_REQUEST['total_lines']))?$_REQUEST['total_lines']:""); // print "\nprice :".$price; // print "\nlineid :".$lineid; // print "\nfacid :".$facid; // print "\ntotalunits :".$totalunits; // print "\ndataqty :".$dataqty; // print "\next_det1 :".$ext_det1; // print "\nlineqty :".$lineqty; // print "\nreduction :".$reduction; // print "\n\n\n"; // print "price : ".( (round( (round( $price,3) * $dataqty) ,2)*$ext_det1)*$lineqty ); $getfac = "SELECT * FROM llx_facturedet WHERE fk_facture=$facid AND rowid=$lineid "; $res_getfac = $db->query($getfac); $fnd_getfac = $db->num_rows($res_getfac); // print "\nfnd_getfac : ".$fnd_getfac; if($fnd_getfac) { $detailfac = $db->fetch_array($res_getfac); if($reduction == 0) { //$price_ht = ( (round( (round( $price,3) * $dataqty) ,2)*$ext_det1)*$lineqty ); //$price_ttc = (( (round( (round( $price,3) * $dataqty) ,2)*$ext_det1)*$lineqty )*(1+($detailfac['tva_tx']/100))); //$differencetva = ($price_ttc-$price_ht); $sql = "UPDATE llx_facturedet SET buy_price_ht='$price' WHERE fk_facture=$facid AND rowid=$lineid "; } else { //$price_subprice = round( ( round(($price*$dataqty),2) *$ext_det1), 2 ) ; //$price_ht = ( (round( (round( $price,3) * $dataqty) ,2)*$ext_det1)*$lineqty ) * (1-($reduction/100)); //$price_ttc = (( (round( (round( $price,3) * $dataqty) ,2)*$ext_det1)*$lineqty )*(1+($detailfac['tva_tx']/100))) * (1-($reduction/100)); //$differencetva = ($price_ttc-$price_ht); $sql = "UPDATE llx_facturedet SET buy_price_ht='$price' WHERE fk_facture=$facid AND rowid=$lineid "; } //price updated. $res = $db->query($sql); $db->commit(); //print "LINEDATA HAS BEEN UPDATED."; //now getall the lines of facture to obtain the total HT TTC and TVA(HT-TTC) $sql_fac = "SELECT * FROM llx_facture WHERE rowid=$facid "; $res_fac = $db->query($sql_fac); $fnd_fac = $db->num_rows($res_fac); if($fnd_fac > 0) { $facture = $db->fetch_array($res_fac); //getlines of this facture $sql_facd= "SELECT * FROM llx_facturedet WHERE fk_facture=".$facture['rowid'].""; $res_facd= $db->query($sql_facd); $fnd_facd= $db->num_rows($res_facd); if($fnd_facd>0) { while($facturedet = $db->fetch_array($res_facd)) { //print "\n".$facturedet['total_ttc']; //print "\n".$facturedet['total_ht']; //print "\n".$facturedet['total_tva']; /*$update_total_ttc += $facturedet['total_ttc']; $update_total_ht += $facturedet['total_ht']; $update_total_tva += $facturedet['total_tva'];*/ $update_buy_price_ht += $facturedet['buy_price_ht']; } //print "\nFinally : ".$update_total_ttc; //print "\nFinally : ".$update_total_ht; //print "\nFinally : ".$update_total_tva; $updatefacprice = " UPDATE llx_facture SET buy_price_ht='".round($update_buy_price_ht,2)."' WHERE rowid ='".$facture['rowid']."' "; //print $updatefacprice; $resfacprice = $db->query($updatefacprice); $db->commit(); //print "\nHEAD DATA HAS BEEN UPDATED."; //print $current_counter." - ".($total_lines-1) ; if($current_counter == ($total_lines-1)) { print "reload"; } } else { //no lines found. } //update facture's total total_ttc and tva <variables //update facture's multicurrency_total_ht multicurrency_total_ttc and multicurrency_tva <variables } else { //facture not found. } } else { print "failed to update the data because rowid of detail facture not found."; } ?>