In Mozart K 545, mm. 22-23, I've always played the short appoggiaturas (e.g. B-C, D#-E) before the beat, because that's what they sound like to me on recordings. Apparently my ears are mistaken, as I recently discovered a detailed edition that indicates on-the-beat timing. Nonetheless, the on-the-beat timing sounds odd to me.
There are no hard rules for playing ornaments on or before the beat. Except that in Baroque music, on the beat is mostly the norm. Don't worry about it too much.