Hi @isaacnewto53724
Use a strong light and a magnifying glass to check if there's any lint etc in the charge port enclosure that may be causing a poor electrical connection between the charger and the port.
If there is any there, ''do not'' use a metal pin or probe to try and clear it out as using it may damage the pins or cause electrical problems in the phone. Try using a vacuum cleaner to see if it can remove it.
If the port seems clear it may be a loose USB-C connector. If it is, it may be easier to replace the charge port board, rather than trying to resolder all the pins of a USB-C connector back onto the charge port board.
Here's a [https://www.youtube.com/watch?v=1xYPpRiY8Yk|video] that shows how to replace the charge port board in the phone.
Search online for [https://www.google.com/search?client=firefox-b-d&q=Xiaomi+Redmi+Note+7+Pro+charge+port+board|Xiaomi Redmi Note 7 Pro charge port board] to find suppliers that suit you best (examples only).
If doing this yourself seems too daunting, contact a reputable, professional mobile phone repair service and ask for a quote to repair the phone.