X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=reporting%2Fincludes%2Fexcel_report.inc;h=7d1379b43676d9bb45929b6173ac95cfed7ad060;hb=9a98bb3bc7a94f1a8e47f8dab45a87c8b4212080;hp=7356da84c3188944cd321901d7a9f496ca59512c;hpb=6b724fc86f632fd277f7fbc330cd748fc019afd3;p=fa-stable.git diff --git a/reporting/includes/excel_report.inc b/reporting/includes/excel_report.inc index 7356da84..7d1379b4 100644 --- a/reporting/includes/excel_report.inc +++ b/reporting/includes/excel_report.inc @@ -29,6 +29,8 @@ class FrontReport extends Spreadsheet_Excel_Writer_Workbook var $bottomMargin = 0; var $lineHeight; var $leftMargin = 0; + var $pageWidth; // dummy + var $rightMargin; // dummy var $cols; var $params; @@ -70,7 +72,7 @@ class FrontReport extends Spreadsheet_Excel_Writer_Workbook $this->title = $title; $this->lineHeight = 12; $this->endLine = 760; - $this->fontSize = $fontsize; + $this->SetFontSize($fontsize); $this->oldFontSize = 0; $this->y = 0; $this->currency = ''; @@ -214,6 +216,11 @@ class FrontReport extends Spreadsheet_Excel_Writer_Workbook function Font($fontname = '', $style = 'normal') { } + + function SetFontSize($size) + { + $this->fontSize = $size; + } function Info($params, $cols, $headers, $aligns, $cols2 = null, $headers2 = null, $aligns2 = null) @@ -558,7 +565,7 @@ class FrontReport extends Spreadsheet_Excel_Writer_Workbook { if (!$conv) $txt = date2sql($txt); - list($year, $mo, $day) = explode("-", $txt); + list($year, $mo, $day) = explode("-", $txt); $date = $this->ymd2date((int)$year, (int)$mo, (int)$day); $this->sheet->writeNumber($this->y, $c, $date, $this->formatDate); } @@ -686,7 +693,7 @@ class FrontReport extends Spreadsheet_Excel_Writer_Workbook return ($px / $unit_offset_length); } - function End($email=0, $subject=null, $myrow=null, $doctype = 0) + function End($email=0, $subject='') { ++$this->y; for ($i = 0; $i < $this->numcols; $i++) @@ -707,7 +714,8 @@ class FrontReport extends Spreadsheet_Excel_Writer_Workbook } closedir($d); } - meta_forward($_SERVER['PHP_SELF'], "xls=1&filename=$this->filename&unique=$this->unique_name"); + + meta_forward($path_to_root.'/reporting/prn_redirect.php', "xls=1&filename=$this->filename&unique=$this->unique_name"); exit(); } }