diff --git a/htdocs/comm/mailing/cibles.php b/htdocs/comm/mailing/cibles.php index 250a155ad57..d3aa3557c89 100644 --- a/htdocs/comm/mailing/cibles.php +++ b/htdocs/comm/mailing/cibles.php @@ -484,24 +484,24 @@ if ($object->fetch($id) >= 0) if ($obj->source_type == 'member') { include_once DOL_DOCUMENT_ROOT.'/adherents/class/adherent.class.php'; - $m=new Adherent($db); - $m->fetch($obj->source_id); - print $m->getNomUrl(2); + $objectstatic=new Adherent($db); + $objectstatic->fetch($obj->source_id); + print $objectstatic->getNomUrl(2); } else if ($obj->source_type == 'user') { include_once DOL_DOCUMENT_ROOT.'/user/class/user.class.php'; - $m=new User($db); - $m->fetch($obj->source_id); - $m->id=$obj->source_id; - print $m->getNomUrl(2); + $objectstatic=new User($db); + $objectstatic->fetch($obj->source_id); + $objectstatic->id=$obj->source_id; + print $objectstatic->getNomUrl(2); } else if ($obj->source_type == 'thirdparty') { include_once DOL_DOCUMENT_ROOT.'/societe/class/societe.class.php'; - $m=new Societe($db); - $m->fetch($obj->source_id); - print $m->getNomUrl(2); + $objectstatic=new Societe($db); + $objectstatic->fetch($obj->source_id); + print $objectstatic->getNomUrl(2); } else { diff --git a/htdocs/commande/orderstoinvoice.php b/htdocs/commande/orderstoinvoice.php index 4d9b6bb53f5..79f18ad26ab 100644 --- a/htdocs/commande/orderstoinvoice.php +++ b/htdocs/commande/orderstoinvoice.php @@ -300,7 +300,8 @@ if (($action == 'create' || $action == 'add') && !$error) $lines[$i]->rowid, $fk_parent_line, $lines[$i]->fk_fournprice, - $lines[$i]->pa_ht + $lines[$i]->pa_ht, + $lines[$i]->label ); if ($result > 0) { @@ -396,9 +397,9 @@ if ($action == 'create' && !$error) print ''; print ''; print ''; - + dol_fiche_head(); - + print '
| '; print img_picto(($pos>0?$langs->trans("MoveField",$pos):''),'uparrow','class="boxhandle" style="cursor:move;"'); print ' | '; @@ -1721,7 +1724,7 @@ function show_elem($fieldssource,$pos,$key,$var,$nostyle='') } elseif ($key == 'none') // Empty line { - print '||||||||
| '; print ' '; print ' | '; @@ -1732,7 +1735,7 @@ function show_elem($fieldssource,$pos,$key,$var,$nostyle='') } else // Print field of source file { - print '||||||||
| ';
// The image must have the class 'boxhandle' beause it's value used in DOM draggable objects to define the area used to catch the full object
print img_picto($langs->trans("MoveField",$pos),'uparrow','class="boxhandle" style="cursor:move;"');
diff --git a/htdocs/langs/ar_SA/main.lang b/htdocs/langs/ar_SA/main.lang
index fc1543d5f3c..33eb00f16ba 100644
--- a/htdocs/langs/ar_SA/main.lang
+++ b/htdocs/langs/ar_SA/main.lang
@@ -1,5 +1,5 @@
# Dolibarr language file - Source file is en_US - main
-DIRECTION=لتر
+DIRECTION=ltr
# Note for Chinese:
# msungstdlight or cid0ct are for traditional Chinese (traditional does not render with Ubuntu pdf reader)
# stsongstdlight or cid0cs are for simplified Chinese
@@ -7,22 +7,22 @@ DIRECTION=لتر
FONTFORPDF=DejaVuSans
FONTSIZEFORPDF=9
SeparatorDecimal=.
-SeparatorThousand=،
-FormatDateShort=٪ م /٪ د /٪ Y
-FormatDateShortInput=٪ م /٪ د /٪ Y
-FormatDateShortJava=MM / DD / YYYY
-FormatDateShortJavaInput=MM / DD / YYYY
-FormatDateShortJQuery=شهر / يوم / سنة
-FormatDateShortJQueryInput=شهر / يوم / سنة
+SeparatorThousand=None
+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=٪عفريت
-FormatHourShortDuration=٪ H:٪ M
-FormatDateTextShort=٪ ب٪ د،٪ Y
-FormatDateText=٪ B٪ د،٪ Y
-FormatDateHourShort=٪ م /٪ د /٪ Y٪ I:٪ M٪ ع
-FormatDateHourSecShort=٪ م /٪ د /٪ Y٪ I:٪ M:٪ S٪ ع
-FormatDateHourTextShort=٪ ب٪ د،٪ Y،٪ I:٪ M٪ ع
-FormatDateHourText=٪ B٪ د،٪ Y،٪ I:٪ M٪ ع
+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
DatabaseConnection=اتصال قاعدة البيانات
NoTemplateDefined=No template defined for this email type
NoTranslation=لا يوجد ترجمة
@@ -30,19 +30,19 @@ NoRecordFound=لا يوجد سجلات
NoError=لا خطأ
Error=خطأ
Errors=أخطاء
-ErrorFieldRequired=مطلوب حقل '٪ ق'
-ErrorFieldFormat=حقل '٪ ق' له قيمة سيئة
-ErrorFileDoesNotExists=الملف غير موجود٪ الصورة
-ErrorFailedToOpenFile=فشل في فتح الملف٪ الصورة
-ErrorCanNotCreateDir=لا يمكن إنشاء DIR٪ الصورة
-ErrorCanNotReadDir=لا يمكن قراءة DIR٪ الصورة
-ErrorConstantNotDefined=المعلمة٪ S غير معرف
+ErrorFieldRequired=Field '%s' is required
+ErrorFieldFormat=Field '%s' has a bad value
+ErrorFileDoesNotExists=File %s does not exist
+ErrorFailedToOpenFile=Failed to open file %s
+ErrorCanNotCreateDir=Can not create dir %s
+ErrorCanNotReadDir=Can not read dir %s
+ErrorConstantNotDefined=Parameter %s not defined
ErrorUnknown=خطأ غير معروف
ErrorSQL=خطأ SQL
-ErrorLogoFileNotFound=لم يتم العثور على ملف شعار '٪ ق'
+ErrorLogoFileNotFound=Logo file '%s' was not found
ErrorGoToGlobalSetup=اذهب إلى 'شركة / مؤسسة' الإعداد لإصلاح هذه
ErrorGoToModuleSetup=الذهاب إلى الوحدة الإعداد لإصلاح هذه
-ErrorFailedToSendMail=فشل في إرسال البريد (المرسل =٪ ق، استقبال =٪ ق)
+ErrorFailedToSendMail=Failed to send mail (sender=%s, receiver=%s)
ErrorAttachedFilesDisabled=تم تعطيل إرفاق ملف في هذا الخادم
ErrorFileNotUploaded=ويتم تحميل الملف. تحقق لا يتجاوز هذا الحجم الأقصى المسموح به، أن المساحة الحرة المتوفرة على القرص والتي لا يوجد بالفعل ملف بنفس الاسم في هذا الدليل.
ErrorInternalErrorDetected=خطأ الكشف عن
@@ -51,20 +51,20 @@ ErrorWrongHostParameter=المعلمة المضيف خاطئة
ErrorYourCountryIsNotDefined=لم يتم تعريف بلدك. الذهاب إلى الصفحة الرئيسية الإعداد-تحرير ومشاركة مرة أخرى في النموذج.
ErrorRecordIsUsedByChild=فشل في حذف هذا السجل. ويستخدم هذا السجل من قبل واحد على الأقل السجلات التابعة.
ErrorWrongValue=قيمة خاطئة
-ErrorWrongValueForParameterX=قيمة خاطئة للمعلمة٪ الصورة
+ErrorWrongValueForParameterX=Wrong value for parameter %s
ErrorNoRequestInError=أي طلب في الخطأ
ErrorServiceUnavailableTryLater=الخدمة غير متوفرة في الوقت الراهن. حاول مجددا لاحقا.
ErrorDuplicateField=قيمة مكررة في حقل فريد
ErrorSomeErrorWereFoundRollbackIsDone=تم العثور على بعض الأخطاء. نحن التراجع التغييرات.
-ErrorConfigParameterNotDefined=لم يتم تعريف المعلمة٪ الصورة داخل ملف التكوين Dolibarr conf.php.
-ErrorCantLoadUserFromDolibarrDatabase=فشل في العثور على المستخدم٪ الصورة في قاعدة بيانات Dolibarr.
-ErrorNoVATRateDefinedForSellerCountry=خطأ، لا معدلات ضريبة القيمة المضافة المحددة للبلد '٪ ق'.
-ErrorNoSocialContributionForSellerCountry=خطأ، لا الاجتماعي / المالي نوع الضرائب المحددة للبلد '٪ ق'.
+ErrorConfigParameterNotDefined=Parameter %s is not defined inside Dolibarr config file conf.php.
+ErrorCantLoadUserFromDolibarrDatabase=Failed to find user %s in Dolibarr database.
+ErrorNoVATRateDefinedForSellerCountry=Error, no vat rates defined for country '%s'.
+ErrorNoSocialContributionForSellerCountry=Error, no social/fiscal taxes type defined for country '%s'.
ErrorFailedToSaveFile=خطأ، فشل في حفظ الملف.
NotAuthorized=غير مصرح لك ان تفعل ذلك.
SetDate=التاريخ المحدد
SelectDate=تحديد تاريخ
-SeeAlso=انظر أيضا الصورة٪
+SeeAlso=See also %s
SeeHere=انظر هنا
BackgroundColorByDefault=لون الخلفية الافتراضية
FileNotUploaded=لم إيداع الملف
@@ -79,7 +79,7 @@ LevelOfFeature=مستوى ميزات
NotDefined=غير معرف
DefinedAndHasThisValue=تعريف وقيمة ل
IsNotDefined=غير محدد
-DolibarrInHttpAuthenticationSoPasswordUseless=Dolibarr وضع مصادقة هو الإعداد إلى٪ s في ملف التكوين conf.php. وهذا يعني أن قاعدة بيانات كلمة السر هي خارجي لDolibarr، لذلك تغيير هذا المجال يمكن أن يكون لها أي آثار. +DolibarrInHttpAuthenticationSoPasswordUseless=Dolibarr authentication mode is setup to %s in configuration file conf.php. This means that password database is extern to Dolibarr, so changing this field may have no effects. Administrator=مدير Undefined=غير محدد PasswordForgotten=نسيت كلمة المرور؟ @@ -103,7 +103,7 @@ TechnicalInformation=المعلومات التقنية TechnicalID=ID الفني NotePublic=ملاحظة (الجمهور) NotePrivate=ملاحظة (خاص) -PrecisionUnitIsLimitedToXDecimals=كان Dolibarr الإعداد للحد من دقة أسعار الوحدات إلى العشرية٪ الصورة. +PrecisionUnitIsLimitedToXDecimals=Dolibarr was setup to limit precision of unit prices to %s decimals. DoTest=اختبار ToFilter=فلتر NoFilter=No filter @@ -140,7 +140,7 @@ AddActionDone=إضافة حدث القيام به Close=إغلاق Close2=إغلاق Confirm=تأكيد -ConfirmSendCardByMail=هل تريد حقا أن ترسل محتوى هذه البطاقة عن طريق البريد إلى٪ s؟ +ConfirmSendCardByMail=Do you really want to send content of this card by mail to %s ? Delete=حذف Remove=إزالة Resiliate=Resiliate @@ -218,7 +218,7 @@ Limit=حد Limits=حدود DevelopmentTeam=فريق التطوير Logout=تسجيل خروج -NoLogoutProcessWithAuthMode=أي ميزة قطع تطبيقية مع وضع المصادقة٪ الصورة +NoLogoutProcessWithAuthMode=No applicative disconnect feature with authentication mode %s Connection=الاتصال Setup=التثبيت Alert=إنذار @@ -388,15 +388,15 @@ ContactsAddressesForCompany=اتصالات / عناوين لهذا الطرف ا AddressesForCompany=عناوين لهذا الطرف الثالث ActionsOnCompany=الأحداث حول هذا الطرف الثالث ActionsOnMember=الأحداث عن هذا العضو -NActions=الأحداث٪ الصورة -NActionsLate=٪ في وقت متأخر الصورة +NActions=%s events +NActionsLate=%s late RequestAlreadyDone=طلب المسجل بالفعل Filter=فلتر -FilterOnInto=معايير البحث '٪ ق' إلى حقول٪ الصورة +FilterOnInto=Search criteria '%s' into fields %s RemoveFilter=إزالة فلتر ChartGenerated=الرسم البياني المتولدة ChartNotGenerated=الرسم البياني لم تولد -GeneratedOn=بناء على٪ الصورة +GeneratedOn=Build on %s Generate=توليد Duration=المدة الزمنية TotalDuration=المدة الإجمالية @@ -529,7 +529,7 @@ File=ملف Files=ملفات NotAllowed=غير مسموح ReadPermissionNotAllowed=إذن لا يسمح للقراءة -AmountInCurrency=المبلغ بالعملة ق ٪ +AmountInCurrency=Amount in %s currency Example=مثال Examples=أمثلة NoExample=على سبيل المثال لا @@ -541,9 +541,9 @@ NbOfObjects=عدد الأجسام NbOfReferers=عدد المشيرين Referers=اشارة الأجسام TotalQuantity=الكمية الإجمالية -DateFromTo=ل٪ من ق ق ٪ -DateFrom=من ق ٪ -DateUntil=حتى ق ٪ +DateFromTo=From %s to %s +DateFrom=From %s +DateUntil=Until %s Check=فحص Uncheck=قم بإلغاء التحديد Internal=الداخلية @@ -595,11 +595,11 @@ GoBack=العودة CanBeModifiedIfOk=يمكن تعديلها إذا كان صحيحا CanBeModifiedIfKo=يمكن تعديلها إذا لم يكن صحيحا RecordModifiedSuccessfully=سجل تعديل بنجاح -RecordsModified=السجلات٪ الصورة المعدلة +RecordsModified=%s records modified AutomaticCode=مدونة الآلي NotManaged=لم يفلح FeatureDisabled=سمة المعوقين -MoveBox=تحرك المربع ٪ ق +MoveBox=Move box %s Offered=عرض NotEnoughPermissions=ليس لديك إذن لهذا العمل SessionName=اسم الدورة @@ -623,7 +623,7 @@ MenuECM=وثائق MenuAWStats=AWStats MenuMembers=أعضاء MenuAgendaGoogle=جوجل جدول الأعمال -ThisLimitIsDefinedInSetup=Dolibarr الحد (القائمة الرئيسية الإعداد للأمن) : %s كيلو بايت ، PHP الحد : %s كيلو بايت +ThisLimitIsDefinedInSetup= NoFileFound=لا الوثائق المحفوظة في هذا المجلد CurrentUserLanguage=الصيغة الحالية CurrentTheme=الموضوع الحالي @@ -707,17 +707,17 @@ toward=نحو Access=وصول SelectAction=حدد العمل HelpCopyToClipboard=استخدم Ctrl + C لنسخ إلى الحافظة -SaveUploadedFileWithMask=حفظ الملف على الخادم مع اسم "٪ ق" (وإلا "٪ ق") +SaveUploadedFileWithMask=حفظ الملف على الخادم مع اسم "%s" (otherwise "%s") OriginFileName=اسم الملف الأصلي SetDemandReason=مجموعة مصدر SetBankAccount=تحديد الحساب المصرفي AccountCurrency=عملة الحساب ViewPrivateNote=عرض الملاحظات -XMoreLines=٪ ق خط (ق) مخبأة +XMoreLines=%s line(s) hidden PublicUrl=URL العام AddBox=إضافة مربع SelectElementAndClickRefresh=حدد عنصر وانقر فوق تحديث -PrintFile=طباعة ملف٪ الصورة +PrintFile=Print File %s ShowTransaction=عرض الصفقة على حساب مصرفي GoIntoSetupToChangeLogo=اذهب إلى الصفحة الرئيسية - إعداد - شركة لتغيير شعار أو الذهاب إلى الصفحة الرئيسية - إعداد - عرض للاختباء. Deny=رفض diff --git a/htdocs/product/class/product.class.php b/htdocs/product/class/product.class.php index 749899e345c..05fbc988c68 100644 --- a/htdocs/product/class/product.class.php +++ b/htdocs/product/class/product.class.php @@ -1735,7 +1735,7 @@ class Product extends CommonObject $sql.= " price_base_type, tva_tx, tosell, price_by_qty, rowid"; $sql.= " FROM ".MAIN_DB_PREFIX."product_price"; $sql.= " WHERE fk_product = '".$this->id."'"; - $sql.= " ORDER BY date_price, rowid DESC"; + $sql.= " ORDER BY date_price DESC, rowid DESC"; $sql.= " LIMIT 1"; $resql = $this->db->query($sql); if ($resql) diff --git a/htdocs/product/price.php b/htdocs/product/price.php index 4e0079b491d..f10d8f17922 100644 --- a/htdocs/product/price.php +++ b/htdocs/product/price.php @@ -1026,7 +1026,7 @@ $sql .= " WHERE fk_product = " . $object->id; $sql .= " AND p.entity IN (" . getEntity('productprice', 1) . ")"; $sql .= " AND p.fk_user_author = u.rowid"; if (! empty($socid) && ! empty($conf->global->PRODUIT_MULTIPRICES)) $sql .= " AND p.price_level = " . $soc->price_level; -$sql .= " ORDER BY p.date_price, p.rowid DESC, p.price_level ASC"; +$sql .= " ORDER BY p.date_price DESC, p.rowid DESC, p.price_level ASC"; // $sql .= $db->plimit(); $result = $db->query($sql); @@ -1063,7 +1063,7 @@ if ($result) } print ' | ' . $langs->trans("PriceBase") . ' | '; - if (! empty($conf->global->PRODUIT_MULTIPRICES_USE_VAT_PER_LEVEL) || ! empty($conf->global->PRODUIT_CUSTOMER_PRICES_BY_QTY)) print '' . $langs->trans("VATRate") . ' | '; + if (! empty($conf->global->PRODUIT_CUSTOMER_PRICES) || ! empty($conf->global->PRODUIT_MULTIPRICES_USE_VAT_PER_LEVEL) || ! empty($conf->global->PRODUIT_CUSTOMER_PRICES_BY_QTY)) print '' . $langs->trans("VATRate") . ' | '; print '' . $langs->trans("HT") . ' | '; print '' . $langs->trans("TTC") . ' | '; if (! empty($conf->dynamicprices->enabled)) { @@ -1098,7 +1098,7 @@ if ($result) } print '' . $langs->trans($objp->price_base_type) . " | "; - if (! empty($conf->global->PRODUIT_MULTIPRICES_USE_VAT_PER_LEVEL) || ! empty($conf->global->PRODUIT_CUSTOMER_PRICES_BY_QTY)) print '' . vatrate($objp->tva_tx, true, $objp->recuperableonly) . " | "; + if (! empty($conf->global->PRODUIT_CUSTOMER_PRICES) || ! empty($conf->global->PRODUIT_MULTIPRICES_USE_VAT_PER_LEVEL) || ! empty($conf->global->PRODUIT_CUSTOMER_PRICES_BY_QTY)) print '' . vatrate($objp->tva_tx, true, $objp->recuperableonly) . " | "; //Price if (! empty($objp->fk_price_expression) && ! empty($conf->dynamicprices->enabled)) diff --git a/htdocs/societe/class/societe.class.php b/htdocs/societe/class/societe.class.php index 1184a490495..93559125874 100644 --- a/htdocs/societe/class/societe.class.php +++ b/htdocs/societe/class/societe.class.php @@ -3026,7 +3026,7 @@ class Societe extends CommonObject } /** - * Check if we must use localtax feature or not according to country (country of $mysocin most cases). + * Check if we must use localtax feature or not according to country (country of $mysoc in most cases). * * @param int $localTaxNum To get info for only localtax1 or localtax2 * @return boolean true or false @@ -3050,6 +3050,27 @@ class Societe extends CommonObject else return false; } + /** + * Check if we must use NPR Vat (french stupid rule) or not according to country (country of $mysoc in most cases). + * + * @return boolean true or false + */ + function useNPR() + { + $sql = "SELECT t.rowid"; + $sql .= " FROM ".MAIN_DB_PREFIX."c_tva as t, ".MAIN_DB_PREFIX."c_country as c"; + $sql .= " WHERE t.fk_pays = c.rowid AND c.code = '".$this->country_code."'"; + $sql .= " AND t.active = 1 AND t.recuperableonly = 1"; + + dol_syslog("useNPR", LOG_DEBUG); + $resql=$this->db->query($sql); + if ($resql) + { + return ($this->db->num_rows($resql) > 0); + } + else return false; + } + /** * Check if we must use revenue stamps feature or not according to country (country of $mysocin most cases). *