package cn.autoform.fw.web.service;
|
|
import java.util.List;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.stereotype.Service;
|
|
import cn.autoform.bean.User;
|
import cn.autoform.fw.TargetDataSource;
|
import cn.autoform.fw.mapper.UserManMapper;
|
|
@Service
|
public class UserService {
|
@Autowired
|
private UserManMapper userMapper;
|
|
public List<User> findAll() {
|
return userMapper.findAll();
|
}
|
|
public User insert(User addedUser) {
|
return null;
|
}
|
|
public User findOne(String id) {
|
return null;
|
}
|
|
public User save(User updatedUser) {
|
return null;
|
}
|
|
public void delete(String id) {
|
throw new UnsupportedOperationException();
|
}
|
|
@TargetDataSource(name="ds1")
|
public User findByUsername(String username) {
|
return userMapper.findByUsername(username);
|
}
|
}
|