My heart goes out to you, JackyB.
Whilst sympathetic to what serkeen says, I incline much more to the 'we are only human' approach. You didn't smack because you had a tummy upset, you smacked because you were not coping well. You probably also felt the pressure of feeling unwell during such a precious time.
In principle, when we can't quite cope, we admit so to the parents (or in my case, DH who helps with the GCs as well). However, life is not perfect, sometimes we think we are just about coping and something suddenly happens to show us that we are not.
Like all parents and all 'hands-on' grandparents, I have one or two 'not quite coping' stories. Like luckygirl, I have worked with children and families for my whole working life, and agree that we must put these occasions int perspective.
I genuinely think that children pick up the real love and care that is shown to them. Your GC, at a very intuitive level, picked up your love, please cherish that. I doubt that your DiL saw it - as she would probably have just called or jumped as an immediate reaction. If by any chance she did, she too has decided that your love & care counts highly on the positive balance.
My own advice would be 'learn from this'. Put it behind you as much as you can - but another time you are 'under the weather' say so, and apologise for not being quite as able to handle things - that means others will step in sooner.
I told DH this - on a day that both GCs were fractious and not good at responding well, DH had promised to do some DIY work around the house, to help (we go to GCs' house to do childcare). After the kind of day that I'm sure all grans can imagine, I decided that youngest child was teething - and accidentally gave him too much infant paracetamol.
I went to the prescribing website to check, and going by weight (rather than age, as on the bottle) I had just about given him an OK dose. So there was no danger, but my 'mistake' remained. Later I told DH that we must not promise to do that sort of work whilst doing child care - fortunately our relationships are such that is not an issue.