package com.palmnest.dao.washcar;

import com.palmnest.application.bean.Page;
import com.palmnest.dao.GenericDao;
import com.palmnest.model.washcar.Customer;

/**
 * 用户dao
 *
 * @author longmeizhen
 */
public interface CustomerDao extends GenericDao<Customer, Long> {
	/**
	 * 删除用户信息
	 *
	 * @param custId
	 * @param userId 操作用户(creator or modifier)
	 * @return
	 * @throws Exception
	 */
	public String deleteCustomer(Long custId, String userId) throws Exception;

	/**
	 * 获取用户列表
	 *
	 * @param mobile电话
	 * @param userName用户名
	 * @param carNumber车牌号
	 * @return
	 * @throws Exception
	 */
	public Page getCustList(String orgIds, String mobile, String userName, String carNumber, String searchStr, int pageNo, int pageSize) throws Exception;

	/**
	 * 根据电话号码查找用户
	 *
	 * @param mobile
	 * @return
	 * @throws Exception
	 */
	public Customer getCustByMobile(String orgId, String mobile) throws Exception;

	/**
	 * 根据openId查找用户
	 *
	 * @param mobile
	 * @return
	 * @throws Exception
	 */
	public Customer getCustByOpenId(String orgId, String openId) throws Exception;
}
