修改考勤人员查询逻辑
parent
2c11fb72cb
commit
e34ff19559
|
@ -631,9 +631,9 @@ export default {
|
||||||
}
|
}
|
||||||
this.laborPersonnelTotal = 0
|
this.laborPersonnelTotal = 0
|
||||||
this.laborPersonnelData = [
|
this.laborPersonnelData = [
|
||||||
{ text: '劳务人员', value: func(['0', '2', '3', '4', '5']) },
|
{ text: '劳务人员', value: func(['4', '5']) },
|
||||||
{ text: '监理人员', value: func(['8']) },
|
{ text: '监理人员', value: func(['1']) },
|
||||||
{ text: '总包人员', value: func(['1', '6']) },
|
{ text: '总包人员', value: func(['1']) },
|
||||||
]
|
]
|
||||||
this.laborPersonnelData.forEach((it) => {
|
this.laborPersonnelData.forEach((it) => {
|
||||||
this.laborPersonnelTotal += it.value
|
this.laborPersonnelTotal += it.value
|
||||||
|
|
|
@ -1275,9 +1275,9 @@ export default {
|
||||||
|
|
||||||
this.laborPersonnelTotal = 0;
|
this.laborPersonnelTotal = 0;
|
||||||
this.laborPersonnelData = [
|
this.laborPersonnelData = [
|
||||||
{ text: "劳务人员", value: func(["0", "2", "3", "4", "5"]) },
|
{ text: "劳务人员", value: func(["4", "5"]) },
|
||||||
{ text: "监理人员", value: func(["8"]) },
|
{ text: "监理人员", value: func(["2"]) },
|
||||||
{ text: "总包人员", value: func(["1", "6"]) },
|
{ text: "总包人员", value: func(["1"]) },
|
||||||
];
|
];
|
||||||
this.laborPersonnelData.forEach((it) => {
|
this.laborPersonnelData.forEach((it) => {
|
||||||
this.laborPersonnelTotal += it.value;
|
this.laborPersonnelTotal += it.value;
|
||||||
|
|
|
@ -690,7 +690,7 @@ export default {
|
||||||
}
|
}
|
||||||
|
|
||||||
this.laborPersonnelTotal = 0;
|
this.laborPersonnelTotal = 0;
|
||||||
this.laborPersonnelData = [{ text: "劳务人员", value: func(["0", "2", "3", "4", "5"]) }, { text: "监理人员", value: func(["8"]) }, { text: "总包人员", value: func(["1", "6"]) }];
|
this.laborPersonnelData = [{ text: "劳务人员", value: func(["4", "5"]) }, { text: "监理人员", value: func(["2"]) }, { text: "总包人员", value: func(["1"]) }];
|
||||||
this.laborPersonnelData.forEach(it => {
|
this.laborPersonnelData.forEach(it => {
|
||||||
this.laborPersonnelTotal += it.value;
|
this.laborPersonnelTotal += it.value;
|
||||||
})
|
})
|
||||||
|
|
|
@ -48,7 +48,7 @@
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
||||||
<el-table v-loading="loading" :data="unitList" class="mytable" height="40vh"
|
<el-table :data="unitList" class="mytable" height="40vh"
|
||||||
style="width: 100%;background: transparent;" ref="tbUnit">
|
style="width: 100%;background: transparent;" ref="tbUnit">
|
||||||
<el-table-column label="单位类型" align="center" prop="type" />
|
<el-table-column label="单位类型" align="center" prop="type" />
|
||||||
<el-table-column label="单位" align="center" prop="deptName" />
|
<el-table-column label="单位" align="center" prop="deptName" />
|
||||||
|
|
|
@ -695,9 +695,9 @@ export default {
|
||||||
|
|
||||||
this.attendanceTotal = 0
|
this.attendanceTotal = 0
|
||||||
this.attendanceData = [
|
this.attendanceData = [
|
||||||
{ text: '劳务人员', value: func(['0', '2', '3', '4', '5']) },
|
{ text: '劳务人员', value: func(['4', '5']) },
|
||||||
{ text: '监理人员', value: func(['8']) },
|
{ text: '监理人员', value: func(['2']) },
|
||||||
{ text: '总包人员', value: func(['1', '6']) },
|
{ text: '总包人员', value: func(['1']) },
|
||||||
]
|
]
|
||||||
this.attendanceData.forEach((it) => {
|
this.attendanceData.forEach((it) => {
|
||||||
this.attendanceTotal += it.value
|
this.attendanceTotal += it.value
|
||||||
|
|
|
@ -504,9 +504,9 @@ export default {
|
||||||
|
|
||||||
this.attendanceTotal = 0;
|
this.attendanceTotal = 0;
|
||||||
this.attendanceData = [
|
this.attendanceData = [
|
||||||
{ text: "劳务人员", value: func(["0", "2", "3", "4", "5"]) },
|
{ text: "劳务人员", value: func(["4", "5"]) },
|
||||||
{ text: "监理人员", value: func(["8"]) },
|
{ text: "监理人员", value: func(["2"]) },
|
||||||
{ text: "总包人员", value: func(["1", "6"]) },
|
{ text: "总包人员", value: func(["1"]) },
|
||||||
];
|
];
|
||||||
this.attendanceData.forEach((it) => {
|
this.attendanceData.forEach((it) => {
|
||||||
this.attendanceTotal += it.value;
|
this.attendanceTotal += it.value;
|
||||||
|
|
|
@ -118,13 +118,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="companyTypeId!=null">
|
<if test="companyTypeId!=null">
|
||||||
<if test="companyTypeId>100">
|
<if test="companyTypeId>100">
|
||||||
<if test="companyTypeId==101">
|
<if test="companyTypeId==101">
|
||||||
and companyTypeId in (1,6)
|
and companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==102">
|
<if test="companyTypeId==102">
|
||||||
and companyTypeId =8
|
and companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==103">
|
<if test="companyTypeId==103">
|
||||||
and companyTypeId in (0,2,3,4,5)
|
and companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId <100">
|
<if test="companyTypeId <100">
|
||||||
|
@ -158,13 +158,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="companyTypeId!=null">
|
<if test="companyTypeId!=null">
|
||||||
<if test="companyTypeId>100">
|
<if test="companyTypeId>100">
|
||||||
<if test="companyTypeId==101">
|
<if test="companyTypeId==101">
|
||||||
and companyTypeId in (1,6)
|
and companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==102">
|
<if test="companyTypeId==102">
|
||||||
and companyTypeId =8
|
and companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==103">
|
<if test="companyTypeId==103">
|
||||||
and companyTypeId in (0,2,3,4,5)
|
and companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId <100">
|
<if test="companyTypeId <100">
|
||||||
|
@ -357,7 +357,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
</if>
|
</if>
|
||||||
<if test="projectId!=null and projectId>0"> and project_id=#{projectId}</if>
|
<if test="projectId!=null and projectId>0"> and project_id=#{projectId}</if>
|
||||||
group by workerId )
|
group by workerId )
|
||||||
and companyTypeId in (1,2,3,4,5,6,8) group by companyTypeId
|
and companyTypeId in (1,2,4,5) group by companyTypeId
|
||||||
</select>
|
</select>
|
||||||
<select id="groupByComany" parameterType="SurProjectAttendanceData" resultMap="SurProjectAttendanceDataResult">
|
<select id="groupByComany" parameterType="SurProjectAttendanceData" resultMap="SurProjectAttendanceDataResult">
|
||||||
select g.companyTypeId,count(1) id from sur_project_attendance_user u, attendance_cfg c,view_sur_project_attendance_group g
|
select g.companyTypeId,count(1) id from sur_project_attendance_user u, attendance_cfg c,view_sur_project_attendance_group g
|
||||||
|
@ -381,7 +381,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
</where>
|
</where>
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
and g.companyTypeId in (1,2,3,4,5,6,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
|
|
||||||
<if test="projectId!=null and projectId>0">
|
<if test="projectId!=null and projectId>0">
|
||||||
and c.project_id=#{projectId}
|
and c.project_id=#{projectId}
|
||||||
|
@ -404,7 +404,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
pro_project_info sp
|
pro_project_info sp
|
||||||
where u.cfgid=c.id and u.groupId=g.teamId and u.state=#{id} and c.project_id = sp.id
|
where u.cfgid=c.id and u.groupId=g.teamId and u.state=#{id} and c.project_id = sp.id
|
||||||
and sp.is_Del=0
|
and sp.is_Del=0
|
||||||
and g.companyTypeId in (0,1,2,3,4,5,6,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
<if test="projectId!=null and projectId>0">
|
<if test="projectId!=null and projectId>0">
|
||||||
and c.project_id=#{projectId}
|
and c.project_id=#{projectId}
|
||||||
</if>
|
</if>
|
||||||
|
@ -472,13 +472,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="companyTypeId!=null">
|
<if test="companyTypeId!=null">
|
||||||
<if test="companyTypeId>100">
|
<if test="companyTypeId>100">
|
||||||
<if test="companyTypeId==101">
|
<if test="companyTypeId==101">
|
||||||
and companyTypeId in (1,6)
|
and companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==102">
|
<if test="companyTypeId==102">
|
||||||
and companyTypeId =8
|
and companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==103">
|
<if test="companyTypeId==103">
|
||||||
and companyTypeId in (0,2,3,4,5)
|
and companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId <100">
|
<if test="companyTypeId <100">
|
||||||
|
@ -540,13 +540,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
and ady.projectId=#{projectId}
|
and ady.projectId=#{projectId}
|
||||||
</if>
|
</if>
|
||||||
<if test="id==1">
|
<if test="id==1">
|
||||||
and ady.companyTypeId in (1,6)
|
and ady.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==2">
|
<if test="id==2">
|
||||||
and ady.companyTypeId in (0,2,3,4,5)
|
and ady.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==8">
|
<if test="id==8">
|
||||||
and ady.companyTypeId =8
|
and ady.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="deptId!=null and deptId>0">
|
<if test="deptId!=null and deptId>0">
|
||||||
and sp.dis_dept_id=#{deptId}
|
and sp.dis_dept_id=#{deptId}
|
||||||
|
@ -565,13 +565,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
select ady.* from sur_project_attendance_data_${year} ady
|
select ady.* from sur_project_attendance_data_${year} ady
|
||||||
where ady.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
where ady.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
||||||
<if test="companyTypeId==101">
|
<if test="companyTypeId==101">
|
||||||
and ady.companyTypeId in (1,6)
|
and ady.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==103">
|
<if test="companyTypeId==103">
|
||||||
and ady.companyTypeId in (0,2,3,4,5)
|
and ady.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==102">
|
<if test="companyTypeId==102">
|
||||||
and ady.companyTypeId =8
|
and ady.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="workerId != null and workerId != ''"> and ady.workerId = #{workerId}</if>
|
<if test="workerId != null and workerId != ''"> and ady.workerId = #{workerId}</if>
|
||||||
<if test="workerName != null and workerName != ''"> and ady.workerName like concat('%', #{workerName}, '%')</if>
|
<if test="workerName != null and workerName != ''"> and ady.workerName like concat('%', #{workerName}, '%')</if>
|
||||||
|
@ -609,7 +609,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
from sur_project_attendance_user u
|
from sur_project_attendance_user u
|
||||||
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
||||||
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
||||||
and g.companyTypeId in (0,1,2,3,4,5,6,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
and u.state=0
|
and u.state=0
|
||||||
group by g.companyTypeId
|
group by g.companyTypeId
|
||||||
UNION ALL
|
UNION ALL
|
||||||
|
@ -617,7 +617,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
from sur_project_attendance_user u
|
from sur_project_attendance_user u
|
||||||
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
||||||
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
||||||
and g.companyTypeId in (0,1,2,3,4,5,6,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
and u.state=1
|
and u.state=1
|
||||||
group by g.companyTypeId
|
group by g.companyTypeId
|
||||||
UNION ALL
|
UNION ALL
|
||||||
|
|
|
@ -69,13 +69,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="companyTypeId!=null">
|
<if test="companyTypeId!=null">
|
||||||
<if test="companyTypeId>100">
|
<if test="companyTypeId>100">
|
||||||
<if test="companyTypeId==101">
|
<if test="companyTypeId==101">
|
||||||
and g.companyTypeId in (1,6)
|
and g.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==102">
|
<if test="companyTypeId==102">
|
||||||
and g.companyTypeId =8
|
and g.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==103">
|
<if test="companyTypeId==103">
|
||||||
and g.companyTypeId in (0,2,3,4,5)
|
and g.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId <100">
|
<if test="companyTypeId <100">
|
||||||
|
@ -172,13 +172,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="companyTypeId!=null">
|
<if test="companyTypeId!=null">
|
||||||
<if test="companyTypeId>100">
|
<if test="companyTypeId>100">
|
||||||
<if test="companyTypeId==101">
|
<if test="companyTypeId==101">
|
||||||
and companyTypeId in (1,6)
|
and companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==102">
|
<if test="companyTypeId==102">
|
||||||
and companyTypeId =8
|
and companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==103">
|
<if test="companyTypeId==103">
|
||||||
and companyTypeId in (0,2,3,4,5)
|
and companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId <100">
|
<if test="companyTypeId <100">
|
||||||
|
@ -229,13 +229,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="companyTypeId!=null">
|
<if test="companyTypeId!=null">
|
||||||
<if test="companyTypeId>100">
|
<if test="companyTypeId>100">
|
||||||
<if test="companyTypeId==101">
|
<if test="companyTypeId==101">
|
||||||
and companyTypeId in (1,6)
|
and companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==102">
|
<if test="companyTypeId==102">
|
||||||
and companyTypeId =8
|
and companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==103">
|
<if test="companyTypeId==103">
|
||||||
and companyTypeId in (0,2,3,4,5)
|
and companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId <100">
|
<if test="companyTypeId <100">
|
||||||
|
@ -537,13 +537,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
SELECT workerid FROM sur_project_attendance_data WHERE DATE(attendance_time)=CURDATE() group by workerid
|
SELECT workerid FROM sur_project_attendance_data WHERE DATE(attendance_time)=CURDATE() group by workerid
|
||||||
)
|
)
|
||||||
<if test="id==1">
|
<if test="id==1">
|
||||||
and g.companyTypeId in (1,6)
|
and g.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==2">
|
<if test="id==2">
|
||||||
and g.companyTypeId in (0,2,3,4,5)
|
and g.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==8">
|
<if test="id==8">
|
||||||
and g.companyTypeId =8
|
and g.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="projectId!=null and projectId>0">
|
<if test="projectId!=null and projectId>0">
|
||||||
and c.project_id=#{projectId}
|
and c.project_id=#{projectId}
|
||||||
|
@ -570,13 +570,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
)
|
)
|
||||||
|
|
||||||
<if test="id==1">
|
<if test="id==1">
|
||||||
and g.companyTypeId in (1,6)
|
and g.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==2">
|
<if test="id==2">
|
||||||
and g.companyTypeId in (0,2,3,4,5)
|
and g.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==8">
|
<if test="id==8">
|
||||||
and g.companyTypeId =8
|
and g.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="projectId!=null and projectId>0">
|
<if test="projectId!=null and projectId>0">
|
||||||
and c.project_id=#{projectId}
|
and c.project_id=#{projectId}
|
||||||
|
@ -601,13 +601,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
)
|
)
|
||||||
|
|
||||||
<if test="id==1">
|
<if test="id==1">
|
||||||
and g.companyTypeId in (1,6)
|
and g.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==2">
|
<if test="id==2">
|
||||||
and g.companyTypeId in (0,2,3,4,5)
|
and g.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==8">
|
<if test="id==8">
|
||||||
and g.companyTypeId =8
|
and g.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="projectId!=null and projectId>0">
|
<if test="projectId!=null and projectId>0">
|
||||||
and c.project_id=#{projectId}
|
and c.project_id=#{projectId}
|
||||||
|
@ -656,13 +656,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info sp
|
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info sp
|
||||||
WHERE u.cfgid=b.id and u.state=0 and u.groupId=g.teamId and sp.is_Del=0 and b.project_id = sp.id
|
WHERE u.cfgid=b.id and u.state=0 and u.groupId=g.teamId and sp.is_Del=0 and b.project_id = sp.id
|
||||||
<if test="id==101">
|
<if test="id==101">
|
||||||
and g.companyTypeId in (1,6)
|
and g.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==102">
|
<if test="id==102">
|
||||||
and g.companyTypeId =8
|
and g.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==103">
|
<if test="id==103">
|
||||||
and g.companyTypeId in (0,2,3,4,5)
|
and g.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
<if test="projectId!=null and projectId>0">
|
<if test="projectId!=null and projectId>0">
|
||||||
and b.project_id=#{projectId}
|
and b.project_id=#{projectId}
|
||||||
|
@ -690,13 +690,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info sp
|
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info sp
|
||||||
WHERE u.cfgid=b.id and u.groupId=g.teamId and sp.is_Del=0 and b.project_id = sp.id
|
WHERE u.cfgid=b.id and u.groupId=g.teamId and sp.is_Del=0 and b.project_id = sp.id
|
||||||
<if test="companyTypeId==101">
|
<if test="companyTypeId==101">
|
||||||
and g.companyTypeId in (1,6)
|
and g.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==102">
|
<if test="companyTypeId==102">
|
||||||
and g.companyTypeId =8
|
and g.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==103">
|
<if test="companyTypeId==103">
|
||||||
and g.companyTypeId in (0,2,3,4,5)
|
and g.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
<if test="projectId!=null and projectId>0">
|
<if test="projectId!=null and projectId>0">
|
||||||
and b.project_id=#{projectId}
|
and b.project_id=#{projectId}
|
||||||
|
@ -712,7 +712,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info p,sys_dept c
|
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info p,sys_dept c
|
||||||
where u.cfgid=b.id and u.state=0 and u.groupId=g.teamId and b.project_id=p.id and c.dept_id=b.dept_id
|
where u.cfgid=b.id and u.state=0 and u.groupId=g.teamId and b.project_id=p.id and c.dept_id=b.dept_id
|
||||||
and p.is_Del=0
|
and p.is_Del=0
|
||||||
and g.companyTypeId in (1,6,0,2,3,4,5,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
<if test="deptId!=null and deptId>0">
|
<if test="deptId!=null and deptId>0">
|
||||||
and p.dis_dept_id=#{deptId}
|
and p.dis_dept_id=#{deptId}
|
||||||
</if>
|
</if>
|
||||||
|
@ -732,7 +732,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
from sur_project_attendance_user u
|
from sur_project_attendance_user u
|
||||||
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
||||||
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
||||||
and g.companyTypeId in (0,1,2,3,4,5,6,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
and u.state=0
|
and u.state=0
|
||||||
<if test="name != null and name != ''"> and u.name like concat('%', #{name}, '%')</if>
|
<if test="name != null and name != ''"> and u.name like concat('%', #{name}, '%')</if>
|
||||||
group by g.companyTypeId
|
group by g.companyTypeId
|
||||||
|
@ -741,7 +741,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
from sur_project_attendance_user u
|
from sur_project_attendance_user u
|
||||||
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
||||||
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
||||||
and g.companyTypeId in (0,1,2,3,4,5,6,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
and u.state=1
|
and u.state=1
|
||||||
<if test="name != null and name != ''"> and u.name like concat('%', #{name}, '%')</if>
|
<if test="name != null and name != ''"> and u.name like concat('%', #{name}, '%')</if>
|
||||||
group by g.companyTypeId
|
group by g.companyTypeId
|
||||||
|
@ -752,7 +752,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
from sur_project_attendance_user u
|
from sur_project_attendance_user u
|
||||||
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
||||||
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
||||||
and g.companyTypeId in (0,1,2,3,4,5,6,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
and u.state=0
|
and u.state=0
|
||||||
group by g.companyTypeId
|
group by g.companyTypeId
|
||||||
</select>
|
</select>
|
||||||
|
@ -762,7 +762,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info p,sys_dept c
|
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info p,sys_dept c
|
||||||
where u.cfgid=b.id and u.state= #{state} and u.groupId=g.teamId and b.project_id=p.id and c.dept_id=b.dept_id
|
where u.cfgid=b.id and u.state= #{state} and u.groupId=g.teamId and b.project_id=p.id and c.dept_id=b.dept_id
|
||||||
and p.is_Del=0
|
and p.is_Del=0
|
||||||
and g.companyTypeId in (1,6,0,2,3,4,5,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
<if test="deptId!=null and deptId>0">
|
<if test="deptId!=null and deptId>0">
|
||||||
and p.dis_dept_id=#{deptId}
|
and p.dis_dept_id=#{deptId}
|
||||||
</if>
|
</if>
|
||||||
|
@ -788,13 +788,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info sp
|
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info sp
|
||||||
WHERE u.cfgid=b.id and u.state=#{state} and u.groupId=g.teamId and sp.is_Del=0 and b.project_id = sp.id
|
WHERE u.cfgid=b.id and u.state=#{state} and u.groupId=g.teamId and sp.is_Del=0 and b.project_id = sp.id
|
||||||
<if test="id==101">
|
<if test="id==101">
|
||||||
and g.companyTypeId in (1,6)
|
and g.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==102">
|
<if test="id==102">
|
||||||
and g.companyTypeId =8
|
and g.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==103">
|
<if test="id==103">
|
||||||
and g.companyTypeId in (0,2,3,4,5)
|
and g.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
<if test="projectId!=null and projectId>0">
|
<if test="projectId!=null and projectId>0">
|
||||||
and b.project_id=#{projectId}
|
and b.project_id=#{projectId}
|
||||||
|
|
|
@ -45,17 +45,7 @@ public class SzjEnterpriseInfo {
|
||||||
|
|
||||||
public void setEnterpriseType(Long enterpriseType) {
|
public void setEnterpriseType(Long enterpriseType) {
|
||||||
this.enterpriseType = enterpriseType;
|
this.enterpriseType = enterpriseType;
|
||||||
if(enterpriseType==null){
|
|
||||||
companyTypeId = 0L;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if(enterpriseType==3L){
|
|
||||||
companyTypeId = 1L;
|
|
||||||
}else if(enterpriseType==1L){
|
|
||||||
companyTypeId = 8L;
|
|
||||||
}else{
|
|
||||||
companyTypeId = 2L;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public Long getCompanyTypeId() {
|
public Long getCompanyTypeId() {
|
||||||
|
|
|
@ -287,7 +287,7 @@ public class AttendanceSzjTask {
|
||||||
group.setBizLicense(szjEnterpriseInfo!=null?szjEnterpriseInfo.getCreditCode():jo.getInteger("enterpriseId")+"");
|
group.setBizLicense(szjEnterpriseInfo!=null?szjEnterpriseInfo.getCreditCode():jo.getInteger("enterpriseId")+"");
|
||||||
group.setCompanyId(jo.getInteger("enterpriseId")+"");
|
group.setCompanyId(jo.getInteger("enterpriseId")+"");
|
||||||
group.setCompanyName(jo.getString("enterpriseName"));
|
group.setCompanyName(jo.getString("enterpriseName"));
|
||||||
group.setCompanyTypeId(jo.getInteger("enterpriseType")+"");
|
group.setCompanyTypeId(convertSubDeptType(jo.getInteger("enterpriseType")+""));
|
||||||
group.setName(jo.getString("teamName"));
|
group.setName(jo.getString("teamName"));
|
||||||
group.setTeamId(jo.getLong("id"));
|
group.setTeamId(jo.getLong("id"));
|
||||||
group.setLeaderName(jo.getString("teamLeader"));
|
group.setLeaderName(jo.getString("teamLeader"));
|
||||||
|
|
|
@ -117,13 +117,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="companyTypeId!=null">
|
<if test="companyTypeId!=null">
|
||||||
<if test="companyTypeId>100">
|
<if test="companyTypeId>100">
|
||||||
<if test="companyTypeId==101">
|
<if test="companyTypeId==101">
|
||||||
and companyTypeId in (1,6)
|
and companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==102">
|
<if test="companyTypeId==102">
|
||||||
and companyTypeId =8
|
and companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==103">
|
<if test="companyTypeId==103">
|
||||||
and companyTypeId in (0,2,3,4,5)
|
and companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId <100">
|
<if test="companyTypeId <100">
|
||||||
|
@ -157,13 +157,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="companyTypeId!=null">
|
<if test="companyTypeId!=null">
|
||||||
<if test="companyTypeId>100">
|
<if test="companyTypeId>100">
|
||||||
<if test="companyTypeId==101">
|
<if test="companyTypeId==101">
|
||||||
and companyTypeId in (1,6)
|
and companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==102">
|
<if test="companyTypeId==102">
|
||||||
and companyTypeId =8
|
and companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==103">
|
<if test="companyTypeId==103">
|
||||||
and companyTypeId in (0,2,3,4,5)
|
and companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId <100">
|
<if test="companyTypeId <100">
|
||||||
|
@ -355,7 +355,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
</if>
|
</if>
|
||||||
<if test="projectId!=null and projectId>0"> and projectId=#{projectId}</if>
|
<if test="projectId!=null and projectId>0"> and projectId=#{projectId}</if>
|
||||||
group by workerId )
|
group by workerId )
|
||||||
and companyTypeId in (1,2,3,4,5,6,8) group by companyTypeId
|
and companyTypeId in (1,2,4,5) group by companyTypeId
|
||||||
</select>
|
</select>
|
||||||
<select id="groupByComany" parameterType="QuartzProjectAttendanceData" resultMap="SurProjectAttendanceDataResult">
|
<select id="groupByComany" parameterType="QuartzProjectAttendanceData" resultMap="SurProjectAttendanceDataResult">
|
||||||
select g.companyTypeId,count(1) id from sur_project_attendance_user u, attendance_cfg c,view_sur_project_attendance_group g
|
select g.companyTypeId,count(1) id from sur_project_attendance_user u, attendance_cfg c,view_sur_project_attendance_group g
|
||||||
|
@ -379,7 +379,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
</where>
|
</where>
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
and g.companyTypeId in (1,2,3,4,5,6,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
|
|
||||||
<if test="projectId!=null and projectId>0">
|
<if test="projectId!=null and projectId>0">
|
||||||
and c.project_id=#{projectId}
|
and c.project_id=#{projectId}
|
||||||
|
@ -402,7 +402,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
pro_project_info sp
|
pro_project_info sp
|
||||||
where u.cfgid=c.id and u.companyId=g.companyId and u.state=#{id} and c.project_id = sp.id
|
where u.cfgid=c.id and u.companyId=g.companyId and u.state=#{id} and c.project_id = sp.id
|
||||||
and sp.is_Del=0
|
and sp.is_Del=0
|
||||||
and g.companyTypeId in (0,1,2,3,4,5,6,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
<if test="projectId!=null and projectId>0">
|
<if test="projectId!=null and projectId>0">
|
||||||
and c.project_id=#{projectId}
|
and c.project_id=#{projectId}
|
||||||
</if>
|
</if>
|
||||||
|
@ -458,13 +458,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
and ady.projectId=#{projectId}
|
and ady.projectId=#{projectId}
|
||||||
</if>
|
</if>
|
||||||
<if test="id==1">
|
<if test="id==1">
|
||||||
and ady.companyTypeId in (1,6)
|
and ady.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==2">
|
<if test="id==2">
|
||||||
and ady.companyTypeId in (0,2,3,4,5)
|
and ady.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==8">
|
<if test="id==8">
|
||||||
and ady.companyTypeId =8
|
and ady.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="deptId!=null and deptId>0">
|
<if test="deptId!=null and deptId>0">
|
||||||
and sp.dis_dept_id=#{deptId}
|
and sp.dis_dept_id=#{deptId}
|
||||||
|
@ -483,13 +483,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
select ady.* from sur_project_attendance_data_${year} ady
|
select ady.* from sur_project_attendance_data_${year} ady
|
||||||
where ady.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
where ady.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
||||||
<if test="companyTypeId==101">
|
<if test="companyTypeId==101">
|
||||||
and ady.companyTypeId in (1,6)
|
and ady.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==103">
|
<if test="companyTypeId==103">
|
||||||
and ady.companyTypeId in (0,2,3,4,5)
|
and ady.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==102">
|
<if test="companyTypeId==102">
|
||||||
and ady.companyTypeId =8
|
and ady.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="workerId != null and workerId != ''"> and ady.workerId = #{workerId}</if>
|
<if test="workerId != null and workerId != ''"> and ady.workerId = #{workerId}</if>
|
||||||
<if test="workerName != null and workerName != ''"> and ady.workerName like concat('%', #{workerName}, '%')</if>
|
<if test="workerName != null and workerName != ''"> and ady.workerName like concat('%', #{workerName}, '%')</if>
|
||||||
|
@ -531,7 +531,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
from sur_project_attendance_user u
|
from sur_project_attendance_user u
|
||||||
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
||||||
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
||||||
and g.companyTypeId in (0,1,2,3,4,5,6,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
and u.state=0
|
and u.state=0
|
||||||
group by g.companyTypeId
|
group by g.companyTypeId
|
||||||
UNION ALL
|
UNION ALL
|
||||||
|
@ -539,7 +539,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
from sur_project_attendance_user u
|
from sur_project_attendance_user u
|
||||||
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
||||||
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
||||||
and g.companyTypeId in (0,1,2,3,4,5,6,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
and u.state=1
|
and u.state=1
|
||||||
group by g.companyTypeId
|
group by g.companyTypeId
|
||||||
UNION ALL
|
UNION ALL
|
||||||
|
|
|
@ -71,13 +71,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="companyTypeId!=null">
|
<if test="companyTypeId!=null">
|
||||||
<if test="companyTypeId>100">
|
<if test="companyTypeId>100">
|
||||||
<if test="companyTypeId==101">
|
<if test="companyTypeId==101">
|
||||||
and g.companyTypeId in (1,6)
|
and g.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==102">
|
<if test="companyTypeId==102">
|
||||||
and g.companyTypeId =8
|
and g.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==103">
|
<if test="companyTypeId==103">
|
||||||
and g.companyTypeId in (0,2,3,4,5)
|
and g.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId <100">
|
<if test="companyTypeId <100">
|
||||||
|
@ -174,13 +174,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="companyTypeId!=null">
|
<if test="companyTypeId!=null">
|
||||||
<if test="companyTypeId>100">
|
<if test="companyTypeId>100">
|
||||||
<if test="companyTypeId==101">
|
<if test="companyTypeId==101">
|
||||||
and companyTypeId in (1,6)
|
and companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==102">
|
<if test="companyTypeId==102">
|
||||||
and companyTypeId =8
|
and companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==103">
|
<if test="companyTypeId==103">
|
||||||
and companyTypeId in (0,2,3,4,5)
|
and companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId <100">
|
<if test="companyTypeId <100">
|
||||||
|
@ -232,13 +232,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="companyTypeId!=null">
|
<if test="companyTypeId!=null">
|
||||||
<if test="companyTypeId>100">
|
<if test="companyTypeId>100">
|
||||||
<if test="companyTypeId==101">
|
<if test="companyTypeId==101">
|
||||||
and companyTypeId in (1,6)
|
and companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==102">
|
<if test="companyTypeId==102">
|
||||||
and companyTypeId =8
|
and companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==103">
|
<if test="companyTypeId==103">
|
||||||
and companyTypeId in (0,2,3,4,5)
|
and companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId <100">
|
<if test="companyTypeId <100">
|
||||||
|
@ -406,8 +406,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="workerCategory != null">workerCategory = #{workerCategory},</if>
|
<if test="workerCategory != null">workerCategory = #{workerCategory},</if>
|
||||||
<if test="qrCode != null">qrCode = #{qrCode},</if>
|
<if test="qrCode != null">qrCode = #{qrCode},</if>
|
||||||
<if test="name != null">name = #{name},</if>
|
<if test="name != null">name = #{name},</if>
|
||||||
<if test="idCardNo != null">name = #{idCardNo},</if>
|
<if test="idCardNo != null">idCardNo = #{idCardNo},</if>
|
||||||
<if test="idTypeName != null">name = #{idTypeName},</if>
|
<if test="idTypeName != null">idTypeName = #{idTypeName},</if>
|
||||||
<if test="ethnic != null">ethnic = #{ethnic},</if>
|
<if test="ethnic != null">ethnic = #{ethnic},</if>
|
||||||
<if test="nativePlace != null">nativePlace = #{nativePlace},</if>
|
<if test="nativePlace != null">nativePlace = #{nativePlace},</if>
|
||||||
<if test="gender != null">gender = #{gender},</if>
|
<if test="gender != null">gender = #{gender},</if>
|
||||||
|
@ -508,13 +508,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
SELECT workerid FROM sur_project_attendance_data WHERE DATE(attendance_time)=CURDATE() group by workerid
|
SELECT workerid FROM sur_project_attendance_data WHERE DATE(attendance_time)=CURDATE() group by workerid
|
||||||
)
|
)
|
||||||
<if test="id==1">
|
<if test="id==1">
|
||||||
and g.companyTypeId in (1,6)
|
and g.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==2">
|
<if test="id==2">
|
||||||
and g.companyTypeId in (0,2,3,4,5)
|
and g.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==8">
|
<if test="id==8">
|
||||||
and g.companyTypeId =8
|
and g.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="projectId!=null and projectId>0">
|
<if test="projectId!=null and projectId>0">
|
||||||
and c.project_id=#{projectId}
|
and c.project_id=#{projectId}
|
||||||
|
@ -539,13 +539,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
)
|
)
|
||||||
|
|
||||||
<if test="id==1">
|
<if test="id==1">
|
||||||
and g.companyTypeId in (1,6)
|
and g.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==2">
|
<if test="id==2">
|
||||||
and g.companyTypeId in (0,2,3,4,5)
|
and g.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==8">
|
<if test="id==8">
|
||||||
and g.companyTypeId =8
|
and g.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="projectId!=null and projectId>0">
|
<if test="projectId!=null and projectId>0">
|
||||||
and c.project_id=#{projectId}
|
and c.project_id=#{projectId}
|
||||||
|
@ -594,13 +594,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info sp
|
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info sp
|
||||||
WHERE u.cfgid=b.id and u.state=0 and u.companyId=g.companyId and sp.is_Del=0 and b.project_id = sp.id
|
WHERE u.cfgid=b.id and u.state=0 and u.companyId=g.companyId and sp.is_Del=0 and b.project_id = sp.id
|
||||||
<if test="id==101">
|
<if test="id==101">
|
||||||
and g.companyTypeId in (1,6)
|
and g.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==102">
|
<if test="id==102">
|
||||||
and g.companyTypeId =8
|
and g.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==103">
|
<if test="id==103">
|
||||||
and g.companyTypeId in (0,2,3,4,5)
|
and g.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
<if test="projectId!=null and projectId>0">
|
<if test="projectId!=null and projectId>0">
|
||||||
and b.project_id=#{projectId}
|
and b.project_id=#{projectId}
|
||||||
|
@ -628,13 +628,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info sp
|
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info sp
|
||||||
WHERE u.cfgid=b.id and u.companyId=g.companyId and sp.is_Del=0 and b.project_id = sp.id
|
WHERE u.cfgid=b.id and u.companyId=g.companyId and sp.is_Del=0 and b.project_id = sp.id
|
||||||
<if test="companyTypeId==101">
|
<if test="companyTypeId==101">
|
||||||
and g.companyTypeId in (1,6)
|
and g.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==102">
|
<if test="companyTypeId==102">
|
||||||
and g.companyTypeId =8
|
and g.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="companyTypeId==103">
|
<if test="companyTypeId==103">
|
||||||
and g.companyTypeId in (0,2,3,4,5)
|
and g.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
<if test="projectId!=null and projectId>0">
|
<if test="projectId!=null and projectId>0">
|
||||||
and b.project_id=#{projectId}
|
and b.project_id=#{projectId}
|
||||||
|
@ -650,7 +650,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info p,sys_dept c
|
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info p,sys_dept c
|
||||||
where u.cfgid=b.id and u.state=0 and u.companyId=g.companyId and b.project_id=p.id and c.dept_id=b.dept_id
|
where u.cfgid=b.id and u.state=0 and u.companyId=g.companyId and b.project_id=p.id and c.dept_id=b.dept_id
|
||||||
and p.is_Del=0
|
and p.is_Del=0
|
||||||
and g.companyTypeId in (1,6,0,2,3,4,5,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
<if test="deptId!=null and deptId>0">
|
<if test="deptId!=null and deptId>0">
|
||||||
and p.dis_dept_id=#{deptId}
|
and p.dis_dept_id=#{deptId}
|
||||||
</if>
|
</if>
|
||||||
|
@ -670,7 +670,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
from sur_project_attendance_user u
|
from sur_project_attendance_user u
|
||||||
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
||||||
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
||||||
and g.companyTypeId in (0,1,2,3,4,5,6,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
and u.state=0
|
and u.state=0
|
||||||
<if test="name != null and name != ''"> and u.name like concat('%', #{name}, '%')</if>
|
<if test="name != null and name != ''"> and u.name like concat('%', #{name}, '%')</if>
|
||||||
group by g.companyTypeId
|
group by g.companyTypeId
|
||||||
|
@ -679,7 +679,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
from sur_project_attendance_user u
|
from sur_project_attendance_user u
|
||||||
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
||||||
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
||||||
and g.companyTypeId in (0,1,2,3,4,5,6,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
and u.state=1
|
and u.state=1
|
||||||
<if test="name != null and name != ''"> and u.name like concat('%', #{name}, '%')</if>
|
<if test="name != null and name != ''"> and u.name like concat('%', #{name}, '%')</if>
|
||||||
group by g.companyTypeId
|
group by g.companyTypeId
|
||||||
|
@ -690,7 +690,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
from sur_project_attendance_user u
|
from sur_project_attendance_user u
|
||||||
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
left join view_sur_project_attendance_group g on g.cfgid = u.cfgid and u.companyId=g.companyId
|
||||||
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
where u.cfgid in (select cfg.id from attendance_cfg cfg where cfg.project_id=#{projectId} and cfg.is_del=0)
|
||||||
and g.companyTypeId in (0,1,2,3,4,5,6,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
and u.state=0
|
and u.state=0
|
||||||
group by g.companyTypeId
|
group by g.companyTypeId
|
||||||
</select>
|
</select>
|
||||||
|
@ -700,7 +700,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info p,sys_dept c
|
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info p,sys_dept c
|
||||||
where u.cfgid=b.id and u.state= #{state} and u.companyId=g.companyId and b.project_id=p.id and c.dept_id=b.dept_id
|
where u.cfgid=b.id and u.state= #{state} and u.companyId=g.companyId and b.project_id=p.id and c.dept_id=b.dept_id
|
||||||
and p.is_Del=0
|
and p.is_Del=0
|
||||||
and g.companyTypeId in (1,6,0,2,3,4,5,8)
|
and g.companyTypeId in (1,2,4,5)
|
||||||
<if test="deptId!=null and deptId>0">
|
<if test="deptId!=null and deptId>0">
|
||||||
and p.dis_dept_id=#{deptId}
|
and p.dis_dept_id=#{deptId}
|
||||||
</if>
|
</if>
|
||||||
|
@ -726,13 +726,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info sp
|
FROM sur_project_attendance_user u,attendance_cfg b,view_sur_project_attendance_group g,pro_project_info sp
|
||||||
WHERE u.cfgid=b.id and u.state=#{state} and u.companyId=g.companyId and sp.is_Del=0 and b.project_id = sp.id
|
WHERE u.cfgid=b.id and u.state=#{state} and u.companyId=g.companyId and sp.is_Del=0 and b.project_id = sp.id
|
||||||
<if test="id==101">
|
<if test="id==101">
|
||||||
and g.companyTypeId in (1,6)
|
and g.companyTypeId in (1)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==102">
|
<if test="id==102">
|
||||||
and g.companyTypeId =8
|
and g.companyTypeId in (2)
|
||||||
</if>
|
</if>
|
||||||
<if test="id==103">
|
<if test="id==103">
|
||||||
and g.companyTypeId in (0,2,3,4,5)
|
and g.companyTypeId in (4,5)
|
||||||
</if>
|
</if>
|
||||||
<if test="projectId!=null and projectId>0">
|
<if test="projectId!=null and projectId>0">
|
||||||
and b.project_id=#{projectId}
|
and b.project_id=#{projectId}
|
||||||
|
|
|
@ -84,4 +84,12 @@ export function devicePositionUpdateItems(data) {
|
||||||
method: "post",
|
method: "post",
|
||||||
data: data,
|
data: data,
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
export function updateBimInfo(data) {
|
||||||
|
return request({
|
||||||
|
url: "/manage/api/bim/plan/updateBimInfo",
|
||||||
|
method: "post",
|
||||||
|
data: data,
|
||||||
|
});
|
||||||
}
|
}
|
|
@ -0,0 +1,24 @@
|
||||||
|
function selectSingle(that) {
|
||||||
|
let api = bimSelectionDlgApi;
|
||||||
|
api.Public.clearHandler();
|
||||||
|
api.Feature.getByEvent(true, (n) => {
|
||||||
|
if (n && n["id"]) {
|
||||||
|
let featureId = n.id;
|
||||||
|
let modelId = featureId.split("^")[0];
|
||||||
|
if(that.selectItems.includes(featureId)){
|
||||||
|
api.Feature.setColor(featureId, "rgba(255,255,255,1)");
|
||||||
|
let index = that.selectItems.indexOf(featureId);
|
||||||
|
if (index > -1) {
|
||||||
|
that.selectItems.splice(index, 1);
|
||||||
|
}
|
||||||
|
}else{
|
||||||
|
api.Feature.setColor(featureId, "rgba(255,0,255,1)");
|
||||||
|
that.selectItems.push(featureId);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
export default {
|
||||||
|
selectSingle,
|
||||||
|
};
|
|
@ -3,13 +3,18 @@
|
||||||
<div id="bimSelectionDlg">
|
<div id="bimSelectionDlg">
|
||||||
<div id="bimSelectionDlgContainer" class="bimSelectionDlgContainer"></div>
|
<div id="bimSelectionDlgContainer" class="bimSelectionDlgContainer"></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="div-left" :class="{'is-hide':!leftExpend}">
|
<div class="div-left" :class="{ 'is-hide': !leftExpend }">
|
||||||
<div class="div-left-title">
|
<div class="div-left-title">
|
||||||
<el-tabs v-model="activeTab">
|
<el-tabs v-model="activeTab">
|
||||||
<el-tab-pane label="结构树" name="a1">
|
<el-tab-pane label="结构树" name="a1"> </el-tab-pane>
|
||||||
|
<el-tab-pane label="已关联" name="a2">
|
||||||
|
<div class="sel-list scroll">
|
||||||
|
<div v-for="(it, idx) in selectItems" :key="idx" class="div-sel-item">
|
||||||
|
<div>{{ it.split("^")[1] }}</div>
|
||||||
|
<el-button link>删除</el-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane label="已关联" name="a2"></el-tab-pane>
|
|
||||||
<el-tab-pane label="已隐藏" name="a3"></el-tab-pane>
|
<el-tab-pane label="已隐藏" name="a3"></el-tab-pane>
|
||||||
</el-tabs>
|
</el-tabs>
|
||||||
<div class="div-icon">
|
<div class="div-icon">
|
||||||
|
@ -18,8 +23,8 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="footer-box" v-if="models.length > 0" >
|
<div class="footer-box" v-if="models.length > 0">
|
||||||
<el-tooltip placement="top" content="主视图">
|
<el-tooltip placement="top" content="主视图">
|
||||||
<div class="footer-btn" @click="doMenu(0)" :class="activeMenu == 0 ? 'is-active' : ''">
|
<div class="footer-btn" @click="doMenu(0)" :class="activeMenu == 0 ? 'is-active' : ''">
|
||||||
<svg-icon icon-class="home" />
|
<svg-icon icon-class="home" />
|
||||||
</div>
|
</div>
|
||||||
|
@ -44,15 +49,12 @@
|
||||||
<svg-icon icon-class="hide" />
|
<svg-icon icon-class="hide" />
|
||||||
</div>
|
</div>
|
||||||
</el-tooltip>
|
</el-tooltip>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<template #footer>
|
<template #footer>
|
||||||
<div class="dialog-footer">
|
<div class="dialog-footer">
|
||||||
<el-button @click="show = false">取消</el-button>
|
<el-button @click="show = false">取消</el-button>
|
||||||
<el-button type="primary" @click="doSave">
|
<el-button type="primary" @click="doSave"> 保存构件 </el-button>
|
||||||
保存构件
|
|
||||||
</el-button>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
@ -60,6 +62,9 @@
|
||||||
<script>
|
<script>
|
||||||
import useUserStore from "@/store/modules/user";
|
import useUserStore from "@/store/modules/user";
|
||||||
import { listBimModel } from "@/api/bim/bimModel";
|
import { listBimModel } from "@/api/bim/bimModel";
|
||||||
|
import bimTools from "./bimSelectTools";
|
||||||
|
import { updateBimInfo } from "@/api/bim/bim";
|
||||||
|
import { ElMessage, ElMessageBox } from "element-plus";
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
@ -75,30 +80,42 @@ export default {
|
||||||
leftExpend: true,
|
leftExpend: true,
|
||||||
activeMenu: 0,
|
activeMenu: 0,
|
||||||
elId: 0,
|
elId: 0,
|
||||||
|
selectItems: [],
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
beforeDestroy() {
|
beforeDestroy() {
|
||||||
let api=bimSelectionDlgApi
|
let api = bimSelectionDlgApi;
|
||||||
if(api){
|
if (api) {
|
||||||
api.Public.clearScene();
|
api.Public.clearScene();
|
||||||
api.Public.destroy();
|
api.Public.destroy();
|
||||||
window.bimSelectionDlgApi = null;
|
window.bimSelectionDlgApi = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
doSave(){
|
doSave() {
|
||||||
|
updateBimInfo({
|
||||||
|
id: this.plan.id,
|
||||||
|
text: JSON.stringify(this.selectItems),
|
||||||
|
}).then((res) => {
|
||||||
|
console.log(res);
|
||||||
|
if(res.success){
|
||||||
|
ElMessage.success('保存成功')
|
||||||
|
this.show = false;
|
||||||
|
}else{
|
||||||
|
ElMessage.error('保存失败')
|
||||||
|
}
|
||||||
|
});
|
||||||
},
|
},
|
||||||
doMenu(index) {
|
doMenu(index) {
|
||||||
this.activeMenu = index;
|
this.activeMenu = index;
|
||||||
switch(index){
|
switch (index) {
|
||||||
case 0:
|
case 0:
|
||||||
this.resetScene();
|
this.resetScene();
|
||||||
break;
|
break;
|
||||||
case 1:
|
case 1:
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
|
bimTools.selectSingle(this);
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
break;
|
break;
|
||||||
|
@ -210,12 +227,12 @@ export default {
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
resetScene() {
|
resetScene() {
|
||||||
let api=bimSelectionDlgApi
|
let api = bimSelectionDlgApi;
|
||||||
api.Camera.stopImmersiveRoam();
|
api.Camera.stopImmersiveRoam();
|
||||||
api.Model.location(bimSelectionDlgApi.m_model.keys().toArray()[0]);
|
api.Model.location(api.m_model.keys().toArray()[0]);
|
||||||
api.Plugin.deleteMiniMap();
|
api.Plugin.deleteMiniMap();
|
||||||
if(this.viewPoint){
|
if (this.viewPoint) {
|
||||||
api.Camera.setViewPort(this.viewPoint);
|
api.Camera.setViewPort(this.viewPoint);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -224,10 +241,9 @@ export default {
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
.bim-selection-dialog {
|
.bim-selection-dialog {
|
||||||
|
|
||||||
.el-dialog {
|
.el-dialog {
|
||||||
min-width: 960px;
|
min-width: 960px;
|
||||||
width: 80%;
|
width: 80%;
|
||||||
height: 80vh;
|
height: 80vh;
|
||||||
.el-dialog__body {
|
.el-dialog__body {
|
||||||
max-height: calc(100% - 80px) !important;
|
max-height: calc(100% - 80px) !important;
|
||||||
|
@ -251,6 +267,17 @@ export default {
|
||||||
height: 45px;
|
height: 45px;
|
||||||
}
|
}
|
||||||
.div-left-title {
|
.div-left-title {
|
||||||
|
height: 100%;
|
||||||
|
.el-tabs {
|
||||||
|
height: 100%;
|
||||||
|
.el-tabs__content {
|
||||||
|
height: 100%;
|
||||||
|
.el-tab-pane {
|
||||||
|
height: 100%;
|
||||||
|
padding-bottom: 10px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
.el-tabs__nav-wrap {
|
.el-tabs__nav-wrap {
|
||||||
.el-tabs__nav-prev,
|
.el-tabs__nav-prev,
|
||||||
.el-tabs__nav-next {
|
.el-tabs__nav-next {
|
||||||
|
@ -288,39 +315,58 @@ export default {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.footer-box {
|
.footer-box {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
bottom: 6vh;
|
bottom: 6vh;
|
||||||
left: 50%;
|
left: 50%;
|
||||||
margin-left: -75px;
|
margin-left: -75px;
|
||||||
background: #274754;
|
background: #274754;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
|
|
||||||
.footer-btn {
|
.footer-btn {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
width: 40px;
|
width: 40px;
|
||||||
height: 40px;
|
height: 40px;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
|
||||||
svg {
|
|
||||||
width: 20px;
|
|
||||||
height: 20px;
|
|
||||||
fill: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
background: #408edb97;
|
|
||||||
}
|
|
||||||
|
|
||||||
&.is-active {
|
|
||||||
svg {
|
svg {
|
||||||
fill: rgb(0, 255, 174);
|
width: 20px;
|
||||||
|
height: 20px;
|
||||||
|
fill: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
background: #408edb97;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.is-active {
|
||||||
|
svg {
|
||||||
|
fill: rgb(0, 255, 174);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.sel-list {
|
||||||
|
padding: 0px 10px 10px;
|
||||||
|
height: 100%;
|
||||||
|
overflow-y: auto;
|
||||||
|
.div-sel-item {
|
||||||
|
background-color: #f7f7f975;
|
||||||
|
position: relative;
|
||||||
|
color: #fff;
|
||||||
|
line-height: 30px;
|
||||||
|
padding: 0px 10px;
|
||||||
|
margin-top: 5px;
|
||||||
|
.el-button {
|
||||||
|
position: absolute;
|
||||||
|
right: 10px;
|
||||||
|
top: 4px;
|
||||||
|
color: #f40606;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
Loading…
Reference in New Issue