Code cleaning

This commit is contained in:
sparkyx 2007-09-17 14:40:25 +00:00
parent 9a23bb3cfc
commit c87aaca24e

View file

@ -1121,68 +1121,4 @@ function display_table_ca($p_cn,$p_seq,$p_jid,$p_own,$p_mode,$p_amount) {
return "";
}
/*
function display_table_ca2($p_cn,$p_jid,$p_own,$p_mode) {
$r="";
$head_ca="</td><td><table><tr>";
$plan=new PlanAnalytic($p_cn);
$a_plan=$plan->get_list();
foreach ($a_plan as $r_plan)
{
$head_ca.="<th>".$r_plan['name']."</th>";
}
$head_ca.="<th>Montant</th>";
$r.=$head_ca.'</tr>';
// show form
$op=new operation($p_cn);
$null=($p_own->MY_ANALYTIC=='op')?1:0;
// $r.=$op->display_form_plan($null,"form",$i,round($fiche_with_vat,2));
$plan=new PlanAnalytic($p_cn);
$a_plan=$plan->get_list();
$max_plan=$plan->count();
// Get all the operation
$op=new operation($p_cn);
$op_array=$op->get_by_jid($p_jid);
echo_debug(__FILE__.':'.__LINE__, "array is ",$op_array);
$count_plan=0;
$r.="<tr>";
foreach ($op_array as $row)
{
$array=make_array($p_cn,
"select po_id as value,".
" po_name as label from poste_analytique ".
" where pa_id = ".$row->pa_id.
" order by po_name",$null);
$select = new widget("select","","plan_".$row->pa_id."_".$p_jid,$array);
$select->selected=$row->po_id;
$select->table=0;
echo_debug(__FILE__.":".__LINE__,"select ",$select);
$select->readonly=($p_mode==0)?true:false;
$r.='<td>'.$select->IOValue().'</tD>';
$count_plan++;
if ( $count_plan == $max_plan) {
$ca_amount=new widget("text");
$r.="<td>".$ca_amount->IOValue("amount",$row->oa_amount);
$r.="</tr>";
$r.="<tr>";
$count_plan=0;
}
}
$r.="</tr></table></td><tr>";
return $r;
}
*/
?>