Summary:
After install, admin section of module does not work
Detailed Description:
After installing (with the patch in bug #10371 -
http://dev.cmsmadesimple.org/bug/view/10371), the admin section does not work. A
page with the following text is displayed:
Tickets
Settings
My Tickets List Templates
Manage Tickets List Templates
New Ticket Form Templates
View Ticket Report Templates
Prototype Templates
SELECT SQL_CALC_FOUND_ROWS T.id, T.owner, T.alert_group, T.e_key1, T.e_key2,
T.e_key3, T.status, T.priority, T.created, COUNT(M.id) AS nmsgs, M.subject,
MAX(M.modified) AS modified_date, S.n_unread FROM cms_mod_cgct_tickets T LEFT
JOIN cms_mod_cgct_msgs M ON T.id = M.ticket_id LEFT JOIN (SELECT
ticket_id,COUNT(id) AS n_unread FROM cms_mod_cgct_msgs WHERE dest < 0 AND
viewed_by IS NULL GROUP BY ticket_id) S ON T.id = S.ticket_id GROUP BY T.id
ORDER BY modified_date DESC LIMIT 0, 100 Expression #11 of SELECT list is not in
GROUP BY clause and contains nonaggregated column 'cmsms-2.1.3.M.subject' which
is not functionally dependent on columns in GROUP BY clause; this is
incompatible with sql_mode=only_full_group_by
The reason is that, in the SQL query, M.subject is selected while it's not in
the GROUP BY clause.
Solution is to change line 43 in class.TicketListResultest.php. "M.subject"
should be replaced with "( select subject from '.CGST_MSGS_TABLE.' where
ticket_id = T.id order by sent desc limit 1 ) as subject"
The complete line then becomes:
$cols =
explode(',','T.id,T.owner,T.alert_group,T.e_key1,T.e_key2,T.e_key3,T.status,T.priority,T.created,COUNT(M.id)
AS nmsgs, ( select subject from '.CGST_MSGS_TABLE.' where ticket_id = T.id order
by sent desc limit 1 ) as subject, MAX(M.modified) AS modified_date');