| | |
| | | package com.fgkj.services; |
| | | |
| | | import com.fgkj.dto.ServiceModel; |
| | | import com.fgkj.dto.User_battmaint_check; |
| | | import com.fgkj.dto.User_battmaint_check_process; |
| | | import com.fgkj.dto.User_inf; |
| | | import com.fgkj.mapper.impl.User_battmaint_check_processMapper; |
| | |
| | | |
| | | import java.util.List; |
| | | |
| | | import javax.annotation.Resource; |
| | | @Service |
| | | public class User_battmaint_check_processService { |
| | | |
| | | @Autowired |
| | | @Resource |
| | | private User_battmaint_check_processMapper mapper; |
| | | @Autowired |
| | | @Resource |
| | | private User_infMapper userInfMapper; |
| | | |
| | | public ServiceModel add(Object obj) { |
| | |
| | | return model; |
| | | } |
| | | //4.10根据User_battmaint_check的num查询User_battmaint_check_process对应的数据 |
| | | public ServiceModel serchByCondition(Object obj){ |
| | | public ServiceModel serchByCondition(User_battmaint_check obj){ |
| | | ServiceModel model = new ServiceModel(); |
| | | List<User_battmaint_check_process> list=mapper.serchByCondition(obj); |
| | | int usr_id=0;//编辑人 |
| | |
| | | for (int i = 0; i <list.size(); i++) { |
| | | User_inf uinf=new User_inf(); |
| | | usr_id=list.get(i).getUsr_id(); |
| | | uinf.setUId(usr_id); |
| | | usr_name=((User_inf)userInfMapper.serchUname(uinf).get(0)).getUName(); |
| | | uinf.setuId(usr_id); |
| | | List<User_inf> user_infs = userInfMapper.serchUname(uinf); |
| | | if (user_infs!=null&&user_infs.size()>0) { |
| | | usr_name = user_infs.get(0).getuName(); |
| | | } |
| | | list.get(i).setUsr_name(usr_name); |
| | | } |
| | | //System.out.println(list); |