I did factory reset and it still doesn't work. It turns off when working normally, and when it tries to restart, there's only the lg logo and the led in different colours.
Battery seems to be good. It charges without any problem.
I've figured out that my phone turns off after locking it. After 5 seconds or so the phone tries to restart, but it just appears the lg logo and the led light in different colours.