You could have a bad battery pack with one or more bad cells. When the battery is connected and you power the laptop, it draws too much juice and the charger dies.
First things first, you can just remove the battery and try reboot or test it with a different battery.
Chances are, you could have a bad power adapter or a bad motherboard as well.
How can you test to see if my motherboard is bad? Check out the [https://www.minitool.com/backup-tips/how-to-test-motherboard.html|post].