Merge remote-tracking branch 'Upstream/3.9' into 3.9-p9

This commit is contained in:
aspangaro 2016-01-31 07:33:57 +01:00
commit 2fa01a1754
12 changed files with 122 additions and 124 deletions

View File

@ -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
{

View File

@ -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 '<input type="hidden" name="origin" value="'.GETPOST('origin').'">';
print '<input type="hidden" name="originid" value="'.GETPOST('originid').'">';
print '<input type="hidden" name="autocloseorders" value="'.GETPOST('autocloseorders').'">';
dol_fiche_head();
print '<table class="border" width="100%">';
// Ref
@ -501,15 +502,15 @@ if ($action == 'create' && !$error)
}
dol_fiche_end();
// Button "Create Draft"
print '<div class="center"><input type="submit" class="button" name="bouton" value="'.$langs->trans('CreateDraft').'" /></div>';
print "</form>\n";
print '</td></tr>';
print "</table>\n";
}
// Mode liste

View File

@ -6,7 +6,7 @@
* Copyright (C) 2010-2015 Juanjo Menent <jmenent@2byte.es>
* Copyright (C) 2013 Christophe Battarel <christophe.battarel@altairis.fr>
* Copyright (C) 2013-2014 Florian Henry <florian.henry@open-concept.pro>
* Copyright (C) 2014 Ferran Marcet <fmarcet@2byte.es>
* Copyright (C) 2014-2016 Ferran Marcet <fmarcet@2byte.es>
* Copyright (C) 2014 Marcos García <marcosgdf@gmail.com>
* Copyright (C) 2015 Jean-François Ferry <jfefe@aternatik.fr>
*
@ -1718,9 +1718,11 @@ else
{
$tmpaction='activateline';
if ($objp->statut == 4) $tmpaction='unactivateline';
print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&amp;ligne='.$object->lines[$cursorline-1]->id.'&amp;action='.$tmpaction.'">';
print img_edit();
print '</a>';
if (($tmpaction=='activateline' && $user->rights->contrat->activer) || ($tmpaction=='unactivateline' && $user->rights->contrat->unactiver)) {
print '<a href="' . $_SERVER["PHP_SELF"] . '?id=' . $object->id . '&amp;ligne=' . $object->lines[$cursorline - 1]->id . '&amp;action=' . $tmpaction . '">';
print img_edit();
print '</a>';
}
}
}
print '</td>';

View File

