package com.pcloud.book.group.dao.impl;

import com.pcloud.book.group.dao.BookQrcodeUserDao;
import com.pcloud.book.group.entity.BookQrcodeUser;
import com.pcloud.book.group.vo.GroupQrcode4ClassifyVO;
import com.pcloud.common.core.dao.BaseDaoImpl;

import org.springframework.stereotype.Component;

import java.util.HashMap;
import java.util.Map;

/**
 * @author lily
 * @date 2019/4/30 11:18
 */
@Component("bookQrcodeUserDao")
public class BookQrcodeUserDaoImpl extends BaseDaoImpl<BookQrcodeUser> implements BookQrcodeUserDao {

    @Override
    public GroupQrcode4ClassifyVO getUserQrcode(Long classifyId, Long wechatUserId) {
        Map<String, Object> paramMap = new HashMap();
        paramMap.put("classifyId", classifyId);
        paramMap.put("wechatUserId", wechatUserId);
        return this.getSqlSession().selectOne(this.getStatement("getUserQrcode"), paramMap);
    }
}
