Public Member Functions | |
rapport ($p_cn, $p_id) | |
Constructor. | |
GetName () | |
Return the report's name. | |
GetRow ($p_start, $p_end) | |
return all the row and parse formula from a report | |
Data Fields | |
$db | |
$id | |
$name |
Definition at line 28 of file class_rapport.php.
|
Constructor.
Definition at line 33 of file class_rapport.php.
|
|
Return the report's name.
Definition at line 40 of file class_rapport.php. References $a, $ret, and name. 00040 { 00041 $ret=execSql($this->db,"select fr_label from formdef where fr_id=".$this->id); 00042 if (pg_NumRows($ret) == 0) return $this->name; 00043 $a=pg_fetch_array($ret,0); 00044 $this->name=$a['fr_label']; 00045 return $this->name; 00046 }
|
|
return all the row and parse formula from a report
Definition at line 53 of file class_rapport.php. References $col, $l_line, $Max, $Res, ExecSql(), and ParseFormula(). 00053 { 00054 00055 $Res=ExecSql($this->db,"select fo_id , 00056 fo_fr_id, 00057 fo_pos, 00058 fo_label, 00059 fo_formula, 00060 fr_label from form 00061 inner join formdef on fr_id=fo_fr_id 00062 where fr_id =".$this->id. 00063 "order by fo_pos"); 00064 $Max=pg_NumRows($Res); 00065 if ($Max==0) { $this->row=0;return null;} 00066 $col=array(); 00067 for ($i=0;$i<$Max;$i++) { 00068 $l_line=pg_fetch_array($Res,$i); 00069 $col[]=ParseFormula($this->db, 00070 $l_line['fo_label'], 00071 $l_line['fo_formula'], 00072 $p_start, 00073 $p_end 00074 ); 00075 00076 } //for ($i 00077 $this->row=$col; 00078 return $col; 00079 }
|
|
database connx Definition at line 29 of file class_rapport.php. |
|
formdef.fr_id Definition at line 30 of file class_rapport.php. |
|
report's name Definition at line 31 of file class_rapport.php. |