Topologically twisted SUSY gauge theory, gauge-Bethe correspondence and quantum cohomology