@ -108,7 +108,7 @@ function vat_by_thirdparty($db, $y, $date_start, $date_end, $modetax, $direction
if ($modetax == 1)
{
// If vat paid on due invoices (non draft)
$sql = "SELECT s.rowid as socid, s.nom as name, s.siren as tva_intra, s.tva_assuj as assuj,";
$sql = "SELECT s.rowid as socid, s.nom as name, s.tva_intra as tva_intra, s.tva_assuj as assuj,";
$sql.= " sum(f.$total_ht) as amount, sum(f.".$total_tva.") as tva,";
$sql.= " sum(f.localtax1) as localtax1,";
$sql.= " sum(f.localtax2) as localtax2";

View File

@ -175,7 +175,7 @@ class modECM extends DolibarrModules
'langs'=>'ecm',
'position'=>103,
'perms'=>'$user->rights->ecm->read || $user->rights->ecm->upload',
'enabled'=>'$user->rights->ecm->read || $user->rights->ecm->upload',
'enabled'=>'($user->rights->ecm->read || $user->rights->ecm->upload) && ! empty($conf->global->ECM_AUTO_TREE_ENABLED)',
'target'=>'',
'user'=>2); // 0=Menu for internal users, 1=external users, 2=both
$r++;

View File

@ -44,7 +44,7 @@ class modProduct extends DolibarrModules
*/
function __construct($db)
{
global $conf;
global $conf, $mysoc;
$this->db = $db;
$this->numero = 50;
@ -148,55 +148,20 @@ class modProduct extends DolibarrModules
$this->export_label[$r]="Products"; // Translation key (used only if key ExportDataset_xxx_z not found)
$this->export_permission[$r]=array(array("produit","export"));
$this->export_fields_array[$r]=array('p.rowid'=>"Id",'p.ref'=>"Ref",'p.label'=>"Label",'p.description'=>"Description",'p.url'=>"PublicUrl",'p.accountancy_code_sell'=>"ProductAccountancySellCode",'p.accountancy_code_buy'=>"ProductAccountancyBuyCode",'p.note'=>"Note",'p.length'=>"Length",'p.surface'=>"Surface",'p.volume'=>"Volume",'p.weight'=>"Weight",'p.customcode'=>'CustomCode','p.price_base_type'=>"PriceBase",'p.price'=>"UnitPriceHT",'p.price_ttc'=>"UnitPriceTTC",'p.tva_tx'=>'VATRate','p.tosell'=>"OnSell",'p.tobuy'=>"OnBuy",'p.datec'=>'DateCreation','p.tms'=>'DateModification');
if ($mysoc->useNPR()) $this->export_fields_array[$r]['p.recuperableonly']='NPR';
if (! empty($conf->stock->enabled)) $this->export_fields_array[$r]=array_merge($this->export_fields_array[$r],array('p.stock'=>'Stock','p.pmp'=>'PMPValue'));
if (! empty($conf->barcode->enabled)) $this->export_fields_array[$r]=array_merge($this->export_fields_array[$r],array('p.barcode'=>'BarCode'));
if (! empty($conf->fournisseur->enabled)) $this->export_fields_array[$r]=array_merge($this->export_fields_array[$r],array('s.nom'=>'Supplier','pf.ref_fourn'=>'SupplierRef','pf.unitprice'=>'SuppliersPrices'));
$this->export_TypeFields_array[$r]=array('p.ref'=>"Text",'p.label'=>"Text",'p.description'=>"Text",'p.url'=>"Text",'p.accountancy_code_sell'=>"Text",'p.accountancy_code_buy'=>"Text",'p.note'=>"Text",'p.length'=>"Numeric",'p.surface'=>"Numeric",'p.volume'=>"Numeric",'p.weight'=>"Numeric",'p.customcode'=>'Text','p.price_base_type'=>"Text",'p.price'=>"Numeric",'p.price_ttc'=>"Numeric",'p.tva_tx'=>'Numeric','p.tosell'=>"Boolean",'p.tobuy'=>"Boolean",'p.datec'=>'Date','p.tms'=>'Date');
if (! empty($conf->stock->enabled)) $this->export_TypeFields_array[$r]=array_merge($this->export_TypeFields_array[$r],array('p.pmp'=>'Numeric'));
if (! empty($conf->stock->enabled)) $this->export_TypeFields_array[$r]=array_merge($this->export_TypeFields_array[$r],array('p.stock'=>'Numeric','p.pmp'=>'Numeric'));
if (! empty($conf->barcode->enabled)) $this->export_TypeFields_array[$r]=array_merge($this->export_TypeFields_array[$r],array('p.barcode'=>'Text'));
if (! empty($conf->fournisseur->enabled)) $this->export_TypeFields_array[$r]=array_merge($this->export_TypeFields_array[$r],array('s.nom'=>'Text','pf.ref_fourn'=>'Text','pf.unitprice'=>'Numeric'));
$this->export_entities_array[$r]=array('p.rowid'=>"product",'p.ref'=>"product",'p.label'=>"product",'p.description'=>"product",'p.url'=>"product",'p.accountancy_code_sell'=>'product','p.accountancy_code_sell'=>'product','p.note'=>"product",'p.length'=>"product",'p.surface'=>"product",'p.volume'=>"product",'p.weight'=>"product",'p.customcode'=>'product','p.price_base_type'=>"product",'p.price'=>"product",'p.price_ttc'=>"product",'p.tva_tx'=>"product",'p.tosell'=>"product",'p.tobuy'=>"product",'p.datec'=>"product",'p.tms'=>"product");
if (! empty($conf->stock->enabled)) $this->export_entities_array[$r]=array_merge($this->export_entities_array[$r],array('p.stock'=>'product','p.pmp'=>'product'));
if (! empty($conf->barcode->enabled)) $this->export_entities_array[$r]=array_merge($this->export_entities_array[$r],array('p.barcode'=>'product'));
if (! empty($conf->fournisseur->enabled)) $this->export_entities_array[$r]=array_merge($this->export_entities_array[$r],array('s.nom'=>'product','pf.ref_fourn'=>'product','pf.unitprice'=>'product'));
// Add extra fields
$sql="SELECT name, label, type FROM ".MAIN_DB_PREFIX."extrafields WHERE elementtype = 'product' AND entity IN (0, ".$conf->entity.')';
$resql=$this->db->query($sql);
if ($resql) // This can fail when class is used on old database (during migration for example)
{
while ($obj=$this->db->fetch_object($resql))
{
$fieldname='extra.'.$obj->name;
$fieldlabel=ucfirst($obj->label);
$typeFilter="Text";
switch($obj->type)
{
case 'int':
case 'double':
case 'price':
$typeFilter="Numeric";
break;
case 'date':
case 'datetime':
$typeFilter="Date";
break;
case 'boolean':
$typeFilter="Boolean";
break;
case 'sellist':
$tmp='';
$tmpparam=unserialize($obj->param); // $tmp ay be array 'options' => array 'c_currencies:code_iso:code_iso' => null
if ($tmpparam['options'] && is_array($tmpparam['options'])) $tmp=array_shift(array_keys($tmpparam['options']));
if (preg_match('/[a-z0-9_]+:[a-z0-9_]+:[a-z0-9_]+/', $tmp)) $typeFilter="List:".$tmp;
break;
}
$this->export_fields_array[$r][$fieldname]=$fieldlabel;
$this->export_TypeFields_array[$r][$fieldname]=$typeFilter;
$this->export_entities_array[$r][$fieldname]='product';
}
}
// End add extra fields
$keyforselect='product'; $keyforelement='product'; $keyforaliasextra='extra';
include DOL_DOCUMENT_ROOT.'/core/extrafieldsinexport.inc.php';
$this->export_sql_start[$r]='SELECT DISTINCT ';
$this->export_sql_end[$r] =' FROM '.MAIN_DB_PREFIX.'product as p';
$this->export_sql_end[$r] .=' LEFT JOIN '.MAIN_DB_PREFIX.'product_extrafields as extra ON p.rowid = extra.fk_object';
@ -216,12 +181,14 @@ class modProduct extends DolibarrModules
'pr.price_min'=>"MinPriceLevelUnitPriceHT",'pr.price_min_ttc'=>"MinPriceLevelUnitPriceTTC",
'pr.tva_tx'=>'PriceLevelVATRate',
'pr.date_price'=>'DateCreation');
if ($mysoc->useNPR()) $this->export_fields_array[$r]['pr.recuperableonly']='NPR';
//$this->export_TypeFields_array[$r]=array('p.ref'=>"Text",'p.label'=>"Text",'p.description'=>"Text",'p.url'=>"Text",'p.accountancy_code_sell'=>"Text",'p.accountancy_code_buy'=>"Text",'p.note'=>"Text",'p.length'=>"Numeric",'p.surface'=>"Numeric",'p.volume'=>"Numeric",'p.weight'=>"Numeric",'p.customcode'=>'Text','p.price_base_type'=>"Text",'p.price'=>"Numeric",'p.price_ttc'=>"Numeric",'p.tva_tx'=>'Numeric','p.tosell'=>"Boolean",'p.tobuy'=>"Boolean",'p.datec'=>'Date','p.tms'=>'Date');
$this->export_entities_array[$r]=array('p.rowid'=>"product",'p.ref'=>"product",
'pr.price_base_type'=>"product",'pr.price_level'=>"product",'pr.price'=>"product",
'pr.price_ttc'=>"product",
'pr.price_min'=>"product",'pr.price_min_ttc'=>"product",
'pr.tva_tx'=>'product',
'pr.recuperableonly'=>'product',
'pr.date_price'=>"product");
$this->export_sql_start[$r]='SELECT DISTINCT ';
$this->export_sql_end[$r] =' FROM '.MAIN_DB_PREFIX.'product as p';
@ -244,6 +211,7 @@ class modProduct extends DolibarrModules
$this->import_tables_creator_array[$r]=array('p'=>'fk_user_author'); // Fields to store import user id
$this->import_fields_array[$r]=array('p.ref'=>"Ref*",'p.label'=>"Label*",'p.description'=>"Description",'p.url'=>"PublicUrl",'p.accountancy_code_sell'=>"ProductAccountancySellCode",'p.accountancy_code_buy'=>"ProductAccountancyBuyCode",'p.note'=>"Note",'p.length'=>"Length",'p.surface'=>"Surface",'p.volume'=>"Volume",'p.weight'=>"Weight",'p.duration'=>"Duration",'p.customcode'=>'CustomCode','p.price'=>"SellingPriceHT",'p.price_ttc'=>"SellingPriceTTC",'p.tva_tx'=>'VAT','p.tosell'=>"OnSell*",'p.tobuy'=>"OnBuy*",'p.fk_product_type'=>"Type*",'p.finished'=>'Nature','p.datec'=>'DateCreation*');
if (! empty($conf->barcode->enabled)) $this->import_fields_array[$r]=array_merge($this->import_fields_array[$r],array('p.barcode'=>'BarCode'));
if ($mysoc->useNPR()) $this->import_fields_array[$r]=array_merge($this->import_fields_array[$r],array('p.recuperableonly'=>'NPR'));
// Add extra fields
$import_extrafield_sample=array();
$sql="SELECT name, label, fieldrequired FROM ".MAIN_DB_PREFIX."extrafields WHERE elementtype = 'product' AND entity IN (0, ".$conf->entity.')';
@ -260,8 +228,8 @@ class modProduct extends DolibarrModules
}
// End add extra fields
$this->import_fieldshidden_array[$r]=array('extra.fk_object'=>'lastrowid-'.MAIN_DB_PREFIX.'product'); // aliastable.field => ('user->id' or 'lastrowid-'.tableparent)
$this->import_regex_array[$r]=array('p.ref'=>'[^ ]','p.tosell'=>'^[0|1]$','p.tobuy'=>'^[0|1]$','p.fk_product_type'=>'^[0|1]$','p.datec'=>'^[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]$');
$import_sample=array('p.ref'=>"PREF123456",'p.label'=>"My product",'p.description'=>"This is a description example for record",'p.note'=>"Some note",'p.price'=>"100",'p.price_ttc'=>"110",'p.tva_tx'=>'10','p.tosell'=>"0 or 1",'p.tobuy'=>"0 or 1",'p.fk_product_type'=>"0 for product/1 for service",'p.finished'=>'','p.duration'=>"1y",'p.datec'=>'2008-12-31');
$this->import_regex_array[$r]=array('p.ref'=>'[^ ]','p.tosell'=>'^[0|1]$','p.tobuy'=>'^[0|1]$','p.fk_product_type'=>'^[0|1]$','p.datec'=>'^[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]$','p.recuperableonly'=>'^[0|1]$');
$import_sample=array('p.ref'=>"PREF123456",'p.label'=>"My product",'p.description'=>"This is a description example for record",'p.note'=>"Some note",'p.price'=>"100",'p.price_ttc'=>"110",'p.tva_tx'=>'10','p.tosell'=>"0 or 1",'p.tobuy'=>"0 or 1",'p.fk_product_type'=>"0 for product/1 for service",'p.finished'=>'','p.duration'=>"1y",'p.datec'=>'2008-12-31','p.recuperableonly'=>'0 or 1');
$this->import_examplevalues_array[$r]=array_merge($import_sample,$import_extrafield_sample);
if (! empty($conf->fournisseur->enabled))
@ -309,12 +277,14 @@ class modProduct extends DolibarrModules
'pr.price_min'=>"MinPriceLevelUnitPriceHT",'pr.price_min_ttc'=>"MinPriceLevelUnitPriceTTC",
'pr.tva_tx'=>'PriceLevelVATRate',
'pr.date_price'=>'DateCreation*');
$this->import_regex_array[$r]=array('pr.datec'=>'^[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]$');
if ($mysoc->useNPR()) $this->import_fields_array[$r]=array_merge($this->import_fields_array[$r],array('pr.recuperableonly'=>'NPR'));
$this->import_regex_array[$r]=array('pr.datec'=>'^[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]$','pr.recuperableonly'=>'^[0|1]$');
$this->import_examplevalues_array[$r]=array('pr.fk_product'=>"1",
'pr.price_base_type'=>"HT",'pr.price_level'=>"1",
'pr.price'=>"100",'pr.price_ttc'=>"110",
'pr.price_min'=>"100",'pr.price_min_ttc'=>"110",
'pr.tva_tx'=>'19.6',
'pr.tva_tx'=>'20',
'pr.recuperableonly'=>'0',
'pr.date_price'=>'2013-04-10');
}

