This commit is contained in:
Florian Henry 2013-06-09 16:56:47 +02:00
commit 4f438224d7
23 changed files with 119 additions and 131 deletions

View File

@ -55,6 +55,7 @@ if ( GETPOST('filtre') ) {
}
$i++;
}
$db->free($resql);
}
else
{
@ -90,6 +91,7 @@ if ( GETPOST('filtre') ) {
}
$i++;
}
$db->free($resql);
}
else
{
@ -147,6 +149,7 @@ if ($res)
}
$i++;
}
$db->free($resql);
}
else
{

View File

@ -494,7 +494,11 @@ if ($action == 'create')
print '<tr><td width="10%">'.$langs->trans("Status").' / '.$langs->trans("Percentage").'</td>';
print '<td>';
$percent=-1;
if (isset($_GET['percentage']) || isset($_POST['percentage']))
if (isset($_GET['status']) || isset($_POST['status']))
{
$percent=GETPOST('status');
}
else if (isset($_GET['percentage']) || isset($_POST['percentage']))
{
$percent=GETPOST('percentage');
}

View File

@ -53,7 +53,8 @@ $endyear=$year;
$form=new Form($db);
$langs->load("propal");
$langs->load('propal');
$langs->load('other');
llxHeader();

View File

@ -51,7 +51,8 @@ $year = GETPOST('year')>0?GETPOST('year'):$nowyear;
$startyear=$year-1;
$endyear=$year;
$langs->load("orders");
$langs->load('orders');
$langs->load('other');
/*

View File

@ -65,7 +65,7 @@ if ($action == 'add')
{
if (! GETPOST('titre'))
{
setEventMessage($langs->trans("ErrorFieldRequired",$langs->trans("Title")), 'errors');
setEventMessage($langs->transnoentities("ErrorFieldRequired",$langs->trans("Title")), 'errors');
$action = "create";
$error++;
}
@ -138,7 +138,7 @@ if ($action == 'create')
print '</td></tr>';
// Title
print '<tr><td>'.$langs->trans("Title").'</td><td>';
print '<tr><td class="fieldrequired">'.$langs->trans("Title").'</td><td>';
print '<input class="flat" type="text" name="titre" size="24" value="'.$_POST["titre"].'">';
print '</td>';

View File

@ -54,8 +54,9 @@ $endyear=$year;
* View
*/
$langs->load("bills");
$langs->load("companies");
$langs->load('bills');
$langs->load('companies');
$langs->load('other');
$form=new Form($db);

View File

@ -701,13 +701,13 @@ class Form
$selected_input_value=$product->ref;
}
=======
if ($selected && empty($selected_input_value))
{
require_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php';
$product = new Product($this->db);
$product->fetch($selected);
$selected_input_value=$product->ref;
}
if ($selected && empty($selected_input_value))
{
require_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php';
$product = new Product($this->db);
$product->fetch($selected);
$selected_input_value=$product->ref;
}
>>>>>>> refs/remotes/origin/3.3
// mode=1 means customers products
$ajaxoptions=array();
@ -1657,8 +1657,8 @@ class Form
{
$opt.= price($objp->fprice).' '.$currencytext."/".$objp->quantity;
$outval.= price($objp->fprice).' '.$currencytextnoent."/".$objp->quantity;
$opt.= $langs->trans("Units"); // Do not use strtolower because it breaks utf8 encoding
$outval.=$langs->transnoentities("Units");
$opt.= ' '.$langs->trans("Units"); // Do not use strtolower because it breaks utf8 encoding
$outval.= ' '.$langs->transnoentities("Units");
}
if ($objp->quantity >= 1)

View File

