update events around purchase function
Merge branch 'wsi-master' of https://github.com/robpointmarc/pointmarc-public into wsi-master