Hi,
I have the same issue, and don't know what to do. I've fresh installed the latest Rom, Miui 9.3 8.2.1 beta, on my Mi 5x, and the problem still persists.
To charge it I have to shutdown it down with the power button. After restarting, it charges again.
Did you find a solution, or still have...