maven中一对多(不需在数据库中写外键) maven中一对多(不需在数据库中写外键) 在POJO中: (把外键在这里定义---->ordersId外键) 在Mapper.xml中: 在js中添加的方法: 在data中外键ordersId 不需写成 orders.ordersId