We prove the existence of a phase transition for a stochastic model of interacting neurons. The spiking activity of each neuron is represented by a point process having rate $1 $ whenever its membrane potential is larger than a threshold value. This membrane potential evolves in time and integrates the spikes of all {\it presynaptic neurons} since the last spiking time of the neuron. When a neuron spikes, its membrane potential is reset to $0$ and simultaneously, a constant value is added to the membrane potentials of its postsynaptic neurons. Moreover, each neuron is exposed to a leakage effect leading to an abrupt loss of potential occurring at random times driven by an independent Poisson point process of rate $\gamma > 0 .$ For this process we prove the existence of a value $\gamma_c$ such that the system has one or two extremal invariant measures according to whether $\gamma > \gamma_c $ or not.