📄 customerdao.java
字号:
package com.yuanchung.sales.dao.customer;
import java.util.List;
import org.springframework.dao.DataAccessException;
import com.yuanchung.sales.model.businessOpportunity.BusinessOpportunity;
import com.yuanchung.sales.model.customer.Customer;
import com.yuanchung.sales.model.customer.CustomerContact;
import com.yuanchung.sales.model.service.CustAccount;
import com.yuanchung.sales.model.user.User;
import com.yuanchung.sales.model.userDefined.UserDefined;
import com.yuanchung.sales.model.userDefined.UserField;
import com.yuanchung.sales.model.userDefined.UserFilter;
public interface CustomerDAO {
// 根据用户取得所有的客户
public List getByUser(User user, int flag) throws DataAccessException ;
public List getByUser(String userIds, int flag);
public void save(Customer customer) throws DataAccessException;
public void saveUserDefined(UserDefined userDefined) throws DataAccessException;
public void saveUserFilter(UserFilter userFilter) throws DataAccessException;
public void saveUserField(UserField userField) throws DataAccessException;
///根据用户和类型查找选项
public List getUserDefinedByUserAndType(User user, int type) throws DataAccessException;
public List<Customer> getByUserAndUserDefined(User user, UserDefined userDefined) throws DataAccessException;
public UserDefined getUserDefinedById(int userDefinedId) throws DataAccessException;
public List<Customer> getCustomerByUserHql(String hql) throws DataAccessException;
//根据选项查找自定义选项
public UserField getUserFieldByOption(UserDefined userDefined) throws DataAccessException;
public Customer getById(int customerId) throws DataAccessException;
public void update(Customer customer) throws DataAccessException;
public void delete(Customer customer) throws DataAccessException;
//根据选项搜索过滤选项
public List getUserFilterByOption(UserDefined userDefined) throws DataAccessException;
//更新用户选项
public void updateUserDefined(UserDefined userDefined) throws DataAccessException;
//根据id查询过滤条件
public UserFilter getUserFilter(int id) throws DataAccessException;
//更新过滤条件
public void updateUserFilter(UserFilter userFilter) throws DataAccessException;
//根据选项搜索显示字段
public UserField getUserFieldByUserDefined(UserDefined userDefined) throws DataAccessException;
//修改显示字段
public void updateUserField(UserField userField) throws DataAccessException;
//删除过滤条件
public void deleteFilter(UserFilter userFilter) throws DataAccessException;
//显示左边页面的最新的客户;
public List<Customer> getTopCustomer() throws DataAccessException;
//根据客户名称搜索客户;
public List<Customer> getCustomerByName(String nameLike) throws DataAccessException;
//删除客户状态;
public void clearCustomer(Integer id) throws DataAccessException;
//罗列出被冻结的客户;
public List getCustomerByDelete(User user, int flag) throws DataAccessException;
//删除客户以及相关信息;
public boolean deleteCustomerAndSome(Integer id) throws DataAccessException;
//根据客户搜索联系人
public List getCusConByCus(Customer customer) throws DataAccessException;
//根据客户搜索业务机会;
public List getOpportByCus(Customer customer) throws DataAccessException;
//根据业务机会搜索业务活动;
public List getPlanByOpport(BusinessOpportunity businessOpportunity) throws DataAccessException;
//根据业务活动搜索业务记录;
//删除业务机会;
public boolean deleteOpport(BusinessOpportunity bo) throws DataAccessException;
//删除该客户的联系人;
//public boolean deleteCusCon(List listCusCon) throws DataAccessException;
//删除相关用户联系人列表
public boolean deleteListUserCon(List listUserCon) throws DataAccessException;
//删除该客户相关联系人;
public boolean deleteCusCon(CustomerContact cusCon) throws DataAccessException;
//搜索用户联系人列表;
public List getUserConListByCusCon(CustomerContact cusCon) throws DataAccessException;
//修改该客户的联系人;
public boolean updateCusCon(CustomerContact cusCon) throws DataAccessException;
//修改业务机会;
public boolean updateOpport(BusinessOpportunity businessOpportunity) throws DataAccessException;
//-------------------------------更新后--------------------------------------------//
//根据客户ID搜索联系人
public List findContactByCustomerId(int customerId) throws DataAccessException;
//根据客户ID搜索业务机会
public List findBusiOpportByCustomerId(int customerId) throws DataAccessException ;
//查找最新保存的客户
public Customer getCustomerLastest() throws DataAccessException;
//查找上次修改人
public User getUserById(int userId) throws DataAccessException;
//更新客户的状态
public void updateCustomers(int modifyManId, String modifiTime, int customerId, int flag) throws DataAccessException;
//根据名称模糊查找所有的客户
public List getCustoemrsByNameLike(int flag, User user, String name) throws DataAccessException;
//************小洪2009-2-28**************//
//取得ID最大的客户
public Customer getCustomerByMaxId();
//保存客户账号
public void saveCustAccount(CustAccount custAccount);
//**************end******************/
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -