Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop
This commit is contained in:
commit
5ea03e7448
@ -440,7 +440,7 @@ if (GETPOST('actionadd') || GETPOST('actionmodify'))
|
||||
}
|
||||
// Clean some parameters
|
||||
if (isset($_POST["localtax1"]) && empty($_POST["localtax1"])) $_POST["localtax1"]='0'; // If empty, we force to 0
|
||||
if (isset($_POST["localtax2"]) && empty($_POST["localtax2"])) $_POST["localtax2"]='0'; // If empty, we force to 0
|
||||
if (isset($_POST["localtax2"]) && empty($_POST["localtax2"])) $_POST["localtax2"]='0'; // If empty, we force to 0
|
||||
|
||||
// Si verif ok et action add, on ajoute la ligne
|
||||
if ($ok && GETPOST('actionadd'))
|
||||
@ -814,7 +814,7 @@ if ($id)
|
||||
/*
|
||||
$tmparray=getLabelOfField($fieldlist[$field]);
|
||||
$showfield=$tmp['showfield'];
|
||||
$valuetoshow=$tmp['valuetoshow'];
|
||||
$valuetoshow=$tmp['valuetoshow'];
|
||||
$align=$tmp['align'];
|
||||
$sortable=$tmp['sortable'];
|
||||
*/
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/* Copyright (C) 2001-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2005-2010 Regis Houssin <regis@dolibarr.fr>
|
||||
/* Copyright (C) 2001-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2005-2012 Regis Houssin <regis@dolibarr.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -76,6 +76,7 @@ if ($action == 'update')
|
||||
|
||||
// This one is not always defined
|
||||
if (isset($_POST["MAIN_USE_PREVIEW_TABS"])) dolibarr_set_const($db, "MAIN_USE_PREVIEW_TABS", $_POST["MAIN_USE_PREVIEW_TABS"],'chaine',0,'',$conf->entity);
|
||||
if (isset($_POST["MAIN_BUGTRACK_ENABLELINK"])) dolibarr_set_const($db, "MAIN_BUGTRACK_ENABLELINK", $_POST["MAIN_BUGTRACK_ENABLELINK"],'chaine',0,'',$conf->entity);
|
||||
|
||||
$_SESSION["mainmenu"]=""; // Le gestionnaire de menu a pu changer
|
||||
|
||||
@ -235,6 +236,17 @@ if ($action == 'edit') // Edit
|
||||
print '<td width="20"> </td>';
|
||||
print '</tr>';
|
||||
|
||||
if ($conf->global->MAIN_FEATURES_LEVEL > 1)
|
||||
{
|
||||
// Show bugtrack link
|
||||
$var=!$var;
|
||||
print '<tr '.$bc[$var].'><td width="35%">'.$langs->trans("ShowBugTrackLink").'</td><td>';
|
||||
print $form->selectyesno('MAIN_BUGTRACK_ENABLELINK',$conf->global->MAIN_BUGTRACK_ENABLELINK,1);
|
||||
print '</td>';
|
||||
print '<td width="20"> </td>';
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
// Message on login page
|
||||
$var=!$var;
|
||||
print '<tr '.$bc[$var].'><td width="35%">'.$langs->trans("MessageLogin").'</td><td colspan="2">';
|
||||
@ -378,6 +390,16 @@ else // Show
|
||||
print yn((isset($conf->global->MAIN_HELP_DISABLELINK)?$conf->global->MAIN_HELP_DISABLELINK:0),1);
|
||||
print '</td></tr>';
|
||||
|
||||
if ($conf->global->MAIN_FEATURES_LEVEL > 1)
|
||||
{
|
||||
// Show bugtrack link
|
||||
$var=!$var;
|
||||
print '<tr '.$bc[$var].'"><td width="35%">'.$langs->trans("ShowBugTrackLink").'</td><td>';
|
||||
print yn($conf->global->MAIN_BUGTRACK_ENABLELINK)."</td>";
|
||||
print '<td width="20"> </td>';
|
||||
print "</tr>";
|
||||
}
|
||||
|
||||
// Message login
|
||||
$var=!$var;
|
||||
print '<tr '.$bc[$var].'><td width="35%">'.$langs->trans("MessageLogin").'</td><td colspan="2">';
|
||||
|
||||
@ -263,21 +263,21 @@ class Contact extends CommonObject
|
||||
unset($this->state_code);
|
||||
unset($this->state);
|
||||
|
||||
// Actions on extra fields (by external module or standard code)
|
||||
include_once DOL_DOCUMENT_ROOT.'/core/class/hookmanager.class.php';
|
||||
$hookmanager=new HookManager($this->db);
|
||||
$hookmanager->initHooks(array('contactdao'));
|
||||
$parameters=array('socid'=>$this->id);
|
||||
$reshook=$hookmanager->executeHooks('insertExtraFields',$parameters,$this,$action); // Note that $action and $object may have been modified by some hooks
|
||||
if (empty($reshook))
|
||||
// Actions on extra fields (by external module or standard code)
|
||||
include_once DOL_DOCUMENT_ROOT.'/core/class/hookmanager.class.php';
|
||||
$hookmanager=new HookManager($this->db);
|
||||
$hookmanager->initHooks(array('contactdao'));
|
||||
$parameters=array('socid'=>$this->id);
|
||||
$reshook=$hookmanager->executeHooks('insertExtraFields',$parameters,$this,$action); // Note that $action and $object may have been modified by some hooks
|
||||
if (empty($reshook))
|
||||
{
|
||||
$result=$this->insertExtraFields();
|
||||
if ($result < 0)
|
||||
{
|
||||
$error++;
|
||||
}
|
||||
}
|
||||
else if ($reshook < 0) $error++;
|
||||
$result=$this->insertExtraFields();
|
||||
if ($result < 0)
|
||||
{
|
||||
$error++;
|
||||
}
|
||||
}
|
||||
else if ($reshook < 0) $error++;
|
||||
|
||||
if (! $error && ! $notrigger)
|
||||
{
|
||||
|
||||
@ -31,7 +31,7 @@ require_once DOL_DOCUMENT_ROOT.'/contact/class/contact.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/contact.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php';
|
||||
|
||||
$langs->load("companies");
|
||||
$langs->load("users");
|
||||
@ -48,7 +48,7 @@ $socid = GETPOST('socid','int');
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
|
||||
$object = new Contact($db);
|
||||
$extrafields = new ExtraFields($db);
|
||||
$extrafields = new ExtraFields($db);
|
||||
|
||||
// Get object canvas (By default, this is not defined, so standard usage of dolibarr)
|
||||
$object->getCanvas($id);
|
||||
@ -76,7 +76,7 @@ $hookmanager->initHooks(array('contactcard'));
|
||||
|
||||
$parameters=array('id'=>$id, 'objcanvas'=>$objcanvas);
|
||||
$reshook=$hookmanager->executeHooks('doActions',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
|
||||
$error=$hookmanager->error; $errors=array_merge($errors, (array) $hookmanager->errors);
|
||||
$error=$hookmanager->error; $errors=array_merge($errors, (array) $hookmanager->errors);
|
||||
|
||||
if (empty($reshook))
|
||||
{
|
||||
@ -254,14 +254,14 @@ if (empty($reshook))
|
||||
$object->priv = $_POST["priv"];
|
||||
$object->note = $_POST["note"];
|
||||
|
||||
// Get extra fields
|
||||
foreach($_POST as $key => $value)
|
||||
{
|
||||
if (preg_match("/^options_/",$key))
|
||||
{
|
||||
$object->array_options[$key]=GETPOST($key);
|
||||
}
|
||||
}
|
||||
// Get extra fields
|
||||
foreach($_POST as $key => $value)
|
||||
{
|
||||
if (preg_match("/^options_/",$key))
|
||||
{
|
||||
$object->array_options[$key]=GETPOST($key);
|
||||
}
|
||||
}
|
||||
|
||||
$result = $object->update($_POST["contactid"], $user);
|
||||
|
||||
@ -285,8 +285,8 @@ if (empty($reshook))
|
||||
* View
|
||||
*/
|
||||
|
||||
// fetch optionals attributes and labels
|
||||
$extralabels=$extrafields->fetch_name_optionals_label('contact');
|
||||
// fetch optionals attributes and labels
|
||||
$extralabels=$extrafields->fetch_name_optionals_label('contact');
|
||||
|
||||
$help_url='EN:Module_Third_Parties|FR:Module_Tiers|ES:Empresas';
|
||||
llxHeader('',$langs->trans("ContactsAddresses"),$help_url);
|
||||
@ -492,20 +492,20 @@ else
|
||||
// Note
|
||||
print '<tr><td valign="top">'.$langs->trans("Note").'</td><td colspan="3" valign="top"><textarea name="note" cols="70" rows="'.ROWS_3.'">'.(isset($_POST["note"])?$_POST["note"]:$object->note).'</textarea></td></tr>';
|
||||
|
||||
// Other attributes
|
||||
$parameters=array('colspan' => ' colspan="3"');
|
||||
$reshook=$hookmanager->executeHooks('formObjectOptions',$parameters,$object,$action); // Note that $action and $object may have been modified by hook
|
||||
if (empty($reshook) && ! empty($extrafields->attribute_label))
|
||||
{
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:(isset($object->array_options["options_".$key])?$object->array_options["options_".$key]:''));
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
}
|
||||
|
||||
// Other attributes
|
||||
$parameters=array('colspan' => ' colspan="3"');
|
||||
$reshook=$hookmanager->executeHooks('formObjectOptions',$parameters,$object,$action); // Note that $action and $object may have been modified by hook
|
||||
if (empty($reshook) && ! empty($extrafields->attribute_label))
|
||||
{
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:(isset($object->array_options["options_".$key])?$object->array_options["options_".$key]:''));
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
}
|
||||
|
||||
print "</table><br>";
|
||||
|
||||
|
||||
@ -688,20 +688,20 @@ else
|
||||
print isset($_POST["note"])?$_POST["note"]:$object->note;
|
||||
print '</textarea></td></tr>';
|
||||
|
||||
// Other attributes
|
||||
$parameters=array('colspan' => ' colspan="3"');
|
||||
$reshook=$hookmanager->executeHooks('formObjectOptions',$parameters,$object,$action); // Note that $action and $object may have been modified by hook
|
||||
if (empty($reshook) && ! empty($extrafields->attribute_label))
|
||||
{
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print "</td></tr>\n";
|
||||
}
|
||||
}
|
||||
|
||||
// Other attributes
|
||||
$parameters=array('colspan' => ' colspan="3"');
|
||||
$reshook=$hookmanager->executeHooks('formObjectOptions',$parameters,$object,$action); // Note that $action and $object may have been modified by hook
|
||||
if (empty($reshook) && ! empty($extrafields->attribute_label))
|
||||
{
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print "</td></tr>\n";
|
||||
}
|
||||
}
|
||||
|
||||
$object->load_ref_elements();
|
||||
|
||||
if (! empty($conf->commande->enabled))
|
||||
@ -898,20 +898,20 @@ else
|
||||
print nl2br($object->note);
|
||||
print '</td></tr>';
|
||||
|
||||
// Other attributes
|
||||
$parameters=array('socid'=>$socid, 'colspan' => ' colspan="3"');
|
||||
$reshook=$hookmanager->executeHooks('formObjectOptions',$parameters,$object,$action); // Note that $action and $object may have been modified by hook
|
||||
if (empty($reshook) && ! empty($extrafields->attribute_label))
|
||||
{
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:(isset($object->array_options['options_'.$key])?$object->array_options['options_'.$key]:''));
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showOutputField($key,$value);
|
||||
print "</td></tr>\n";
|
||||
}
|
||||
}
|
||||
|
||||
// Other attributes
|
||||
$parameters=array('socid'=>$socid, 'colspan' => ' colspan="3"');
|
||||
$reshook=$hookmanager->executeHooks('formObjectOptions',$parameters,$object,$action); // Note that $action and $object may have been modified by hook
|
||||
if (empty($reshook) && ! empty($extrafields->attribute_label))
|
||||
{
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:(isset($object->array_options['options_'.$key])?$object->array_options['options_'.$key]:''));
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showOutputField($key,$value);
|
||||
print "</td></tr>\n";
|
||||
}
|
||||
}
|
||||
|
||||
$object->load_ref_elements();
|
||||
|
||||
if (! empty($conf->commande->enabled))
|
||||
|
||||
@ -450,46 +450,49 @@ class FormFile
|
||||
}
|
||||
|
||||
// Loop on each file found
|
||||
foreach($file_list as $file)
|
||||
{
|
||||
$var=!$var;
|
||||
if (is_array($file_list))
|
||||
{
|
||||
foreach($file_list as $file)
|
||||
{
|
||||
$var=!$var;
|
||||
|
||||
// Define relative path for download link (depends on module)
|
||||
$relativepath=$file["name"]; // Cas general
|
||||
if ($filename) $relativepath=$filename."/".$file["name"]; // Cas propal, facture...
|
||||
// Autre cas
|
||||
if ($modulepart == 'donation') { $relativepath = get_exdir($filename,2).$file["name"]; }
|
||||
if ($modulepart == 'export') { $relativepath = $file["name"]; }
|
||||
// Define relative path for download link (depends on module)
|
||||
$relativepath=$file["name"]; // Cas general
|
||||
if ($filename) $relativepath=$filename."/".$file["name"]; // Cas propal, facture...
|
||||
// Autre cas
|
||||
if ($modulepart == 'donation') { $relativepath = get_exdir($filename,2).$file["name"]; }
|
||||
if ($modulepart == 'export') { $relativepath = $file["name"]; }
|
||||
|
||||
$out.= "<tr ".$bc[$var].">";
|
||||
$out.= "<tr ".$bc[$var].">";
|
||||
|
||||
// Show file name with link to download
|
||||
$out.= '<td nowrap="nowrap">';
|
||||
$out.= '<a href="'.DOL_URL_ROOT . '/document.php?modulepart='.$modulepart.'&file='.urlencode($relativepath).'"';
|
||||
$mime=dol_mimetype($relativepath,'',0);
|
||||
if (preg_match('/text/',$mime)) $out.= ' target="_blank"';
|
||||
$out.= '>';
|
||||
$out.= img_mime($file["name"],$langs->trans("File").': '.$file["name"]).' '.dol_trunc($file["name"],$maxfilenamelength);
|
||||
$out.= '</a>'."\n";
|
||||
$out.= '</td>';
|
||||
// Show file name with link to download
|
||||
$out.= '<td nowrap="nowrap">';
|
||||
$out.= '<a href="'.DOL_URL_ROOT . '/document.php?modulepart='.$modulepart.'&file='.urlencode($relativepath).'"';
|
||||
$mime=dol_mimetype($relativepath,'',0);
|
||||
if (preg_match('/text/',$mime)) $out.= ' target="_blank"';
|
||||
$out.= '>';
|
||||
$out.= img_mime($file["name"],$langs->trans("File").': '.$file["name"]).' '.dol_trunc($file["name"],$maxfilenamelength);
|
||||
$out.= '</a>'."\n";
|
||||
$out.= '</td>';
|
||||
|
||||
// Show file size
|
||||
$size=(! empty($file['size'])?$file['size']:dol_filesize($filedir."/".$file["name"]));
|
||||
$out.= '<td align="right" nowrap="nowrap">'.dol_print_size($size).'</td>';
|
||||
// Show file size
|
||||
$size=(! empty($file['size'])?$file['size']:dol_filesize($filedir."/".$file["name"]));
|
||||
$out.= '<td align="right" nowrap="nowrap">'.dol_print_size($size).'</td>';
|
||||
|
||||
// Show file date
|
||||
$date=(! empty($file['date'])?$file['date']:dol_filemtime($filedir."/".$file["name"]));
|
||||
$out.= '<td align="right" nowrap="nowrap">'.dol_print_date($date, 'dayhour','tzuser').'</td>';
|
||||
// Show file date
|
||||
$date=(! empty($file['date'])?$file['date']:dol_filemtime($filedir."/".$file["name"]));
|
||||
$out.= '<td align="right" nowrap="nowrap">'.dol_print_date($date, 'dayhour').'</td>';
|
||||
|
||||
if ($delallowed)
|
||||
{
|
||||
$out.= '<td align="right">';
|
||||
$out.= '<a href="'.$urlsource.(strpos($urlsource,'?')?'&':'?').'action=remove_file&file='.urlencode($relativepath);
|
||||
$out.= ($param?'&'.$param:'');
|
||||
//$out.= '&modulepart='.$modulepart; // TODO obsolete ?
|
||||
//$out.= '&urlsource='.urlencode($urlsource); // TODO obsolete ?
|
||||
$out.= '">'.img_delete().'</a></td>';
|
||||
}
|
||||
if ($delallowed)
|
||||
{
|
||||
$out.= '<td align="right">';
|
||||
$out.= '<a href="'.$urlsource.(strpos($urlsource,'?')?'&':'?').'action=remove_file&file='.urlencode($relativepath);
|
||||
$out.= ($param?'&'.$param:'');
|
||||
//$out.= '&modulepart='.$modulepart; // TODO obsolete ?
|
||||
//$out.= '&urlsource='.urlencode($urlsource); // TODO obsolete ?
|
||||
$out.= '">'.img_delete().'</a></td>';
|
||||
}
|
||||
}
|
||||
|
||||
$out.= '</tr>';
|
||||
|
||||
|
||||
@ -906,12 +906,12 @@ function dol_meta_create($object)
|
||||
// Define parent dir of elements
|
||||
$element=$object->element;
|
||||
|
||||
if ($object->element == 'order_supplier') $dir = $conf->fournisseur->dir_output.'/commande';
|
||||
elseif ($object->element == 'invoice_supplier') $dir = $conf->fournisseur->dir_output.'/facture';
|
||||
elseif ($object->element == 'project') $dir = $conf->projet->dir_output;
|
||||
elseif ($object->element == 'shipping') $dir = $conf->expedition->dir_output.'/sending';
|
||||
elseif ($object->element == 'delivery') $dir = $conf->expedition->dir_output.'/receipt';
|
||||
elseif ($object->element == 'fichinter') $dir = $conf->ficheinter->dir_output;
|
||||
if ($object->element == 'order_supplier') $dir = $conf->fournisseur->dir_output.'/commande';
|
||||
elseif ($object->element == 'invoice_supplier') $dir = $conf->fournisseur->dir_output.'/facture';
|
||||
elseif ($object->element == 'project') $dir = $conf->projet->dir_output;
|
||||
elseif ($object->element == 'shipping') $dir = $conf->expedition->dir_output.'/sending';
|
||||
elseif ($object->element == 'delivery') $dir = $conf->expedition->dir_output.'/receipt';
|
||||
elseif ($object->element == 'fichinter') $dir = $conf->ficheinter->dir_output;
|
||||
else $dir=empty($conf->$element->dir_output)?'':$conf->$element->dir_output;
|
||||
|
||||
if ($dir)
|
||||
|
||||
@ -262,7 +262,7 @@ class pdf_einstein extends ModelePDFCommandes
|
||||
{
|
||||
$curY = $nexY;
|
||||
$pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
|
||||
$pdf->setTopMargin($tab_top_newpage);
|
||||
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
|
||||
|
||||
@ -206,7 +206,7 @@ class pdf_expedition_merou extends ModelePdfExpedition
|
||||
{
|
||||
$curY = $nexY;
|
||||
$pdf->SetFont('','', $default_font_size - 3);
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
|
||||
$pdf->setTopMargin($tab_top_newpage);
|
||||
$pdf->setPageOrientation('', 1, $heightforfooter); // The only function to edit the bottom margin of current page to set it.
|
||||
|
||||
@ -233,7 +233,7 @@ class pdf_expedition_rouget extends ModelePdfExpedition
|
||||
{
|
||||
$curY = $nexY;
|
||||
$pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
|
||||
$pdf->setTopMargin($tab_top_newpage);
|
||||
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
|
||||
|
||||
@ -265,7 +265,7 @@ class pdf_crabe extends ModelePDFFactures
|
||||
{
|
||||
$curY = $nexY;
|
||||
$pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
|
||||
$pdf->setTopMargin($tab_top_newpage);
|
||||
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
|
||||
|
||||
@ -246,7 +246,7 @@ class pdf_soleil extends ModelePDFFicheinter
|
||||
{
|
||||
$curY = $nexY;
|
||||
$pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
|
||||
$pdf->setTopMargin($tab_top_newpage);
|
||||
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
|
||||
|
||||
@ -184,7 +184,7 @@ class pdf_sirocco extends ModelePDFDeliveryOrder
|
||||
{
|
||||
$curY = $nexY;
|
||||
$pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
|
||||
$pdf->setTopMargin($tab_top_newpage);
|
||||
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
|
||||
|
||||
@ -239,7 +239,7 @@ class pdf_typhon extends ModelePDFDeliveryOrder
|
||||
{
|
||||
$curY = $nexY;
|
||||
$pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
|
||||
$pdf->setTopMargin($tab_top_newpage);
|
||||
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot-50); // The only function to edit the bottom margin of current page to set it.
|
||||
|
||||
@ -263,7 +263,7 @@ class pdf_azur extends ModelePDFPropales
|
||||
{
|
||||
$curY = $nexY;
|
||||
$pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
|
||||
$pdf->setTopMargin($tab_top_newpage);
|
||||
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
|
||||
|
||||
@ -260,7 +260,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
|
||||
{
|
||||
$curY = $nexY;
|
||||
$pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
|
||||
$pdf->setTopMargin($tab_top_newpage);
|
||||
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
|
||||
|
||||
@ -272,7 +272,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
|
||||
{
|
||||
$curY = $nexY;
|
||||
$pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
|
||||
$pdf->setTopMargin($tab_top_newpage);
|
||||
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
|
||||
|
||||
@ -142,8 +142,7 @@ if (! empty($conf->margin->enabled)) {
|
||||
$("#idprod").change(function() {
|
||||
$("#fournprice options").remove();
|
||||
$("#fournprice").hide();
|
||||
$("#buying_price").val("");
|
||||
$("#buying_price").show();
|
||||
$("#buying_price").val("").show();
|
||||
$.post('<?php echo DOL_URL_ROOT; ?>/fourn/ajax/getSupplierPrices.php', {'idprod': $(this).val()}, function(data) {
|
||||
if (data && data.length > 0) {
|
||||
var options = '';
|
||||
@ -158,9 +157,8 @@ $("#idprod").change(function() {
|
||||
options += '>'+this.label+'</option>';
|
||||
});
|
||||
options += '<option value=null><?php echo $langs->trans("InputPrice"); ?></option>';
|
||||
$("#fournprice").html(options);
|
||||
$("#buying_price").hide();
|
||||
$("#fournprice").show();
|
||||
$("#fournprice").html(options).show();
|
||||
$("#fournprice").change(function() {
|
||||
var selval = $(this).find('option:selected').attr("price");
|
||||
if (selval)
|
||||
|
||||
@ -1905,7 +1905,7 @@ class CommandeFournisseurLigne
|
||||
var $total_localtax2;
|
||||
var $total_ttc;
|
||||
var $info_bits;
|
||||
var $special_code;
|
||||
var $special_code;
|
||||
|
||||
// From llx_product
|
||||
var $libelle; // Label produit
|
||||
|
||||
@ -266,7 +266,7 @@ print '<br>';
|
||||
|
||||
print_fiche_titre($langs->trans('TitleOptionMainCP'),'','');
|
||||
|
||||
dol_fiche_head(array(),'','');
|
||||
dol_fiche_head(array(),'','');
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER['PHP_SELF'].'?leftmenu=setup" name="config">'."\n";
|
||||
print '<input type="hidden" name="action" value="add" />'."\n";
|
||||
@ -334,13 +334,13 @@ print '</table>'."\n";
|
||||
print '<div align="center"><input type="submit" value="'.$langs->trans("ConfirmConfigCP").'" name="bouton" class="button"/></div>'."\n";
|
||||
print '</form>'."\n\n";
|
||||
|
||||
dol_fiche_end();
|
||||
dol_fiche_end();
|
||||
|
||||
print '<br>';
|
||||
|
||||
print_fiche_titre($langs->trans('TitleOptionEventCP'),'','');
|
||||
|
||||
dol_fiche_head(array(),'','');
|
||||
dol_fiche_head(array(),'','');
|
||||
|
||||
|
||||
$cp_events = $cp->fetchEventsCP();
|
||||
|
||||
@ -190,10 +190,10 @@ INSERT INTO llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) VALUES (20
|
||||
INSERT INTO llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) VALUES (2023, 202, '0', '0', 'VAT Rate 0', 1);
|
||||
|
||||
-- SPAIN (id country=4)
|
||||
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,localtax1,localtax1_type,note,active) values ( 41, 4, '21','0','5.2','1','VAT standard rate',1);
|
||||
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,localtax1,localtax1_type,note,active) values ( 42, 4, '10','0','1.4','1','VAT reduced rate',1);
|
||||
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,localtax1,localtax1_type,note,active) values ( 43, 4, '4','0','0.5','1','VAT super-reduced rate',1);
|
||||
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) values ( 44, 4, '0','0','VAT Rate 0',1);
|
||||
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,localtax1,localtax1_type,localtax2,localtax2_type,note,active) values ( 41, 4,'21','0','5.2','3','-15','1','VAT standard rate',1);
|
||||
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,localtax1,localtax1_type,localtax2,localtax2_type,note,active) values ( 42, 4,'10','0','1.4','3','-15','1','VAT reduced rate',1);
|
||||
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,localtax1,localtax1_type,localtax2,localtax2_type,note,active) values ( 43, 4, '4','0','0.5','3','-15','1','VAT super-reduced rate',1);
|
||||
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,localtax1,localtax1_type,localtax2,localtax2_type,note,active) values ( 44, 4, '0','0', '0','3','-15','1','VAT Rate 0',1);
|
||||
|
||||
-- SWEDEN (id country=20)
|
||||
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) values (201,20, '25','0','VAT standard rate',1);
|
||||
|
||||
@ -1512,7 +1512,7 @@ function left_menu($menu_array_before, $helppagename='', $moresearchform='', $me
|
||||
}
|
||||
|
||||
// Link to bugtrack
|
||||
if (! empty($conf->global->MAIN_SHOW_BUGTRACK_LINK))
|
||||
if (! empty($conf->global->MAIN_BUGTRACK_ENABLELINK))
|
||||
{
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php';
|
||||
|
||||
|
||||
@ -146,7 +146,7 @@ if ($action == 'create')
|
||||
print "<br>";
|
||||
print_titre($langs->trans('NewAttribute'));
|
||||
|
||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields.tpl.php';
|
||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields.tpl.php';
|
||||
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'" method="post">';
|
||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||
|
||||
@ -134,7 +134,7 @@ if ($id > 0 || ! empty($ref))
|
||||
print '<br>';
|
||||
|
||||
$colwidth=30;
|
||||
include DOL_DOCUMENT_ROOT.'/core/tpl/notes.tpl.php';
|
||||
include DOL_DOCUMENT_ROOT.'/core/tpl/notes.tpl.php';
|
||||
|
||||
dol_fiche_end();;
|
||||
}
|
||||
|
||||
@ -354,10 +354,10 @@ else
|
||||
//var_dump($tasksarray);
|
||||
//var_dump($tasksrole);
|
||||
|
||||
if (! empty($conf->use_javascript_ajax))
|
||||
if (! empty($conf->use_javascript_ajax))
|
||||
{
|
||||
include DOL_DOCUMENT_ROOT.'/core/tpl/ajaxrow.tpl.php';
|
||||
}
|
||||
include DOL_DOCUMENT_ROOT.'/core/tpl/ajaxrow.tpl.php';
|
||||
}
|
||||
|
||||
print '<table id="tablelines" class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
|
||||
Loading…
Reference in New Issue
Block a user