Commit 84dcb2ef authored by wujipeng's avatar wujipeng
Browse files

优化

parent 0cb3dc3c
......@@ -39,7 +39,12 @@ public class ContractServiceImpl extends ServiceImpl<ContractDao, ContractEntity
@Override
public List<ContractVO> listSecondLevel(String homId) {
return baseMapper.listSecondLevel(homId);
List<ContractVO> list = baseMapper.listSecondLevel(homId);
for (ContractVO contractVO : list) {
int l = (int) DateUtils.daysBetween(new Date(), contractVO.getEndTime());
contractVO.setRemainingDays(l);
}
return list;
}
@Override
......
......@@ -18,6 +18,8 @@
contract
where
parent_id is null
and
user_id = #{userId}
order by
begin_time
desc
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment