From 4624f1b1b84d036b6eac7ca9e747217affef2555 Mon Sep 17 00:00:00 2001 From: atm-greg Date: Wed, 6 Feb 2019 17:19:16 +0100 Subject: [PATCH 001/181] FIX positive values creating diff on addline rounding --- htdocs/fourn/class/fournisseur.facture.class.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/htdocs/fourn/class/fournisseur.facture.class.php b/htdocs/fourn/class/fournisseur.facture.class.php index 086f154184d..a006b5391b1 100644 --- a/htdocs/fourn/class/fournisseur.facture.class.php +++ b/htdocs/fourn/class/fournisseur.facture.class.php @@ -1665,9 +1665,9 @@ class FactureFournisseur extends CommonInvoice $this->line->rang=$rang; $this->line->info_bits=$info_bits; $this->line->total_ht= (($this->type==self::TYPE_CREDIT_NOTE||$qty<0)?-abs($total_ht):$total_ht); // For credit note and if qty is negative, total is negative - $this->line->total_tva= $total_tva; - $this->line->total_localtax1=$total_localtax1; - $this->line->total_localtax2=$total_localtax2; + $this->line->total_tva= (($this->type==self::TYPE_CREDIT_NOTE||$qty<0)?-abs($total_tva):$total_tva); + $this->line->total_localtax1=(($this->type==self::TYPE_CREDIT_NOTE||$qty<0)?-abs($total_localtax1):$total_localtax1); + $this->line->total_localtax2=(($this->type==self::TYPE_CREDIT_NOTE||$qty<0)?-abs($total_localtax2):$total_localtax2); $this->line->total_ttc= (($this->type==self::TYPE_CREDIT_NOTE||$qty<0)?-abs($total_ttc):$total_ttc); $this->line->special_code=$this->special_code; $this->line->fk_parent_line=$this->fk_parent_line; @@ -1837,11 +1837,11 @@ class FactureFournisseur extends CommonInvoice $line->localtax2_tx = $txlocaltax2; $line->localtax1_type = $localtaxes_type[0]; $line->localtax2_type = $localtaxes_type[2]; - $line->total_ht = $total_ht; - $line->total_tva = $total_tva; + $line->total_ht = (($this->type==self::TYPE_CREDIT_NOTE||$qty<0)?-abs($total_ht):$total_ht); + $line->total_tva = (($this->type==self::TYPE_CREDIT_NOTE||$qty<0)?-abs($total_tva):$total_tva); $line->total_localtax1 = $total_localtax1; $line->total_localtax2 = $total_localtax2; - $line->total_ttc = $total_ttc; + $line->total_ttc = (($this->type==self::TYPE_CREDIT_NOTE||$qty<0)?-abs($total_ttc):$total_ttc); $line->fk_product = $idproduct; $line->product_type = $product_type; $line->info_bits = $info_bits; From 288a876491ec67529bc0166ba266ec345fa18234 Mon Sep 17 00:00:00 2001 From: Dan Rusu Date: Mon, 11 Feb 2019 09:14:06 +0200 Subject: [PATCH 002/181] add API method to create credit note from invoice --- .../facture/class/api_invoices.class.php | 112 ++++++++++++++++++ 1 file changed, 112 insertions(+) diff --git a/htdocs/compta/facture/class/api_invoices.class.php b/htdocs/compta/facture/class/api_invoices.class.php index 555b6179677..0fb203f50d1 100644 --- a/htdocs/compta/facture/class/api_invoices.class.php +++ b/htdocs/compta/facture/class/api_invoices.class.php @@ -839,6 +839,118 @@ class Invoices extends DolibarrApi return $this->_cleanObjectDatas($this->invoice); } + /** + * Make credt note from invoice + * + * @param int $id Invoice ID + * @url POST {id}/makecreditnote + * + * @return array An invoice object + * + * @throws 200 + * @throws 304 + * @throws 401 + * @throws 404 + * @throws 500 + */ + function makecreditnote($id) + { + if(! DolibarrApiAccess::$user->rights->facture->creer) { + throw new RestException(401); + } + + $this->db->begin(); + + $result = $this->invoice->fetch($id); + if( ! $result ) { + throw new RestException(404, 'Invoice not found'); + } + + if( ! DolibarrApi::_checkAccessToResource('facture',$this->invoice->id)) { + throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login); + } + + $result = $this->invoice->fetch_thirdparty(); + if( ! $result ) { + throw new RestException(404, 'Thirdparty not found'); + } + + if (! $object->paye) // protection against multiple submit + { + $this->invoice->fetch_lines(); + + // Boucle sur chaque taux de tva + $i=0; + foreach($this->invoice->lines as $line) + { + $amount_ht[$line->tva_tx]+=$line->total_ht; + $amount_tva[$line->tva_tx]+=$line->total_tva; + $amount_ttc[$line->tva_tx]+=$line->total_ttc; + $i++; + } + + // Insert one discount by VAT rate category + $discount = new DiscountAbsolute($this->db); + if ($this->invoice->type == 2) $discount->description='(CREDIT_NOTE)'; + elseif ($this->invoice->type == 3) $discount->description='(DEPOSIT)'; + else { + $this->error="CantConvertToReducAnInvoiceOfThisType"; + return -1; + } + $discount->tva_tx=abs($this->invoice->total_ttc); + $discount->fk_soc=$this->invoice->socid; + $discount->fk_facture_source=$this->invoice->id; + + $error=0; + foreach($amount_ht as $tva_tx => $xxx) + { + $discount->amount_ht=abs($amount_ht[$tva_tx]); + $discount->amount_tva=abs($amount_tva[$tva_tx]); + $discount->amount_ttc=abs($amount_ttc[$tva_tx]); + $discount->tva_tx=abs($tva_tx); + + $result=$discount->create(DolibarrApiAccess::$user); + if ($result < 0) + { + $error++; + break; + } + } + + if (! $error) + { + // Classe facture + $result=$this->invoice->set_paid(DolibarrApiAccess::$user); + if ($result > 0) + { + //$mesg='OK'.$discount->id; + $this->db->commit(); + } + else + { + throw new RestException(500, 'Could not set paid'); + $this->db->rollback(); + } + } + else + { + throw new RestException(500, 'Discount error'); + $this->db->rollback(); + } + } + + $result = $this->invoice->fetch($id); + if( ! $result ) { + throw new RestException(404, 'Invoice not found'); + } + + if( ! DolibarrApi::_checkAccessToResource('facture',$this->invoice->id)) { + throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login); + } + + return $this->_cleanObjectDatas($this->invoice); + } + /** * Add a discount line into an invoice (as an invoice line) using an existing absolute discount * From 0698ddbd7779a6eec7c546c470d63c8c65e6d1cc Mon Sep 17 00:00:00 2001 From: Dan Rusu Date: Mon, 11 Feb 2019 09:24:16 +0200 Subject: [PATCH 003/181] Revert "add API method to create credit note from invoice" This reverts commit 288a876491ec67529bc0166ba266ec345fa18234. --- .../facture/class/api_invoices.class.php | 112 ------------------ 1 file changed, 112 deletions(-) diff --git a/htdocs/compta/facture/class/api_invoices.class.php b/htdocs/compta/facture/class/api_invoices.class.php index 0fb203f50d1..555b6179677 100644 --- a/htdocs/compta/facture/class/api_invoices.class.php +++ b/htdocs/compta/facture/class/api_invoices.class.php @@ -839,118 +839,6 @@ class Invoices extends DolibarrApi return $this->_cleanObjectDatas($this->invoice); } - /** - * Make credt note from invoice - * - * @param int $id Invoice ID - * @url POST {id}/makecreditnote - * - * @return array An invoice object - * - * @throws 200 - * @throws 304 - * @throws 401 - * @throws 404 - * @throws 500 - */ - function makecreditnote($id) - { - if(! DolibarrApiAccess::$user->rights->facture->creer) { - throw new RestException(401); - } - - $this->db->begin(); - - $result = $this->invoice->fetch($id); - if( ! $result ) { - throw new RestException(404, 'Invoice not found'); - } - - if( ! DolibarrApi::_checkAccessToResource('facture',$this->invoice->id)) { - throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login); - } - - $result = $this->invoice->fetch_thirdparty(); - if( ! $result ) { - throw new RestException(404, 'Thirdparty not found'); - } - - if (! $object->paye) // protection against multiple submit - { - $this->invoice->fetch_lines(); - - // Boucle sur chaque taux de tva - $i=0; - foreach($this->invoice->lines as $line) - { - $amount_ht[$line->tva_tx]+=$line->total_ht; - $amount_tva[$line->tva_tx]+=$line->total_tva; - $amount_ttc[$line->tva_tx]+=$line->total_ttc; - $i++; - } - - // Insert one discount by VAT rate category - $discount = new DiscountAbsolute($this->db); - if ($this->invoice->type == 2) $discount->description='(CREDIT_NOTE)'; - elseif ($this->invoice->type == 3) $discount->description='(DEPOSIT)'; - else { - $this->error="CantConvertToReducAnInvoiceOfThisType"; - return -1; - } - $discount->tva_tx=abs($this->invoice->total_ttc); - $discount->fk_soc=$this->invoice->socid; - $discount->fk_facture_source=$this->invoice->id; - - $error=0; - foreach($amount_ht as $tva_tx => $xxx) - { - $discount->amount_ht=abs($amount_ht[$tva_tx]); - $discount->amount_tva=abs($amount_tva[$tva_tx]); - $discount->amount_ttc=abs($amount_ttc[$tva_tx]); - $discount->tva_tx=abs($tva_tx); - - $result=$discount->create(DolibarrApiAccess::$user); - if ($result < 0) - { - $error++; - break; - } - } - - if (! $error) - { - // Classe facture - $result=$this->invoice->set_paid(DolibarrApiAccess::$user); - if ($result > 0) - { - //$mesg='OK'.$discount->id; - $this->db->commit(); - } - else - { - throw new RestException(500, 'Could not set paid'); - $this->db->rollback(); - } - } - else - { - throw new RestException(500, 'Discount error'); - $this->db->rollback(); - } - } - - $result = $this->invoice->fetch($id); - if( ! $result ) { - throw new RestException(404, 'Invoice not found'); - } - - if( ! DolibarrApi::_checkAccessToResource('facture',$this->invoice->id)) { - throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login); - } - - return $this->_cleanObjectDatas($this->invoice); - } - /** * Add a discount line into an invoice (as an invoice line) using an existing absolute discount * From 9ce4b91f5d17e07617abe5c818f7b49289b39fa2 Mon Sep 17 00:00:00 2001 From: Dan Rusu Date: Mon, 11 Feb 2019 09:31:43 +0200 Subject: [PATCH 004/181] NEW | make credit note from invoice inspired from the action of the button "Make credit note" from UI. - load invoice data and lines - check invoice type - calculate totals and create new credit notes - create DiscountAbsolute & commit changes --- .../facture/class/api_invoices.class.php | 112 ++++++++++++++++++ 1 file changed, 112 insertions(+) diff --git a/htdocs/compta/facture/class/api_invoices.class.php b/htdocs/compta/facture/class/api_invoices.class.php index 555b6179677..dede6f735c6 100644 --- a/htdocs/compta/facture/class/api_invoices.class.php +++ b/htdocs/compta/facture/class/api_invoices.class.php @@ -839,6 +839,118 @@ class Invoices extends DolibarrApi return $this->_cleanObjectDatas($this->invoice); } + /** + * Make credt note from invoice + * + * @param int $id Invoice ID + * @url POST {id}/makecreditnote + * + * @return array An invoice object + * + * @throws 200 + * @throws 304 + * @throws 401 + * @throws 404 + * @throws 500 + */ + function makecreditnote($id) + { + if(! DolibarrApiAccess::$user->rights->facture->creer) { + throw new RestException(401); + } + + $this->db->begin(); + + $result = $this->invoice->fetch($id); + if( ! $result ) { + throw new RestException(404, 'Invoice not found'); + } + + if( ! DolibarrApi::_checkAccessToResource('facture',$this->invoice->id)) { + throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login); + } + + $result = $this->invoice->fetch_thirdparty(); + if( ! $result ) { + throw new RestException(404, 'Thirdparty not found'); + } + + if (! $object->paye) // protection against multiple submit + { + $this->invoice->fetch_lines(); + + // Boucle sur chaque taux de tva + $i=0; + foreach($this->invoice->lines as $line) + { + $amount_ht[$line->tva_tx]+=$line->total_ht; + $amount_tva[$line->tva_tx]+=$line->total_tva; + $amount_ttc[$line->tva_tx]+=$line->total_ttc; + $i++; + } + + // Insert one discount by VAT rate category + $discount = new DiscountAbsolute($this->db); + if ($this->invoice->type == 2) $discount->description='(CREDIT_NOTE)'; + elseif ($this->invoice->type == 3) $discount->description='(DEPOSIT)'; + else { + $this->error="CantConvertToReducAnInvoiceOfThisType"; + return -1; + } + $discount->tva_tx=abs($this->invoice->total_ttc); + $discount->fk_soc=$this->invoice->socid; + $discount->fk_facture_source=$this->invoice->id; + + $error=0; + foreach($amount_ht as $tva_tx => $xxx) + { + $discount->amount_ht=abs($amount_ht[$tva_tx]); + $discount->amount_tva=abs($amount_tva[$tva_tx]); + $discount->amount_ttc=abs($amount_ttc[$tva_tx]); + $discount->tva_tx=abs($tva_tx); + + $result=$discount->create(DolibarrApiAccess::$user); + if ($result < 0) + { + $error++; + break; + } + } + + if (! $error) + { + // Classe facture + $result=$this->invoice->set_paid(DolibarrApiAccess::$user); + if ($result > 0) + { + //$mesg='OK'.$discount->id; + $this->db->commit(); + } + else + { + throw new RestException(500, 'Could not set paid'); + $this->db->rollback(); + } + } + else + { + throw new RestException(500, 'Discount error'); + $this->db->rollback(); + } + } + + $result = $this->invoice->fetch($id); + if( ! $result ) { + throw new RestException(404, 'Invoice not found'); + } + + if( ! DolibarrApi::_checkAccessToResource('facture',$this->invoice->id)) { + throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login); + } + + return $this->_cleanObjectDatas($this->invoice); + } + /** * Add a discount line into an invoice (as an invoice line) using an existing absolute discount * From 57e2971a22ad350b96e2a1bc8f303d909e9d7d41 Mon Sep 17 00:00:00 2001 From: Dan Rusu Date: Mon, 11 Feb 2019 19:58:01 +0200 Subject: [PATCH 005/181] fix code indent --- htdocs/compta/facture/class/api_invoices.class.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/compta/facture/class/api_invoices.class.php b/htdocs/compta/facture/class/api_invoices.class.php index dede6f735c6..8fbfa34bce9 100644 --- a/htdocs/compta/facture/class/api_invoices.class.php +++ b/htdocs/compta/facture/class/api_invoices.class.php @@ -866,7 +866,7 @@ class Invoices extends DolibarrApi throw new RestException(404, 'Invoice not found'); } - if( ! DolibarrApi::_checkAccessToResource('facture',$this->invoice->id)) { + if( ! DolibarrApi::_checkAccessToResource('facture', $this->invoice->id)) { throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login); } @@ -944,7 +944,7 @@ class Invoices extends DolibarrApi throw new RestException(404, 'Invoice not found'); } - if( ! DolibarrApi::_checkAccessToResource('facture',$this->invoice->id)) { + if( ! DolibarrApi::_checkAccessToResource('facture', $this->invoice->id)) { throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login); } From 45d05da6ed7d563b44c8b0e77c3e2d5c5a918d6a Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Thu, 14 Feb 2019 16:14:19 +0100 Subject: [PATCH 006/181] FIX missing $ismultientitymanaged for previous/next ref --- htdocs/product/stock/class/entrepot.class.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/htdocs/product/stock/class/entrepot.class.php b/htdocs/product/stock/class/entrepot.class.php index add121b902e..850c652c59f 100644 --- a/htdocs/product/stock/class/entrepot.class.php +++ b/htdocs/product/stock/class/entrepot.class.php @@ -36,6 +36,7 @@ class Entrepot extends CommonObject public $element='stock'; public $table_element='entrepot'; public $picto='stock'; + public $ismultientitymanaged = 1; // 0=No test on entity, 1=Test with field entity, 2=Test with link by societe /** * Warehouse closed, inactive @@ -716,7 +717,7 @@ class Entrepot extends CommonObject return $TChildWarehouses; } - + /** * Create object on disk * From 69f350eb0e0d6f066f81fb356541fcd852ebb216 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Thu, 14 Feb 2019 16:33:38 +0100 Subject: [PATCH 007/181] update with html5 compliant code --- htdocs/compta/tva/index.php | 56 ++++++++++++++++++------------------- 1 file changed, 28 insertions(+), 28 deletions(-) diff --git a/htdocs/compta/tva/index.php b/htdocs/compta/tva/index.php index e307a86ade9..f0c96dccdd6 100644 --- a/htdocs/compta/tva/index.php +++ b/htdocs/compta/tva/index.php @@ -101,8 +101,8 @@ function pt($db, $sql, $date) print ''; print ''.$date.''; - print ''.$langs->trans("ClaimedForThisPeriod").''; - print ''.$langs->trans("PaidDuringThisPeriod").''; + print ''.$langs->trans("ClaimedForThisPeriod").''; + print ''.$langs->trans("PaidDuringThisPeriod").''; print "\n"; $totalclaimed = 0; @@ -122,8 +122,8 @@ function pt($db, $sql, $date) { print ''; print ''.$previousmonth."\n"; - print ''.price($amountclaimed)."\n"; - print ''.price($amountpaid)."\n"; + print ''.price($amountclaimed)."\n"; + print ''.price($amountpaid)."\n"; print "\n"; $amountclaimed = 0; @@ -145,8 +145,8 @@ function pt($db, $sql, $date) { print ''; print ''.$obj->dm."\n"; - print ''.price($amountclaimed)."\n"; - print ''.price($amountpaid)."\n"; + print ''.price($amountclaimed)."\n"; + print ''.price($amountpaid)."\n"; print "\n"; $amountclaimed = 0; $amountpaid = 0; @@ -166,8 +166,8 @@ function pt($db, $sql, $date) { print ''; print ''.$previousmonth."\n"; - print ''.price($amountclaimed)."\n"; - print ''.price($amountpaid)."\n"; + print ''.price($amountclaimed)."\n"; + print ''.price($amountpaid)."\n"; print "\n"; $amountclaimed = 0; @@ -175,9 +175,9 @@ function pt($db, $sql, $date) } print ''; - print ''.$langs->trans("Total").''; - print ''.price($totalclaimed).''; - print ''.price($totalpaid).''; + print ''.$langs->trans("Total").''; + print ''.price($totalclaimed).''; + print ''.price($totalpaid).''; print ""; print ""; @@ -242,9 +242,9 @@ print load_fiche_titre($langs->trans("VATSummary"), '', ''); print ''; print ''; print ''; -print ''; -print ''; -print ''; +print ''; +print ''; +print ''; print ''."\n"; print ''."\n"; @@ -444,7 +444,7 @@ while ((($y < $yend) || ($y == $yend && $m <= $mend)) && $mcursor < 1000) // $mc $x_coll_sum += $temp_vat; } } - print ""; + print ''; $x_paye_sum = 0; foreach (array_keys($x_paye) as $rate) @@ -488,7 +488,7 @@ while ((($y < $yend) || ($y == $yend && $m <= $mend)) && $mcursor < 1000) // $mc $x_paye_sum += $temp_vat; } } - print ""; + print ''; $subtotalcoll = $subtotalcoll + $x_coll_sum; $subtotalpaye = $subtotalpaye + $x_paye_sum; @@ -497,7 +497,7 @@ while ((($y < $yend) || ($y == $yend && $m <= $mend)) && $mcursor < 1000) // $mc $total = $total + $diff; $subtotal = price2num($subtotal + $diff, 'MT'); - print "\n"; + print ''."\n"; print "\n"; print "\n"; @@ -505,16 +505,16 @@ while ((($y < $yend) || ($y == $yend && $m <= $mend)) && $mcursor < 1000) // $mc if ($i > 2) { print ''; - print ''; - print ''; - print ''; - print ''; + print ''; + print ''; + print ''; + print ''; print ''; $i = 0; $subtotalcoll=0; $subtotalpaye=0; $subtotal=0; } } -print ''; +print ''; print "\n"; print ''; @@ -575,19 +575,19 @@ if (! empty($conf->global->MAIN_FEATURES_LEVEL)) print '
'.$langs->trans("Year")." ".$y.''.$langs->trans("VATToPay").''.$langs->trans("VATToCollect").''.$langs->trans("Balance").''.$langs->trans("VATToPay").''.$langs->trans("VATToCollect").''.$langs->trans("Balance").' 
".price(price2num($x_coll_sum, 'MT'))."'.price(price2num($x_coll_sum, 'MT')).'".price(price2num($x_paye_sum, 'MT'))."'.price(price2num($x_paye_sum, 'MT')).'".price(price2num($diff, 'MT'))."'.price(price2num($diff, 'MT')).' 
'.$langs->trans("SubTotal").':'.price(price2num($subtotalcoll, 'MT')).''.price(price2num($subtotalpaye, 'MT')).''.price(price2num($subtotal, 'MT')).''.$langs->trans("SubTotal").':'.price(price2num($subtotalcoll, 'MT')).''.price(price2num($subtotalpaye, 'MT')).''.price(price2num($subtotal, 'MT')).' 
'.$langs->trans("TotalToPay").':'.price(price2num($total, 'MT')).'
'.$langs->trans("TotalToPay").':'.price(price2num($total, 'MT')).' 
'; print ""; - print ''; - print ''; + print ''; + print ''; print "\n"; print ""; - print ''; - print '\n"; + print ''; + print '\n"; print "\n"; $restopay = $total - $obj->mm; print ""; - print ''; - print ''; + print ''; + print ''; print "\n"; print '
' . $langs->trans("VATDue") . '' . price(price2num($total, 'MT')) . '' . $langs->trans("VATDue") . '' . price(price2num($total, 'MT')) . '
' . $langs->trans("VATPaid") . '' . price(price2num($obj->mm, 'MT')) . "' . $langs->trans("VATPaid") . '' . price(price2num($obj->mm, 'MT')) . "
' . $langs->trans("RemainToPay") . '' . price(price2num($restopay, 'MT')) . '' . $langs->trans("RemainToPay") . '' . price(price2num($restopay, 'MT')) . '
'; From 1f2dd3bc29348bcccb62145723842e44044c2f98 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Thu, 14 Feb 2019 16:38:03 +0100 Subject: [PATCH 008/181] update with html5 compliant code --- htdocs/compta/tva/list.php | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/htdocs/compta/tva/list.php b/htdocs/compta/tva/list.php index d3ec5e53f71..dcac389b988 100644 --- a/htdocs/compta/tva/list.php +++ b/htdocs/compta/tva/list.php @@ -188,8 +188,8 @@ if ($result) $form->select_comptes($search_account, 'search_account', 0, '', 1); print ''; } - print ''; - print ''; + print ''; + print ''; $searchpicto=$form->showFilterAndCheckAddButtons(0); print $searchpicto; print ''; @@ -202,7 +202,7 @@ if ($result) print_liste_field_titre("DatePayment", $_SERVER["PHP_SELF"], "t.datep", "", $param, 'align="center"', $sortfield, $sortorder); print_liste_field_titre("Type", $_SERVER["PHP_SELF"], "type", "", $param, 'align="left"', $sortfield, $sortorder); if (! empty($conf->banque->enabled)) print_liste_field_titre("Account", $_SERVER["PHP_SELF"], "ba.label", "", $param, "", $sortfield, $sortorder); - print_liste_field_titre("PayedByThisPayment", $_SERVER["PHP_SELF"], "t.amount", "", $param, 'align="right"', $sortfield, $sortorder); + print_liste_field_titre("PayedByThisPayment", $_SERVER["PHP_SELF"], "t.amount", "", $param, 'class="right"', $sortfield, $sortorder); print_liste_field_titre('', $_SERVER["PHP_SELF"], "", '', '', '', $sortfield, $sortorder, 'maxwidthsearch '); print "\n"; @@ -265,7 +265,7 @@ if ($result) $colspan=5; if (! empty($conf->banque->enabled)) $colspan++; print ''.$langs->trans("Total").''; - print ''.price($total).''; + print ''.price($total).''; print " "; print ""; @@ -280,7 +280,6 @@ else dol_print_error($db); } - +// End of page llxFooter(); - $db->close(); From ed1a59d00bac40174b35e36fc138f9006c7b8417 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Thu, 14 Feb 2019 16:43:40 +0100 Subject: [PATCH 009/181] update with html5 compliant code --- htdocs/compta/tva/quadri_detail.php | 78 ++++++++++++++--------------- 1 file changed, 39 insertions(+), 39 deletions(-) diff --git a/htdocs/compta/tva/quadri_detail.php b/htdocs/compta/tva/quadri_detail.php index f749df2b548..8b58bde4199 100644 --- a/htdocs/compta/tva/quadri_detail.php +++ b/htdocs/compta/tva/quadri_detail.php @@ -344,11 +344,11 @@ if (! is_array($x_coll) || ! is_array($x_paye)) print ''.$productcust.''; if ($modetax != 1) { - print ''.$amountcust.''; - print ''.$langs->trans("Payment").' ('.$langs->trans("PercentOfInvoice").')'; + print ''.$amountcust.''; + print ''.$langs->trans("Payment").' ('.$langs->trans("PercentOfInvoice").')'; } - print ''.$langs->trans("AmountHTVATRealReceived").''; - print ''.$vatcust.''; + print ''.$langs->trans("AmountHTVATRealReceived").''; + print ''.$vatcust.''; print ''; $action = "tvadetail"; @@ -390,7 +390,7 @@ if (! is_array($x_coll) || ! is_array($x_paye)) print ''; // Ref - print ''.$fields['link'].''; + print ''.$fields['link'].''; // Invoice date print '' . dol_print_date($fields['datef'], 'day') . ''; @@ -440,7 +440,7 @@ if (! is_array($x_coll) || ! is_array($x_paye)) // Total HT if ($modetax != 1) { - print ''; + print ''; print price($fields['totalht']); if (price2num($fields['ftotal_ttc'])) { @@ -455,7 +455,7 @@ if (! is_array($x_coll) || ! is_array($x_paye)) $ratiopaymentinvoice=1; if ($modetax != 1) { - print ''; + print ''; //print $fields['totalht']."-".$fields['payment_amount']."-".$fields['ftotal_ttc']; if ($fields['payment_amount'] && $fields['ftotal_ttc']) { @@ -479,13 +479,13 @@ if (! is_array($x_coll) || ! is_array($x_paye)) } // Total collected - print ''; + print ''; $temp_ht=$fields['totalht']*$ratiopaymentinvoice; print price(price2num($temp_ht, 'MT'), 1); print ''; // VAT - print ''; + print ''; $temp_vat=$fields['vat']*$ratiopaymentinvoice; print price(price2num($temp_vat, 'MT'), 1); //print price($fields['vat']); @@ -500,13 +500,13 @@ if (! is_array($x_coll) || ! is_array($x_paye)) // Total customers for this vat rate print ''; print ''; - print ''.$langs->trans("Total").':'; + print ''.$langs->trans("Total").':'; if ($modetax != 1) { - print ' '; - print ' '; + print ' '; + print ' '; } - print ''.price(price2num($subtot_coll_total_ht, 'MT')).''; - print ''.price(price2num($subtot_coll_vat, 'MT')).''; + print ''.price(price2num($subtot_coll_total_ht, 'MT')).''; + print ''.price(price2num($subtot_coll_vat, 'MT')).''; print ''; } @@ -514,13 +514,13 @@ if (! is_array($x_coll) || ! is_array($x_paye)) { print ''; print ''; - print ''.$langs->trans("Total").':'; + print ''.$langs->trans("Total").':'; if ($modetax != 1) { - print ' '; - print ' '; + print ' '; + print ' '; } - print ''.price(price2num(0, 'MT')).''; - print ''.price(price2num(0, 'MT')).''; + print ''.price(price2num(0, 'MT')).''; + print ''.price(price2num(0, 'MT')).''; print ''; } @@ -536,11 +536,11 @@ if (! is_array($x_coll) || ! is_array($x_paye)) print ''.$namesup.''; print ''.$productsup.''; if ($modetax != 1) { - print ''.$amountsup.''; - print ''.$langs->trans("Payment").' ('.$langs->trans("PercentOfInvoice").')'; + print ''.$amountsup.''; + print ''.$langs->trans("Payment").' ('.$langs->trans("PercentOfInvoice").')'; } - print ''.$langs->trans("AmountHTVATRealPaid").''; - print ''.$vatsup.''; + print ''.$langs->trans("AmountHTVATRealPaid").''; + print ''.$vatsup.''; print ''."\n"; foreach (array_keys($x_paye) as $rate) @@ -571,7 +571,7 @@ if (! is_array($x_coll) || ! is_array($x_paye)) print ''; // Ref - print ''.$fields['link'].''; + print ''.$fields['link'].''; // Invoice date print '' . dol_print_date($fields['datef'], 'day') . ''; @@ -621,7 +621,7 @@ if (! is_array($x_coll) || ! is_array($x_paye)) // Total HT if ($modetax != 1) { - print ''; + print ''; print price($fields['totalht']); if (price2num($fields['ftotal_ttc'])) { @@ -636,7 +636,7 @@ if (! is_array($x_coll) || ! is_array($x_paye)) $ratiopaymentinvoice=1; if ($modetax != 1) { - print ''; + print ''; if ($fields['payment_amount'] && $fields['ftotal_ttc']) { $paymentfourn_static->id=$fields['payment_id']; @@ -662,13 +662,13 @@ if (! is_array($x_coll) || ! is_array($x_paye)) } // VAT paid - print ''; + print ''; $temp_ht=$fields['totalht']*$ratiopaymentinvoice; print price(price2num($temp_ht, 'MT'), 1); print ''; // VAT - print ''; + print ''; $temp_vat=$fields['vat']*$ratiopaymentinvoice; print price(price2num($temp_vat, 'MT'), 1); //print price($fields['vat']); @@ -683,26 +683,26 @@ if (! is_array($x_coll) || ! is_array($x_paye)) // Total suppliers for this vat rate print ''; print ''; - print ''.$langs->trans("Total").':'; + print ''.$langs->trans("Total").':'; if ($modetax != 1) { - print ' '; - print ' '; + print ' '; + print ' '; } - print ''.price(price2num($subtot_paye_total_ht, 'MT')).''; - print ''.price(price2num($subtot_paye_vat, 'MT')).''; + print ''.price(price2num($subtot_paye_total_ht, 'MT')).''; + print ''.price(price2num($subtot_paye_vat, 'MT')).''; print ''; } if (count($x_paye) == 0) { // Show a total line if nothing shown print ''; print ''; - print ''.$langs->trans("Total").':'; + print ''.$langs->trans("Total").':'; if ($modetax != 1) { - print ' '; - print ' '; + print ' '; + print ' '; } - print ''.price(price2num(0, 'MT')).''; - print ''.price(price2num(0, 'MT')).''; + print ''.price(price2num(0, 'MT')).''; + print ''.price(price2num(0, 'MT')).''; print ''; } @@ -714,7 +714,7 @@ if (! is_array($x_coll) || ! is_array($x_paye)) $diff = $x_coll_sum - $x_paye_sum; print ''; print ''.$langs->trans("TotalToPay").($q?', '.$langs->trans("Quadri").' '.$q:'').''; - print ''.price(price2num($diff, 'MT'))."\n"; + print ''.price(price2num($diff, 'MT'))."\n"; print "\n"; $i++; From 2507ff9684eb3ad6c7b31b0d78987c3933fb4d13 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Thu, 14 Feb 2019 16:45:49 +0100 Subject: [PATCH 010/181] update with html5 compliant code --- htdocs/compta/clients.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/htdocs/compta/clients.php b/htdocs/compta/clients.php index 06e818db0a3..6e9d1acc174 100644 --- a/htdocs/compta/clients.php +++ b/htdocs/compta/clients.php @@ -148,26 +148,26 @@ if ($resql) print_liste_field_titre("Town", $_SERVER["PHP_SELF"], "s.town", "", "", 'valign="center"', $sortfield, $sortorder); print_liste_field_titre("CustomerCode", $_SERVER["PHP_SELF"], "s.code_client", "", "", 'align="left"', $sortfield, $sortorder); print_liste_field_titre("AccountancyCode", $_SERVER["PHP_SELF"], "s.code_compta", "", "", 'align="left"', $sortfield, $sortorder); - print_liste_field_titre("DateCreation", $_SERVER["PHP_SELF"], "datec", $addu, "", 'align="right"', $sortfield, $sortorder); + print_liste_field_titre("DateCreation", $_SERVER["PHP_SELF"], "datec", $addu, "", 'class="right"', $sortfield, $sortorder); print "\n"; // Lignes des champs de filtre print ''; - print ''; + print ''; print ''; print ' '; - print ''; + print ''; print ''; print ''; - print ''; + print ''; print ''; print ''; - print ''; + print ''; print ''; print ''; print "\n"; @@ -186,7 +186,7 @@ if ($resql) print ''.$obj->town.' '; print ''.$obj->code_client.' '; print ''.$obj->code_compta.' '; - print ''.dol_print_date($db->jdate($obj->datec)).''; + print ''.dol_print_date($db->jdate($obj->datec)).''; print "\n"; $i++; } From 91fca7a1af6c2380c720d33848908d120b181ded Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Thu, 14 Feb 2019 16:48:10 +0100 Subject: [PATCH 011/181] update with html5 compliant code --- htdocs/compta/compta-files.php | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/htdocs/compta/compta-files.php b/htdocs/compta/compta-files.php index 7bfd7565ab5..e91fa1ffac5 100644 --- a/htdocs/compta/compta-files.php +++ b/htdocs/compta/compta-files.php @@ -374,9 +374,9 @@ if (!empty($date_start) && !empty($date_stop)) print ''.$langs->trans("Ref").''; print ''.$langs->trans("Link").''; print ''.$langs->trans("Paid").''; - print ''.$langs->trans("Debit").''; - print ''.$langs->trans("Credit").''; - print ''.$langs->trans("Balance").''; + print ''.$langs->trans("Debit").''; + print ''.$langs->trans("Credit").''; + print ''.$langs->trans("Balance").''; print ''; if ($result) { @@ -421,21 +421,21 @@ if (!empty($date_start) && !empty($date_stop)) // File link print '".$data['name']."\n"; - print ''.$data['paid'].''; - print ''.(($data['amount'] > 0) ? price(abs($data['amount'])) : '')."\n"; + print ''.$data['paid'].''; + print ''.(($data['amount'] > 0) ? price(abs($data['amount'])) : '')."\n"; $totalDebit += ($data['amount'] > 0) ? abs($data['amount']) : 0; - print ''.(($data['amount'] > 0) ? '' : price(abs($data['amount'])))."\n"; + print ''.(($data['amount'] > 0) ? '' : price(abs($data['amount'])))."\n"; $totalCredit += ($data['amount'] > 0) ? 0 : abs($data['amount']); // Balance - print ''.price($data['balance'])."\n"; + print ''.price($data['balance'])."\n"; print "\n"; } print ''; print ' '; - print ''.price($totalDebit).''; - print ''.price($totalCredit).''; - print ''.price(price2num($totalDebit - $totalCredit, 'MT')).''; + print ''.price($totalDebit).''; + print ''.price($totalCredit).''; + print ''.price(price2num($totalDebit - $totalCredit, 'MT')).''; print "\n"; } } From 5b2c80b62d50981663ce98845d486ebdc2845111 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Thu, 14 Feb 2019 16:51:09 +0100 Subject: [PATCH 012/181] update with html5 compliant code --- htdocs/compta/index.php | 124 ++++++++++++++++++++-------------------- 1 file changed, 62 insertions(+), 62 deletions(-) diff --git a/htdocs/compta/index.php b/htdocs/compta/index.php index bac1b724504..c872fae3def 100644 --- a/htdocs/compta/index.php +++ b/htdocs/compta/index.php @@ -200,14 +200,14 @@ if (! empty($conf->facture->enabled) && $user->rights->facture->lire) print ''; print $companystatic->getNomUrl(1, 'customer', 16); print ''; - print ''.price($obj->total_ttc).''; + print ''.price($obj->total_ttc).''; print ''; $tot_ttc+=$obj->total_ttc; $i++; } print ''.$langs->trans("Total").''; - print ''.price($tot_ttc).''; + print ''.price($tot_ttc).''; print ''; } else @@ -287,14 +287,14 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->facture- print ''; print $companystatic->getNomUrl(1, 'supplier', 16); print ''; - print ''.price($obj->total_ttc).''; + print ''.price($obj->total_ttc).''; print ''; $tot_ttc+=$obj->total_ttc; $i++; } print ''.$langs->trans("Total").''; - print ''.price($tot_ttc).''; + print ''.price($tot_ttc).''; print ''; } else @@ -353,9 +353,9 @@ if (! empty($conf->facture->enabled) && $user->rights->facture->lire) print ''; print ''; - if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; - print ''; - print ''; + if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; + print ''; + print ''; print ''; print ''; if ($num) @@ -398,7 +398,7 @@ if (! empty($conf->facture->enabled) && $user->rights->facture->lire) print img_warning($langs->trans("Late")); } print ''; - print ''; - if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; - print ''; - print ''; + if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; + print ''; + print ''; print ''; print ''; @@ -474,9 +474,9 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->facture- print '
'.$langs->trans("BoxTitleLastCustomerBills", $max).''.$langs->trans("AmountHT").''.$langs->trans("AmountTTC").''.$langs->trans("DateModificationShort").''.$langs->trans("AmountHT").''.$langs->trans("AmountTTC").''.$langs->trans("DateModificationShort").' 
'; + print ''; $filename=dol_sanitizeFileName($obj->ref); $filedir=$conf->facture->dir_output . '/' . dol_sanitizeFileName($obj->ref); $urlsource=$_SERVER['PHP_SELF'].'?facid='.$obj->rowid; @@ -409,9 +409,9 @@ if (! empty($conf->facture->enabled) && $user->rights->facture->lire) print ''; print $thirdpartystatic->getNomUrl(1, 'customer', 44); print ''.price($obj->total_ht).''.price($obj->total_ttc).''.dol_print_date($db->jdate($obj->tms), 'day').''.price($obj->total_ht).''.price($obj->total_ttc).''.dol_print_date($db->jdate($obj->tms), 'day').''.$facstatic->LibStatut($obj->paye, $obj->fk_statut, 3, $obj->am).'
'; print ''; - if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; - print ''; - print ''; + if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; + print ''; + print ''; print ''; print "\n"; if ($num) @@ -507,9 +507,9 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->facture- print ''; - if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; - print ''; - print ''; + if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; + print ''; + print ''; print ''; print ''; $total += $obj->total_ht; @@ -565,8 +565,8 @@ if (! empty($conf->don->enabled) && $user->rights->societe->lire) print ''; print ''; print ''; - print ''; - print ''; + print ''; + print ''; print ''; print ''; if ($num) @@ -588,8 +588,8 @@ if (! empty($conf->don->enabled) && $user->rights->societe->lire) print ''; print ''; print ''; - print ''; - print ''; + print ''; + print ''; print ''; print ''; @@ -638,8 +638,8 @@ if (! empty($conf->tax->enabled) && $user->rights->tax->charges->lire) print ''; print ''; print ''; - print ''; - print ''; + print ''; + print ''; print ''; print ''; if ($num) @@ -658,18 +658,18 @@ if (! empty($conf->tax->enabled) && $user->rights->tax->charges->lire) print ''; print ''; print ''; - print ''; - print ''; + print ''; + print ''; print ''; print ''; $tot_ttc+=$obj->amount; $i++; } - print ''; - print ''; - print ''; - print ''; + print ''; + print ''; + print ''; + print ''; print ''; } else @@ -729,9 +729,9 @@ if (! empty($conf->facture->enabled) && ! empty($conf->commande->enabled) && $us print '
'.$langs->trans("BoxTitleLastSupplierBills", $max).''.$langs->trans("AmountHT").''.$langs->trans("AmountTTC").''.$langs->trans("DateModificationShort").''.$langs->trans("AmountHT").''.$langs->trans("AmountTTC").''.$langs->trans("DateModificationShort").' 
'; print $thirdpartystatic->getNomUrl(1, 'supplier', 44); print ''.price($obj->total_ht).''.price($obj->total_ttc).''.dol_print_date($db->jdate($obj->tms), 'day').''.price($obj->total_ht).''.price($obj->total_ttc).''.dol_print_date($db->jdate($obj->tms), 'day').''.$facstatic->LibStatut($obj->paye, $obj->fk_statut, 3).'
'.$langs->trans("BoxTitleLastModifiedDonations", $max).''.$langs->trans("AmountTTC").''.$langs->trans("DateModificationShort").''.$langs->trans("AmountTTC").''.$langs->trans("DateModificationShort").' 
'.$donationstatic->getNomUrl(1).''.$label.''.price($objp->amount).''.dol_print_date($db->jdate($objp->dm), 'day').''.price($objp->amount).''.dol_print_date($db->jdate($objp->dm), 'day').''.$donationstatic->LibStatut($objp->fk_statut, 3).'
'.$langs->trans("ContributionsToPay").($num?' '.$num.'':'').''.$langs->trans("DateDue").''.$langs->trans("AmountTTC").''.$langs->trans("Paid").''.$langs->trans("AmountTTC").''.$langs->trans("Paid").' 
'.$chargestatic->getNomUrl(1).''.dol_print_date($db->jdate($obj->date_ech), 'day').''.price($obj->amount).''.price($obj->sumpaid).''.price($obj->amount).''.price($obj->sumpaid).''.$chargestatic->getLibStatut(3).'
'.$langs->trans("Total").''.price($tot_ttc).' 
'.$langs->trans("Total").''.price($tot_ttc).' 
'; print ""; print ''; - if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; - print ''; - print ''; + if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; + print ''; + print ''; print ''; print ''; @@ -765,7 +765,7 @@ if (! empty($conf->facture->enabled) && ! empty($conf->commande->enabled) && $us print ''; - print ''; - if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; - print ''; - print ''; + if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; + print ''; + print ''; print ''; print ''; $tot_ht += $obj->total_ht; @@ -790,9 +790,9 @@ if (! empty($conf->facture->enabled) && ! empty($conf->commande->enabled) && $us } print ''; - if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; - print ''; - print ''; + if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; + print ''; + print ''; print ''; print ''; print '
'.$langs->trans("OrdersDeliveredToBill").' '.$num.''.$langs->trans("AmountHT").''.$langs->trans("AmountTTC").''.$langs->trans("ToBill").''.$langs->trans("AmountHT").''.$langs->trans("AmountTTC").''.$langs->trans("ToBill").' 
'; print ' '; print ''; + print ''; $filename=dol_sanitizeFileName($obj->ref); $filedir=$conf->commande->dir_output . '/' . dol_sanitizeFileName($obj->ref); $urlsource=$_SERVER['PHP_SELF'].'?id='.$obj->rowid; @@ -777,9 +777,9 @@ if (! empty($conf->facture->enabled) && ! empty($conf->commande->enabled) && $us print ''; print $societestatic->getNomUrl(1, 'customer', 44); print ''.price($obj->total_ht).''.price($obj->total_ttc).''.price($obj->total_ttc-$obj->tot_fttc).''.price($obj->total_ht).''.price($obj->total_ttc).''.price($obj->total_ttc-$obj->tot_fttc).''.$commandestatic->LibStatut($obj->fk_statut, $obj->facture, 3).'
'.$langs->trans("Total").'   ('.$langs->trans("RemainderToBill").': '.price($tot_tobill).') '.price($tot_ht).''.price($tot_ttc).''.price($tot_tobill).''.price($tot_ht).''.price($tot_ttc).''.price($tot_tobill).' 

