package com.iamberry.wechat.service.wechat.dao.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import com.iamberry.wechat.core.entity.wx.FirstJoinKey;
import com.iamberry.wechat.service.mapper.FirstJoinKeyMapper;
import com.iamberry.wechat.service.wechat.dao.FirstJoinKeyDAO;

@Repository
public class FirstJoinKeyDaoImpl implements FirstJoinKeyDAO{
	
	@Autowired
	private FirstJoinKeyMapper firstJoinKeyMapper;
	public void setFirstJoinKeyMaper(FirstJoinKeyMapper firstJoinKeyMapper) {
		this.firstJoinKeyMapper = firstJoinKeyMapper;
	}
	
	/**
	 * 查询首次回复
	 */
	@Override
	public FirstJoinKey getBywxpublicNO(String wxpublicNo) {
		// TODO Auto-generated method stub
		return firstJoinKeyMapper.selectOne(wxpublicNo);
	}
	
	/**
	 * 修改首次回复
	 */
	@Override
	public int updatebyFirstJoinKey(FirstJoinKey firstJoinKey) {
		// TODO Auto-generated method stub
		return firstJoinKeyMapper.updateOne(firstJoinKey);
	}
	
	/**
	 * 添加记录
	 */
	@Override
	public int addFirstJoinKey(FirstJoinKey firstJoinKey) {
		// TODO Auto-generated method stub
		return firstJoinKeyMapper.addOne(firstJoinKey);
	}
	
	
	
}
