Optimized fabrication of NiCr2O4 and its electrochemical performance in half-cell and full-cell lithium ion batteries