[Koha-patches] [PATCH 2/2] bug 3434 Fix SQL Syntax Error when setting claimdate

Chris Cormack chrisc at catalyst.net.nz
Thu Jul 23 11:57:49 CEST 2009


* Colin Campbell (colin.campbell at ptfs-europe.com) wrote:
> On 07/22/2009 08:36 PM, Joe Atzberger wrote:
> > Why not go farther and abstract the function so that it takes a status
> > argument too?  Have UpdateClaimdateIssues call it with 7.  Otherwise you
> > have to copy and paste this function for every status.
> Actually it would be an error to call it with any value other than 7. 
> There is an updateClaim which also updates the date on a single row 
> where status already is 7. We could possibly remove some duplication 
> there. Looking through the code readability would be enhanced by naming 
> the magic numbers (like 7) which at present you have to go to the 
> template to find out what they mean.
> 
Might be easy change to set them as constants, then use that, much
more readable that way

Chris

-- 
Chris Cormack
Catalyst IT Ltd.
+64 4 803 2238
PO Box 11-053, Manners St, Wellington 6142, New Zealand



More information about the Koha-patches mailing list