Entanglement detection by Bragg scattering