楼下说的ExceptionHandle类中else里手写-1,"未知错误",我们可以修改return ResultUtil.error(-1,"未知错误");为GirlException girlException = new GirlException(ResultEnum.UNKNOWN_ERROR);
return ResultUtil.error(girlException.getCode(),girlException.getMessage());就不会硬编码了。
return ResultUtil.error(girlException.getCode(),girlException.getMessage());就不会硬编码了。
2017-11-30
我报错了~大佬们,你们有没有这个错误啊…
"status": 500,
"error": "Internal Server Error",
"exception": "org.springframework.orm.jpa.JpaSystemException",
"message": "The database returned no natively generated identity value; nested exception is org.hibernate.HibernateExcepti
"status": 500,
"error": "Internal Server Error",
"exception": "org.springframework.orm.jpa.JpaSystemException",
"message": "The database returned no natively generated identity value; nested exception is org.hibernate.HibernateExcepti
2017-11-28
本人的学习代码: https://github.com/liujingwei7/myClub.git
有需要的同学可以clone下来参考,每个项目都有相关说明
有需要的同学可以clone下来参考,每个项目都有相关说明
2017-11-26