mybaits-plus中小细节

如果你在实体类中想定义一个对应数据库中没有的字段一定要加上,这是mybatis-plus的一个细节,这个主要用于后端需要向前端传一些数据库中没有的数据

点击查看代码
@TableField(exist = false)
private String teacher;

image
看这个数据库中没有这个字段
image

posted @ 2023-02-14 00:20  lipu123  阅读(13)  评论(0编辑  收藏  举报