Measure the voltage at the AC Adapter plug, and see if it is within 5-10% of the rated voltage. If the voltage is not correct, then the battery will most likely not be charging, and the system will drain the battery and die in the middle of what it was doing...booting in your case.
You can tell how much voltage is remaining in your battery and if it is charging by checking the blinking of the battery status light.
Download the Hardware Maintenance Manual here:
http://download.lenovo.com/UserFiles/UserGuide/en/User%27s%20guides%20and%20manuals/Z370&Z470&Z570/Lenovo%20Z370Z470Z570%20Hardware%20Maintenance%20Manual%20V1.0.pdf
and go to page 30 and look at item 7 under battery status for blinking light meaning.
1. Blinking amber: (500ms off/1s on)
The remaining power of the battery is less than 5% of
its capacity.
2. Blinking amber: (100ms off/3.2s on)
The battery is being charged with the remaining
power between 5% and 20% of its capacity.
3. Amber: The computer is operating on battery power with the
remaining power between 5% and 20% of its
capacity
With the AC Adapter plugged in, and giving the correct voltage, If you are getting 1. Blinking Amber (light on for 1 sec, off for 1/2 second), then the battery is not being charged. Could be AC Adapter, Battery or Battery Circuit on motherboard. If the light is solid on 3. Amber, then the battery is not charging, and is draining.
Also make sure the power socket on the laptop is not loose or damaged. If it is, then it will need to be replaced.
I hope this gets you in the right direction.