diff --git a/include/anc_imp.inc.php b/include/anc_imp.inc.php
index 2565fbc63..3291a8084 100644
--- a/include/anc_imp.inc.php
+++ b/include/anc_imp.inc.php
@@ -164,7 +164,6 @@ if ( $sub == 'ancgl')
echo '';
if ( isset($_GET['result']))
{
- // echo $gl->show_button($str_hidden);
echo $gl->display_html();
}
- }
\ No newline at end of file
+ }
diff --git a/include/anc_pa.inc.php b/include/anc_pa.inc.php
index 30e6de4b0..bca801aa7 100644
--- a/include/anc_pa.inc.php
+++ b/include/anc_pa.inc.php
@@ -167,7 +167,7 @@ if ( isset($_REQUEST['sa']))
$ret.=HtmlInput::hidden('sa','po_update');
$ret.=HtmlInput::submit('Correction','Correction');
$ret.=sprintf(''.
- '',
+ '',
$po->id,
$_REQUEST['pa_id']
);
@@ -195,7 +195,7 @@ if ( isset($_REQUEST['sa']))
$new=new Anc_Plan($cn,$_REQUEST['pa_id']);
$new->get();
- $array=$new->get_poste_analytique();
+ $array=$new->get_poste_analytique(" order by po_name");
$ret.='
';
$ret.='
';
$ret.="";
@@ -215,8 +215,8 @@ if ( isset($_REQUEST['sa']))
$class="odd";
$ret.="
";
- $ret.="| ".
- '".
+ ''.
h($obj->name).
'';
@@ -278,7 +278,7 @@ else
' | ';
echo ''.
''.
- "Postes".
+ "Activités".
"";
echo ' |
';
diff --git a/include/class_anc_acc_list.php b/include/class_anc_acc_list.php
index 7c20f57f5..0828a1c09 100644
--- a/include/class_anc_acc_list.php
+++ b/include/class_anc_acc_list.php
@@ -42,10 +42,10 @@ class Anc_Acc_List extends Anc_Acc_Link
$r=parent::display_form($p_hidden);
$icard=new ISelect('card_poste');
$icard->value=array(
- array('value'=>1,'label'=>'Par fiche /Poste Analytique'),
- array('value'=>2,'label'=>'Par poste comptable/Poste Analytique'),
- array('value'=>3,'label'=>'Par poste Analytique/Fiche'),
- array('value'=>4,'label'=>'Par poste Analytique/Poste Comptable')
+ array('value'=>1,'label'=>'Par fiche /Activité'),
+ array('value'=>2,'label'=>'Par poste comptable/Activité'),
+ array('value'=>3,'label'=>'Par activité/Fiche'),
+ array('value'=>4,'label'=>'Par activité/Poste Comptable')
);
diff --git a/include/class_anc_balance_double.php b/include/class_anc_balance_double.php
index 922191b69..a0afe206b 100644
--- a/include/class_anc_balance_double.php
+++ b/include/class_anc_balance_double.php
@@ -273,12 +273,12 @@ class Anc_Balance_Double extends Anc_Print
{
$r="";
- $r.='"Poste comptable Analytique",';
- $r.='"Poste comptable Analytique",';
- $r.='"Debit",';
- $r.='"Credit",';
- $r.='"Solde",';
- $r.='"D/C",';
+ $r.='"Poste comptable Analytique";';
+ $r.='"Poste comptable Analytique";';
+ $r.='"Debit";';
+ $r.='"Credit";';
+ $r.='"Solde";';
+ $r.='"D/C"';
$r.="\r\n";
@@ -291,11 +291,11 @@ class Anc_Balance_Double extends Anc_Print
foreach ( $array as $row)
{
- $r.=sprintf('"%s",',$row['a_po_name']);
- $r.=sprintf('"%s",',$row['b_po_name']);
- $r.=sprintf("%12.2f,",$row['a_d']);
- $r.=sprintf("%12.2f,",$row['a_c']);
- $r.=sprintf("%12.2f,",$row['a_solde']);
+ $r.=sprintf('"%s";',$row['a_po_name']);
+ $r.=sprintf('"%s";',$row['b_po_name']);
+ $r.=sprintf("%s;",nb($row['a_d']));
+ $r.=sprintf("%s;",nb($row['a_c']));
+ $r.=sprintf("%s;",nb($row['a_solde']));
$r.=sprintf('"%s"',$row['a_debit']);
$r.="\r\n";
}
diff --git a/include/class_anc_balance_simple.php b/include/class_anc_balance_simple.php
index 39733b8d5..e1b352b7a 100644
--- a/include/class_anc_balance_simple.php
+++ b/include/class_anc_balance_simple.php
@@ -191,9 +191,9 @@ class Anc_Balance_Simple extends Anc_Print
$row=$array[$i];
$pdf->Cell(20,6,$row['po_id'],0,0,'L');
$pdf->Cell(90,6,$row['po_name'],0,0,'L');
- $pdf->Cell(20,6,sprintf('%.2f',$row['sum_deb']),0,0,'R');
- $pdf->Cell(20,6,sprintf('%.2f',$row['sum_cred']),0,0,'R');
- $pdf->Cell(20,6,sprintf('%.2f',$row['solde']),0,0,'R');
+ $pdf->Cell(20,6,sprintf('%s',nbm($row['sum_deb'])),0,0,'R');
+ $pdf->Cell(20,6,sprintf('%s',nbm($row['sum_cred'])),0,0,'R');
+ $pdf->Cell(20,6,sprintf('%s',nbm($row['solde'])),0,0,'R');
$pdf->Cell(20,6,$row['debit'],0,0,'R');
$pdf->Ln();
}
@@ -219,11 +219,11 @@ class Anc_Balance_Simple extends Anc_Print
// the name and po_id
$solde=($row['sum_cred']>$row['sum_deb'])?'C':'D';
$solde=($row['sum_cred']==$row['sum_deb'])?'':$solde;
- $r.=sprintf("'%s',",$row['po_id']);
- $r.=sprintf("'%s',",$row['po_name']);
- $r.=sprintf("%12.2f,",$row['sum_deb']);
- $r.=sprintf("%12.2f,",$row['sum_cred']);
- $r.=sprintf("%12.2f,",$row['solde']);
+ $r.=sprintf("'%s';",$row['po_id']);
+ $r.=sprintf("'%s';",$row['po_name']);
+ $r.=sprintf("%s;",nb($row['sum_deb']));
+ $r.=sprintf("%s;",nb($row['sum_cred']));
+ $r.=sprintf("%s;",nb($row['solde']));
$r.=sprintf("'%s'",$row['debit']);
$r.="\r\n";
}
diff --git a/include/class_anc_plan.php b/include/class_anc_plan.php
index 279f8063c..5e64eb4b2 100644
--- a/include/class_anc_plan.php
+++ b/include/class_anc_plan.php
@@ -140,9 +140,9 @@ class Anc_Plan
* Analytic plan
* \return an array of Poste_analytic object
*/
- function get_poste_analytique()
+ function get_poste_analytique($p_order="")
{
- $sql="select po_id from poste_analytique where pa_id=".$this->id;
+ $sql="select po_id,po_name from poste_analytique where pa_id=".$this->id." $p_order";
$r=$this->db->exec_sql($sql);
$ret=array();
if ( Database::num_row($r) == 0 )
diff --git a/include/class_anc_print.php b/include/class_anc_print.php
index 607904502..3bf621f3e 100644
--- a/include/class_anc_print.php
+++ b/include/class_anc_print.php
@@ -127,14 +127,14 @@ class Anc_Print
$poste=new IText();
$poste->size=10;
- $r.=_("Entre le poste ").$poste->input("from_poste",$this->from_poste);
+ $r.=_("Entre l'activité ").$poste->input("from_poste",$this->from_poste);
$choose=new IButton();
$choose->name=_("Choix Poste");
$choose->label=_("Recherche");
$choose->javascript="onClick=search_ca(".dossier::id().",'from_poste','pa_id')";
$r.=$choose->input();
- $r.=_(" et le poste ").$poste->input("to_poste",$this->to_poste);
+ $r.=_(" et l'activité ").$poste->input("to_poste",$this->to_poste);
$choose->javascript="onClick=search_ca(".dossier::id().",'to_poste','pa_id')";
$r.=$choose->input();
$r.=''._('Selectionnez le plan qui vous intéresse avant de cliquer sur Recherche').'';