30 lines
923 B
Plaintext
30 lines
923 B
Plaintext
|
|
package com.nationalelectric.greenH5.service;
|
||
|
|
|
||
|
|
import java.util.List;
|
||
|
|
|
||
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
||
|
|
import org.springframework.jdbc.core.BeanPropertyRowMapper;
|
||
|
|
import org.springframework.stereotype.Service;
|
||
|
|
|
||
|
|
import com.nationalelectric.greenH5.po.GreenInternalUser;
|
||
|
|
import com.sgcc.uap.persistence.IHibernateDao;
|
||
|
|
|
||
|
|
@Service
|
||
|
|
public class InternalUserService {
|
||
|
|
|
||
|
|
@Autowired
|
||
|
|
private IHibernateDao hibernateDao;
|
||
|
|
|
||
|
|
/**
|
||
|
|
* 根据用户名和手机号 和单位 查询
|
||
|
|
* @param userName
|
||
|
|
* @param phoneNum
|
||
|
|
* @return
|
||
|
|
*/
|
||
|
|
public List<GreenInternalUser> getListByNameAndPhone(String userName,String phoneNum) {
|
||
|
|
String sql = "select * from green_internal_user where name = ? and phone = ? ";
|
||
|
|
List<GreenInternalUser> list = hibernateDao.queryForListWithSql(sql, new Object[]{userName, phoneNum},new BeanPropertyRowMapper<GreenInternalUser>(GreenInternalUser.class) );
|
||
|
|
return list;
|
||
|
|
}
|
||
|
|
}
|