[SOLVED] how to wire jack connector to rca connector?

Solution
When pointing a jack toward right, you'll have gnd at the innermost ring (the longest one), then left in the middle and right out at the tip.

Pointing toward right is just so that is easier to remember.
You can get an adaptor like this one for around a buck in any electronics store.
No reason to make one except for the experience, maybe.
Adaptor-RCA-2-x-to-a-single-3.5mm-500x500.webp
 
You have it right. One note for clarity. On the three-contact Tip-Ring-Sleeve connector if used in a stereo audio application, the TIP is the LEFT channel signal (Red in your diagram); the RING is the RIGHT channel (Blue in your diagram); the SLEEVE is the Common Ground.

On most commercially-sold cables and adapters, at the RCA connector ends and on RCA female sockets on audio input or output panels, the LEFT one is colour-coded WHITE, and the RIGHT is RED.