I think it's obvious why Riley was promoted
He was the son professor Wash desperately but did not have.
A platoon leader is not such a high ranking position, nor is a TA. He may well actually have done well (he has of course, dealt with 16 hostiles). We haven't seen any of it though. As an audience, all we have seen is him fail at whatever he tries and have a really inflated opinion of himself. Flashbacks were used to establish the vampires (Spike. Angel, Darla, and Drusilla) as legitimate badasses, it would have been nice to have seen a few similar scenes with Riley, it would have made his character easier to take seriously.