I had several years of losing most of my beans and peas to rabbits and woodchucks in my fenced garden. I had a trench dug 6"deep around the bottom of the fence and fencing buried at an angle facing out. Haven't had a problem in the garden since. Except from the #@!&# mice and voles that eat my beets. Nothing I have found stops them.
Edited to add - rabbit makes great pasta sauce as well as stew.