Skip to content
Snippets Groups Projects
Commit 2c9cbcbd authored by Carsten  Rose's avatar Carsten Rose
Browse files

Report.php: fixed problem that columns with '_...' are displayed.

parent 00bf127c
No related branches found
No related tags found
No related merge requests found
......@@ -152,7 +152,30 @@ New Button
* Client does not save the modified record.
* Client stays on current page.
Formelement type: DATE / DATETIME / TIME
----------------------------------------
* Available Formats:
* 'yyyy-mm-dd' = FORMAT_DATE_INTERNATIONAL.
* 'dd.mm.yyyy' = FORMAT_DATE_GERMAN.
* The 'DATE_FORMAT' can be specified systemwide in `config.ini`
* The default format is FORMAT_DATE_INTERNATIONAL.
* Optional: 'dateFormat' can be specified per form element in `form.parameter` - this overwrites 'systemwide'.
* If there is no placeholder defined on the form element, the defined dateFormat is shown as placeholder.
* Browser:
* checks the input with a system regexp.
* regexp might be user defined. If given, do not use system regexp!
* No min/max check.
* Server:
* check with system wirde regexp
* regexp might be user defined. If given, do not use system regexp!
* Do min/max check.
* MySQL data: 1000-01-01 - 9999-12-31 and 0000-00-00
* MySQL time: 00:00:00 - 23:59:59
* datetime format: 'DATE TIME'
Debug / Log / Errormessages
===========================
......
......@@ -493,8 +493,9 @@ class Report {
$this->store->setVar(SYSTEM_REPORT_COLUMN_NAME, $keys[$ii], STORE_SYSTEM);
$this->store->setVar(SYSTEM_REPORT_COLUMN_VALUE, $row[$ii], STORE_SYSTEM);
$renderedColumn = $this->renderColumn($ii, $keys[$ii], $row[$ii], $full_level, $rowIndex);
if ($renderedColumn != '') {
$flagOutput = false;
$renderedColumn = $this->renderColumn($ii, $keys[$ii], $row[$ii], $full_level, $rowIndex, $flagOutput);
if ($flagOutput) {
//prints
$content .= $this->variables->doVariables($fsep);
$content .= $this->variables->doVariables($this->frArray[$full_level . "." . "fbeg"]);
......@@ -517,10 +518,13 @@ class Report {
* @return string rendered column
* @throws SyntaxReportException
*/
private function renderColumn($columnIndex, $columnName, $columnValue, $full_level, $rowIndex) {
private function renderColumn($columnIndex, $columnName, $columnValue, $full_level, $rowIndex, &$flagOutput) {
$content = "";
$flagControl = false;
$flagOutput = true;
if (substr($columnName, 0, 1) == "_") {
$flagControl = true;
$columnName = substr($columnName, 1);
}
......@@ -714,7 +718,7 @@ class Report {
# reconstruct remaining parameters
$arr = implode("|", $remain);
# render
$content = $this->renderColumn($columnIndex, $columnName, $arr, $full_level, $rowIndex);
$content = $this->renderColumn($columnIndex, $columnName, $arr, $full_level, $rowIndex, $flagOutput);
if ($newFinalColumnName)
$columnName = $newFinalColumnName;
......@@ -729,9 +733,14 @@ class Report {
break;
default :
$content .= $columnValue;
if ($flagControl) {
$flagOutput = false;
} else {
$content .= $columnValue;
}
break;
}
$this->variables->resultArray[$full_level . "."][$columnName] = $content;
return $content;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment