Because my three year old has just discovered Frozen, I was reading your post with the soundtrack Let It Goooooo!!
But in all seriousness -- the solution to this is in your hands, if you want to change it. You have to learn to let it go rather than try and change the past through wishing it different.
If feeling angry about petty things makes you unhappy, you could do something to change. But you have to be honest with yourself: do you like the feeling of stewing in a sense of anger and rage over small petty things? If you dothen all power to you (but maybe don't be surprised if you're stressed out or other people don't like hearing it!) If you don't like getting so wound up by petty things, then you can change your reaction. But the one thing you can't do is stop the world from serving you up occasional irritations. There will always be accidents, mistakes, slights, etc the snarkiest, sharpest comeback you can possibly imagine in your head won't actually save you from irritating things happening again some time in the future.
If you actually want to make it easier for yourself to stop getting upset about petty things try this: Separate out the thing that happened and is now in the past (the mistake over the tickets) from the thing that's making you feel crappy in the present (constantly stewing and ruminating over it, running scenarios through your head, etc). Ask yourself: How much misery did the thing that happened cause? Then how much extra misery is the ruminating causing? Add the two together, then then ask yourself: is the extra misery worth it, is it doing anything to help me get over the initial thing that happened, or is it just additional unhappiness?
You brought an extra ticket by mistake. Even though you'd like a refund, its not going to happen. That's done and dusted; you can't change that one bad thing that's happened to you now. But the second bad thing that's happening to you is this feeling of anger and irritation and ruminating. That's the thing that is, as you put it, taking over your head -- not the actual ticket mistake. If you really do want your head back, you can: you have to admit to yourself that the thing that's upsetting you now is your rumination, not the actual ticket mistake.
A (rather extreme) example but here goes: just before christmas, my partner spilt wine over my laptop. Laptop died instantly, with no chance to recover any of my data, and I don't have the money to replace it. So that was a really, really crappy thing to happen. But the worst had already happened! No amount of cursing and crying was going to undo it and bring my poor wine drenched macbook back to life. If I'd spent the next week being angry and upset about it, the only extra thing I would have achieved is ruining christmas and making my partner feel ashamed for what was, after all, an accident. I'd have just given myself more misery, if I'd carried on ruminating about it.