The most common cause of nuisance behaviours in dogs comes from them being bored. Dogs are social creatures and crave attention and affirmation.
Ignoring a dog for long stretches at a time and then reprimanding them for seeking attention is counter productive. Reprimands are a form of attention. Behaviours that earn the dog attention will increase in frequency. Reprimands only confuse the dog.
Keep you dog busy. Give them something to do.
When you take breaks, don't forget to pay attention to your dog.
Teach / Reward to relax in their bed.
Give your dog exercise, play and mental stimulation every day.