// Path: src/main/java/co/lilpilot/blog/model/User.java
// @Data
// @Entity
// public class User extends BaseModel {
//     @ApiModelProperty(value = "用户名")
//     private String username;
//     @ApiModelProperty(value = "密码（md5）")
//     private String passwordHashed;
//     @ApiModelProperty(value = "角色")
//     private String role;
// }
// 
// Path: src/main/java/co/lilpilot/blog/repository/UserRepository.java
// @Repository
// public interface UserRepository extends JpaRepository<User, Long> {
//     User findByUsername(String username);
// }


import co.lilpilot.blog.model.User;
import co.lilpilot.blog.repository.UserRepository;
import com.google.common.base.Strings;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
import org.springframework.stereotype.Service;
import org.springframework.util.StringUtils;
package co.lilpilot.blog.service;


/**
 * Created by lilpilot on 2017/5/2.
 */
@Service
public class UserService {

    @Autowired
// Path: src/main/java/co/lilpilot/blog/model/User.java
// @Data
// @Entity
// public class User extends BaseModel {
//     @ApiModelProperty(value = "用户名")
//     private String username;
//     @ApiModelProperty(value = "密码（md5）")
//     private String passwordHashed;
//     @ApiModelProperty(value = "角色")
//     private String role;
// }
// 
// Path: src/main/java/co/lilpilot/blog/repository/UserRepository.java
// @Repository
// public interface UserRepository extends JpaRepository<User, Long> {
//     User findByUsername(String username);
// }


// Path: src/main/java/co/lilpilot/blog/service/UserService.java
import co.lilpilot.blog.model.User;
import co.lilpilot.blog.repository.UserRepository;
import com.google.common.base.Strings;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
import org.springframework.stereotype.Service;
import org.springframework.util.StringUtils;

package co.lilpilot.blog.service;


/**
 * Created by lilpilot on 2017/5/2.
 */
@Service
public class UserService {

    @Autowired
    private UserRepository userRepository;