+/* Copyright (C) 2023-2024 Frédéric France
* Copyright (C) 2024 MDW
*
* This program is free software; you can redistribute it and/or modify
@@ -152,9 +152,9 @@ trait CommonPeople
/**
* Return full address for banner
*
- * @param string $htmlkey HTML id to make banner content unique
- * @param Object $object Object (thirdparty, thirdparty of contact for contact, null for a member)
- * @return string Full address string
+ * @param string $htmlkey HTML id to make banner content unique
+ * @param CommonObject $object Object (thirdparty, thirdparty of contact for contact, null for a member)
+ * @return string Full address string
*/
public function getBannerAddress($htmlkey, $object)
{
@@ -165,20 +165,24 @@ trait CommonPeople
$contactid = 0;
$thirdpartyid = 0;
$elementforaltlanguage = $this->element;
- if ($this instanceOf Societe && $this->element === 'societe') {
- /** @var Societe $this */
+ if ($this->element === 'societe' && $this instanceof Societe) {
$thirdpartyid = $this->id;
}
- if ($this instanceOf Contact && $this->element === 'contact') {
- /** @var Contact $this */
+ if ($this->element === 'contact' && $this instanceof Contact) {
$contactid = $this->id;
$thirdpartyid = empty($this->fk_soc) ? 0 : $this->fk_soc;
}
- if ($this instanceOf User && $this->element === 'user') {
- /** @var User $this */
+ if ($this->element == 'member' && $this instanceof Adherent) {
+ $contactid = $this->id;
+ $thirdpartyid = empty($this->socid) ? 0 : $this->socid;
+ }
+ if ($this->element === 'user' && $this instanceof User) {
$contactid = $this->contact_id;
$thirdpartyid = empty($object->fk_soc) ? 0 : $object->fk_soc;
}
+ if ($this->element == 'recruitmentcandidature' && $this instanceof RecruitmentCandidature) {
+ $thirdpartyid = 0;
+ }
$out = '';
@@ -210,7 +214,7 @@ trait CommonPeople
$arrayoflangcode[] = getDolGlobalString('PDF_USE_ALSO_LANGUAGE_CODE');
}
- if (is_array($arrayoflangcode) && count($arrayoflangcode)) {
+ if (/* is_array($arrayoflangcode) && */count($arrayoflangcode)) {
if (!is_object($extralanguages)) {
include_once DOL_DOCUMENT_ROOT.'/core/class/extralanguages.class.php';
$extralanguages = new ExtraLanguages($this->db);
@@ -258,7 +262,7 @@ trait CommonPeople
// Phones
$outphonedone = 0;
if (!empty($this->phone) && empty($this->phone_pro)) { // For objects that store pro phone into ->phone
- $out .= ($outphonedone ? ' ' : '');
+ // $out .= ($outphonedone ? ' ' : '');
$out .= dol_print_phone($this->phone, $this->country_code, $contactid, $thirdpartyid, 'AC_TEL', ' ', 'phone', $langs->trans("PhonePro"));
$outdone++;
$outphonedone++;
@@ -387,7 +391,7 @@ trait CommonPeople
$this->address = dol_strtoupper($this->address);
$this->town = dol_strtoupper($this->town);
}
- if (isset($this->email)) {
+ if (!empty($this->email)) {
$this->email = dol_strtolower($this->email);
}
if (isset($this->personal_email)) {
diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php
index e61568e6209..d27e941d1e6 100644
--- a/htdocs/core/class/html.form.class.php
+++ b/htdocs/core/class/html.form.class.php
@@ -2767,9 +2767,9 @@ class Form
}
if (empty($hidelabel)) {
- $out .= $langs->trans("RefOrLabel") . ' : ';
+ $placeholder = ' placeholder="' . dolPrintHTMLForAttribute($langs->trans("RefOrLabel")) . '"';
} elseif ($hidelabel > 1) {
- $placeholder = ' placeholder="' . $langs->trans("RefOrLabel") . '"';
+ $placeholder = ' placeholder="' . dolPrintHTMLForAttribute($langs->trans("RefOrLabel")) . '"';
if ($hidelabel == 2) {
$out .= img_picto($langs->trans("Search"), 'search');
}
diff --git a/htdocs/expedition/list.php b/htdocs/expedition/list.php
index e2cbfed00c5..b45450396bc 100644
--- a/htdocs/expedition/list.php
+++ b/htdocs/expedition/list.php
@@ -669,7 +669,7 @@ $companystatic = new Societe($db);
$formcompany = new FormCompany($db);
$shipment = new Expedition($db);
-$title = $langs->trans('ListOfSendings');
+$title = $langs->trans('Shipments');
$help_url = 'EN:Module_Shipments|FR:Module_Expéditions|ES:Módulo_Expediciones';
llxHeader('', $title, $help_url, '', 0, 0, '', '', '', 'bodyforlist mod-expedition page-list');
@@ -934,8 +934,6 @@ if ($num == 1 && !empty($conf->global->MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE) && $
exit;
}
-$expedition = new Expedition($db);
-
if ($socid > 0) {
$soc = new Societe($db);
$soc->fetch($socid);
@@ -1074,7 +1072,7 @@ print '';
print '';
// @phan-suppress-next-line PhanPluginSuspiciousParamOrder
-print_barre_liste($langs->trans('ListOfSendings'), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'dolly', 0, $newcardbutton, '', $limit, 0, 0, 1);
+print_barre_liste($langs->trans('Shipments'), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'dolly', 0, $newcardbutton, '', $limit, 0, 0, 1);
$topicmail = "SendShippingRef";
$modelmail = "shipping_send";
@@ -1085,7 +1083,7 @@ include DOL_DOCUMENT_ROOT.'/core/tpl/massactions_pre.tpl.php';
if ($massaction == 'createbills') {
print '';
- print '
';
+ print '
';
print '
';
print '
';
print $langs->trans('DateInvoice');
diff --git a/htdocs/fourn/class/fournisseur.facture-rec.class.php b/htdocs/fourn/class/fournisseur.facture-rec.class.php
index f57cfab72fb..7d2ea231dfc 100644
--- a/htdocs/fourn/class/fournisseur.facture-rec.class.php
+++ b/htdocs/fourn/class/fournisseur.facture-rec.class.php
@@ -1307,7 +1307,7 @@ class FactureFournisseurRec extends CommonInvoice
if (empty($this->date_when)) {
return false;
}
- return dol_time_plus_duree((int) $this->date_when, $this->frequency, $this->unit_frequency);
+ return dol_time_plus_duree((int) $this->date_when, $this->frequency, $this->unit_frequency, 1);
}
/**
diff --git a/htdocs/langs/en_US/cashdesk.lang b/htdocs/langs/en_US/cashdesk.lang
index afe22259f17..5155d532f7c 100644
--- a/htdocs/langs/en_US/cashdesk.lang
+++ b/htdocs/langs/en_US/cashdesk.lang
@@ -60,7 +60,7 @@ Numberspad=Numbers Pad
BillsCoinsPad=Coins and banknotes Pad
DolistorePosCategory=TakePOS modules and other POS solutions for Dolibarr
TakeposNeedsCategories=TakePOS needs at least one product category to work
-TakeposNeedsAtLeastOnSubCategoryIntoParentCategory=TakePOS needs at least 1 product category under the category %s to work
+TakeposNeedsAtLeastOnSubCategoryIntoParentCategory=TakePOS needs at least 1 sub-category under the product category %s to work
OrderNotes=Can add some notes to each ordered items
CashDeskBankAccountFor=Default account to use for payments in
NoPaimementModesDefined=No paiment mode defined in TakePOS configuration
diff --git a/htdocs/langs/en_US/languages.lang b/htdocs/langs/en_US/languages.lang
index 6afa486d033..4ea49a160fa 100644
--- a/htdocs/langs/en_US/languages.lang
+++ b/htdocs/langs/en_US/languages.lang
@@ -72,6 +72,7 @@ Language_fr_FR=French
Language_fr_GA=French (Gabon)
Language_fr_NC=French (New Caledonia)
Language_fr_SN=French (Senegal)
+Language_fr_TN=French (Tunisia)
Language_fy_NL=Frisian
Language_gl_ES=Galician
Language_he_IL=Hebrew
diff --git a/htdocs/langs/en_US/products.lang b/htdocs/langs/en_US/products.lang
index c3b29b9751b..2d8d05e9761 100644
--- a/htdocs/langs/en_US/products.lang
+++ b/htdocs/langs/en_US/products.lang
@@ -97,7 +97,6 @@ ShowService=Show service
ProductsAndServicesArea=Product and Services area
ProductsArea=Product area
ServicesArea=Services area
-ListOfStockMovements=List of stock movements
BuyingPrice=Buying price
PriceForEachProduct=Products with specific prices
SupplierCard=Vendor card
diff --git a/htdocs/langs/en_US/receptions.lang b/htdocs/langs/en_US/receptions.lang
index 80e9724b3b4..34b2276fca7 100644
--- a/htdocs/langs/en_US/receptions.lang
+++ b/htdocs/langs/en_US/receptions.lang
@@ -7,7 +7,6 @@ Receptions=Receptions
AllReceptions=All Receptions
ShowReception=Show Receptions
ReceptionsArea=Receptions area
-ListOfReceptions=List of receptions
ReceptionMethod=Reception method
LastReceptions=Latest %s receptions
StatisticsOfReceptions=Statistics for receptions
diff --git a/htdocs/langs/en_US/sendings.lang b/htdocs/langs/en_US/sendings.lang
index eb9c16239cc..95406dcc87e 100644
--- a/htdocs/langs/en_US/sendings.lang
+++ b/htdocs/langs/en_US/sendings.lang
@@ -8,13 +8,12 @@ Shipments=Shipments
ShowSending=Show Shipments
Receivings=Delivery Receipts
SendingsArea=Shipments area
-ListOfSendings=List of shipments
SendingMethod=Shipping method
LastSendings=Latest %s shipments
StatisticsOfSendings=Statistics for shipments
NbOfSendings=Number of shipments
NumberOfShipmentsByMonth=Number of shipments by month
-SendingCard=Shipment card
+SendingCard=Shipment
NewSending=New shipment
CreateShipment=Create shipment
QtyShipped=Qty shipped
diff --git a/htdocs/langs/en_US/stocks.lang b/htdocs/langs/en_US/stocks.lang
index 0648dde54b4..9b651192a6b 100644
--- a/htdocs/langs/en_US/stocks.lang
+++ b/htdocs/langs/en_US/stocks.lang
@@ -27,9 +27,6 @@ LotSerialList=List of lot/serials
SubjectToLotSerialOnly=Products subject to lot/serial only
Movements=Movements
ErrorWarehouseRefRequired=Warehouse reference name is required
-ListOfWarehouses=List of warehouses
-ListOfStockMovements=List of stock movements
-ListOfInventories=List of inventories
MovementId=Movement ID
StockMovementForId=Movement ID %d
ListMouvementStockProject=List of stock movements associated to project
diff --git a/htdocs/langs/fr_FR/cashdesk.lang b/htdocs/langs/fr_FR/cashdesk.lang
index 2f7a1a59aa8..ecbb052ad0b 100644
--- a/htdocs/langs/fr_FR/cashdesk.lang
+++ b/htdocs/langs/fr_FR/cashdesk.lang
@@ -60,7 +60,7 @@ Numberspad=Pavé numérique
BillsCoinsPad=Pavé avec montant des Pièces et Billets
DolistorePosCategory=Modules TakePOS et autres solutions de PDV pour Dolibarr
TakeposNeedsCategories=TakePOS a besoin d'au moins une catégorie de produits pour fonctionner
-TakeposNeedsAtLeastOnSubCategoryIntoParentCategory=TakePOS a besoin d'au moins 1 catégorie de produits dans la catégorie %s pour fonctionner
+TakeposNeedsAtLeastOnSubCategoryIntoParentCategory=TakePOS a besoin d'au moins 1 sous-catégorie dans la catégorie de produit %s pour fonctionner
OrderNotes=Il est possible d'ajouter des notes sur chacun des produits commandés
CashDeskBankAccountFor=Compte par défaut à utiliser pour les paiements en
NoPaimementModesDefined=Aucun mode de paiement défini dans la configuration de TakePOS
diff --git a/htdocs/langs/fr_TN/main.lang b/htdocs/langs/fr_TN/main.lang
new file mode 100644
index 00000000000..ae3db1eeb17
--- /dev/null
+++ b/htdocs/langs/fr_TN/main.lang
@@ -0,0 +1,31 @@
+# Dolibarr language file - Source file is en_US - main
+DIRECTION=ltr
+# Default for FONTFORPDF=helvetica
+# Note for Chinese:
+# msungstdlight or cid0ct are for traditional Chinese zh_TW (traditional does not render with Ubuntu pdf reader)
+# stsongstdlight or cid0cs are for simplified Chinese zh_CN
+# To read Chinese pdf with Linux: sudo apt-get install poppler-data
+# cid0jp is for Japanish
+# cid0kr is for Korean
+# DejaVuSans is for some Eastern languages, some Asian languages and some Arabic languages
+# freemono is for ru_RU or uk_UA, uz_UZ
+# freeserif is for Tamil or Ethiopian
+FONTFORPDF=helvetica
+FONTSIZEFORPDF=10
+SeparatorDecimal=,
+SeparatorThousand=Space
+FormatDateShort=%d/%m/%Y
+FormatDateShortInput=%d/%m/%Y
+FormatDateShortJava=dd/MM/yyyy
+FormatDateShortJavaInput=dd/MM/yyyy
+FormatDateShortJQuery=dd/mm/yy
+FormatDateShortJQueryInput=dd/mm/yy
+FormatHourShortJQuery=HH:MI
+FormatHourShort=%H:%M
+FormatHourShortDuration=%H:%M
+FormatDateTextShort=%d %b %Y
+FormatDateText=%d %B %Y
+FormatDateHourShort=%d/%m/%Y %H:%M
+FormatDateHourSecShort=%d/%m/%Y %H:%M:%S
+FormatDateHourTextShort=%d %b %Y %H:%M
+FormatDateHourText=%d %B %Y %H:%M
diff --git a/htdocs/langs/fr_TN/sendings.lang b/htdocs/langs/fr_TN/sendings.lang
new file mode 100644
index 00000000000..776063f7602
--- /dev/null
+++ b/htdocs/langs/fr_TN/sendings.lang
@@ -0,0 +1,2 @@
+# Dolibarr language file - Source file is en_US - sendings
+SendingCard=Bon livraison
diff --git a/htdocs/product/admin/product.php b/htdocs/product/admin/product.php
index ea093c7885a..3d7e56c8de8 100644
--- a/htdocs/product/admin/product.php
+++ b/htdocs/product/admin/product.php
@@ -650,6 +650,9 @@ print '';
+print ' ';
+
+
print load_fiche_titre($langs->trans("UserInterface"), '', '');
diff --git a/htdocs/product/stats/card.php b/htdocs/product/stats/card.php
index a0d2cf1a04a..f2708e0df27 100644
--- a/htdocs/product/stats/card.php
+++ b/htdocs/product/stats/card.php
@@ -217,7 +217,7 @@ if ($result || !($id > 0)) {
// Product
print '