forked from Wavyzz/dolibarr
Merge branch '17.0' of git@github.com:Dolibarr/dolibarr.git into 17.0
This commit is contained in:
@@ -1365,7 +1365,7 @@ function pdf_writelinedesc(&$pdf, $object, $i, $outputlangs, $w, $h, $posx, $pos
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduct this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = empty($object->lines[$i]->special_code) ? '' : $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array('pdf'=>$pdf, 'i'=>$i, 'outputlangs'=>$outputlangs, 'w'=>$w, 'h'=>$h, 'posx'=>$posx, 'posy'=>$posy, 'hideref'=>$hideref, 'hidedesc'=>$hidedesc, 'issupplierline'=>$issupplierline, 'special_code'=>$special_code);
|
||||
@@ -1733,7 +1733,7 @@ function pdf_getlinenum($object, $i, $outputlangs, $hidedetails = 0)
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduct this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array('i'=>$i, 'outputlangs'=>$outputlangs, 'hidedetails'=>$hidedetails, 'special_code'=>$special_code);
|
||||
@@ -1766,7 +1766,7 @@ function pdf_getlineref($object, $i, $outputlangs, $hidedetails = 0)
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduct this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array('i'=>$i, 'outputlangs'=>$outputlangs, 'hidedetails'=>$hidedetails, 'special_code'=>$special_code);
|
||||
@@ -1798,7 +1798,7 @@ function pdf_getlineref_supplier($object, $i, $outputlangs, $hidedetails = 0)
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduct this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array('i'=>$i, 'outputlangs'=>$outputlangs, 'hidedetails'=>$hidedetails, 'special_code'=>$special_code);
|
||||
@@ -1829,8 +1829,8 @@ function pdf_getlinevatrate($object, $i, $outputlangs, $hidedetails = 0)
|
||||
$reshook = 0;
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduce this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
$special_code = empty($object->lines[$i]) ? '' : $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array('i'=>$i, 'outputlangs'=>$outputlangs, 'hidedetails'=>$hidedetails, 'special_code'=>$special_code);
|
||||
@@ -1896,8 +1896,8 @@ function pdf_getlineupexcltax($object, $i, $outputlangs, $hidedetails = 0)
|
||||
$reshook = 0;
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduct this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
$special_code = empty($object->lines[$i]) ? '' : $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array('i'=>$i, 'outputlangs'=>$outputlangs, 'hidedetails'=>$hidedetails, 'special_code'=>$special_code);
|
||||
@@ -1940,7 +1940,7 @@ function pdf_getlineupwithtax($object, $i, $outputlangs, $hidedetails = 0)
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduct this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array('i'=>$i, 'outputlangs'=>$outputlangs, 'hidedetails'=>$hidedetails, 'special_code'=>$special_code);
|
||||
@@ -1976,8 +1976,8 @@ function pdf_getlineqty($object, $i, $outputlangs, $hidedetails = 0)
|
||||
$reshook = 0;
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduct this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
$special_code = empty($object->lines[$i]) ? '' : $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array('i'=>$i, 'outputlangs'=>$outputlangs, 'hidedetails'=>$hidedetails, 'special_code'=>$special_code);
|
||||
@@ -2017,7 +2017,7 @@ function pdf_getlineqty_asked($object, $i, $outputlangs, $hidedetails = 0)
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduct this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array('i'=>$i, 'outputlangs'=>$outputlangs, 'hidedetails'=>$hidedetails, 'special_code'=>$special_code);
|
||||
@@ -2057,7 +2057,7 @@ function pdf_getlineqty_shipped($object, $i, $outputlangs, $hidedetails = 0)
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduct this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array('i'=>$i, 'outputlangs'=>$outputlangs, 'hidedetails'=>$hidedetails, 'special_code'=>$special_code);
|
||||
@@ -2097,7 +2097,7 @@ function pdf_getlineqty_keeptoship($object, $i, $outputlangs, $hidedetails = 0)
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduct this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array('i'=>$i, 'outputlangs'=>$outputlangs, 'hidedetails'=>$hidedetails, 'special_code'=>$special_code);
|
||||
@@ -2138,7 +2138,7 @@ function pdf_getlineunit($object, $i, $outputlangs, $hidedetails = 0, $hookmanag
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduct this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array(
|
||||
@@ -2183,7 +2183,7 @@ function pdf_getlineremisepercent($object, $i, $outputlangs, $hidedetails = 0)
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduct this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array('i'=>$i, 'outputlangs'=>$outputlangs, 'hidedetails'=>$hidedetails, 'special_code'=>$special_code);
|
||||
@@ -2227,7 +2227,7 @@ function pdf_getlineprogress($object, $i, $outputlangs, $hidedetails = 0, $hookm
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduct this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array('i' => $i, 'outputlangs' => $outputlangs, 'hidedetails' => $hidedetails, 'special_code' => $special_code);
|
||||
@@ -2279,8 +2279,8 @@ function pdf_getlinetotalexcltax($object, $i, $outputlangs, $hidedetails = 0)
|
||||
$result = '';
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduct this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
$special_code = empty($object->lines[$i]) ? '' : $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array('i'=>$i, 'outputlangs'=>$outputlangs, 'hidedetails'=>$hidedetails, 'special_code'=>$special_code, 'sign'=>$sign);
|
||||
@@ -2292,7 +2292,7 @@ function pdf_getlinetotalexcltax($object, $i, $outputlangs, $hidedetails = 0)
|
||||
}
|
||||
}
|
||||
if (empty($reshook)) {
|
||||
if ($object->lines[$i]->special_code == 3) {
|
||||
if (!empty($object->lines[$i]) && $object->lines[$i]->special_code == 3) {
|
||||
$result .= $outputlangs->transnoentities("Option");
|
||||
} elseif (empty($hidedetails) || $hidedetails > 1) {
|
||||
$total_ht = (isModEnabled("multicurrency") && $object->multicurrency_tx != 1 ? $object->lines[$i]->multicurrency_total_ht : $object->lines[$i]->total_ht);
|
||||
@@ -2336,7 +2336,7 @@ function pdf_getlinetotalwithtax($object, $i, $outputlangs, $hidedetails = 0)
|
||||
//if (is_object($hookmanager) && ( (isset($object->lines[$i]->product_type) && $object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line) ) )
|
||||
if (is_object($hookmanager)) { // Old code is commented on preceding line. Reproduct this test in the pdf_xxx function if you don't want your hook to run
|
||||
$special_code = $object->lines[$i]->special_code;
|
||||
if (!empty($object->lines[$i]->fk_parent_line)) {
|
||||
if (!empty($object->lines[$i]->fk_parent_line) && $object->lines[$i]->fk_parent_line > 0) {
|
||||
$special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
|
||||
}
|
||||
$parameters = array('i'=>$i, 'outputlangs'=>$outputlangs, 'hidedetails'=>$hidedetails, 'special_code'=>$special_code);
|
||||
|
||||
Reference in New Issue
Block a user