Move delete payment note JS into payments object and make a few minor improvements. #1190