DPersonReceptionDao.java 988 Bytes
package com.viontech.keliu.dao;

import com.viontech.keliu.entity.DPersonReception;
import org.springframework.jdbc.core.BeanPropertyRowMapper;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.stereotype.Repository;

import javax.annotation.Resource;
import java.util.Date;
import java.util.List;

/**
 * Created with IntelliJ IDEA.
 *
 * @author: zhuhai
 * Date: 2023-12-23
 * Time: 15:51
 */
@Repository
public class DPersonReceptionDao {

    @Resource
    private JdbcTemplate jdbcTemplate;


    public List<DPersonReception> getPersonReceptionList(Long mallId, Date countDate, String personUnid, Date startTime, Date endTime) {
        String sql  = "select * from d_person_reception where mall_id = ? and count_date = ? and person_unid = ? and start_time >= ? and end_time <= ? order by start_time;";
        return jdbcTemplate.query(sql, new BeanPropertyRowMapper<>(DPersonReception.class), mallId, countDate, personUnid, startTime, endTime);
    }
}