package com.template.services.impl; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.template.mapper.SmartAuthorGroupMapper; import com.template.model.pojo.SmartAttendance; import com.template.mapper.SmartAttendanceMapper; import com.template.services.SmartAttendanceService; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.util.StringUtils; import java.util.List; /** *

* 楼栋表 服务实现类 *

* * @author ceshi * @since 2023-12-25 */ @Service public class SmartAttendanceServiceImpl extends ServiceImpl implements SmartAttendanceService { @Autowired private SmartAttendanceMapper smartAttendanceMapper; @Override public List queryAttendances(String startDate, String endDate) { QueryWrapper queryWrapper = new QueryWrapper<>(); queryWrapper.ge(StringUtils.hasText(startDate), "attend_time", startDate);//大于等于 queryWrapper.le(StringUtils.hasText(endDate), "attend_time", endDate);//小于等于 List result = smartAttendanceMapper.selectList(queryWrapper); return result; } }