From 84bbab4689ea2690055ee89b4d5090ee74924309 Mon Sep 17 00:00:00 2001
From: fuliqi <fuliqi@qq.com>
Date: 星期一, 15 七月 2024 14:35:12 +0800
Subject: [PATCH] 海康api
---
ycl-server/src/main/java/com/ycl/platform/service/impl/TContractServiceImpl.java | 10 +++-------
1 files changed, 3 insertions(+), 7 deletions(-)
diff --git a/ycl-server/src/main/java/com/ycl/platform/service/impl/TContractServiceImpl.java b/ycl-server/src/main/java/com/ycl/platform/service/impl/TContractServiceImpl.java
index f26f06f..b48b540 100644
--- a/ycl-server/src/main/java/com/ycl/platform/service/impl/TContractServiceImpl.java
+++ b/ycl-server/src/main/java/com/ycl/platform/service/impl/TContractServiceImpl.java
@@ -198,11 +198,7 @@
@Override
public List<TContract> selectAll() {
- return list(new LambdaQueryWrapper<TContract>()
- .orderByDesc(TContract::getCreateTime))
- .stream().peek(
- tContract -> tContract.setUnitName(ywUnitService.getById(tContract.getUnitId()).getUnitName())
- ).toList();
+ return baseMapper.selectAll();
}
@Override
@@ -213,8 +209,8 @@
@Override
public List<TContract> selectUsingContract() {
return new LambdaQueryChainWrapper<>(baseMapper)
- .gt(TContract::getStartTime, DateUtils.getNowDate())
- .lt(TContract::getEndTime, DateUtils.getNowDate())
+ .le(TContract::getStartTime, DateUtils.getDate())
+ .ge(TContract::getEndTime, DateUtils.getDate())
.list();
}
}
--
Gitblit v1.8.0