2
0
forked from Wavyzz/dolibarr
This commit is contained in:
ldestailleur
2025-10-06 11:29:03 +02:00
parent 0e79c7817f
commit adb02003f5
3 changed files with 3 additions and 2 deletions

View File

@@ -1584,7 +1584,7 @@ class FormMail extends Form
$out .= '</div>';
if (isModEnabled('product') || isModEnabled('service')) {
include_once DOL_DOCUMENT_ROOT.'/htdocs/core/class/html.form.class.php';
include_once DOL_DOCUMENT_ROOT.'/core/class/html.form.class.php';
$form = new Form($this->db);
$out .= '<div id="product-dropdown-container" class="email-layout-container hidden" style="height: 32px; display:none;">';
$out .= '<label for="product-select">'.img_picto('', 'product', 'class="pictofixedwidth"').$langs->trans("Product").' : </label>';

View File

@@ -104,6 +104,7 @@ if ($action == 'uploadfile') { // Test on permission not required here. Done lat
include DOL_DOCUMENT_ROOT.'/core/actions_linkedfiles.inc.php';
// @phpstan-ignore-next-line $error may have been modified by actions_linkedfiles.inc.php
if (!$error) {
header("Location: ".DOL_URL_ROOT.'/core/upload_page2.php?file='.urlencode($fileprefix));
exit;

View File

@@ -3680,7 +3680,7 @@ class Product extends CommonObject
$sql .= " UNION ";
$sql .= "SELECT SUM(".$this->db->ifsql('f.type=2', -1, 1)." * fd.qty) as count FROM ".$this->db->prefix()."facturedet as fd ";
$sql .= "SELECT SUM(".$this->db->ifsql('f.type=2', '-1', '1')." * fd.qty) as count FROM ".$this->db->prefix()."facturedet as fd ";
$sql .= " JOIN ".$this->db->prefix()."facture as f ON fd.fk_facture = f.rowid";
$sql .= " JOIN ".$this->db->prefix()."element_element as el ON el.fk_source = f.rowid AND el.targettype = 'commande' AND sourcetype = 'facture' ";
$sql .= " JOIN ".$this->db->prefix()."commande as c ON el.fk_source = c.rowid";