Bug 5476 - Harcoded date format en Members.pm -> GetMessages
Summary: Harcoded date format en Members.pm -> GetMessages
Status: CLOSED DUPLICATE of bug 5475
Alias: None
Product: Koha
Classification: Unclassified
Component: Patrons (show other bugs)
Version: rel_3_2
Hardware: All All
: P5 - low minor
Assignee: Kyle M Hall
QA Contact: Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-12-06 21:08 UTC by Martin Longo
Modified: 2012-10-26 00:41 UTC (History)
1 user (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Longo 2010-12-06 21:08:59 UTC
I have came across a problem with the messages system, as it displays the messages for the borrowers with a date format that is not the format chosen for the system in SysPrefs...

We use the dd/mm/yyyy date format system wide, and the messages have their dates in the mm/dd/yyyy format.

I backtraced the date that is printed with the message and found that this problematic format is harcoded in the GetMessage routine, inside the module Messages.pm, as can be seen in the following chunk of code...

my $query = "SELECT
                  branches.branchname,
                  messages.*,
                  DATE_FORMAT( message_date, '%m/%d/%Y' ) AS message_date_formatted,
                  messages.branchcode LIKE '$branchcode' AS can_delete
                  FROM messages, branches
                  WHERE borrowernumber = ?
                  AND message_type LIKE ?
                  AND messages.branchcode = branches.branchcode
                  ORDER BY message_date DESC";
Comment 1 Owen Leonard 2010-12-06 21:12:30 UTC

*** This bug has been marked as a duplicate of bug 5475 ***