Try googling Obsessive compulsive disorder. It is a habit thing.
If you can break the cycle, i.e. have him on a lead when you are watching TV and get him to lie down, or give him something he can chew on (other than his leg). As Annlinda said he needs plenty of exercise so he is tired when he gets home.
The biting of the back leg could be a lick granuloma, which is a difficult cycle to break, they chew, it irritates, so they chew etc. Try some anti chew spray (make sure its one you can use on open wounds).