| | |
| | | |
| | | import com.java110.common.util.StringUtil; |
| | | import com.java110.core.base.dao.BaseServiceDao; |
| | | import com.java110.entity.order.ServiceBusiness; |
| | | import com.java110.entity.service.ServiceSql; |
| | | import com.java110.service.dao.IQueryServiceDAO; |
| | | import org.slf4j.Logger; |
| | | import org.slf4j.LoggerFactory; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | |
| | |
| | | @Service("queryServiceDAOImpl") |
| | | @Transactional |
| | | public class QueryServiceDAOImpl extends BaseServiceDao implements IQueryServiceDAO { |
| | | |
| | | private final static Logger logger = LoggerFactory.getLogger(QueryServiceDAOImpl.class); |
| | | |
| | | /** |
| | | * 防止sql注入 改造成直接用prepareStatement 预处理sql |
| | |
| | | }finally{ |
| | | try { |
| | | //conn.close(); |
| | | ps.close(); |
| | | rs.close(); |
| | | if( ps!=null) { |
| | | ps.close(); |
| | | } |
| | | if(rs != null) { |
| | | rs.close(); |
| | | } |
| | | } catch (SQLException e) { |
| | | e.printStackTrace(); |
| | | } |
| | |
| | | public List<ServiceSql> qureyServiceSqlAll() { |
| | | return sqlSessionTemplate.selectList("queryServiceDAOImpl.qureyServiceSqlAll"); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 查询服务业务信息 |
| | | * @return |
| | | */ |
| | | public List<ServiceBusiness> qureyServiceBusiness(){ |
| | | return sqlSessionTemplate.selectList("queryServiceDAOImpl.queryServiceBusiness"); |
| | | } |
| | | } |