@ -1150,7 +1150,7 @@ function pdf_getlineupexcltax($object,$i,$outputlangs,$hidedetails=0)
}
else
{
if (empty($hidedetails) || $hidedetails > 1) return price($sign * $object->lines[$i]->subprice);
if (empty($hidedetails) || $hidedetails > 1) return price($sign * $object->lines[$i]->subprice, 0, $outputlangs);
}
}
@ -1175,11 +1175,11 @@ function pdf_getlineupwithtax($object,$i,$outputlangs,$hidedetails=0)
{
if (method_exists($modules[$special_code],'pdf_getlineupwithtax')) return $modules[$special_code]->pdf_getlineupwithtax($object,$i,$outputlangs,$hidedetails);
}
}
else
{
if (empty($hidedetails) || $hidedetails > 1) return price(($object->lines[$i]->subprice) + ($object->lines[$i]->subprice)*($object->lines[$i]->tva_tx)/100);
}
}
else
{
if (empty($hidedetails) || $hidedetails > 1) return price(($object->lines[$i]->subprice) + ($object->lines[$i]->subprice)*($object->lines[$i]->tva_tx)/100, 0, $outputlangs);
}
}
/**
@ -1366,7 +1366,7 @@ function pdf_getlinetotalexcltax($object,$i,$outputlangs,$hidedetails=0)
}
else
{
if (empty($hidedetails) || $hidedetails > 1) return price($sign * $object->lines[$i]->total_ht);
if (empty($hidedetails) || $hidedetails > 1) return price($sign * $object->lines[$i]->total_ht, 0, $outputlangs);
}
}
}
@ -1398,13 +1398,13 @@ function pdf_getlinetotalwithtax($object,$i,$outputlangs,$hidedetails=0)
{
if (method_exists($modules[$special_code],'pdf_getlinetotalwithtax')) return $modules[$special_code]->pdf_getlinetotalwithtax($object,$i,$outputlangs,$hidedetails);
}
}
else
{
if (empty($hidedetails) || $hidedetails > 1) return
price(($object->lines[$i]->total_ht) + ($object->lines[$i]->total_ht)*($object->lines[$i]->tva_tx)/100);
}
}
}
else
{
if (empty($hidedetails) || $hidedetails > 1) return
price(($object->lines[$i]->total_ht) + ($object->lines[$i]->total_ht)*($object->lines[$i]->tva_tx)/100, 0, $outputlangs);
}
}
}
/**

View File

@ -698,7 +698,7 @@ class pdf_einstein extends ModelePDFCommandes
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalHT"), 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + 0);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ht + (! empty($object->remise)?$object->remise:0)), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ht + (! empty($object->remise)?$object->remise:0), 0, $outputlangs), 0, 'R', 1);
// Show VAT by rates and total
$pdf->SetFillColor(248,248,248);
@ -739,7 +739,7 @@ class pdf_einstein extends ModelePDFCommandes
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval, 0, $outputlangs), 0, 'R', 1);
}
}
}
@ -772,7 +772,7 @@ class pdf_einstein extends ModelePDFCommandes
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval, 0, $outputlangs), 0, 'R', 1);
}
}
@ -799,7 +799,7 @@ class pdf_einstein extends ModelePDFCommandes
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval, 0, $outputlangs), 0, 'R', 1);
}
}
@ -830,14 +830,14 @@ class pdf_einstein extends ModelePDFCommandes
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvakey), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvakey, 0, $outputlangs), 0, 'R', 1);
}
else
{
$totalvat.=vatrate(abs($tvakey),1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval, 0, $outputlangs), 0, 'R', 1);
}
}
}
@ -870,7 +870,7 @@ class pdf_einstein extends ModelePDFCommandes
if ($localtax_type == '7') { // amount on order
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvakey), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvakey, 0, $outputlangs), 0, 'R', 1);
}
else
{
@ -878,7 +878,7 @@ class pdf_einstein extends ModelePDFCommandes
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval, 0, $outputlangs), 0, 'R', 1);
}
}
}
@ -893,7 +893,7 @@ class pdf_einstein extends ModelePDFCommandes
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalTTC"), $useborder, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc), $useborder, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc, 0, $outputlangs), $useborder, 'R', 1);
}
}
@ -915,7 +915,7 @@ class pdf_einstein extends ModelePDFCommandes
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("AlreadyPaid"), 0, 'L', 0);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($deja_regle), 0, 'R', 0);
$pdf->MultiCell($largcol2, $tab2_hl, price($deja_regle, 0, $outputlangs), 0, 'R', 0);
$index++;
$pdf->SetTextColor(0,0,60);
@ -924,7 +924,7 @@ class pdf_einstein extends ModelePDFCommandes
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("RemainderToPay"), $useborder, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($resteapayer), $useborder, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($resteapayer, 0, $outputlangs), $useborder, 'R', 1);
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetTextColor(0,0,0);

View File

@ -585,7 +585,7 @@ class pdf_crabe extends ModelePDFFactures
$pdf->SetXY($tab3_posx, $tab3_top+$y);
$pdf->MultiCell(20, 3, dol_print_date($obj->datef,'day',false,$outputlangs,true), 0, 'L', 0);
$pdf->SetXY($tab3_posx+21, $tab3_top+$y);
$pdf->MultiCell(20, 3, price($obj->amount_ttc), 0, 'L', 0);
$pdf->MultiCell(20, 3, price($obj->amount_ttc, 0, $outputlangs), 0, 'L', 0);
$pdf->SetXY($tab3_posx+40, $tab3_top+$y);
$pdf->MultiCell(20, 3, $text, 0, 'L', 0);
$pdf->SetXY($tab3_posx+58, $tab3_top+$y);
@ -622,7 +622,7 @@ class pdf_crabe extends ModelePDFFactures
$pdf->SetXY($tab3_posx, $tab3_top+$y);
$pdf->MultiCell(20, 3, dol_print_date($this->db->jdate($row->date),'day',false,$outputlangs,true), 0, 'L', 0);
$pdf->SetXY($tab3_posx+21, $tab3_top+$y);
$pdf->MultiCell(20, 3, price($sign * $row->amount), 0, 'L', 0);
$pdf->MultiCell(20, 3, price($sign * $row->amount, 0, $outputlangs), 0, 'L', 0);
$pdf->SetXY($tab3_posx+40, $tab3_top+$y);
$oper = $outputlangs->transnoentitiesnoconv("PaymentTypeShort" . $row->code);
@ -732,7 +732,7 @@ class pdf_crabe extends ModelePDFFactures
if (! empty($conf->global->FACTURE_CHQ_NUMBER))
{
$diffsizetitle=(empty($conf->global->PDF_DIFFSIZE_TITLE)?3:$conf->global->PDF_DIFFSIZE_TITLE);
if ($conf->global->FACTURE_CHQ_NUMBER > 0)
{
$account = new Account($this->db);
@ -831,7 +831,7 @@ class pdf_crabe extends ModelePDFFactures
$pdf->SetXY($col1x, $tab2_top + 0);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalHT"), 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + 0);
$pdf->MultiCell($largcol2, $tab2_hl, price($sign * ($object->total_ht + (! empty($object->remise)?$object->remise:0))), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($sign * ($object->total_ht + (! empty($object->remise)?$object->remise:0)), 0, $outputlangs), 0, 'R', 1);
// Show VAT by rates and total
$pdf->SetFillColor(248,248,248);
@ -874,7 +874,7 @@ class pdf_crabe extends ModelePDFFactures
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval, 0, $outputlangs), 0, 'R', 1);
}
}
}
@ -908,7 +908,7 @@ class pdf_crabe extends ModelePDFFactures
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval, 0, $outputlangs), 0, 'R', 1);
}
}
@ -935,7 +935,7 @@ class pdf_crabe extends ModelePDFFactures
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval, 0, $outputlangs), 0, 'R', 1);
}
}
@ -966,14 +966,14 @@ class pdf_crabe extends ModelePDFFactures
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvakey), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvakey, 0, $outputlangs), 0, 'R', 1);
}
else
{
$totalvat.=vatrate(abs($tvakey),1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval, 0, $outputlangs), 0, 'R', 1);
}
}
}
@ -1007,7 +1007,7 @@ class pdf_crabe extends ModelePDFFactures
if ($localtax_type == '7') { // amount on order
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvakey), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvakey, 0, $outputlangs), 0, 'R', 1);
}
else
{
@ -1015,7 +1015,7 @@ class pdf_crabe extends ModelePDFFactures
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval, 0, $outputlangs), 0, 'R', 1);
}
}
}
@ -1041,7 +1041,7 @@ class pdf_crabe extends ModelePDFFactures
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalTTC"), $useborder, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($sign * $object->total_ttc), $useborder, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($sign * $object->total_ttc, 0, $outputlangs), $useborder, 'R', 1);
}
}
@ -1060,7 +1060,7 @@ class pdf_crabe extends ModelePDFFactures
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("Paid"), 0, 'L', 0);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($deja_regle + $depositsamount), 0, 'R', 0);
$pdf->MultiCell($largcol2, $tab2_hl, price($deja_regle + $depositsamount, 0, $outputlangs), 0, 'R', 0);
// Credit note
if ($creditnoteamount)
@ -1069,7 +1069,7 @@ class pdf_crabe extends ModelePDFFactures
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("CreditNotes"), 0, 'L', 0);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($creditnoteamount), 0, 'R', 0);
$pdf->MultiCell($largcol2, $tab2_hl, price($creditnoteamount, 0, $outputlangs), 0, 'R', 0);
}
// Escompte
@ -1081,7 +1081,7 @@ class pdf_crabe extends ModelePDFFactures
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("EscompteOffered"), $useborder, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc - $deja_regle - $creditnoteamount - $depositsamount), $useborder, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc - $deja_regle - $creditnoteamount - $depositsamount, 0, $outputlangs), $useborder, 'R', 1);
$resteapayer=0;
}
@ -1092,7 +1092,7 @@ class pdf_crabe extends ModelePDFFactures
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("RemainderToPay"), $useborder, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($resteapayer), $useborder, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($resteapayer, 0, $outputlangs), $useborder, 'R', 1);
// Fin
$pdf->SetFont('','', $default_font_size - 1);

View File

@ -727,7 +727,7 @@ class pdf_azur extends ModelePDFPropales
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalHT"), 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + 0);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ht + (! empty($object->remise)?$object->remise:0)), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ht + (! empty($object->remise)?$object->remise:0), 0, $outputlangs), 0, 'R', 1);
// Show VAT by rates and total
$pdf->SetFillColor(248,248,248);
@ -769,7 +769,7 @@ class pdf_azur extends ModelePDFPropales
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval, 0, $outputlangs), 0, 'R', 1);
}
}
}
@ -803,7 +803,7 @@ class pdf_azur extends ModelePDFPropales
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval, 0, $outputlangs), 0, 'R', 1);
}
}
@ -830,7 +830,7 @@ class pdf_azur extends ModelePDFPropales
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval, 0, $outputlangs), 0, 'R', 1);
}
}
@ -861,14 +861,14 @@ class pdf_azur extends ModelePDFPropales
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvakey), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvakey, 0, $outputlangs), 0, 'R', 1);
}
else
{
$totalvat.=vatrate(abs($tvakey),1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval, 0, $outputlangs), 0, 'R', 1);
}
}
}
@ -901,7 +901,7 @@ class pdf_azur extends ModelePDFPropales
if ($localtax_type == '7') { // amount on order
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvakey), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvakey, 0, $outputlangs), 0, 'R', 1);
}
else
{
@ -909,7 +909,7 @@ class pdf_azur extends ModelePDFPropales
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval, 0, $outputlangs), 0, 'R', 1);
}
}
}
@ -924,7 +924,7 @@ class pdf_azur extends ModelePDFPropales
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalTTC"), $useborder, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc), $useborder, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc, 0, $outputlangs), $useborder, 'R', 1);
}
}
@ -943,7 +943,7 @@ class pdf_azur extends ModelePDFPropales
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("AlreadyPaid"), 0, 'L', 0);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($deja_regle), 0, 'R', 0);
$pdf->MultiCell($largcol2, $tab2_hl, price($deja_regle, 0, $outputlangs), 0, 'R', 0);
/*
if ($object->close_code == 'discount_vat')
@ -955,7 +955,7 @@ class pdf_azur extends ModelePDFPropales
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("EscompteOffered"), $useborder, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc - $deja_regle), $useborder, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc - $deja_regle, 0, $outputlangs), $useborder, 'R', 1);
$resteapayer=0;
}
@ -968,7 +968,7 @@ class pdf_azur extends ModelePDFPropales
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("RemainderToPay"), $useborder, 'L', 1);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($resteapayer), $useborder, 'R', 1);
$pdf->MultiCell($largcol2, $tab2_hl, price($resteapayer, 0, $outputlangs), $useborder, 'R', 1);
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetTextColor(0,0,0);

View File

@ -132,6 +132,7 @@ if ($action == 'confirm_deletedir' && $confirm == 'yes')
}
else
{
$langs->load('errors');
setEventMessage($langs->trans($ecmdir->error,$ecmdir->label), 'errors');
}
}

View File

@ -986,8 +986,7 @@ class CommandeFournisseur extends CommonOrder
);
if ($result < 0)
{
$this->error=$this->db->lasterror();
dol_print_error($this->db);
dol_syslog(get_class($this)."::create ".$this->error, LOG_WARNING); // do not use dol_print_error here as it may be a functionnal error
$this->db->rollback();
return -1;
}
@ -1022,7 +1021,7 @@ class CommandeFournisseur extends CommonOrder
}
else if ($reshook < 0) $error++;
}
if (! $notrigger)
{
// Appel des triggers
@ -1441,7 +1440,7 @@ class CommandeFournisseur extends CommonOrder
{
$error++;
}
// Remove extrafields
if ((! $error) && (empty($conf->global->MAIN_EXTRAFIELDS_DISABLED))) // For avoid conflicts if trigger used
{

View File

@ -1109,7 +1109,7 @@ elseif (! empty($object->id))
//'text' => $langs->trans("ConfirmClone"),
//array('type' => 'checkbox', 'name' => 'clone_content', 'label' => $langs->trans("CloneMainAttributes"), 'value' => 1),
//array('type' => 'checkbox', 'name' => 'update_prices', 'label' => $langs->trans("PuttingPricesUpToDate"), 'value' => 1),
array('type' => 'other', 'name' => 'idwarehouse', 'label' => $langs->trans("SelectWarehouseForStockDecrease"), 'value' => $formproduct->selectWarehouses(GETPOST('idwarehouse'),'idwarehouse','',1))
array('type' => 'other', 'name' => 'idwarehouse', 'label' => $langs->trans("SelectWarehouseForStockIncrease"), 'value' => $formproduct->selectWarehouses(GETPOST('idwarehouse'),'idwarehouse','',1))
);
}

View File

@ -42,27 +42,4 @@ if (empty($conf->holiday->enabled))
exit();
}
/*$sql = "SELECT value";
$sql.= " FROM ".MAIN_DB_PREFIX."holiday_config";
$sql.= " WHERE name = 'userGroup'";
$result = $db->query($sql);
$obj = $db->fetch_object($result);
if ($obj->value == null || $obj->value < 0)
{
llxHeader('',$langs->trans('CPTitreMenu'));
$langs->load("errors");
$warnpicto=img_error($langs->trans("WarningMandatorySetupNotComplete"));
print '<div class="tabBar">';
print $warnpicto.' '.$langs->trans("NotConfigModCP");
print '</div>';
llxFooter();
exit();
}
*/
?>
?>

