提交 4f8164e5 作者: han

获取飞手团队管理员ID以及飞手手机号相关接口

上级 c5302c8c
......@@ -200,11 +200,17 @@ public class PilotCertificationController extends BaseController {
return certificationService.selectPilotIdList(this.getUserLoginInfoFromRedis(request).getUserAccountId());
}
@ApiOperation(value = "查询飞手的团队信息(团队管理员的ID)")
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = TeamMessageDO.class)})
@GetMapping("/selectPilotTeam")
public TeamMessageDO selectPilotTeam(@RequestParam Integer pilotId){
return certificationService.selectPilotTeam(pilotId);
@ApiOperation(value = "查询飞手的团队管理员的ID")
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = Integer.class)})
@GetMapping("/selectPilotTeamManagerId")
public Integer selectPilotTeamManagerId(@RequestParam Integer pilotUserId){
return certificationService.selectPilotTeam(pilotUserId);
}
;
@ApiOperation(value = "查询飞手的手机号")
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = Integer.class)})
@GetMapping("/getPilotApplyPhone")
public String getPilotApplyPhone(@RequestParam Integer pilotId){
return certificationService.getPilotApplyPhone(pilotId);
}
}
......@@ -159,5 +159,5 @@ public interface PilotCertificationDao {
/**
* 通过通过飞手ID查询飞手的团队信息
*/
TeamMessageDO selectPilotTeam(Integer pilotId);
Integer selectPilotTeam(Integer pilotUserId);
}
......@@ -61,7 +61,11 @@ public interface PilotCertificationService {
List<Integer> selectPilotIdList(Integer backUserId);
/**
* 通过通过飞手ID查询飞手的团队信息
* 通过通过飞手用户ID查询飞手的团队信息
*/
TeamMessageDO selectPilotTeam(Integer pilotId);
Integer selectPilotTeam(Integer pilotUserId);
/**
* 通过飞手id查询飞手的手机号
*/
String getPilotApplyPhone(Integer pilotId);
}
......@@ -670,8 +670,13 @@ public class PilotCertificationServiceImpl implements PilotCertificationService
}
@Override
public TeamMessageDO selectPilotTeam(Integer pilotId) {
return certificationDao.selectPilotTeam(pilotId);
public Integer selectPilotTeam(Integer pilotUserId) {
return certificationDao.selectPilotTeam(pilotUserId);
}
@Override
public String getPilotApplyPhone(Integer pilotId) {
return certificationDao.getPilotApplyPhone(pilotId);
}
public JSONObject spellMsg(String name, String result){
......
......@@ -524,12 +524,12 @@
select phone_num from pilot_certification pc left join user_account ua on pc.user_account_id = ua.id
where pc.id = #{pilotId}
</select>
<select id="selectPilotTeam" resultType="com.mmc.iuav.user.model.dto.TeamMessageDO">
SELECT p.id AS pilotId, p.pilot_user_id AS pilotUserId, cm.user_account_id AS pilotMessageId
<select id="selectPilotTeam" resultType="java.lang.Integer">
SELECT cm.user_account_id
FROM pilot_join_team p
JOIN company_back_user cb ON p.back_user_id = cb.back_user_account_id
JOIN company_member cm ON cb.company_info_id = cm.company_info_id
WHERE p.id = #{pilotId};
WHERE p.pilot_user_id = #{pilotUserId};
</select>
</mapper>
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论