'; @@ -844,10 +844,10 @@ if (! empty($conf->facture->enabled) && $user->rights->facture->lire) print '
'; print ''; print ''; - print ''; - if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; - print ''; - print ''; + print ''; + if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; + print ''; + print ''; print ''; print ''; if ($num) @@ -890,7 +890,7 @@ if (! empty($conf->facture->enabled) && $user->rights->facture->lire) print img_warning($langs->trans("Late")); } print ''; - print ''; - print ''; - if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; - print ''; - print ''; + print ''; + if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; + print ''; + print ''; print ''; print ''; @@ -917,9 +917,9 @@ if (! empty($conf->facture->enabled) && $user->rights->facture->lire) print ''; print ''; - if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; - print ''; - print ''; + if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; + print ''; + print ''; print ''; print ''; } @@ -978,10 +978,10 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->facture- print '
'; print '
'.$langs->trans("BillsCustomersUnpaid", $num).' '.$num.''.$langs->trans("DateDue").''.$langs->trans("AmountHT").''.$langs->trans("AmountTTC").''.$langs->trans("Received").''.$langs->trans("DateDue").''.$langs->trans("AmountHT").''.$langs->trans("AmountTTC").''.$langs->trans("Received").' 
'; + print ''; $filename=dol_sanitizeFileName($obj->ref); $filedir=$conf->facture->dir_output . '/' . dol_sanitizeFileName($obj->ref); $urlsource=$_SERVER['PHP_SELF'].'?facid='.$obj->rowid; @@ -901,10 +901,10 @@ if (! empty($conf->facture->enabled) && $user->rights->facture->lire) print '' ; print $societestatic->getNomUrl(1, 'customer', 44); print ''.dol_print_date($db->jdate($obj->datelimite), 'day').''.price($obj->total_ht).''.price($obj->total_ttc).''.price($obj->am).''.dol_print_date($db->jdate($obj->datelimite), 'day').''.price($obj->total_ht).''.price($obj->total_ttc).''.price($obj->am).''.$facstatic->LibStatut($obj->paye, $obj->fk_statut, 3, $obj->am).'
'.$langs->trans("Total").'   ('.$langs->trans("RemainderToTake").': '.price($total_ttc-$totalam).')  '.price($total).''.price($total_ttc).''.price($totalam).''.price($total).''.price($total_ttc).''.price($totalam).' 
'; print ''; - print ''; - if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; - print ''; - print ''; + print ''; + if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; + print ''; + print ''; print ''; print "\n"; $societestatic = new Societe($db); @@ -1013,10 +1013,10 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->facture- print $facstatic->getNomUrl(1, ''); print ''; print ''; - print ''; - if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; - print ''; - print ''; + print ''; + if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; + print ''; + print ''; print ''; print ''; $total += $obj->total_ht; @@ -1027,9 +1027,9 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->facture- print ''; print ''; - if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; - print ''; - print ''; + if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print ''; + print ''; + print ''; print ''; print ''; } From a6cc8278c841b2c8396c38e261b5aae7259262f7 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Thu, 14 Feb 2019 16:54:53 +0100 Subject: [PATCH 013/181] update with html5 compliant code --- htdocs/compta/paiement_charge.php | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/htdocs/compta/paiement_charge.php b/htdocs/compta/paiement_charge.php index aa4cf649bf2..94bbc9b87b6 100644 --- a/htdocs/compta/paiement_charge.php +++ b/htdocs/compta/paiement_charge.php @@ -265,9 +265,9 @@ if ($action == 'create') print ''; //print ''; print ''; - print ''; - print ''; - print ''; + print ''; + print ''; + print ''; print ''; print "\n"; @@ -282,18 +282,18 @@ if ($action == 'create') if ($objp->date_ech > 0) { - print "\n"; + print '."\n"; } else { print "\n"; } - print '"; + print '"; - print '"; + print '"; - print '"; + print '"; print ''; - print ''; - print ""; - print ""; - print ""; + print ''; + print ''; + print ''; + print ''; print ''; print "\n"; } From 43486828dbd9c01e1a0bc98ba09449a35e81362a Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Thu, 14 Feb 2019 16:56:49 +0100 Subject: [PATCH 014/181] update with html5 compliant code --- htdocs/compta/paiement.php | 50 +++++++++++++++++++------------------- 1 file changed, 25 insertions(+), 25 deletions(-) diff --git a/htdocs/compta/paiement.php b/htdocs/compta/paiement.php index 887c1d9993e..f0caba60230 100644 --- a/htdocs/compta/paiement.php +++ b/htdocs/compta/paiement.php @@ -583,16 +583,16 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie print ''; if (!empty($conf->multicurrency->enabled)) { print ''; - print ''; - print ''; - print ''; - print ''; + print ''; + print ''; + print ''; + print ''; } - print ''; - print ''; - print ''; - print ''; - print ''; + print ''; + print ''; + print ''; + print ''; + print ''; print "\n"; $total=0; @@ -659,12 +659,12 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie // Multicurrency Price if (!empty($conf->multicurrency->enabled)) { - print ''; // Multicurrency Price - print ''; // Multicurrency Price - print ''; - print ''; + print ''; // Received or paid back - print ''; // Remain to take or to pay back - print ''; + print ''; //$test= price(price2num($objp->total_ttc - $paiement - $creditnotes - $deposits)); // Amount - print ''; - print ''; + print ''; if (!empty($conf->multicurrency->enabled)) { print ''; print ''; print ''; print ''; - print ''; + print ''; } - print ''; - print ''; + print ''; - print ''; - print ''; // Autofilled + print ''; + print ''; // Autofilled print ''; print "\n"; } @@ -873,7 +873,7 @@ if (! GETPOST('action', 'aZ09')) print_liste_field_titre('Invoice', $_SERVER["PHP_SELF"], 'ref', '', '', '', $sortfield, $sortorder); print_liste_field_titre('Date', $_SERVER["PHP_SELF"], 'dp', '', '', '', $sortfield, $sortorder); print_liste_field_titre('Type', $_SERVER["PHP_SELF"], 'libelle', '', '', '', $sortfield, $sortorder); - print_liste_field_titre('Amount', $_SERVER["PHP_SELF"], 'fa_amount', '', '', 'align="right"', $sortfield, $sortorder); + print_liste_field_titre('Amount', $_SERVER["PHP_SELF"], 'fa_amount', '', '', 'class="right"', $sortfield, $sortorder); print_liste_field_titre('', $_SERVER["PHP_SELF"], "", '', '', '', $sortfield, $sortorder, 'maxwidthsearch '); print "\n"; @@ -885,7 +885,7 @@ if (! GETPOST('action', 'aZ09')) print '\n"; print '\n"; print '\n"; - print ''; + print ''; $parameters=array(); $reshook=$hookmanager->executeHooks('printObjectLine', $parameters, $objp, $action); // Note that $action and $object may have been modified by hook From ec370e247a8213c79fa4504a007c30c261752073 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Thu, 14 Feb 2019 16:59:24 +0100 Subject: [PATCH 015/181] update with html5 compliant code --- htdocs/compta/recap-compta.php | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/htdocs/compta/recap-compta.php b/htdocs/compta/recap-compta.php index c8ba8806c36..f7b2ec89008 100644 --- a/htdocs/compta/recap-compta.php +++ b/htdocs/compta/recap-compta.php @@ -109,10 +109,10 @@ if ($id > 0) if (! empty($arrayfields['f.datef']['checked'])) print_liste_field_titre($arrayfields['f.datef']['label'], $_SERVER["PHP_SELF"], "f.datef", "", $param, 'align="center" class="nowrap"', $sortfield, $sortorder); print ''; print ''; - print ''; - print ''; - print ''; - print ''; + print ''; + print ''; + print ''; + print ''; print ''; $TData = array(); @@ -261,18 +261,18 @@ if ($id > 0) print ''; - print '\n"; + print '\n"; $totalDebit += ($data['amount'] > 0) ? abs($data['amount']) : 0; - print '\n"; + print '\n"; $totalCredit += ($data['amount'] > 0) ? 0 : abs($data['amount']); // Balance - print '\n"; + print '\n"; // Author - print ''; @@ -281,9 +281,9 @@ if ($id > 0) print ''; print ''; - print ''; - print ''; - print ''; + print ''; + print ''; + print ''; print ''; print "\n"; } From bd031bd29419770dea8b78841a8c6ad69d4a99d8 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Thu, 14 Feb 2019 17:02:17 +0100 Subject: [PATCH 016/181] update with html5 compliant code --- htdocs/contact/consumption.php | 36 +++++++++++++++++----------------- htdocs/contact/list.php | 2 +- 2 files changed, 19 insertions(+), 19 deletions(-) diff --git a/htdocs/contact/consumption.php b/htdocs/contact/consumption.php index ebbe7332236..d4f6f2cb9e5 100644 --- a/htdocs/contact/consumption.php +++ b/htdocs/contact/consumption.php @@ -372,7 +372,7 @@ if ($sql_select) // Filters print ''; - print ''; print ''; print ''; - print ''; print ''; print ''; - print ''; @@ -398,14 +398,14 @@ if ($sql_select) // Titles with sort buttons print ''; - print_liste_field_titre('Ref', $_SERVER['PHP_SELF'], 'doc_number', '', $param, 'align="left"', $sortfield, $sortorder); + print_liste_field_titre('Ref', $_SERVER['PHP_SELF'], 'doc_number', '', $param, 'class="left"', $sortfield, $sortorder); print_liste_field_titre('Date', $_SERVER['PHP_SELF'], 'dateprint', '', $param, 'align="center" width="150"', $sortfield, $sortorder); print_liste_field_titre('Status', $_SERVER['PHP_SELF'], 'fk_statut', '', $param, 'align="center"', $sortfield, $sortorder); - print_liste_field_titre('Product', $_SERVER['PHP_SELF'], '', '', $param, 'align="left"', $sortfield, $sortorder); - print_liste_field_titre('ContactType', $_SERVER['PHP_SELF'], '', '', $param, 'align="left"', $sortfield, $sortorder); - print_liste_field_titre('Quantity', $_SERVER['PHP_SELF'], 'prod_qty', '', $param, 'align="right"', $sortfield, $sortorder); - print_liste_field_titre('TotalHT', $_SERVER['PHP_SELF'], 'total_ht', '', $param, 'align="right"', $sortfield, $sortorder); - print_liste_field_titre('UnitPrice', $_SERVER['PHP_SELF'], '', '', $param, 'align="right"', $sortfield, $sortorder); + print_liste_field_titre('Product', $_SERVER['PHP_SELF'], '', '', $param, 'class="left"', $sortfield, $sortorder); + print_liste_field_titre('ContactType', $_SERVER['PHP_SELF'], '', '', $param, 'class="left"', $sortfield, $sortorder); + print_liste_field_titre('Quantity', $_SERVER['PHP_SELF'], 'prod_qty', '', $param, 'class="right"', $sortfield, $sortorder); + print_liste_field_titre('TotalHT', $_SERVER['PHP_SELF'], 'total_ht', '', $param, 'class="right"', $sortfield, $sortorder); + print_liste_field_titre('UnitPrice', $_SERVER['PHP_SELF'], '', '', $param, 'class="right"', $sortfield, $sortorder); print "\n"; @@ -590,13 +590,13 @@ if ($sql_select) //print ''; print ''; - print ''; + print ''; $total_qty+=$objp->prod_qty; - print ''; + print ''; $total_ht+=$objp->total_ht; - print ''; + print ''; print "\n"; $i++; @@ -606,9 +606,9 @@ if ($sql_select) print ''; print ''; print ''; - print ''; - print ''; - print ''; + print ''; + print ''; + print ''; print "
'.$langs->trans("BillsSuppliersUnpaid", $num).' '.$num.''.$langs->trans("DateDue").''.$langs->trans("AmountHT").''.$langs->trans("AmountTTC").''.$langs->trans("Paid").''.$langs->trans("DateDue").''.$langs->trans("AmountHT").''.$langs->trans("AmountTTC").''.$langs->trans("Paid").' 
'.$societestatic->getNomUrl(1, 'supplier', 44).''.dol_print_date($db->jdate($obj->date_lim_reglement), 'day').''.price($obj->total_ht).''.price($obj->total_ttc).''.price($obj->am).''.dol_print_date($db->jdate($obj->date_lim_reglement), 'day').''.price($obj->total_ht).''.price($obj->total_ttc).''.price($obj->am).''.$facstatic->LibStatut($obj->paye, $obj->fk_statut, 3).'
'.$langs->trans("Total").'   ('.$langs->trans("RemainderToPay").': '.price($total_ttc-$totalam).')  '.price($total).''.price($total_ttc).''.price($totalam).''.price($total).''.price($total_ttc).''.price($totalam).' 
'.$langs->trans("SocialContribution").''.$langs->trans("DateDue").''.$langs->trans("Amount").''.$langs->trans("AlreadyPaid").''.$langs->trans("RemainderToPay").''.$langs->trans("Amount").''.$langs->trans("AlreadyPaid").''.$langs->trans("RemainderToPay").''.$langs->trans("Amount").'
".dol_print_date($objp->date_ech, 'day')."'.dol_print_date($objp->date_ech, 'day').'!!!'.price($objp->amount)."'.price($objp->amount)."'.price($sumpaid)."'.price($sumpaid)."'.price($objp->amount - $sumpaid)."'.price($objp->amount - $sumpaid)."'; if ($sumpaid < $objp->amount) @@ -322,10 +322,10 @@ if ($action == 'create') { // Print total print '
'.$langs->trans("Total").':".price($total_ttc)."".price($totalrecu)."".price($total_ttc - $totalrecu)."'.$langs->trans("Total").':'.price($total_ttc).''.price($totalrecu).''.price($total_ttc - $totalrecu).' 
'.$langs->trans('DateMaxPayment').''.$langs->trans('Currency').''.$langs->trans('MulticurrencyAmountTTC').''.$multicurrencyalreadypayedlabel.''.$multicurrencyremaindertopay.''.$langs->trans('MulticurrencyPaymentAmount').''.$langs->trans('MulticurrencyAmountTTC').''.$multicurrencyalreadypayedlabel.''.$multicurrencyremaindertopay.''.$langs->trans('MulticurrencyPaymentAmount').''.$langs->trans('AmountTTC').''.$alreadypayedlabel.''.$remaindertopay.''.$langs->trans('PaymentAmount').' '.$langs->trans('AmountTTC').''.$alreadypayedlabel.''.$remaindertopay.''.$langs->trans('PaymentAmount').' 
'; + print ''; if ($objp->multicurrency_code && $objp->multicurrency_code != $conf->currency) print price($sign * $objp->multicurrency_total_ttc); print ''; + print ''; if ($objp->multicurrency_code && $objp->multicurrency_code != $conf->currency) { print price($sign * $multicurrency_payment); @@ -674,11 +674,11 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie print ''; + print ''; if ($objp->multicurrency_code && $objp->multicurrency_code != $conf->currency) print price($sign * $multicurrency_remaintopay); print ''; + print ''; // Add remind multicurrency amount $namef = 'multicurrency_amount_'.$objp->facid; @@ -703,20 +703,20 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie } // Price - print 'id==$facid)?' style="font-weight: bold" ':'').'>'.price($sign * $objp->total_ttc).'id==$facid)?' style="font-weight: bold" ':'').'>'.price($sign * $objp->total_ttc).''.price($sign * $paiement); + print ''.price($sign * $paiement); if ($creditnotes) print '+'.price($creditnotes); if ($deposits) print '+'.price($deposits); print ''.price($sign * $remaintopay).''.price($sign * $remaintopay).''; + print ''; // Add remind amount $namef = 'amount_'.$objp->facid; @@ -763,21 +763,21 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie { // Print total print '
'.$langs->trans('TotalTTC').''.$langs->trans('TotalTTC').''.price($sign * $total_ttc).''.price($sign * $totalrecu); + print ''.price($sign * $total_ttc).''.price($sign * $totalrecu); if ($totalrecucreditnote) print '+'.price($totalrecucreditnote); if ($totalrecudeposits) print '+'.price($totalrecudeposits); print ''.price($sign * price2num($total_ttc - $totalrecu - $totalrecucreditnote - $totalrecudeposits, 'MT')).''.price($sign * price2num($total_ttc - $totalrecu - $totalrecucreditnote - $totalrecudeposits, 'MT')).' 
'.$objp->ref."'.dol_print_date($db->jdate($objp->dp))."'.$objp->paiement_type.' '.$objp->num_paiement."'.price($objp->amount).' '.price($objp->amount).' '.$langs->trans("Element").''.$langs->trans("Status").''.$langs->trans("Debit").''.$langs->trans("Credit").''.$langs->trans("Balance").''.$langs->trans("Author").''.$langs->trans("Debit").''.$langs->trans("Credit").''.$langs->trans("Balance").''.$langs->trans("Author").'
'.$data['status'].''.(($data['amount'] > 0) ? price(abs($data['amount'])) : '')."'.(($data['amount'] > 0) ? price(abs($data['amount'])) : '')."'.(($data['amount'] > 0) ? '' : price(abs($data['amount'])))."'.(($data['amount'] > 0) ? '' : price(abs($data['amount'])))."'.price($data['balance'])."'.price($data['balance'])."'; + print ''; print $data['author']; print '
 '.price($totalDebit).''.price($totalCredit).''.price(price2num($totalDebit - $totalCredit, 'MT')).''.price($totalDebit).''.price($totalCredit).''.price(price2num($totalDebit - $totalCredit, 'MT')).'