View File

@ -30,6 +30,7 @@ $langs->load("sendings");
$langs->load("deliveries");
$langs->load('companies');
$socid=GETPOST('socid','int');
// Security check
$expeditionid = GETPOST('id','int');
if ($user->societe_id) $socid=$user->societe_id;

View File

@ -836,6 +836,7 @@ if ($step == 4 && $datatoimport)
print '</td><td width="50%">';
// List of targets fields
$height=24;
$i = 0;
$var=true;
$mandatoryfieldshavesource=true;
@ -843,7 +844,7 @@ if ($step == 4 && $datatoimport)
foreach($fieldstarget as $code=>$label)
{
$var=!$var;
print '<tr '.$bc[$var].' height="20">';
print '<tr '.$bc[$var].' height="'.$height.'">';
$i++;
@ -1704,13 +1705,15 @@ function show_elem($fieldssource,$pos,$key,$var,$nostyle='')
{
global $langs,$bc;
$height='24';
print "\n\n<!-- Box ".$pos." start -->\n";
print '<div class="box" style="padding: 0px 0px 0px 0px;" id="boxto_'.$pos.'">'."\n";
print '<table summary="boxtable'.$pos.'" width="100%" class="nobordernopadding">'."\n";
if ($pos && $pos > count($fieldssource)) // No fields
{
print '<tr '.($nostyle?'':$bc[$var]).' height="20">';
print '<tr '.($nostyle?'':$bc[$var]).' height="'.$height.'">';
print '<td class="nocellnopadding" width="16" style="font-weight: normal">';
print img_picto(($pos>0?$langs->trans("MoveField",$pos):''),'uparrow','class="boxhandle" style="cursor:move;"');
print '</td>';
@ -1721,7 +1724,7 @@ function show_elem($fieldssource,$pos,$key,$var,$nostyle='')
}
elseif ($key == 'none') // Empty line
{
print '<tr '.($nostyle?'':$bc[$var]).' height="20">';
print '<tr '.($nostyle?'':$bc[$var]).' height="'.$height.'">';
print '<td class="nocellnopadding" width="16" style="font-weight: normal">';
print '&nbsp;';
print '</td>';
@ -1732,7 +1735,7 @@ function show_elem($fieldssource,$pos,$key,$var,$nostyle='')
}
else // Print field of source file
{
print '<tr '.($nostyle?'':$bc[$var]).' height="20">';
print '<tr '.($nostyle?'':$bc[$var]).' height="'.$height.'">';
print '<td class="nocellnopadding" width="16" style="font-weight: normal">';
// 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;"');

View File

@ -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=لم يتم تعريف <b>المعلمة٪ الصورة</b> داخل ملف التكوين Dolibarr <b>conf.php.</b>
ErrorCantLoadUserFromDolibarrDatabase=فشل في العثور على <b>المستخدم٪ الصورة</b> في قاعدة بيانات Dolibarr.
ErrorNoVATRateDefinedForSellerCountry=خطأ، لا معدلات ضريبة القيمة المضافة المحددة للبلد '٪ ق'.
ErrorNoSocialContributionForSellerCountry=خطأ، لا الاجتماعي / المالي نوع الضرائب المحددة للبلد '٪ ق'.
ErrorConfigParameterNotDefined=Parameter <b>%s</b> is not defined inside Dolibarr config file <b>conf.php</b>.
ErrorCantLoadUserFromDolibarrDatabase=Failed to find user <b>%s</b> 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 وضع مصادقة هو الإعداد <b>إلى٪</b> s في ملف التكوين <b>conf.php.</b> <br> وهذا يعني أن قاعدة بيانات كلمة السر هي خارجي لDolibarr، لذلك تغيير هذا المجال يمكن أن يكون لها أي آثار.
DolibarrInHttpAuthenticationSoPasswordUseless=Dolibarr authentication mode is setup to <b>%s</b> in configuration file <b>conf.php</b>.<br>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 الإعداد للحد من دقة أسعار الوحدات إلى <b>العشرية٪ الصورة.</b>
PrecisionUnitIsLimitedToXDecimals=Dolibarr was setup to limit precision of unit prices to <b>%s</b> decimals.
DoTest=اختبار
ToFilter=فلتر
NoFilter=No filter
@ -140,7 +140,7 @@ AddActionDone=إضافة حدث القيام به
Close=إغلاق
Close2=إغلاق
Confirm=تأكيد
ConfirmSendCardByMail=هل تريد حقا أن ترسل محتوى هذه البطاقة عن طريق البريد <b>إلى٪</b> s؟
ConfirmSendCardByMail=Do you really want to send content of this card by mail to <b>%s</b> ?
Delete=حذف
Remove=إزالة
Resiliate=Resiliate
@ -218,7 +218,7 @@ Limit=حد
Limits=حدود
DevelopmentTeam=فريق التطوير
Logout=تسجيل خروج
NoLogoutProcessWithAuthMode=أي ميزة قطع تطبيقية مع وضع <b>المصادقة٪ الصورة</b>
NoLogoutProcessWithAuthMode=No applicative disconnect feature with authentication mode <b>%s</b>
Connection=الاتصال
Setup=التثبيت
Alert=إنذار
@ -388,15 +388,15 @@ ContactsAddressesForCompany=اتصالات / عناوين لهذا الطرف ا
AddressesForCompany=عناوين لهذا الطرف الثالث
ActionsOnCompany=الأحداث حول هذا الطرف الثالث
ActionsOnMember=الأحداث عن هذا العضو
NActions=الأحداث٪ الصورة
NActionsLate=٪ في وقت متأخر الصورة
NActions=%s events
NActionsLate=%s late
RequestAlreadyDone=طلب المسجل بالفعل
Filter=فلتر
FilterOnInto=معايير البحث <strong>'٪ ق'</strong> إلى حقول٪ الصورة
FilterOnInto=Search criteria '<strong>%s</strong>' 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=حفظ الملف على الخادم مع اسم <strong>"٪ ق"</strong> (وإلا "٪ ق")
SaveUploadedFileWithMask=حفظ الملف على الخادم مع اسم <strong>"%s"</strong> (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=رفض

View File

@ -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)

View File

@ -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 '<td align="center">' . $langs->trans("PriceBase") . '</td>';
if (! empty($conf->global->PRODUIT_MULTIPRICES_USE_VAT_PER_LEVEL) || ! empty($conf->global->PRODUIT_CUSTOMER_PRICES_BY_QTY)) print '<td align="right">' . $langs->trans("VATRate") . '</td>';
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 '<td align="right">' . $langs->trans("VATRate") . '</td>';
print '<td align="right">' . $langs->trans("HT") . '</td>';
print '<td align="right">' . $langs->trans("TTC") . '</td>';
if (! empty($conf->dynamicprices->enabled)) {
@ -1098,7 +1098,7 @@ if ($result)
}
print '<td align="center">' . $langs->trans($objp->price_base_type) . "</td>";
if (! empty($conf->global->PRODUIT_MULTIPRICES_USE_VAT_PER_LEVEL) || ! empty($conf->global->PRODUIT_CUSTOMER_PRICES_BY_QTY)) print '<td align="right">' . vatrate($objp->tva_tx, true, $objp->recuperableonly) . "</td>";
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 '<td align="right">' . vatrate($objp->tva_tx, true, $objp->recuperableonly) . "</td>";
//Price
if (! empty($objp->fk_price_expression) && ! empty($conf->dynamicprices->enabled))

View File

@ -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).
*