/**
 * Copyright &copy; 2015-2020 <a href="http://www.jeeplus.org/">JeePlus</a> All rights reserved.
 */
package com.jeeplus.modules.workbidproject.dao;

import com.jeeplus.modules.workbidproject.entity.WorkBidProjectList;
import com.jeeplus.modules.workclientinfo.entity.WorkClientInfo;
import com.jeeplus.modules.sys.entity.Office;
import com.jeeplus.modules.sys.entity.User;
import java.util.List;
import com.jeeplus.common.persistence.CrudDao;
import com.jeeplus.common.persistence.annotation.MyBatisDao;
import com.jeeplus.modules.workbidproject.entity.WorkBidProject;
import com.jeeplus.modules.workproject.entity.WorkProject;

/**
 * 投标项目DAO接口
 * @author mengxy
 * @version 2017-05-27
 */
@MyBatisDao
public interface WorkBidProjectDao extends CrudDao<WorkBidProject> {

	public List<WorkClientInfo> findListBybidCompany(WorkClientInfo bidCompany);
	public List<Office> findListByimplementingDept(Office implementingDept);
	public List<User> findListByprojectMaster(User projectMaster);
	//一览表
	public List<WorkBidProjectList> findLists(WorkBidProjectList workBidProjectList);
	/**
	 * 取得工程成员用户数据
	 * @param workBidProject
	 * @return
	 */
	public List<String> getProjectMember(WorkBidProject workBidProject);
	
	
	
	/**
	 * 取得工程成员用户数据
	 * @param workBidProject
	 * @return
	 */
	public List<String> getProjectMaster(WorkBidProject workBidProject);
	
	
	/**
	 * 插入工程成员用户数据
	 * @param workBidProject
	 * @return
	 */
	public int insertProjectMember(WorkBidProject workBidProject);
	
	/**
	 * 插入工程负责人用户数据
	 * @param workBidProject
	 * @return
	 */
	public int insertProjectMaster(WorkBidProject workBidProject);
	
	/**
	 * 删除工程用户关联数据
	 * @param workBidProject
	 * @return
	 */
	public int deleteProjectUser(WorkBidProject workBidProject);

	/**
	 *  删除成员用户和资格预审工程关联表数据
	 * @param workBidProject
	 * @return
	 */
	public int deleteProjectMember(WorkBidProject workBidProject);


	/**
	 * 删除负责人用户和资格预审工程关联表数据 
	 * @param workBidProject
	 * @return
	 */
	public int deleteProjectMaster(WorkBidProject workBidProject);
	
	
	
	
	/**
	 * 取得工程实施部门数据
	 * @param workBidProject
	 * @return
	 */
	public List<String> getImplementingDept(WorkBidProject workBidProject);
	
	
	
	/**
	 * 插入工程实施部门数据
	 * @param workBidProject
	 * @return
	 */
	public int insertImplementingDept(WorkBidProject workBidProject);
	
	/**
	 * 删除工程实施部门数据
	 * @param workBidProject
	 * @return
	 */
	public int deleteImplementingDept(WorkBidProject workBidProject);

	/**
	 * 更新流程实例ID
	 * @param workBidProject
	 * @return
	 */
	public int updateProcessInstanceId(WorkBidProject workBidProject);

	/**
	 * 根据流程实例ID获取Leave
	 * @param processInstanceId
	 * @return
	 */
	public WorkBidProject getByProcessInstanceId(String processInstanceId);

	//根据总项目外键获取
	public WorkBidProject getByPId(WorkProject workProject);


    void updateForTans(WorkBidProject workBidProject);

    //更新投标保证金交付提醒标记
	public int updateGiveDateSign(WorkBidProject workBidProject);

	public List<WorkBidProject> findListByGiveDate(WorkBidProject workBidProject);

	//更新投标保证金确认提醒标记
	public int updateBidDateSign(WorkBidProject workBidProject);

	public List<WorkBidProject> findListByBidDate(WorkBidProject workBidProject);
	//单独查总数
	int queryCount(WorkBidProject workBidProject);
}