Global bifurcations in a dynamical model of recurrent neural networks