package cn.com.countrygarden.bi.main.dao.bigholderSatisfy;

import java.util.List;

import org.apache.ibatis.annotations.Param;

import com.github.pagehelper.PageRowBounds;

import cn.com.countrygarden.bi.main.model.BigholderLandEstate;
import cn.com.countrygarden.bi.main.model.BigholderSatisfacationInfo;

public interface BigholderSatisfyMapper1 {

	/**
	 * 通过月份和地区来查找
	 * 
	 * @param yearMon
	 * @param area
	 * @return
	 */
	public List<BigholderSatisfacationInfo> getSelectByMonAndArea(@Param(value = "yearMonth") String yearMonth,
			@Param(value = "area") String area);

	/**
	 * 通过月份和多个地区来查找
	 * 
	 * @param yearMon
	 * @param area
	 * @return
	 */
	public List<BigholderSatisfacationInfo> getSelectByMonAndAreas(@Param(value = "yearMonth") String yearMonth,
			@Param(value = "areas") List<String> areas);

	/**
	 * 通过月份和地区和审核状态来查找
	 * 
	 * @param yearMon
	 * @param area
	 * @return
	 */
	public List<BigholderSatisfacationInfo> getSelectByMonAreaAduit(@Param(value = "yearMonth") String yearMonth,
			@Param(value = "area") String area, @Param(value = "aduitStruts") List<String> aduitStruts);

	/**
	 * 通过月份和地区和审核状态来查找
	 * 
	 * @param yearMon
	 * @param area
	 * @return
	 */
	public List<BigholderSatisfacationInfo> getSelectByMonAreasAduit(@Param(value = "yearMonth") String yearMonth,
			@Param(value = "areas") List<String> areas, @Param(value = "aduitStruts") List<String> aduitStruts);

	/**
	 * 修改对应的项目
	 * 
	 * @param yearMonth
	 * @param area
	 * @param correspondProject
	 * @param id
	 * @param commName 
	 */
	public void updateBigholderSatisfy(@Param(value = "correspondProject") String correspondProject,
			@Param(value = "id") String id, @Param(value="commName")String commName);

	/**
	 * 修改推送状态
	 * 
	 * @param bigholderSatisfacationInfo
	 */
	public void updateAuditIsPush(BigholderSatisfacationInfo bigholderSatisfacationInfo);

	/**
	 * 修改审核转态
	 * 
	 * @param bigholderSatisfacationInfo
	 */
	public void updateAuditStatus(BigholderSatisfacationInfo bigholderSatisfacationInfo);

	/**
	 * 查看满意度信息
	 * 
	 * @param id
	 * @return
	 */
	public BigholderSatisfacationInfo getViewInfo(@Param(value = "id") String id);

	/**
	 * 修改异常信息
	 * 
	 * @param id
	 * @param exceptionInfoAuditStruts
	 * @param exceptionMessage
	 * @return
	 */

	public void updateExceptionStatus(@Param(value = "id") String id,
			@Param(value = "exceptionStruts") String exceptionStruts,
			@Param(value = "exceptionMessage") String exceptionMessage);

	/**
	 * 删除异常信息
	 * 
	 * @param id
	 * @return
	 */
	public void deleteExceptionStatus(@Param(value = "id") String id);

	/**
	 * 修改区域和对应的项目
	 * 
	 * @param bigholderSatisfacationInfo
	 */
	public void updateAreaOrProjectName(BigholderSatisfacationInfo bigholderSatisfacationInfo);

	/**
	 * 修改驳回信息
	 * 
	 * @param bigholderSatisfacationInfo
	 */
	public void updateRejectedInfo(BigholderSatisfacationInfo bigholderSatisfacationInfo);

	/**
	 * 批量删除
	 * 
	 * @param list1
	 */
	public void deleteById(@Param(value = "list1") List<BigholderSatisfacationInfo> list1);

	/**
	 * 通过项目id查询
	 * 
	 * @param commId
	 * @param yearMon
	 * @param area 
	 * @return
	 */
	public List<BigholderSatisfacationInfo> selectByErpCommunity(@Param(value = "commId") String commId,
			@Param(value = "yearMon") String yearMon, @Param(value="area")String area);

	/**
	 * 查询当前月份和区域下的同一个对应项目名称的不同id的数据列表
	 * 
	 * @param yearMonth
	 * @param area
	 * @param id
	 * @param correspondProject
	 * @return
	 */
	public BigholderSatisfacationInfo selectByNoThisId(@Param(value = "yearMonth") String yearMonth,
			@Param(value = "area") String area, @Param(value = "id") String id,
			@Param(value = "correspondProject") String correspondProject);

	/**
	 * 通过区域和对应项目来查找
	 * 
	 * @param area
	 * @param correspondProject
	 * @param yearMonth
	 * @return
	 */
	public List<BigholderSatisfacationInfo> getSfInfoByAreaOProject(@Param(value = "area") String area,
			@Param(value = "correspondProject") String correspondProject, @Param(value = "yearMonth") String yearMonth);

	/**
	 * 通过月份和原始项目名来查找
	 * 
	 * @param yearMonth
	 * @param projectName
	 * @param area
	 * @return
	 */
	public List<BigholderSatisfacationInfo> getByProNameOrYear(@Param(value = "year") List<String> year,
			@Param(value = "projectName") String projectName, @Param(value = "area") String area);

	public List<BigholderSatisfacationInfo> getSelectByMonAndArea(PageRowBounds pageRowBounds,
			@Param(value = "yearMonth") String yearMonth, @Param(value = "area") String area);

	/**
	 * 查询所有问卷列表
	 * 
	 * @param yearMonth
	 * @return
	 */
	public List<BigholderSatisfacationInfo> findAll(@Param(value = "yearMonth") String yearMonth);

	public List<BigholderSatisfacationInfo> getByAreaOrProName(@Param(value = "area") String area,
			@Param(value = "projectName") String projectName);

	public List<BigholderSatisfacationInfo> findAllByArea(@Param(value = "area") String area);

	public List<BigholderSatisfacationInfo> getSelectByYearAndArea(@Param(value = "year") List<String> yearMonth,
			@Param(value = "area") String area);

	public List<BigholderSatisfacationInfo> getByMonsAndArea(@Param(value = "yearMonth") List<String> yearMonth,
			@Param(value = "area") String area);

	public List<BigholderSatisfacationInfo> getBSByProNameOrMonYear(@Param(value = "yearMonth") List<String> yearMonth,
			@Param(value = "projectName") String projectName, @Param(value = "area") String area);

	public List<BigholderSatisfacationInfo> getSelectByYearAndArea(PageRowBounds pageRowBounds,
			@Param(value = "year") List<String> yearMonth, @Param(value = "area") String area);

	public List<BigholderSatisfacationInfo> getByMonsAndArea(PageRowBounds pageRowBounds,
			@Param(value = "yearMonth") List<String> yearMonth, @Param(value = "area") String area);
	
	/**
	 * 导入时间
	 */
	public List<BigholderSatisfacationInfo> importTime(@Param(value="yearMonth") String yearMonth);
	
	/**
	 * 更新所有状态
	 * @param bigholderSatisfacationInfo
	 */
	public void updateAllStatus(BigholderSatisfacationInfo bigholderSatisfacationInfo);
}