提交 2419eaf6 作者: 恶龙咆哮

优化可以灵活查询各个状态

上级 2460f82e
...@@ -108,9 +108,10 @@ public interface PilotCertificationDao { ...@@ -108,9 +108,10 @@ public interface PilotCertificationDao {
/** /**
* 通过飞手id去获取飞手所在飞手团队的团队信息 * 通过飞手id去获取飞手所在飞手团队的团队信息
* @param pilotId 飞手id * @param pilotId 飞手id
* @param pilotStatus 查询不同状态 0飞手未操作 1飞手同意加入 2 飞手拒绝加入
* @return {@link CompanyInfoDO} * @return {@link CompanyInfoDO}
*/ */
CompanyInfoDO selectCompanyInfoByPilotId(Integer pilotId); CompanyInfoDO selectCompanyInfoByPilotId(Integer pilotId,Integer pilotStatus);
/** /**
......
...@@ -598,7 +598,7 @@ public class PilotCertificationServiceImpl implements PilotCertificationService ...@@ -598,7 +598,7 @@ public class PilotCertificationServiceImpl implements PilotCertificationService
@Override @Override
public ResultBody selectCompanyInfoByPilotId(Integer pilotId) { public ResultBody selectCompanyInfoByPilotId(Integer pilotId) {
CompanyInfoDO companyInfoDO = certificationDao.selectCompanyInfoByPilotId(pilotId); CompanyInfoDO companyInfoDO = certificationDao.selectCompanyInfoByPilotId(pilotId,0);
if (companyInfoDO == null) { if (companyInfoDO == null) {
return ResultBody.success(); return ResultBody.success();
} }
......
...@@ -143,7 +143,7 @@ public class UserAccountServiceImpl implements UserAccountService { ...@@ -143,7 +143,7 @@ public class UserAccountServiceImpl implements UserAccountService {
userAccountVO.setSubStatus(0); userAccountVO.setSubStatus(0);
} }
CompanyInfoDO companyInfoDO = certificationDao.selectCompanyInfoByPilotId(userAccountId); CompanyInfoDO companyInfoDO = certificationDao.selectCompanyInfoByPilotId(userAccountId,1);
if(companyInfoDO !=null) { if(companyInfoDO !=null) {
CompanyInfoVO companyInfoVO = companyInfoDO.buildCompanyInfoVO(); CompanyInfoVO companyInfoVO = companyInfoDO.buildCompanyInfoVO();
userAccountVO.setCompanyInfoVO(companyInfoVO); userAccountVO.setCompanyInfoVO(companyInfoVO);
......
...@@ -490,6 +490,6 @@ ...@@ -490,6 +490,6 @@
ci.phone_num, ci.remark, ci.create_time,ci.brand_logo, ci.brand_name, ci.license_img, ci.credit_code, ci.content, ci.score,ci.lon,ci.lat, ci.back_img ci.phone_num, ci.remark, ci.create_time,ci.brand_logo, ci.brand_name, ci.license_img, ci.credit_code, ci.content, ci.score,ci.lon,ci.lat, ci.back_img
FROM company_info ci INNER JOIN company_back_user cbu ON ci.id = cbu.company_info_id FROM company_info ci INNER JOIN company_back_user cbu ON ci.id = cbu.company_info_id
INNER JOIN pilot_join_team pjt on pjt.back_user_id = cbu.back_user_account_id INNER JOIN pilot_join_team pjt on pjt.back_user_id = cbu.back_user_account_id
WHERE pjt.pilot_user_id = #{pilotId} and ci.is_deleted = 0 and pjt.pilot_status = 0 WHERE pjt.pilot_user_id = #{pilotId} and ci.is_deleted = 0 and pjt.pilot_status = #{pilotStatus}
</select> </select>
</mapper> </mapper>
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论