Problem creating issue in Back end v1.6.0

10 years 2 weeks ago - 10 years 2 weeks ago #1 by chrisc
There has been a problem identified where in Issue Tracker 1.6.0 upon Joomla 3.2
it is not possible to save a new issue in the back end (admin) part of the site.

The problem shows itself typically with a message as follows:

Error 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1 SQL=SELECT name FROM `#__it_custom_field_group` AS cfg LEFT JOIN `#__it_projects` AS p ON p.customfieldsgroup = cfg.id WHERE p.id =

Where #_ is your database prefix.

The problem is caused by p.id field being empty, since the field would not have been populated at the time of the call.

Fix required in back end view.html.file for getCustomFieldGroup method.

In the file admin/components/com_issuetracker/views/itissue/view.html.php

Around line 220 (just before end of file) there is a function named getCustomGroupName.

Change the function so it looks like the following:
function getCustomGroupName($pid)
{
$gname = null;
if ( !empty($pid) ) {
$db = JFactory::getDBO();
$query = 'SELECT name FROM `#__it_custom_field_group` AS cfg ';
$query .= ' LEFT JOIN `#__it_projects` AS p ';
$query .= ' ON p.customfieldsgroup = cfg.id ';
$query .= ' WHERE p.id = '.$pid;
$db->setQuery( $query );
$gname = $db->loadResult();
}

if (empty($gname) || $gname == '')
$gname = JText::_( 'COM_ISSUETRACKER_CUSTOMFIELDS' );
return $gname;
}

The fix will be included in the next release 1.6.1. Saving new issues from the front end is not impacted. Joomla 2.5 installations also do not seem to be impacted.

Regards

If you are using our extensions please leave a review at the JED: IP Mapping | Issue Tracker | JAudit | Password Control
The following user(s) said Thank You: zanc

Please Log in or Create an account to join the conversation.

Time to create page: 0.134 seconds
Go To Top

Joomla! Debug Console

Session

Profile Information

Memory Usage

Database Queries