刚解决,试了网上多种方法都未解决哦。

最后通过打开 File — Project Structure — JDK location:在Use embedded JDK(recommended)前打钩,完美解决