diff --git a/ChangeLog b/ChangeLog
index d2cad1045fa..d6caeca60c3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -13,12 +13,13 @@ Fix: [ bug #1142 ] Set paiement on invoice (PGSql)
Fix: [ bug #1145 ] Agenda button list type do not display
Fix: [ bug #1148 ] Product consomation : supplier order bad status
Fix: [ bug #1159 ] Commercial search "other" give p.note do not exists
+Fix: [ bug #1174 ] Product translated description not good into PDF
Fix: [ bug #1163 ] SQL Error when searching for supplier orders
Fix: [ bug #1162 ] Translaction for morning and afternoon
Fix: [ bug #1161 ] Search on product label
-Fix: [ bug #1075 ] POS module doesn't decrement stock of products in
- delayed payment mode.
+Fix: [ bug #1075 ] POS module doesn't decrement stock of products in delayed payment mode.
Fix: [ bug #1171 ] Documents lost in interventions after validating
+Fix: fix unsubscribe URL into mailing when sending manually (not by script)
***** ChangeLog for 3.4.1 compared to 3.4.0 *****
Fix: Display buying price on line edit when no supplier price is defined
diff --git a/htdocs/comm/mailing/fiche.php b/htdocs/comm/mailing/fiche.php
index 88ee011bf8f..c3f87e6e4e8 100644
--- a/htdocs/comm/mailing/fiche.php
+++ b/htdocs/comm/mailing/fiche.php
@@ -221,8 +221,8 @@ if ($action == 'sendallconfirmed' && $confirm == 'yes')
$substitutionarray=array(
'__ID__' => $obj->source_id,
'__EMAIL__' => $obj->email,
- '__CHECK_READ__' => '
',
- '__UNSUBSCRIBE__' => ''.$langs->trans("MailUnsubcribe").'',
+ '__CHECK_READ__' => '
',
+ '__UNSUBSCRIBE__' => ''.$langs->trans("MailUnsubcribe").'',
'__MAILTOEMAIL__' => ''.$obj->email.'',
'__LASTNAME__' => $obj->lastname,
'__FIRSTNAME__' => $obj->firstname,
diff --git a/htdocs/comm/propal.php b/htdocs/comm/propal.php
index 33fed6c76d1..60e29a74543 100644
--- a/htdocs/comm/propal.php
+++ b/htdocs/comm/propal.php
@@ -786,7 +786,7 @@ else if ($action == "addline" && $user->rights->propal->creer)
$info_bits=0;
if ($tva_npr) $info_bits |= 0x01;
-
+
if (! empty($price_min) && (price2num($pu_ht)*(1-price2num(GETPOST('remise_percent'))/100) < price2num($price_min)))
{
$mesg = $langs->trans("CantBeLessThanMinPrice",price2num($price_min,'MU').$langs->getCurrencySymbol($conf->currency));
@@ -920,7 +920,7 @@ else if ($action == 'updateligne' && $user->rights->propal->creer && GETPOST('sa
$error++;
}
}
-
+
if (! $error)
{
$result = $object->updateline(
diff --git a/htdocs/core/lib/pdf.lib.php b/htdocs/core/lib/pdf.lib.php
index 5301f5daa04..1f5ef92f711 100644
--- a/htdocs/core/lib/pdf.lib.php
+++ b/htdocs/core/lib/pdf.lib.php
@@ -923,7 +923,17 @@ function pdf_getlinedesc($object,$i,$outputlangs,$hideref=0,$hidedesc=0,$issuppl
if (! empty($conf->global->MAIN_MULTILANGS) && ($outputlangs->defaultlang != $langs->defaultlang))
{
if (! empty($prodser->multilangs[$outputlangs->defaultlang]["label"]) && $label == $prodser->label) $label=$prodser->multilangs[$outputlangs->defaultlang]["label"];
- if (! empty($prodser->multilangs[$outputlangs->defaultlang]["description"]) && $desc == $prodser->description) $desc=$prodser->multilangs[$outputlangs->defaultlang]["description"];
+
+ //Manage HTML entities description test
+ //Cause $prodser->description is store with htmlentities but $desc no
+ $needdesctranslation=false;
+ if (!empty($desc) && dol_textishtml($desc) && !empty($prodser->description) && dol_textishtml($prodser->description)) {
+ $needdesctranslation=(strpos(dol_html_entity_decode($desc,ENT_QUOTES | ENT_HTML401),dol_html_entity_decode($prodser->description,ENT_QUOTES | ENT_HTML401))!==false);
+ } else {
+ $needdesctranslation=($desc == $prodser->description);
+ }
+
+ if (! empty($prodser->multilangs[$outputlangs->defaultlang]["description"]) && ($needdesctranslation)) $desc=$prodser->multilangs[$outputlangs->defaultlang]["description"];
if (! empty($prodser->multilangs[$outputlangs->defaultlang]["note"]) && $note == $prodser->note) $note=$prodser->multilangs[$outputlangs->defaultlang]["note"];
}
}