I work in a collision repair/body shop and to fix non textured trim pieces and the like we use a 3m brand 2 part epoxy called "super fast plastic repair". You can find it on ebay or anywhere else. It's kind of expensive but really does hold up. Here is what you do:
1) Sand BEHIND with a piece of 80 or 120 grit (in a pinch 180 or 220 would probably work but go no higher than 320) to get it the surface kind of crunchy to allow the epoxy to "bite" to it.
2) Clean the area with some isopropyl alcohol, make sure it has evaporated. Clean the spot two or three times with the alcohol to be sure your rag is coming up clean.
3) Get an "acid brush" and a piece of paper/cardboard and mix up the solution. This stuff sets extremely fast, literally 20 seconds.
4) Spread it inside and hold the piece together for a full minute then allow it to cure for an hour.
5) To fix up some small cracks that may appear on the outside surface you could use some 3m flexible plastic repair to inject into the crack (same deal as before sand with 80 or 120 to allow the epoxy to bite to it). And then you can go in steps starting with 180 grit working up to 320 to get it flat.
6) Spray primer over the surface, sand the primer to feather-edge it out.
7) Spray another coat of primer and this time use red (for white plastic) or gray/green (for black plastic) scotch brite to prep the surface.
😎 Paint it!
If you go this route make sure you get some extra "static mixing nozzles" because this plastic stuff setups insanely fast and after 20 seconds they are junk. The scotch brite must be the real stuff, not the kind you get in the grocery store for cleaning your pans that stuff is way too aggressive and may show fine scratches in your paint surface after all the paint fully cures after a few days.
The flexible plastic repair epoxy is meant for bumpers and rubber trim pieces. Obviously it is flexible so it won't just completely crack like most epoxies. You could use any other brand besides 3M, but we use 3M exclusively at the shop I am at so I can't recommend any other brands but as long as it's all stuff rated for collision repair it should be more than overkill for some plastic parts that won't be subject to extreme vibrations like on a car 😀.