The RV outlet boxes are anchored by two fingers that swing out on diagonal corners. A finger may have broken or may simply have loosened. There are screws at the corners that pull the fingers against the inside of the wall. If the fingers are undamaged, you can loosen the screws, fold the fingers back against the box, and reinsert the box in the wall. Holding the box in place, tighten the screws. The first rotation of the screws swings the fingers out behind the wall. Tighten the screws, but do not over tighten.
If a finger on the old box is damaged, go to HD, Lowes, or such and buy a repair box, an outlet, and a plate. Ask if you need help choosing a repair box. The repair boxes attach to the wall with swinging fingers, just like RV outlets. With power off, detach the RV box and attach the wires to the new outlet through the rear openings in the repair box. Attach the box to the wall just like I described for the damaged RV outlet. Attach the plate and you are done.
John W. Irwin
2005 Classic 28 "Sabre-Dog III"
2013 Silverado 2500HD Duramax/Allison LTZ
WBCCI #9632, TAC TX-10