|
@@ -43,7 +43,7 @@ public class FosterRecordServiceImpl extends ServiceImpl<IFosterRecordMapper, Fo
|
|
|
|
|
|
@Transactional
|
|
@Transactional
|
|
@Override
|
|
@Override
|
|
- public boolean addFosterRecord(FosterRecordAddDTO addDTO) {
|
|
|
|
|
|
+ public Integer addFosterRecord(FosterRecordAddDTO addDTO) {
|
|
int tenantId = StpAppUtil.getTokenSession().getInt("tenantId");
|
|
int tenantId = StpAppUtil.getTokenSession().getInt("tenantId");
|
|
// 一个用户在同一个果园只能认领一棵树
|
|
// 一个用户在同一个果园只能认领一棵树
|
|
FosterRecord fosterRecord = this.lambdaQuery()
|
|
FosterRecord fosterRecord = this.lambdaQuery()
|
|
@@ -81,6 +81,6 @@ public class FosterRecordServiceImpl extends ServiceImpl<IFosterRecordMapper, Fo
|
|
fosterRecord.setUpdatedTime(LocalDateTime.now());
|
|
fosterRecord.setUpdatedTime(LocalDateTime.now());
|
|
this.save(fosterRecord);
|
|
this.save(fosterRecord);
|
|
}
|
|
}
|
|
- return true;
|
|
|
|
|
|
+ return fosterRecord.getBirdseyeTreeId();
|
|
}
|
|
}
|
|
}
|
|
}
|