Ticket #5562 (closed patch: fixed)

Opened 1 year ago

Last modified 7 months ago

Report column title prefixed

Reported by: prasad Assigned to: sandeep
Priority: minor Milestone: 5.1.0
Component: vtigercrm Version: 5.1.0-val1
Keywords: Cc:

Description

Issue 1:

The report columns are prefixed with module name (without applying) translation to the labels!

e.g. HelpDesk? is used instead of Trouble Tickets.

Issue 2:

When report is created with only one module there is no need to prefix the column title. This will improve the usability.

Attachments

before_patch.JPG (16.0 kB) - added by Pierluigi.Bucolo on 06/03/09 02:36:01.
Fields names before changeset 12851
After_patch.JPG (14.4 kB) - added by Pierluigi.Bucolo on 06/03/09 02:36:36.
Fields names After changeset 12851

Change History

05/20/09 04:01:28 changed by asha

  • status changed from new to closed.
  • resolution set to fixed.

This issue is fixed Post 5.1.0 Validation build 2

05/31/09 13:44:59 changed by Pierluigi.Bucolo

The prefix in the column name is always present.

It seems that the $modules is empty in the follow function (modules/Reports/ReportRun.php):

function getLstringforReportHeaders($fldname)

{

global $modules,$current_language,$current_user,$app_strings; $rep_header = ltrim(str_replace($modules," ",$fldname)); .......

}

Replacing the row with:

$rep_header = ltrim(str_replace("HelpDesk?"," ",$fldname));

the report columns are displayed without module name.

05/31/09 13:46:02 changed by Pierluigi.Bucolo

  • status changed from closed to reopened.
  • resolution deleted.

06/03/09 01:05:54 changed by asha

  • status changed from reopened to closed.
  • resolution set to fixed.

This issue is fixed with the changeset - [12851]

06/03/09 02:34:57 changed by Pierluigi.Bucolo

  • status changed from closed to reopened.
  • resolution deleted.

Sorry, but the patch delete part of field name too.

See pictures, before and after changeset 12851 applied.

The rigth fields name are: Data Ritiro Comune Ticket No Descrizione Nominativo Indirizzo Telefono

06/03/09 02:36:01 changed by Pierluigi.Bucolo

  • attachment before_patch.JPG added.

Fields names before changeset 12851

06/03/09 02:36:36 changed by Pierluigi.Bucolo

  • attachment After_patch.JPG added.

Fields names After changeset 12851

06/11/09 00:29:46 changed by asha

  • status changed from reopened to closed.
  • resolution set to fixed.

This issue is fixed with the changeset [12873]

06/29/09 03:38:00 changed by Pierluigi.Bucolo

  • status changed from closed to reopened.
  • resolution deleted.

The coulumn are rigth if is used "Export to PDF" or "Export to Excel", but when I use "Print Report" the Module Name Prefix is present in each column.

One suggestion, add the Report Name in the Print Report, like it's in the Export to PDF.

06/29/09 09:48:07 changed by Pierluigi.Bucolo

Fix for Report Name Title (Print Report), file Smarty/templates/PrintReport.tpl

Originale Code: <td align="left" valign="top" style="border:0px solid #000000;"> <h2>{$MOD.REPORT_NAME}</h2> <font color="#666666"><div id="report_info"></div></font>

Modified Code (changed second row): <td align="left" valign="top" style="border:0px solid #000000;"> <h2>{$REPORT_NAME}</h2> <font color="#666666"><div id="report_info"></div></font>

Remaining open the issue in the Header Names, containt Module Name in when "Print Report" is clicked.

07/10/09 03:25:13 changed by Pierluigi.Bucolo

  • status changed from reopened to closed.
  • type changed from defect to patch.
  • resolution set to fixed.

Solved HEADER for the Print Report too.

Apply the patch attached.

07/10/09 03:32:35 changed by Pierluigi.Bucolo

}elseif($outputformat == "PRINT") {

$sSQL = $this->sGetSQLforReport($this->reportid,$filterlist); $result = $adb->query($sSQL); if($is_admin==false && $profileGlobalPermission[1] == 1 && $profileGlobalPermission[2] == 1) $picklistarray = $this->getAccessPickListValues();

if($result) {

$y=$adb->num_fields($result); $arrayHeaders = Array(); for ($x=0; $x<$y; $x++) {

$fld = $adb->field_name($result, $x); $headerLabel = str_replace("_"," ",$fld->name);

/* DELETE THE ROWS INSIDE REMARK

  • if(in_array($this->getLstringforReportHeaders($fld->name), $arrayHeaders))

{

$headerLabel = str_replace("_"," ",$fld->name); $arrayHeaders[] = $headerLabel;

} else {

$headerLabel = str_replace($modules," ",$this->getLstringforReportHeaders($fld->name)); $arrayHeaders[] = $headerLabel;

}

*/

// END - DELETE