Transition to chaos in a shell model of turbulence