package bdqn.newsManageServlet.Service.Impl;
import bdqn.newsManageServlet.Dao.UserDao;
import bdqn.newsManageServlet.Dao.Impl.UserDaoImpl;
import bdqn.newsManageServlet.Service.UserService;
import bdqn.newsManageServlet.entity.User;
public class UserServiceImpl implements UserService {
UserDao userdao=new UserDaoImpl();
public User getLoginUser(String uName, String pwd, String msg) {
User user=userdao.getLoginUser(uName);
if(user==null){
msg="用户名错误";
}else{
if(!user.getUserPassword().equals(pwd)){
msg="密码错误";
}
}
msg="";
return user;
}
}