'; + print ''; print ''; print ''; // date @@ -381,7 +381,7 @@ if ($sql_select) print ''; print ''; + print ''; print ''; print ''; // TODO: Add filters ! @@ -390,7 +390,7 @@ if ($sql_select) print ''; print ''; + print ''; $searchpicto=$form->showFilterAndCheckAddButtons(0); print $searchpicto; print '
'.$prodreftxt.''.$objp->libelle.''.$objp->prod_qty.''.$objp->prod_qty.''.price($objp->total_ht).''.price($objp->total_ht).''.price($objp->total_ht/(empty($objp->prod_qty)?1:$objp->prod_qty)).''.price($objp->total_ht/(empty($objp->prod_qty)?1:$objp->prod_qty)).'
' . $langs->trans('Total') . '' . $total_qty . '' . price($total_ht) . '' . price($total_ht/(empty($total_qty)?1:$total_qty)) . '' . $total_qty . '' . price($total_ht) . '' . price($total_ht/(empty($total_qty)?1:$total_qty)) . '
"; print '
'; @@ -624,11 +624,11 @@ elseif (empty($type_element) || $type_element == -1) print ''."\n"; // Titles with sort buttons print ''; - print_liste_field_titre('Ref', $_SERVER['PHP_SELF'], 'doc_number', '', $param, 'align="left"', $sortfield, $sortorder); + print_liste_field_titre('Ref', $_SERVER['PHP_SELF'], 'doc_number', '', $param, 'class="left"', $sortfield, $sortorder); print_liste_field_titre('Date', $_SERVER['PHP_SELF'], 'dateprint', '', $param, 'align="center" width="150"', $sortfield, $sortorder); print_liste_field_titre('Status', $_SERVER['PHP_SELF'], 'fk_status', '', $param, 'align="center"', $sortfield, $sortorder); - print_liste_field_titre('Product', $_SERVER['PHP_SELF'], '', '', $param, 'align="left"', $sortfield, $sortorder); - print_liste_field_titre('Quantity', $_SERVER['PHP_SELF'], 'prod_qty', '', $param, 'align="right"', $sortfield, $sortorder); + print_liste_field_titre('Product', $_SERVER['PHP_SELF'], '', '', $param, 'class="left"', $sortfield, $sortorder); + print_liste_field_titre('Quantity', $_SERVER['PHP_SELF'], 'prod_qty', '', $param, 'class="right"', $sortfield, $sortorder); print "\n"; print ''; diff --git a/htdocs/contact/list.php b/htdocs/contact/list.php index 244dffcc0e1..cd25107d744 100644 --- a/htdocs/contact/list.php +++ b/htdocs/contact/list.php @@ -670,7 +670,7 @@ if (! empty($arrayfields['p.import_key']['checked'])) print ''; } // Action column -print ''; From 31e9fd46a44df16acc48a0b8180fa2e86f16cdb4 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 14 Feb 2019 20:59:31 +0100 Subject: [PATCH 017/181] Merge --- htdocs/adherents/subscription/list.php | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/htdocs/adherents/subscription/list.php b/htdocs/adherents/subscription/list.php index 6279d2c61cc..e3a31a0c4c2 100644 --- a/htdocs/adherents/subscription/list.php +++ b/htdocs/adherents/subscription/list.php @@ -84,8 +84,8 @@ $arrayfields=array( 'c.dateadh'=>array('label'=>$langs->trans("DateSubscription"), 'checked'=>1, 'position'=>100), 'c.datef'=>array('label'=>$langs->trans("EndSubscription"), 'checked'=>1, 'position'=>101), 'd.amount'=>array('label'=>$langs->trans("Amount"), 'checked'=>1, 'position'=>102), - 'd.datec'=>array('label'=>$langs->trans("DateCreation"), 'checked'=>0, 'position'=>500), - 'd.tms'=>array('label'=>$langs->trans("DateModificationShort"), 'checked'=>0, 'position'=>500), + 'c.datec'=>array('label'=>$langs->trans("DateCreation"), 'checked'=>0, 'position'=>500), + 'c.tms'=>array('label'=>$langs->trans("DateModificationShort"), 'checked'=>0, 'position'=>500), // 'd.statut'=>array('label'=>$langs->trans("Status"), 'checked'=>1, 'position'=>1000) ); @@ -353,13 +353,13 @@ $parameters=array('arrayfields'=>$arrayfields); $reshook=$hookmanager->executeHooks('printFieldListOption',$parameters); // Note that $action and $object may have been modified by hook print $hookmanager->resPrint; // Date creation -if (! empty($arrayfields['d.datec']['checked'])) +if (! empty($arrayfields['c.datec']['checked'])) { print ''; } // Date modification -if (! empty($arrayfields['d.tms']['checked'])) +if (! empty($arrayfields['c.tms']['checked'])) { print ''; @@ -418,8 +418,8 @@ include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_search_title.tpl.php'; $parameters=array('arrayfields'=>$arrayfields,'param'=>$param,'sortfield'=>$sortfield,'sortorder'=>$sortorder); $reshook=$hookmanager->executeHooks('printFieldListTitle',$parameters); // Note that $action and $object may have been modified by hook print $hookmanager->resPrint; -if (! empty($arrayfields['d.datec']['checked'])) print_liste_field_titre($arrayfields['d.datec']['label'],$_SERVER["PHP_SELF"],"d.datec","",$param,'align="center" class="nowrap"',$sortfield,$sortorder); -if (! empty($arrayfields['d.tms']['checked'])) print_liste_field_titre($arrayfields['d.tms']['label'],$_SERVER["PHP_SELF"],"d.tms","",$param,'align="center" class="nowrap"',$sortfield,$sortorder); +if (! empty($arrayfields['c.datec']['checked'])) print_liste_field_titre($arrayfields['c.datec']['label'],$_SERVER["PHP_SELF"],"c.datec","",$param,'align="center" class="nowrap"',$sortfield,$sortorder); +if (! empty($arrayfields['c.tms']['checked'])) print_liste_field_titre($arrayfields['c.tms']['label'],$_SERVER["PHP_SELF"],"c.tms","",$param,'align="center" class="nowrap"',$sortfield,$sortorder); print_liste_field_titre($selectedfields, $_SERVER["PHP_SELF"],"",'','','align="center"',$sortfield,$sortorder,'maxwidthsearch '); print "\n"; @@ -525,7 +525,7 @@ while ($i < min($num, $limit)) $reshook=$hookmanager->executeHooks('printFieldListValue',$parameters); // Note that $action and $object may have been modified by hook print $hookmanager->resPrint; // Date creation - if (! empty($arrayfields['d.datec']['checked'])) + if (! empty($arrayfields['c.datec']['checked'])) { print '\n"; + +if ($conf->global->TAKEPOSCONNECTOR){ + print ''; +} + +// Bar Restaurant mode +print '\n"; + +if ($conf->global->TAKEPOS_BAR_RESTAURANT && $conf->global->TAKEPOSCONNECTOR){ + print ''; +} + +// Payment numpad +print '\n"; + +$substitutionarray=pdf_getSubstitutionArray($langs, null, null, 2); +$substitutionarray['__(AnyTranslationKey)__']=$langs->trans("Translation"); +$htmltext = ''.$langs->trans("AvailableVariables").':
'; +foreach($substitutionarray as $key => $val) $htmltext.=$key.'
'; +$htmltext.='
'; + +print '\n"; + +print '\n"; + +print '
'.$langs->trans("SelectElementAndClick", $langs->transnoentitiesnoconv("Search")).'
'; +print ''; $searchpicto=$form->showFilterButtons(); print $searchpicto; print ''; print ''; print '
'; print dol_print_date($db->jdate($obj->date_creation), 'dayhour', 'tzuser'); @@ -533,7 +533,7 @@ while ($i < min($num, $limit)) if (! $i) $totalarray['nbfield']++; } // Date modification - if (! empty($arrayfields['d.tms']['checked'])) + if (! empty($arrayfields['c.tms']['checked'])) { print ''; print dol_print_date($db->jdate($obj->date_update), 'dayhour', 'tzuser'); From 8cc2662f01d362836b588887cd1e566b7d68fb7d Mon Sep 17 00:00:00 2001 From: andreubisquerra Date: Thu, 14 Feb 2019 20:59:32 +0100 Subject: [PATCH 018/181] Update TakePOS in Dolibarr 9 --- htdocs/langs/en_US/cashdesk.lang | 12 +- htdocs/takepos/admin/orderprinters.php | 1 - htdocs/takepos/admin/setup.php | 192 +++++++++++------ htdocs/takepos/css/pos.css | 180 +++++++++++++--- htdocs/takepos/invoice.php | 44 +++- htdocs/takepos/pay.php | 43 ++-- htdocs/takepos/receipt.php | 27 ++- htdocs/takepos/takepos.php | 286 +++++++++++++++++-------- 8 files changed, 563 insertions(+), 222 deletions(-) diff --git a/htdocs/langs/en_US/cashdesk.lang b/htdocs/langs/en_US/cashdesk.lang index 836a9489b25..0ca2382d214 100644 --- a/htdocs/langs/en_US/cashdesk.lang +++ b/htdocs/langs/en_US/cashdesk.lang @@ -32,7 +32,7 @@ DeleteArticle=Click to remove this article FilterRefOrLabelOrBC=Search (Ref/Label) UserNeedPermissionToEditStockToUsePos=You ask to decrease stock on invoice creation, so user that uses POS needs to have permission to edit stock. DolibarrReceiptPrinter=Dolibarr Receipt Printer -PointOfSale=Point of sales +PointOfSale=Point of Sale PointOfSaleShort=POS CloseBill=Close Bill Floors=Floors @@ -42,8 +42,16 @@ Place=Place TakeposConnectorNecesary='TakePOS Connector' required OrderPrinters=Order printers SearchProduct=Search product +Receipt=Receipt +Header=Header +Footer=Footer AmountAtEndOfPeriod=Amount at end of period (day, month or year) TheoricalAmount=Theorical amount RealAmount=Real amount CashFenceDone=Cash fence done for the period -NbOfInvoices=Nb of invoices \ No newline at end of file +NbOfInvoices=Nb of invoices +Paymentnumpad=Payment Num Pad +Numberspad=Numbers Pad +BillsCoinsPad=Bills and Coins Pad +DolistorePosCategory=TakePOS modules and other POS solutions for Dolibarr +TakeposNeedsCategories=TakePOS needs product categories to work \ No newline at end of file diff --git a/htdocs/takepos/admin/orderprinters.php b/htdocs/takepos/admin/orderprinters.php index a37a1d71c61..8306bb40e82 100644 --- a/htdocs/takepos/admin/orderprinters.php +++ b/htdocs/takepos/admin/orderprinters.php @@ -48,7 +48,6 @@ if (is_numeric($type)) $type=Categorie::$MAP_ID_TO_CODE[$type]; // For backward /* * Actions */ -print $action; if ($action=="SavePrinter1"){ $printedcategories=";"; if (is_array($printer1)) foreach ($printer1 as $cat){ diff --git a/htdocs/takepos/admin/setup.php b/htdocs/takepos/admin/setup.php index aaec165baa5..9163b718077 100644 --- a/htdocs/takepos/admin/setup.php +++ b/htdocs/takepos/admin/setup.php @@ -25,13 +25,14 @@ require '../../main.inc.php'; // Load $user and permissions require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php'; require_once DOL_DOCUMENT_ROOT.'/product/class/html.formproduct.class.php'; +require_once DOL_DOCUMENT_ROOT.'/core/lib/pdf.lib.php'; // If socid provided by ajax company selector if (! empty($_REQUEST['CASHDESK_ID_THIRDPARTY_id'])) { - $_GET['CASHDESK_ID_THIRDPARTY'] = GETPOST('CASHDESK_ID_THIRDPARTY_id','alpha'); - $_POST['CASHDESK_ID_THIRDPARTY'] = GETPOST('CASHDESK_ID_THIRDPARTY_id','alpha'); - $_REQUEST['CASHDESK_ID_THIRDPARTY'] = GETPOST('CASHDESK_ID_THIRDPARTY_id','alpha'); + $_GET['CASHDESK_ID_THIRDPARTY'] = GETPOST('CASHDESK_ID_THIRDPARTY_id', 'alpha'); + $_POST['CASHDESK_ID_THIRDPARTY'] = GETPOST('CASHDESK_ID_THIRDPARTY_id', 'alpha'); + $_REQUEST['CASHDESK_ID_THIRDPARTY'] = GETPOST('CASHDESK_ID_THIRDPARTY_id', 'alpha'); } // Security check @@ -42,25 +43,28 @@ $langs->loadLangs(array("admin", "cashdesk")); /* * Actions */ -if (GETPOST('action','alpha') == 'set') +if (GETPOST('action', 'alpha') == 'set') { $db->begin(); - if (GETPOST('socid','int') < 0) $_POST["socid"]=''; + if (GETPOST('socid', 'int') < 0) $_POST["socid"]=''; - $res = dolibarr_set_const($db,"CASHDESK_ID_THIRDPARTY",(GETPOST('socid','int') > 0 ? GETPOST('socid','int') : ''),'chaine',0,'',$conf->entity); - $res = dolibarr_set_const($db,"CASHDESK_ID_BANKACCOUNT_CASH",(GETPOST('CASHDESK_ID_BANKACCOUNT_CASH','alpha') > 0 ? GETPOST('CASHDESK_ID_BANKACCOUNT_CASH','alpha') : ''),'chaine',0,'',$conf->entity); - $res = dolibarr_set_const($db,"CASHDESK_ID_BANKACCOUNT_CHEQUE",(GETPOST('CASHDESK_ID_BANKACCOUNT_CHEQUE','alpha') > 0 ? GETPOST('CASHDESK_ID_BANKACCOUNT_CHEQUE','alpha') : ''),'chaine',0,'',$conf->entity); - $res = dolibarr_set_const($db,"CASHDESK_ID_BANKACCOUNT_CB",(GETPOST('CASHDESK_ID_BANKACCOUNT_CB','alpha') > 0 ? GETPOST('CASHDESK_ID_BANKACCOUNT_CB','alpha') : ''),'chaine',0,'',$conf->entity); - $res = dolibarr_set_const($db,"CASHDESK_ID_WAREHOUSE",(GETPOST('CASHDESK_ID_WAREHOUSE','alpha') > 0 ? GETPOST('CASHDESK_ID_WAREHOUSE','alpha') : ''),'chaine',0,'',$conf->entity); - $res = dolibarr_set_const($db,"CASHDESK_NO_DECREASE_STOCK",GETPOST('CASHDESK_NO_DECREASE_STOCK','alpha'),'chaine',0,'',$conf->entity); - $res = dolibarr_set_const($db,"CASHDESK_SERVICES", GETPOST('CASHDESK_SERVICES','alpha'),'chaine',0,'',$conf->entity); - $res = dolibarr_set_const($db,"TAKEPOSCONNECTOR", GETPOST('TAKEPOSCONNECTOR','alpha'),'chaine',0,'',$conf->entity); - $res = dolibarr_set_const($db,"TAKEPOS_BAR_RESTAURANT", GETPOST('TAKEPOS_BAR_RESTAURANT','alpha'),'chaine',0,'',$conf->entity); - $res = dolibarr_set_const($db,"TAKEPOS_PRINT_SERVER", GETPOST('TAKEPOS_PRINT_SERVER','alpha'),'chaine',0,'',$conf->entity); - $res = dolibarr_set_const($db,"TAKEPOS_ORDER_PRINTERS", GETPOST('TAKEPOS_ORDER_PRINTERS','alpha'),'chaine',0,'',$conf->entity); + $res = dolibarr_set_const($db, "CASHDESK_ID_THIRDPARTY", (GETPOST('socid', 'int') > 0 ? GETPOST('socid', 'int') : ''), 'chaine', 0, '', $conf->entity); + $res = dolibarr_set_const($db, "CASHDESK_ID_BANKACCOUNT_CASH", (GETPOST('CASHDESK_ID_BANKACCOUNT_CASH', 'alpha') > 0 ? GETPOST('CASHDESK_ID_BANKACCOUNT_CASH', 'alpha') : ''), 'chaine', 0, '', $conf->entity); + $res = dolibarr_set_const($db, "CASHDESK_ID_BANKACCOUNT_CHEQUE", (GETPOST('CASHDESK_ID_BANKACCOUNT_CHEQUE', 'alpha') > 0 ? GETPOST('CASHDESK_ID_BANKACCOUNT_CHEQUE', 'alpha') : ''), 'chaine', 0, '', $conf->entity); + $res = dolibarr_set_const($db, "CASHDESK_ID_BANKACCOUNT_CB", (GETPOST('CASHDESK_ID_BANKACCOUNT_CB', 'alpha') > 0 ? GETPOST('CASHDESK_ID_BANKACCOUNT_CB', 'alpha') : ''), 'chaine', 0, '', $conf->entity); + $res = dolibarr_set_const($db, "CASHDESK_ID_WAREHOUSE", (GETPOST('CASHDESK_ID_WAREHOUSE', 'alpha') > 0 ? GETPOST('CASHDESK_ID_WAREHOUSE', 'alpha') : ''), 'chaine', 0, '', $conf->entity); + $res = dolibarr_set_const($db, "CASHDESK_NO_DECREASE_STOCK", GETPOST('CASHDESK_NO_DECREASE_STOCK', 'alpha'), 'chaine', 0, '', $conf->entity); + $res = dolibarr_set_const($db, "CASHDESK_SERVICES", GETPOST('CASHDESK_SERVICES', 'alpha'), 'chaine', 0, '', $conf->entity); + $res = dolibarr_set_const($db, "TAKEPOSCONNECTOR", GETPOST('TAKEPOSCONNECTOR', 'alpha'), 'chaine', 0, '', $conf->entity); + $res = dolibarr_set_const($db, "TAKEPOS_BAR_RESTAURANT", GETPOST('TAKEPOS_BAR_RESTAURANT', 'alpha'), 'chaine', 0, '', $conf->entity); + $res = dolibarr_set_const($db, "TAKEPOS_PRINT_SERVER", GETPOST('TAKEPOS_PRINT_SERVER', 'alpha'), 'chaine', 0, '', $conf->entity); + $res = dolibarr_set_const($db, "TAKEPOS_ORDER_PRINTERS", GETPOST('TAKEPOS_ORDER_PRINTERS', 'alpha'), 'chaine', 0, '', $conf->entity); + $res = dolibarr_set_const($db, "TAKEPOS_HEADER", GETPOST('TAKEPOS_HEADER', 'alpha'), 'chaine', 0, '', $conf->entity); + $res = dolibarr_set_const($db, "TAKEPOS_FOOTER", GETPOST('TAKEPOS_FOOTER', 'alpha'), 'chaine', 0, '', $conf->entity); + $res = dolibarr_set_const($db, "TAKEPOS_NUMPAD", GETPOST('TAKEPOS_NUMPAD', 'alpha'), 'chaine', 0, '', $conf->entity); - dol_syslog("admin/cashdesk: level ".GETPOST('level','alpha')); + dol_syslog("admin/cashdesk: level ".GETPOST('level', 'alpha')); if (! $res > 0) $error++; @@ -83,10 +87,10 @@ if (GETPOST('action','alpha') == 'set') $form=new Form($db); $formproduct=new FormProduct($db); -llxHeader('',$langs->trans("CashDeskSetup")); +llxHeader('', $langs->trans("CashDeskSetup")); $linkback=''.$langs->trans("BackToModuleList").''; -print load_fiche_titre($langs->trans("CashDeskSetup").' (TakePOS)',$linkback,'title_setup'); +print load_fiche_titre($langs->trans("CashDeskSetup").' (TakePOS)', $linkback, 'title_setup'); print '
'; @@ -95,55 +99,101 @@ print '
'; print ''; print ''; +print ''; + +print ''; +print ''; +print "\n"; + if (! empty($conf->service->enabled)) { - print '
'.$langs->trans("Parameters").''.$langs->trans("Value").'
'; - - print ''; - print ''; - print "\n"; - print '\n"; - - // Use Takepos printing - print '\n"; - - if ($conf->global->TAKEPOSCONNECTOR){ - print ''; - } - - // Bar Restaurant mode - print '\n"; - - if ($conf->global->TAKEPOS_BAR_RESTAURANT and $conf->global->TAKEPOSCONNECTOR){ - print ''; - } - - print '
'.$langs->trans("Parameters").''.$langs->trans("Value").'
'; print $langs->trans("CashdeskShowServices"); print ''; - print $form->selectyesno("CASHDESK_SERVICES",$conf->global->CASHDESK_SERVICES,1); + print $form->selectyesno("CASHDESK_SERVICES", $conf->global->CASHDESK_SERVICES, 1); print "
'; - print $langs->trans("DolibarrReceiptPrinter").' ('.$langs->trans("TakeposConnectorNecesary").')'; - print ''; - print $form->selectyesno("TAKEPOSCONNECTOR",$conf->global->TAKEPOSCONNECTOR,1); - print "
'; - print $langs->trans("IPAddress").' ('.$langs->trans("TakeposConnectorNecesary").')'; - print ''; - print ''; - print '
'; - print 'Bar Restaurant'; - print ''; - print $form->selectyesno("TAKEPOS_BAR_RESTAURANT",$conf->global->TAKEPOS_BAR_RESTAURANT,1); - print "
'; - print $langs->trans("OrderPrinters").' ('.$langs->trans("Setup").')'; - print ''; - print $form->selectyesno("TAKEPOS_ORDER_PRINTERS",$conf->global->TAKEPOS_ORDER_PRINTERS,1); - print '
'; - - print '
'; } +// Use Takepos printing +print '
'; +print $langs->trans("DolibarrReceiptPrinter").' ('.$langs->trans("TakeposConnectorNecesary").')'; +print ''; +print $form->selectyesno("TAKEPOSCONNECTOR", $conf->global->TAKEPOSCONNECTOR, 1); +print "
'; + print $langs->trans("IPAddress").' ('.$langs->trans("TakeposConnectorNecesary").')'; + print ''; + print ''; + print '
'; +print 'Bar Restaurant'; +print ''; +print $form->selectyesno("TAKEPOS_BAR_RESTAURANT", $conf->global->TAKEPOS_BAR_RESTAURANT, 1); +print "
'; + print $langs->trans("OrderPrinters").' ('.$langs->trans("Setup").')'; + print ''; + print $form->selectyesno("TAKEPOS_ORDER_PRINTERS", $conf->global->TAKEPOS_ORDER_PRINTERS, 1); + print '
'; +print $langs->trans("Paymentnumpad"); +print ''; +$array=array(0=>$langs->trans("Numberspad"), 1=>$langs->trans("BillsCoinsPad")); +print $form->selectarray('TAKEPOS_NUMPAD', $array, (empty($conf->global->TAKEPOS_NUMPAD)?'0':$conf->global->TAKEPOS_NUMPAD), 0); +print "
'; +print $form->textwithpicto($langs->trans("FreeLegalTextOnInvoices")." - ".$langs->trans("Header"), $htmltext, 1, 'help', '', 0, 2, 'freetexttooltip').'
'; +print '
'; +$variablename='TAKEPOS_HEADER'; +if (empty($conf->global->PDF_ALLOW_HTML_FOR_FREE_TEXT)) +{ + print ''; +} +else +{ + include_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php'; + $doleditor=new DolEditor($variablename, $conf->global->$variablename, '', 80, 'dolibarr_notes'); + print $doleditor->Create(); +} +print "
'; +print $form->textwithpicto($langs->trans("FreeLegalTextOnInvoices")." - ".$langs->trans("Footer"), $htmltext, 1, 'help', '', 0, 2, 'freetexttooltip').'
'; +print '
'; +$variablename='TAKEPOS_FOOTER'; +if (empty($conf->global->PDF_ALLOW_HTML_FOR_FREE_TEXT)) +{ + print ''; +} +else +{ + include_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php'; + $doleditor=new DolEditor($variablename, $conf->global->$variablename, '', 80, 'dolibarr_notes'); + print $doleditor->Create(); +} +print "
'; + +print '
'; + print ''; print ''; @@ -159,19 +209,19 @@ if (! empty($conf->banque->enabled)) print ''; print ''; print ''; print ''; print ''; print ''; } @@ -181,12 +231,12 @@ if (! empty($conf->stock->enabled)) print ''; // Force warehouse (this is not a default value) print '
'.$langs->trans("CashDeskBankAccountForSell").''; - $form->select_comptes($conf->global->CASHDESK_ID_BANKACCOUNT_CASH,'CASHDESK_ID_BANKACCOUNT_CASH',0,"courant=2",1); + $form->select_comptes($conf->global->CASHDESK_ID_BANKACCOUNT_CASH, 'CASHDESK_ID_BANKACCOUNT_CASH', 0, "courant=2", 1); print '
'.$langs->trans("CashDeskBankAccountForCheque").''; - $form->select_comptes($conf->global->CASHDESK_ID_BANKACCOUNT_CHEQUE,'CASHDESK_ID_BANKACCOUNT_CHEQUE',0,"courant=1",1); + $form->select_comptes($conf->global->CASHDESK_ID_BANKACCOUNT_CHEQUE, 'CASHDESK_ID_BANKACCOUNT_CHEQUE', 0, "courant=1", 1); print '
'.$langs->trans("CashDeskBankAccountForCB").''; - $form->select_comptes($conf->global->CASHDESK_ID_BANKACCOUNT_CB,'CASHDESK_ID_BANKACCOUNT_CB',0,"courant=1",1); + $form->select_comptes($conf->global->CASHDESK_ID_BANKACCOUNT_CB, 'CASHDESK_ID_BANKACCOUNT_CB', 0, "courant=1", 1); print '
'.$langs->trans("CashDeskDoNotDecreaseStock").''; if (empty($conf->productbatch->enabled)) { - print $form->selectyesno('CASHDESK_NO_DECREASE_STOCK',$conf->global->CASHDESK_NO_DECREASE_STOCK,1); + print $form->selectyesno('CASHDESK_NO_DECREASE_STOCK', $conf->global->CASHDESK_NO_DECREASE_STOCK, 1); } else { if (!$conf->global->CASHDESK_NO_DECREASE_STOCK) { - $res = dolibarr_set_const($db,"CASHDESK_NO_DECREASE_STOCK",1,'chaine',0,'',$conf->entity); + $res = dolibarr_set_const($db, "CASHDESK_NO_DECREASE_STOCK", 1, 'chaine', 0, '', $conf->entity); } print $langs->trans("Yes").'
'; print ''.$langs->trans('StockDecreaseForPointOfSaleDisabledbyBatch').''; @@ -200,7 +250,7 @@ if (! empty($conf->stock->enabled)) print '
'; if (! $disabled) { - print $formproduct->selectWarehouses($conf->global->CASHDESK_ID_WAREHOUSE,'CASHDESK_ID_WAREHOUSE','',1,$disabled); + print $formproduct->selectWarehouses($conf->global->CASHDESK_ID_WAREHOUSE, 'CASHDESK_ID_WAREHOUSE', '', 1, $disabled); print ' ('.$langs->trans("Create").')'; } else @@ -223,14 +273,14 @@ print '

