As far as the affair is concerned, I don't think something like that needs to sink a presidential candidacy. But in a primary where there are lots of other options, it's a serious problem. And you can't let your campaign be about your sexual misdeeds, which is basically what had happened to the Cain campaign. I guess that's what can happen to candidates who have lots of misdeeds and poor-to-mediocre top-level campaign staff. I don't think even the best management would've saved him, but things got a lot weirder than I imagine they would've with the best and brightest in charge.
I imagine that part of the reason Republicans got so excited about Cain was that they liked the idea of playing the race card back against Democrats. It's not so much that they thought he'd win black voters (though I'm sure some of them had unreasonable ambitions of stealing black voters from Obama). It's more that a lot of them feel that accusations of racism have been unjustly used as a political weapon against them, and they were pleased at the thought of having that weapon in their hands to use against their enemies.
Of all the bad things Cain has done, the one that I felt the most upset about came recently, when his campaign attacked the various women accusing him of sexual harassment and affairs for being "husbandless." I've had the good fortune to be briefly involved with a few husbandless ladies in the past few months, and I won't stand for anyone saying nasty things about them. I know he's done a lot worse than that stray remark, but I guess it just really got to me.