The old water squirting trick should be a last resort for stopping problem behaviors. There are much more proactive ways of training your dog out of problem barking. Keep in mind that barking is totally natural for a JRT and is part and parcel of the breed. That said, you can control the behavior to a reasonable extent. Take a look at this page: