分包商统计
This commit is contained in:
parent
e2e30d99e7
commit
e02d9aa490
|
|
@ -79,7 +79,6 @@ public class SubStatisticsController extends BaseController {
|
|||
@SysLog(title = "分包工程信息", businessType = OperaType.QUERY, logType = 0, module = "分包统计->分包工程信息", details = "分包工程信息")
|
||||
public TableDataInfo getSubProMsg(HomePagePo homePagePo) {
|
||||
try {
|
||||
startPage();
|
||||
List<HomePageSubProVo> list = subStatisticsService.getSubProMsg(homePagePo);
|
||||
return getDataTable(list);
|
||||
} catch (Exception e) {
|
||||
|
|
@ -98,7 +97,6 @@ public class SubStatisticsController extends BaseController {
|
|||
@SysLog(title = "班组信息", businessType = OperaType.QUERY, logType = 0, module = "分包统计->班组信息", details = "班组信息")
|
||||
public TableDataInfo getSubTeamMsg(HomePagePo homePagePo) {
|
||||
try {
|
||||
startPage();
|
||||
List<HomePageSubProVo> list = subStatisticsService.getSubTeamMsg(homePagePo);
|
||||
return getDataTable(list);
|
||||
} catch (Exception e) {
|
||||
|
|
@ -117,7 +115,6 @@ public class SubStatisticsController extends BaseController {
|
|||
@SysLog(title = "考勤机信息", businessType = OperaType.QUERY, logType = 0, module = "分包统计->考勤机信息", details = "考勤机信息")
|
||||
public TableDataInfo getSubDeviceMsg(HomePagePo homePagePo) {
|
||||
try {
|
||||
startPage();
|
||||
List<PmAttDevice> list = subStatisticsService.getSubDeviceMsg(homePagePo);
|
||||
return getDataTable(list);
|
||||
} catch (Exception e) {
|
||||
|
|
|
|||
|
|
@ -117,4 +117,9 @@ public class PmSubTeamContract {
|
|||
* 项目部id
|
||||
*/
|
||||
private Integer orgId;
|
||||
|
||||
/**
|
||||
* 是否上海项目 1 是 0 不是
|
||||
*/
|
||||
private Integer isShanghai;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -104,4 +104,10 @@ public class BmSubContractVo {
|
|||
*/
|
||||
List<UploadFileVo> contractFile;
|
||||
|
||||
|
||||
/**
|
||||
* 是否上海项目 1 是 0 不是
|
||||
*/
|
||||
private Integer isShanghai;
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -70,10 +70,15 @@ public class SubStatisticsServiceImpl implements SubStatisticsService {
|
|||
//累计入场
|
||||
ProStatisticsPo einNum = subStatisticsMapper.getEinNumByHis(homePagePo);
|
||||
if(einNum != null){
|
||||
//累计入场
|
||||
map.put("einNumHis",einNum.getEinNumHis());
|
||||
map.put("exitNum",einNum.getEinNumHis() - Long.parseLong((String) map.get("einNum")) );
|
||||
//出场
|
||||
map.put("exitNum",einNum.getEinNumHis() - Long.parseLong(String.valueOf(map.get("einNum"))));
|
||||
//入场时间
|
||||
map.put("einTime",einNum.getEinTime());
|
||||
//出场时间
|
||||
map.put("exitTime",einNum.getExitTime());
|
||||
|
||||
map.put("exitUploadFile",einNum.getExitUploadFile());
|
||||
map.put("noExitUploadFile",einNum.getNoExitUploadFile());
|
||||
}else{
|
||||
|
|
@ -87,8 +92,11 @@ public class SubStatisticsServiceImpl implements SubStatisticsService {
|
|||
//在场灯状态
|
||||
ProStatisticsPo lightStatus = subStatisticsMapper.getEinWorkerLight(homePagePo);
|
||||
if(lightStatus != null){
|
||||
//黄灯数量
|
||||
map.put("yellowNum",lightStatus.getYellowNum());
|
||||
//绿灯数量
|
||||
map.put("greenNum",lightStatus.getGreenNum());
|
||||
//黄灯7天人数
|
||||
map.put("yellowThanSevenDayNum",lightStatus.getYellowThanSevenDayNum());
|
||||
}else{
|
||||
map.put("yellowNum",0);
|
||||
|
|
@ -98,6 +106,7 @@ public class SubStatisticsServiceImpl implements SubStatisticsService {
|
|||
//考勤
|
||||
ProStatisticsPo attAndRepair = subStatisticsMapper.getWorkerAttAndRepair(homePagePo);
|
||||
if(attAndRepair != null){
|
||||
//累计考勤天数
|
||||
map.put("attNumHis",attAndRepair.getAttNumHis());
|
||||
map.put("repairPersonNum",attAndRepair.getRepairPersonNum());
|
||||
map.put("repairNumHis",attAndRepair.getRepairNumHis());
|
||||
|
|
@ -112,6 +121,7 @@ public class SubStatisticsServiceImpl implements SubStatisticsService {
|
|||
//工资
|
||||
ProStatisticsPo workerWage = subStatisticsMapper.getWorkerWage(homePagePo);
|
||||
if(workerWage != null){
|
||||
//累计发放工资
|
||||
map.put("salaryMoneyNum",workerWage.getSalaryMoneyNum());
|
||||
map.put("payrollNum",workerWage.getPayrollNum());
|
||||
map.put("payrollWorkerTime",workerWage.getPayrollWorkerTime());
|
||||
|
|
|
|||
|
|
@ -39,7 +39,8 @@
|
|||
pp.pro_name as proName,
|
||||
bsc.sub_ein_time as subEinTime,
|
||||
bsc.sub_exit_time as subExitTime,
|
||||
bsc.sub_ein_status as subEinStatus
|
||||
bsc.sub_ein_status as subEinStatus,
|
||||
pp.is_shanghai as isShanghai
|
||||
from bm_sub_contract bsc
|
||||
left join pm_sub ps on bsc.sub_id = ps.id
|
||||
left join pm_project pp on bsc.pro_id = pp.id
|
||||
|
|
@ -102,7 +103,8 @@
|
|||
pp.pro_name as proName,
|
||||
bsc.sub_ein_time as subEinTime,
|
||||
bsc.sub_exit_time as subExitTime,
|
||||
bsc.sub_ein_status as subEinStatus
|
||||
bsc.sub_ein_status as subEinStatus,
|
||||
pp.is_shanghai as isShanghai
|
||||
from bm_sub_contract bsc
|
||||
left join pm_sub ps on bsc.sub_id = ps.id
|
||||
left join pm_project pp on bsc.pro_id = pp.id
|
||||
|
|
|
|||
|
|
@ -14,7 +14,15 @@
|
|||
#{createTime}, #{updateTime},#{subId},#{teamId})
|
||||
</insert>
|
||||
<update id="updatePmAttDevice">
|
||||
update pm_att_device set pro_id = #{proId},update_time = #{updateTime},update_user = #{updateUser}
|
||||
update pm_att_device
|
||||
<set>
|
||||
pro_id = #{proId},
|
||||
update_time = #{updateTime},
|
||||
update_user = #{updateUser},
|
||||
<if test="serialNumber != null and serialNumber != ''">
|
||||
serial_number = #{serialNumber},
|
||||
</if>
|
||||
</set>
|
||||
where is_active = '1' and device_code = #{deviceCode}
|
||||
</update>
|
||||
<delete id="delPmAttDevice">
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@
|
|||
|
||||
<select id="selectSubTeamContractList" resultType="com.bonus.bmw.domain.po.PmSubTeamContract">
|
||||
select pstc.id,pstc.team_id,pstc.team_name,pstc.sub_id,pstc.sub_name,pstc.pro_id,pstc.pro_name,
|
||||
pstc.team_ein_time,pstc.team_ein_status,pstc.team_exit_time
|
||||
pstc.team_ein_time,pstc.team_ein_status,pstc.team_exit_time,pp.is_shanghai
|
||||
from pm_sub_team_contract pstc
|
||||
left join pm_project pp on pstc.pro_id = pp.id
|
||||
where pstc.is_active = '1'
|
||||
|
|
|
|||
|
|
@ -4,9 +4,9 @@
|
|||
|
||||
<select id="getSubStatisticsTable" resultType="com.bonus.bmw.domain.po.PmSub">
|
||||
select
|
||||
ps.id as subId,
|
||||
ps.id ,
|
||||
ps.sub_name as subName,
|
||||
ps.legal_person as
|
||||
ps.legal_person,
|
||||
count(DISTINCT bsc.pro_id) as proNum,
|
||||
count(DISTINCT pstc.id) as teamNum,
|
||||
count(DISTINCT bwem.worker_id) as einNum
|
||||
|
|
@ -18,6 +18,9 @@
|
|||
<if test="subName !=null and subName!= ''" >
|
||||
and ps.sub_name like concat('%', #{subName}, '%')
|
||||
</if>
|
||||
<if test="subId !=null " >
|
||||
and ps.id =#{subId}
|
||||
</if>
|
||||
GROUP BY
|
||||
ps.id
|
||||
</select>
|
||||
|
|
@ -87,7 +90,7 @@
|
|||
bsc.sub_contract_code,
|
||||
bsc.sub_contract_name,
|
||||
bsc.sub_ein_status,
|
||||
count(bwem.worker_id) as einNum,
|
||||
count(DISTINCT bwem.worker_id) as einNum,
|
||||
count(DISTINCT bwer.worker_id) as einNumHis,
|
||||
bsc.sub_ein_time,
|
||||
bsc.sub_exit_time,
|
||||
|
|
@ -117,7 +120,8 @@
|
|||
pstc.id as teamId,
|
||||
ps.sub_name,
|
||||
count(DISTINCT bwem.worker_id) as einNum,
|
||||
count(DISTINCT bwer.worker_id) as einNumHis
|
||||
count(DISTINCT bwer.worker_id) as einNumHis,
|
||||
pp.pro_name
|
||||
FROM
|
||||
pm_sub ps
|
||||
INNER JOIN bm_sub_contract bsc ON ps.id = bsc.sub_id
|
||||
|
|
|
|||
Loading…
Reference in New Issue