Seems like a damaged connection between the battery and the laptop internals if the battery itself works. I would recommend taking it to someone who is trained in laptop repair.
If you don't want to try to fix the battery connection issue, an external battery may work as it seems your DC jack...