| | |
| | | <!--派遣记录分页数据--> |
| | | <select id="selectDispatcherPage" resultType="org.springblade.modules.dispatcher.vo.DispatcherVO"> |
| | | select |
| | | sd.*,bu.real_name securityName,sdu.name dispatcherCompany,bu.cardid idCardNo |
| | | sd.*, |
| | | bu.real_name securityName,sdu.name dispatcherCompany,bu.cardid idCardNo,bu.phone securityPhone, |
| | | bd.dept_name deptName, |
| | | sdu.linkman,sdu.phone |
| | | from |
| | | sys_dispatcher sd |
| | | left join |
| | |
| | | blade_user bu |
| | | on |
| | | bu.id = sd.user_ids |
| | | left join |
| | | blade_dept bd |
| | | on |
| | | bd.id = bu.dept_id |
| | | where 1=1 |
| | | and bu.status =1 |
| | | and bu.is_deleted = 0 |
| | | <if test="dispatcher.dispatcherUnitId!=null"> |
| | | and sd.dispatcher_unit_id = #{dispatcher.dispatcherUnitId} |
| | | </if> |
| | |
| | | </if> |
| | | </select> |
| | | |
| | | <!--查询派遣的保安员数量--> |
| | | <select id="getDispatcherNum" resultType="java.lang.Integer"> |
| | | select |
| | | ifnull(count(*),0) |
| | | from |
| | | sys_dispatcher |
| | | where 1=1 |
| | | and status = 0 |
| | | and dispatcher_unit_id = #{dispatcher.id} |
| | | </select> |
| | | |
| | | </mapper> |