金融供应链平台后端
本项目基于Spring Boot & MyBatis
- Model内成员变量建议与表字段数量对应,如需扩展成员变量(比如连表查询)建议创建DTO,否则需在扩展的成员变量上加
@Transient
注解,详情见通用Mapper插件文档说明 - 建议业务失败直接使用
ServiceException("message")
抛出,由统一异常处理器来封装业务失败的响应结果,比如throw new ServiceException("该手机号已被注册")
,会直接被封装为{"code":400,"message":"该手机号已被注册"}
返回,无需自己处理,尽情抛出 - 开发规范建议遵循阿里巴巴Java开发手册(最新版下载)
- Spring Boot(查看Spring Boot学习&使用指南)
- MyBatis(查看官方中文文档)
- MyBatisb通用Mapper插件(查看官方中文文档)
- MyBatis PageHelper分页插件(查看官方中文文档)