升级mybatis-plus到3.5.1
This commit is contained in:
@@ -27,9 +27,4 @@ public class SuperEntity<T extends Model<?>> extends Model<T> {
|
||||
private Date createTime;
|
||||
@TableField(fill = FieldFill.INSERT_UPDATE)
|
||||
private Date updateTime;
|
||||
|
||||
@Override
|
||||
protected Serializable pkVal() {
|
||||
return this.id;
|
||||
}
|
||||
}
|
||||
|
||||
+1
-1
@@ -42,7 +42,7 @@ public class SuperServiceImpl<M extends BaseMapper<T>, T> extends ServiceImpl<M,
|
||||
) {
|
||||
if (lock != null) {
|
||||
//判断记录是否已存在
|
||||
int count = super.count(countWrapper);
|
||||
long count = super.count(countWrapper);
|
||||
if (count == 0) {
|
||||
return super.save(entity);
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user