View File

@ -76,7 +76,7 @@
// dullus for text Justification.
// Bob Vincent (pillarsdotnet@users.sourceforge.net) for <li> value attribute.
// Patrick Benny for text stretch suggestion on Cell().
// Johannes Güntert for JavaScript support.
// Johannes G<EFBFBD>ntert for JavaScript support.
// Denis Van Nuffelen for Dynamic Form.
// Jacek Czekaj for multibyte justification
// Anthony Ferrara for the reintroduction of legacy image methods.
@ -87,7 +87,7 @@
// Mohamad Ali Golkar, Saleh AlMatrafe, Charles Abbott for Arabic and Persian support.
// Moritz Wagner and Andreas Wurmser for graphic functions.
// Andrew Whitehead for core fonts support.
// Esteban Joël Marín for OpenType font conversion.
// Esteban Jo<EFBFBD>l Mar<61>n for OpenType font conversion.
// Teus Hagen for several suggestions and fixes.
// Yukihiro Nakadaira for CID-0 CJK fonts fixes.
// Kosmas Papachristos for some CSS improvements.
@ -5324,7 +5324,7 @@ class TCPDF {
$cbbox = array();
}
// initialize subsetchars
$subsetchars = array();
$subsetchars = array_fill(0, 256, true);
$this->setFontBuffer($fontkey, array('fontkey' => $fontkey, 'i' => $this->numfonts, 'type' => $type, 'name' => $name, 'desc' => $desc, 'up' => $up, 'ut' => $ut, 'cw' => $cw, 'cbbox' => $cbbox, 'dw' => $dw, 'enc' => $enc, 'cidinfo' => $cidinfo, 'file' => $file, 'ctg' => $ctg, 'subset' => $subset, 'subsetchars' => $subsetchars));
if ($this->inxobj) {
// we are inside an XObject template
@ -7123,7 +7123,7 @@ class TCPDF {
* @param $cellpadding (float) Internal cell padding, if empty uses default cell padding.
* @param $border (mixed) Indicates if borders must be drawn around the cell. The value can be a number:<ul><li>0: no border (default)</li><li>1: frame</li></ul> or a string containing some or all of the following characters (in any order):<ul><li>L: left</li><li>T: top</li><li>R: right</li><li>B: bottom</li></ul> or an array of line styles for each border group - for example: array('LTRB' => array('width' => 2, 'cap' => 'butt', 'join' => 'miter', 'dash' => 0, 'color' => array(0, 0, 0)))
* @return float Return the minimal height needed for multicell method for printing the $txt param.
* @author Alexander Escalona Fernández, Nicola Asuni
* @author Alexander Escalona Fern<EFBFBD>ndez, Nicola Asuni
* @public
* @since 4.5.011
*/
@ -7230,7 +7230,7 @@ class TCPDF {
* @param $cellpadding (float) Internal cell padding, if empty uses default cell padding.
* @param $border (mixed) Indicates if borders must be drawn around the cell. The value can be a number:<ul><li>0: no border (default)</li><li>1: frame</li></ul> or a string containing some or all of the following characters (in any order):<ul><li>L: left</li><li>T: top</li><li>R: right</li><li>B: bottom</li></ul> or an array of line styles for each border group - for example: array('LTRB' => array('width' => 2, 'cap' => 'butt', 'join' => 'miter', 'dash' => 0, 'color' => array(0, 0, 0)))
* @return float Return the minimal height needed for multicell method for printing the $txt param.
* @author Nicola Asuni, Alexander Escalona Fernández
* @author Nicola Asuni, Alexander Escalona Fern<EFBFBD>ndez
* @public
*/
public function getStringHeight($w, $txt, $reseth=false, $autopadding=true, $cellpadding='', $border=0) {
@ -15417,7 +15417,7 @@ class TCPDF {
}
/**
* Append a cubic Bézier curve to the current path. The curve shall extend from the current point to the point (x3, y3), using (x1, y1) and (x2, y2) as the Bézier control points.
* Append a cubic B<EFBFBD>zier curve to the current path. The curve shall extend from the current point to the point (x3, y3), using (x1, y1) and (x2, y2) as the B<EFBFBD>zier control points.
* The new current point shall be (x3, y3).
* @param $x1 (float) Abscissa of control point 1.
* @param $y1 (float) Ordinate of control point 1.
@ -15435,7 +15435,7 @@ class TCPDF {
}
/**
* Append a cubic Bézier curve to the current path. The curve shall extend from the current point to the point (x3, y3), using the current point and (x2, y2) as the Bézier control points.
* Append a cubic B<EFBFBD>zier curve to the current path. The curve shall extend from the current point to the point (x3, y3), using the current point and (x2, y2) as the B<EFBFBD>zier control points.
* The new current point shall be (x3, y3).
* @param $x2 (float) Abscissa of control point 2.
* @param $y2 (float) Ordinate of control point 2.
@ -15451,7 +15451,7 @@ class TCPDF {
}
/**
* Append a cubic Bézier curve to the current path. The curve shall extend from the current point to the point (x3, y3), using (x1, y1) and (x3, y3) as the Bézier control points.
* Append a cubic B<EFBFBD>zier curve to the current path. The curve shall extend from the current point to the point (x3, y3), using (x1, y1) and (x3, y3) as the B<EFBFBD>zier control points.
* The new current point shall be (x3, y3).
* @param $x1 (float) Abscissa of control point 1.
* @param $y1 (float) Ordinate of control point 1.
@ -16855,7 +16855,7 @@ class TCPDF {
/**
* Insert Named Destinations.
* @protected
* @author Johannes Güntert, Nicola Asuni
* @author Johannes G<EFBFBD>ntert, Nicola Asuni
* @since 5.9.098 (2011-06-23)
*/
protected function _putdests() {
@ -17054,7 +17054,7 @@ class TCPDF {
* Adds a javascript
* @param $script (string) Javascript code
* @public
* @author Johannes Güntert, Nicola Asuni
* @author Johannes G<EFBFBD>ntert, Nicola Asuni
* @since 2.1.002 (2008-02-12)
*/
public function IncludeJS($script) {
@ -17083,7 +17083,7 @@ class TCPDF {
/**
* Create a javascript PDF string.
* @protected
* @author Johannes Güntert, Nicola Asuni
* @author Johannes G<EFBFBD>ntert, Nicola Asuni
* @since 2.1.002 (2008-02-12)
*/
protected function _putjavascript() {
@ -19146,7 +19146,7 @@ class TCPDF {
* @param $col1 (array) first color (Grayscale, RGB or CMYK components).
* @param $col2 (array) second color (Grayscale, RGB or CMYK components).
* @param $coords (array) array of the form (x1, y1, x2, y2) which defines the gradient vector (see linear_gradient_coords.jpg). The default value is from left to right (x1=0, y1=0, x2=1, y2=0).
* @author Andreas Würmser, Nicola Asuni
* @author Andreas W<EFBFBD>rmser, Nicola Asuni
* @since 3.1.000 (2008-06-09)
* @public
*/
@ -19164,7 +19164,7 @@ class TCPDF {
* @param $col1 (array) first color (Grayscale, RGB or CMYK components).
* @param $col2 (array) second color (Grayscale, RGB or CMYK components).
* @param $coords (array) array of the form (fx, fy, cx, cy, r) where (fx, fy) is the starting point of the gradient with color1, (cx, cy) is the center of the circle with color2, and r is the radius of the circle (see radial_gradient_coords.jpg). (fx, fy) should be inside the circle, otherwise some areas will not be defined.
* @author Andreas Würmser, Nicola Asuni
* @author Andreas W<EFBFBD>rmser, Nicola Asuni
* @since 3.1.000 (2008-06-09)
* @public
*/
@ -19187,7 +19187,7 @@ class TCPDF {
* @param $coords_min (array) minimum value used by the coordinates. If a coordinate's value is smaller than this it will be cut to coords_min. default: 0
* @param $coords_max (array) maximum value used by the coordinates. If a coordinate's value is greater than this it will be cut to coords_max. default: 1
* @param $antialias (boolean) A flag indicating whether to filter the shading function to prevent aliasing artifacts.
* @author Andreas Würmser, Nicola Asuni
* @author Andreas W<EFBFBD>rmser, Nicola Asuni
* @since 3.1.000 (2008-06-09)
* @public
*/
@ -19279,7 +19279,7 @@ class TCPDF {
* @param $y (float) ordinate of the top left corner of the rectangle.
* @param $w (float) width of the rectangle.
* @param $h (float) height of the rectangle.
* @author Andreas Würmser, Nicola Asuni
* @author Andreas W<EFBFBD>rmser, Nicola Asuni
* @since 3.1.000 (2008-06-09)
* @protected
*/
@ -20797,19 +20797,19 @@ class TCPDF {
// remove empty blocks
$cssdata = preg_replace('/([^\}\{]+)\{\}/', '', $cssdata);
// replace media type parenthesis
$cssdata = preg_replace('/@media[\s]+([^\{]*)\{/i', '@media \\1§', $cssdata);
$cssdata = preg_replace('/\}\}/si', '}§', $cssdata);
$cssdata = preg_replace('/@media[\s]+([^\{]*)\{/i', '@media \\1<EFBFBD>', $cssdata);
$cssdata = preg_replace('/\}\}/si', '}<EFBFBD>', $cssdata);
// trim string
$cssdata = trim($cssdata);
// find media blocks (all, braille, embossed, handheld, print, projection, screen, speech, tty, tv)
$cssblocks = array();
$matches = array();
if (preg_match_all('/@media[\s]+([^\§]*)§([^§]*)§/i', $cssdata, $matches) > 0) {
if (preg_match_all('/@media[\s]+([^\<EFBFBD>]*)<29>([^<5E>]*)<29>/i', $cssdata, $matches) > 0) {
foreach ($matches[1] as $key => $type) {
$cssblocks[$type] = $matches[2][$key];
}
// remove media blocks
$cssdata = preg_replace('/@media[\s]+([^\§]*)§([^§]*)§/i', '', $cssdata);
$cssdata = preg_replace('/@media[\s]+([^\<EFBFBD>]*)<29>([^<5E>]*)<29>/i', '', $cssdata);
}
// keep 'all' and 'print' media, other media types are discarded
if (isset($cssblocks['all']) AND !empty($cssblocks['all'])) {
@ -29032,7 +29032,7 @@ Putting 1 is equivalent to putting 0 and calling Ln() just after. Default value:
}
break;
}
case 'Q': { // quadratic Bézier curveto
case 'Q': { // quadratic B<EFBFBD>zier curveto
foreach ($params as $ck => $cp) {
$params[$ck] = $cp;
if ((($ck + 1) % 4) == 0) {
@ -29058,7 +29058,7 @@ Putting 1 is equivalent to putting 0 and calling Ln() just after. Default value:
}
break;
}
case 'T': { // shorthand/smooth quadratic Bézier curveto
case 'T': { // shorthand/smooth quadratic B<EFBFBD>zier curveto
foreach ($params as $ck => $cp) {
$params[$ck] = $cp;
if (($ck % 2) != 0) {

View File

@ -109,7 +109,6 @@ ToExport=Export
NewExport=New export
##### External sites #####
ExternalSites=External sites
FONTFORPDF=Freemono
// START - Lines generated via autotranslator.php tool (2011-06-26 15:35:22).

View File

@ -19,7 +19,7 @@ FormatDateHourTextShort=%b %d, %Y, %I:%M %p
FormatDateHourText=%B %d, %Y, %I:%M %p
DatabaseConnection=Database connection
NoTranslation=No translation
NoRecordFound=Aucun enregistrement trouvé
NoRecordFound=No record found
NoError=No error
Error=Error
ErrorFieldRequired=Field '%s' is required

View File

@ -84,14 +84,14 @@ ShowService=Mostrar servicio
ProductsAndServicesArea=Área productos y servicios
ProductsArea=Área Productos
ServicesArea=Área Servicios
AddToMyProposals=Adjuntar a mis presupuestos
AddToOtherProposals=Adjuntar a otros presupuestos
AddToMyBills=Adjuntar a mis facturas
AddToOtherBills=Adjuntar a otras facturas
AddToMyProposals=Añadir a mis presupuestos
AddToOtherProposals=Añadir a otros presupuestos
AddToMyBills=Añadir a mis facturas
AddToOtherBills=Añadir a otras facturas
CorrectStock=Corregir stock
AddPhoto=Adjuntar una foto
ListOfStockMovements=Listado de movimientos de stock
NoPhotoYet=No hay fotografía disponible por el momento
NoPhotoYet=No hay fotografías disponibles por el momento
BuyingPrice=Precio de compra
SupplierCard=Ficha proveedor
CommercialCard=Ficha comercial
@ -114,6 +114,8 @@ AssociatedProductsAbility=Activar productos compuestos
AssociatedProducts=Productos compuestos
AssociatedProductsNumber=Nº de productos que componen este producto
ParentProductsNumber=Nº de productos que este producto compone
IfZeroItIsNotAVirtualProduct=Si 0, este producto no es un producto virtual
IfZeroItIsNotUsedByVirtualProduct=Si 0, este producto no está siendo utilizado por ningún producto virtual
EditAssociate=Componer
Translation=Traducción
KeywordFilter=Filtro por clave

View File

@ -72,7 +72,6 @@ $cancel <> $langs->trans("Cancel") &&
$error=0;
for($i=0;$i<$_POST["max_prod"];$i++)
{
print "<br> : ".$_POST["prod_id_chk".$i];
if ($_POST["prod_id_chk".$i] > 0)
{
if($product->add_sousproduit($id, $_POST["prod_id_".$i],$_POST["prod_qty_".$i]) > 0)

View File

@ -1417,7 +1417,7 @@ if ($object->id && ($action == '' || $action == 'view') && $object->status)
$langs->load("bills");
$html .= '<tr class="liste_titre">';
$html .= '<td class="liste_titre">'.$langs->trans("AddToOtherOrders").'</td>';
$html .= '<td class="liste_titre">'.$langs->trans("AddToOtherBills").'</td>';
$html .= '</tr><tr>';
$html .= '<td valign="top">';

View File

@ -212,9 +212,9 @@ class NumberingModulesTest extends PHPUnit_Framework_TestCase
$this->assertEquals(1, $result); // Case 1 can be deleted (because there was a reset for case 2)
// Try an offset when an invoice already exists
$conf->global->FACTURE_MERCURE_MASK_CREDIT='{yyyy}{mm}-{0000+9990}';
$conf->global->FACTURE_MERCURE_MASK_INVOICE='{yyyy}{mm}-{0000+9990}';
$result=$numbering->getNextValue($mysoc, $localobject2);
$conf->global->FACTURE_MERCURE_MASK_CREDIT='{yyyy}{mm}-{0000+9990}';
$conf->global->FACTURE_MERCURE_MASK_INVOICE='{yyyy}{mm}-{0000+9990}';
$result=$numbering->getNextValue($mysoc, $localobject2);
// Now we try with a different fiscal month (forced by mask)
$conf->global->FACTURE_MERCURE_MASK_CREDIT='{yyyy}{mm}-{0000@6}';

View File

@ -47,6 +47,7 @@
<directory suffix=".php">../../htdocs/societe/canvas/</directory>
<directory suffix=".php">../../htdocs/includes/</directory>
<file>../../htdocs/boutique/osc_master.inc.php</file>
<file>../../htdocs/holiday/common.inc.php</file>
</exclude>
</whitelist>
</filter>