Hi, I hope it works out for the best, but the stator being down to earth doesn't bode well. I think what's happening is that just one phase has shorted with the chassis. So when you unplug it for testing there is no path for the fault current to take via the chassis because it's completely disconnected from the 12v system. Hence the voltage tests look fine. With the plugs connected and everything back in circuit, then there is a fault path between the stator and the 12v side of the system.
If my theory is correct then you ought to be able to measure AC voltage being generated between 2 of the phases and the bike chassis with it unplugged, but I hope I'm wrong for your sake.