Bug 5741

Summary: Extra comma causes JavaScript error in Internet Explorer
Product: Koha Reporter: Owen Leonard <oleonard>
Component: CirculationAssignee: Owen Leonard <oleonard>
Status: CLOSED FIXED QA Contact: Bugs List <koha-bugs>
Severity: normal    
Priority: PATCH-Sent (DO NOT USE) CC: chris, colin.campbell, gmcharlt, julian.maurice, reed
Version: Main   
Hardware: All   
OS: All   
GIT URL: Change sponsored?: Sponsored
Patch complexity: --- Documentation contact:
Documentation submission: Text to go in the release notes:
Version(s) released in:
Circulation function:
Attachments: Proposed fix
removes stray comma at end of js list in 8 files

Description Owen Leonard 2011-02-11 17:40:00 UTC
A trailing comma on the last item causes an error:

Calendar.setup(
  {
     inputField : "newduedate",
     ifFormat : "<!-- TMPL_VAR NAME="DHTMLcalendar_dateformat" -->",
     button : "newduedate_button",
     disableFunc : validate1,
     dateStatusFunc : validate1,
   }
);

See: http://wiki.koha-community.org/wiki/Coding_Guidelines#JavaScript
Comment 1 Owen Leonard 2011-02-11 17:42:14 UTC
Created attachment 3130 [details] [review]
Proposed fix
Comment 2 Reed Wade 2011-02-15 01:05:04 UTC
Created attachment 3154 [details] [review]
removes stray comma at end of js list in 8 files

This one probably obsoletes the earlier proposed fix. It covers more cases.
Comment 3 Reed Wade 2011-02-15 01:06:28 UTC
Catalyst work on this item sponsored by Opus.
Comment 4 Chris Cormack 2011-02-15 18:01:20 UTC
*** Bug 5762 has been marked as a duplicate of this bug. ***
Comment 5 Chris Cormack 2011-02-20 07:33:20 UTC
Signed off and pushed, please test
Comment 6 MJ Ray (software.coop) 2011-03-07 09:39:39 UTC
This bug is mentioned in:
Fix for Bug 5741 - Extra comma causes	JavaScript error in Internet Explorer http://lists.koha-community.org/pipermail/koha-patches/2011-February/013834.html
Bug 5741 - Extra comma causes JavaScript	error in Internet Explorer http://lists.koha-community.org/pipermail/koha-patches/2011-February/013865.html