'; // Marketplace print "\n"; print "\n"; -print ''; +print ''; print ''; print ''; print "\n"; -$url='https://www.dolistore.com/en/modules/980-TakePOS-7-mobile.html'; -print ''; -print ''; +$url='https://www.dolistore.com/45-pos'; + print ''; +print ''; print ''; print ''; @@ -246,7 +296,7 @@ print ''; print "\n"; $url='http://www.takepos.com'; -print ''; +print ''; print ''; print ''; print ''; diff --git a/htdocs/takepos/css/pos.css b/htdocs/takepos/css/pos.css index 62a0865482f..87c74c8952d 100644 --- a/htdocs/takepos/css/pos.css +++ b/htdocs/takepos/css/pos.css @@ -1,22 +1,9 @@ html,body { - padding:0; + box-sizing: border-box; + padding:3px; margin:0; height:100%; -} - -body { - width:100%; -} - -.row { - width:100%; - height:50%; -} - -.row div { - width:33%; - height:100%; - float:left; + width:100%; } button.calcbutton { @@ -27,10 +14,11 @@ button.calcbutton { cursor: pointer; vertical-align: middle; text-align: center; - font-size:180%; overflow: visible; /* removes extra width in IE */ width:24%; height:24%; + font-weight: bold; + color: #555555; } button.calcbutton2 { @@ -41,10 +29,11 @@ button.calcbutton2 { cursor: pointer; vertical-align: middle; text-align: center; - font-size:120%; overflow: visible; /* removes extra width in IE */ width:24%; height:24%; + font-weight: bold; + color: #555555; } button.calcbutton3 { @@ -59,7 +48,6 @@ button.calcbutton3 { overflow: visible; /* removes extra width in IE */ width:12%; height:24%; - } button.actionbutton { @@ -70,35 +58,42 @@ button.actionbutton { cursor: pointer; vertical-align: middle; text-align: center; - font-size:100%; overflow: visible; /* removes extra width in IE */ - width:32%; - height:32%; + width:33%; + height:33%; } div.wrapper{ float:left; /* important */ position:relative; /* important(so we can absolutely position the description div */ - width:21.5%; - height:23%; - margin:1%; + width:25%; + height:25%; + margin:0; + padding:1px; border: 0.1em solid; box-shadow: 3px 3px 2px #888; text-align: center; + box-sizing: border-box; + background-color:#f0eeee; } div.wrapper2{ float:left; /* important */ position:relative; /* important(so we can absolutely position the description div */ - width:10.2%; - height:23%; - margin-top:0.5%; - margin-bottom:0.5%; - margin-left:0.5%; - margin-right:0.5%; + width:12.5%; + height:25%; + margin:0; + padding:1px; border: 0.1em solid; - box-shadow: 3px 3px 2px #888; + box-shadow: 2px 2px 1px #888; text-align: center; + box-sizing: border-box; + background-color:#f0eeee; +} + +button:active{ + background:black; + color: white; } div.description{ @@ -106,10 +101,9 @@ div.description{ bottom:0px; /* position will be on bottom */ left:0px; width:100%; - /* styling bellow */ + /* styling below */ background-color:black; font-family: 'tahoma'; - font-size:100%; color:white; opacity:0.8; /* transparency */ filter:alpha(opacity=80); /* IE transparency */ @@ -122,8 +116,126 @@ div.description{ } } +.container{ + width: 100%; + height: 100%; + margin: 0 auto; + overflow: visible; + box-sizing: border-box; +} + +.row1{ + margin: 0 auto; + width: 100%; + height: 34%; +} + +.row2{ + margin: 0 auto; + width: 100%; + height: 66%; +} + +.div1{ + height:100%; + width: 34%; + float: left; + text-align: center; + box-sizing: border-box; + overflow: auto; + background-color:white; +} + +.div2{ + height: 100%; + width: 33%; + font-size: 0; + float: left; + padding-left: 10px; + box-sizing: border-box; +} + +.div3{ + height: 100%; + width: 33%; + float: left; + box-sizing: border-box; +} + +.div4{ + height: 100%; + width: 34%; + float: left; + box-sizing: border-box; + font-size: 6px; + padding:3px; +} + +.div5{ + height: 100%; + width: 66%; + float: left; + box-sizing: border-box; + font-size: 6px; + padding:10px; +} + p.description_content{ padding:10px; margin:0px; } + +@media screen and (min-width: 892px) { + .calcbutton{ + font-size: 18px; + } + .calcbutton2{ + font-size: 14px; + } + .actionbutton{ + font-size: 13px; + } + div.description{ + font-size: 15px; + } + .invoice{ + font-size: 14px; + } +} + +@media (max-width: 891px) and (min-width: 386px) { + .calcbutton{ + font-size: 12px; + } + .calcbutton2{ + font-size: 9px; + } + .actionbutton{ + font-size: 12px; + } + div.description{ + font-size: 13px; + } + .invoice{ + font-size: 12px; + } +} + +@media screen and (max-width: 385px){ + .calcbutton{ + font-size: 8px; + } + .calcbutton2{ + font-size: 7px; + } + .actionbutton{ + font-size: 10px; + } + div.description{ + font-size: 11px; + } + .invoice{ + font-size: 10px; + } +} \ No newline at end of file diff --git a/htdocs/takepos/invoice.php b/htdocs/takepos/invoice.php index 52d4864385f..ed3e5def318 100644 --- a/htdocs/takepos/invoice.php +++ b/htdocs/takepos/invoice.php @@ -189,7 +189,7 @@ if ($action=="order" and $placeid!=0){ ?>
TakePOS Marketplace'.$langs->trans("WebSiteDesc").''.$langs->trans("URL").'
TakePOS for mobile devices'.$langs->trans("DolistorePosCategory").''.$url.'
TakePOS original developers'.$url.'