A plain diode will automatically permit charging from the PV panel when called for. The diode will prevent the inverter from trying to charge the PV panels (if that situation ever occurs).
In a blackout I believe your inverter will automatically stop charging, and start inverting. I don't think you need to put a switching device between the battery and inverter.
Does your system have a transfer switch, to isolate it from the grid? That is important.
You don't want to send your high-V AC out to the street. You don't want to electrocute a lineman.