Ticket #5347 (new defect)

Opened 4 months ago

getRecordOwnerId() fails when group assigned to new module

Reported by: joebordes Assigned to: developer
Priority: unassigned Milestone: 5.1.0
Component: vtigercrm Version: 5.0.4
Keywords: Cc:

Description

In the include/utils/utils.php::getRecordOwnerId() function there is an if-else cascade to fetch the group that owns an entity. This cascade defaults to an sql that uses the construction:

select vtiger_groups.groupid from vtiger_".$module."grouprelation inner...

In the case of a new module, for example Timesheet, this ends up calling the table vtiger_Timesheetgrouprelation, which does not exist because the real table is all lower case letters (as all the rest in the application).

I propose converting the module name to lower case as the alternative of creating the database table in camelcase is a lot more work.

Joe TSolucio

Attachments

tolowmodulename4group.diff (0.8 kB) - added by joebordes on 09/05/08 17:15:35.
to lower module name for record owned by group

Change History

09/05/08 17:15:35 changed by joebordes

  • attachment tolowmodulename4group.diff added.

to lower module name for record owned by group