Electrical transport and magnetic properties of the triangular-lattice compound Zr$_2$NiP$_2$