提交 02bbb860 作者: 刘明祎-运维用途

Merge branch 'develop'

流水线 #7833 已通过 于阶段
in 2 分 21 秒
......@@ -39,6 +39,7 @@ public interface PilotCertificationDao {
List<PilotCertificationDO> pilotList(PilotCertificationQO param);
int pilotListCount(PilotCertificationQO param);
/**
* 查询这个用户是否绑定飞手团队
* @param userId 飞手id
......
......@@ -138,6 +138,13 @@ public class PilotCertificationServiceImpl implements PilotCertificationService
@Override
public PageResult pilotList(PilotCertificationQO param) {
int pilotListSize = certificationDao.pilotListCount(param);
if(pilotListSize < 1) {
return PageResult.buildPage(param.getPageNo(), param.getPageSize(), pilotListSize, null);
}
Integer pageNo = param.getPageNo();
param.buildCurrentPage();
List<PilotCertificationDO> pilotList = certificationDao.pilotList(param);
......@@ -191,7 +198,7 @@ public class PilotCertificationServiceImpl implements PilotCertificationService
}
}
}
PageResult pageResult = PageResult.buildPage(pageNo, param.getPageSize(), pilotList.size(), collect);
PageResult pageResult = PageResult.buildPage(pageNo, param.getPageSize(), pilotListSize, collect);
return pageResult;
}
......
......@@ -556,6 +556,43 @@
inner join company_member cm on cm.company_info_id = cbu.company_info_id
where cm.user_account_id = #{userId} limit 1
</select>
<select id="pilotListCount" resultType="java.lang.Integer">
SELECT
count(*)
FROM
pilot_certification pc
LEFT JOIN real_name_auth rna ON pc.user_account_id = rna.user_account_id
LEFT JOIN user_account ua ON pc.user_account_id = ua.id
LEFT JOIN pilot_reason pr ON pc.reason_id = pr.id
left join pilot_join_team pjt on pjt.pilot_user_id = ua.id
WHERE
1 = 1
AND ua.`disable` = 0
AND rna.is_deleted =0
<if test=" areaNumber != null and areaNumber != '' ">
and pc.area_number =#{areaNumber}
</if>
<if test=" id != null ">
and pc.id =#{id}
</if>
<if test=" licenseType != null and licenseType != '' ">
and pc.license_type =#{licenseType}
</if>
<if test=" auditStatus != null ">
and pc.audit_status =#{auditStatus}
</if>
<if test="accountNumber != null and accountNumber != '' ">
and ( pc.user_account_id like concat('%',#{accountNumber},'%')
or rna.user_name like concat('%',#{accountNumber},'%')
or ua.phone_num like concat('%',#{accountNumber},'%'))
</if>
<if test="backUserId != null">
and pjt.back_user_id = #{backUserId} and pjt.pilot_status = 1
</if>
<if test="isTeam == 1">
and pjt.back_user_id is not null and pjt.pilot_status = 1
</if>
</select>
</mapper>
......@@ -18,4 +18,4 @@ patches:
images:
- name: REGISTRY/NAMESPACE/IMAGE:TAG
newName: mmc-registry.cn-shenzhen.cr.aliyuncs.com/sharefly-dev/cms
newTag: bcbb780e01ea45e7995837afec4ad62c87babdd1
newTag: cc45806733feb5663997b70a4e08c411052f3b3c
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论