|
|
@@ -13,6 +13,7 @@ import com.template.model.pojo.SmartRelation;
|
|
|
import com.template.mapper.SmartRelationMapper;
|
|
|
import com.template.model.pojo.SmartUser;
|
|
|
import com.template.model.result.PageUtils;
|
|
|
+import com.template.model.vo.SmartRelationVo;
|
|
|
import com.template.model.vo.UserVo;
|
|
|
import com.template.services.SmartAccessService;
|
|
|
import com.template.services.SmartFaceDiscernService;
|
|
|
@@ -56,8 +57,8 @@ public class SmartRelationServiceImpl extends ServiceImpl<SmartRelationMapper, S
|
|
|
SmartRelationMapper smartRelationMapper;
|
|
|
|
|
|
@Async
|
|
|
- @Scheduled(cron = "0 0 1 * * ? ")//每天凌晨一点
|
|
|
-// @Scheduled(cron = "0 41 10 * * ? ")//每天凌晨一点
|
|
|
+ @Scheduled(cron = "0 20 0 * * ? ")//每天凌晨一点
|
|
|
+// @Scheduled(cron = "0 10 14 * * ? ")//每天凌晨一点
|
|
|
public void getAccessSmartRelation() {
|
|
|
if (scheduleConfig.getIsOpen().equals("1")) {
|
|
|
DateTimeFormatter pattern = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
|
|
|
@@ -119,7 +120,7 @@ public class SmartRelationServiceImpl extends ServiceImpl<SmartRelationMapper, S
|
|
|
}
|
|
|
|
|
|
@Async
|
|
|
- @Scheduled(cron = "0 0 3 * * ? ")//每天凌晨两点
|
|
|
+ @Scheduled(cron = "0 40 2 * * ? ")//每天凌晨两点
|
|
|
// @Scheduled(cron = "0 25` * * * ? ")//每天凌晨两点
|
|
|
public void getFaceDiscernListSmartRelation() {
|
|
|
if (scheduleConfig.getIsOpen().equals("1")) {
|
|
|
@@ -184,12 +185,12 @@ public class SmartRelationServiceImpl extends ServiceImpl<SmartRelationMapper, S
|
|
|
|
|
|
|
|
|
@Override
|
|
|
- public PageUtils<SmartRelation> getPage(int currentPage, int pageCount, Integer userId) {
|
|
|
-// Page<UserVo> page = new Page<>();
|
|
|
-// page.setCurrent(currentPage);
|
|
|
-// page.setSize(pageCount);
|
|
|
-// IPage<WarningUserDto> result = smartUserMapper.warningUserList(page, name);
|
|
|
-// return new PageUtils(result);
|
|
|
- return null;
|
|
|
+ public PageUtils<SmartRelationVo> getList(int currentPage,int pageCount,Integer userId, String startTime, String endTime) {
|
|
|
+ Page<SmartRelationVo> page = new Page<>();
|
|
|
+ page.setCurrent(currentPage);
|
|
|
+ page.setSize(pageCount);
|
|
|
+ IPage<SmartRelationVo> result =smartRelationMapper.getList(page,userId,startTime,endTime);
|
|
|
+
|
|
|
+ return new PageUtils(result);
|
|
|
}
|
|
|
}
|