How to repair disconnected battery connector MacBook Air 2011
There is no easy fix.

You may be able to salvage the battery connector.  If you can get it back into place and secure it with some tape and the the Mac functions, chances are the connector can be soldered back to the board.  (This is not a permanent fix, only a diagnostic)

If not, the connector and/or logic board needs to be repaired.

Either way, you won't be able to do this with a soldering iron - you will need a hot air re-flow gun and some technical skill to do this without un-soldering or heat damaging the components near it.

There are companies that specialize in repairs like this and are quite good at this type of repair.  They would be your best bet for repairing this type of damage.