package com.service;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import com.dto.User;
import com.mapper.UserMapper;
@Service
@Transactional
public class UserService {
@Autowired
private UserMapper userMapper;
public int login(User user) {
User u = userMapper.login(user);
System.out.println(u);
if(u!=null){
return 1;
}else{
return 2;
}
}
}
没有必要成为谁,他们有的我没有,而我有的,他们未必有。
——钟汉良