找到生成代码的entity类的主键字段

/**id*/
@TableId(type = IdType.ASSIGN_ID)
@ApiModelProperty(value = "id")
private java.lang.Integer id;

 

把上面的 type = IdType.ASSIGN_ID 改成 type = IdType.AUTO 即可

 

@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id")
private java.lang.Integer id;

 

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-01-22
  • 2021-12-10
  • 2021-12-13
  • 2022-12-23
  • 2021-12-22
猜你喜欢
  • 2021-12-05
  • 2022-12-23
  • 2022-12-23
  • 2022-01-22
  • 2021-12-17
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案