The dog bit the child because it stepped on her foot. The OP should have kept the child away from the dog, if she couldnt do this she should have rehomed the poor bloody animal before hand. It is perfectly reasonable to rehome the dog in a home without children, where she can get a bit of peace and quiet. But of course, its only a dog!
If it was an unprovoked bite then i would agree that the dog had to be pts, but this sounds like the child doesn't leave the dog alone (dogs are not toys!) as the OP struggles to keep them apart as the child thinks the dog is his best friend
the OP said that the child trod on the dogs foot, so the dog snapped in retaliation.
Yes, the dog needs rehoming and that wont be easy now that the bite has been allowed to happen, but christ on a bike, surely she should at least TRY!!
I found myself in a very similar situation when my rottie bit my DD (see above post) i knew i couldnt keep him as i had a baby, dog came along before baby did, and i coudlnt garuntee to keep them separate - but i did everything in my power to find that dog a home, unfortunately it turned out that he had bone cancer and must have been agony for him when his leg trodden on (by accident - dog laying at bottom of stairs DD tried to step over, misjudged - 17 yo DD! not a toddler)
But hey, maybe the OP can get shot of this dog and get her child a new best friend
I dont care if i sound harsh, but had the OP came on saying anything other than i'll give the dog 24 hours and if i can't rehome then its PTS she would have gotten sympathy and advice.