ILSGateway, EWSGhana changes

http://manage.dimagi.com/default.asp?148847#837455
http://manage.dimagi.com/default.asp?134684#831319
http://manage.dimagi.com/default.asp?148852#831253
changes in checkpoint according to discussion in google group.  
@czue @twymer
i optimized this function slightly, but i think this could be a source of speedup. though probably not worth spending too much effort on since the number of products is so low.