代码提交

This commit is contained in:
liang.chao 2025-12-18 11:19:21 +08:00 committed by 马三炮
parent be32242198
commit 956c7436b4
15 changed files with 275 additions and 45 deletions

View File

@ -1,3 +1,4 @@
/*
package com.bonus.digital.controller; package com.bonus.digital.controller;
import com.bonus.business.controller.tool.MonthPlanExcelExporter; import com.bonus.business.controller.tool.MonthPlanExcelExporter;
@ -6,8 +7,10 @@ import com.bonus.common.core.controller.BaseController;
import com.bonus.common.core.domain.AjaxResult; import com.bonus.common.core.domain.AjaxResult;
import com.bonus.common.core.page.TableDataInfo; import com.bonus.common.core.page.TableDataInfo;
import com.bonus.common.enums.BusinessType; import com.bonus.common.enums.BusinessType;
import com.bonus.digital.dao.DayPlanVo;
import com.bonus.digital.dao.ExportMonthPlanPersonVo; import com.bonus.digital.dao.ExportMonthPlanPersonVo;
import com.bonus.digital.dao.MonthlyPlanVo; import com.bonus.digital.dao.MonthlyPlanVo;
import com.bonus.digital.service.DayPlanService;
import com.bonus.digital.service.MonthlyPlanService; import com.bonus.digital.service.MonthlyPlanService;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.springframework.security.access.prepost.PreAuthorize; import org.springframework.security.access.prepost.PreAuthorize;
@ -21,41 +24,47 @@ import javax.servlet.http.HttpServletResponse;
import java.io.IOException; import java.io.IOException;
import java.util.List; import java.util.List;
*/
/** /**
* @author 马三炮 * @author 马三炮
* @date 2025/12/16 * @date 2025/12/16
*/ *//*
@Slf4j @Slf4j
@RestController @RestController
@RequestMapping("/dayPlan") @RequestMapping("/dayPlan")
public class DayPlanController extends BaseController { public class DayPlanController extends BaseController {
@Resource @Resource
private MonthlyPlanService monthlyPlanService; private DayPlanService dayPlanService;
*/
/** /**
* 月计划列表 * 月计划列表
*/ *//*
@PreAuthorize("@ss.hasPermi('monthly:plan:list')") @PreAuthorize("@ss.hasPermi('monthly:plan:list')")
@GetMapping("/getMonthlyPlanList") @GetMapping("/getDayPlanList")
public TableDataInfo getMonthlyPlanList(MonthlyPlanVo monthlyPlanVo) { public TableDataInfo getMonthlyPlanList(DayPlanVo dayPlanVo) {
try { try {
startPage(); startPage();
List<MonthlyPlanVo> list = monthlyPlanService.getPlanMajorList(monthlyPlanVo); List<DayPlanVo> list = dayPlanService.getDayPlanList(dayPlanVo);
return getDataTable(list); return getDataTable(list);
} catch (Exception e) { } catch (Exception e) {
return getDataTable(null); return getDataTable(null);
} }
} }
*/
/** /**
* 新增月计划 * 新增月计划
*/ *//*
@PreAuthorize("@ss.hasPermi('monthly:plan:add')") @PreAuthorize("@ss.hasPermi('monthly:plan:add')")
@PostMapping("/addMonthlyPlan") @PostMapping("/addMonthlyPlan")
public AjaxResult addMonthlyPlan(MonthlyPlanVo monthlyPlanVo) { public AjaxResult addMonthlyPlan(MonthlyPlanVo monthlyPlanVo) {
try { try {
int res = monthlyPlanService.addMonthlyPlanList(monthlyPlanVo); int res = dayPlanService.addMonthlyPlanList(monthlyPlanVo);
if (res > 0) { if (res > 0) {
return AjaxResult.success(); return AjaxResult.success();
} else { } else {
@ -66,14 +75,16 @@ public class DayPlanController extends BaseController {
} }
} }
*/
/** /**
* 删除月计划 * 删除月计划
*/ *//*
@PreAuthorize("@ss.hasPermi('monthly:plan:del')") @PreAuthorize("@ss.hasPermi('monthly:plan:del')")
@PostMapping("/delMonthlyPlan") @PostMapping("/delMonthlyPlan")
public AjaxResult delMonthlyPlan(MonthlyPlanVo monthlyPlanVo) { public AjaxResult delMonthlyPlan(MonthlyPlanVo monthlyPlanVo) {
try { try {
int res = monthlyPlanService.delMonthlyPlanList(monthlyPlanVo); int res = dayPlanService.delMonthlyPlanList(monthlyPlanVo);
if (res > 0) { if (res > 0) {
return AjaxResult.success(); return AjaxResult.success();
} else { } else {
@ -84,14 +95,16 @@ public class DayPlanController extends BaseController {
} }
} }
*/
/** /**
* 修改月计划 * 修改月计划
*/ *//*
@PreAuthorize("@ss.hasPermi('monthly:plan:update')") @PreAuthorize("@ss.hasPermi('monthly:plan:update')")
@PostMapping("/updateMonthlyPlan") @PostMapping("/updateMonthlyPlan")
public AjaxResult updateMonthlyPlan(MonthlyPlanVo monthlyPlanVo) { public AjaxResult updateMonthlyPlan(MonthlyPlanVo monthlyPlanVo) {
try { try {
int res = monthlyPlanService.updateMonthlyPlan(monthlyPlanVo); int res = dayPlanService.updateMonthlyPlan(monthlyPlanVo);
if (res > 0) { if (res > 0) {
return AjaxResult.success(); return AjaxResult.success();
} else { } else {
@ -106,7 +119,8 @@ public class DayPlanController extends BaseController {
@PreAuthorize("@ss.hasPermi('monthly:plan:export')") @PreAuthorize("@ss.hasPermi('monthly:plan:export')")
@PostMapping("/export") @PostMapping("/export")
public void export(HttpServletResponse response, MonthlyPlanVo monthlyPlanVo) throws IOException { public void export(HttpServletResponse response, MonthlyPlanVo monthlyPlanVo) throws IOException {
List<ExportMonthPlanPersonVo> list = monthlyPlanService.exportMonthlyPlanPerson(monthlyPlanVo); List<ExportMonthPlanPersonVo> list = dayPlanService.exportMonthlyPlanPerson(monthlyPlanVo);
MonthPlanExcelExporter.exportToExcel(response, list, 2025, 10, "10月运检人员安排"); MonthPlanExcelExporter.exportToExcel(response, list, 2025, 10, "10月运检人员安排");
} }
} }
*/

View File

@ -4,8 +4,8 @@ import com.bonus.common.core.controller.BaseController;
import com.bonus.common.core.domain.AjaxResult; import com.bonus.common.core.domain.AjaxResult;
import com.bonus.common.core.page.TableDataInfo; import com.bonus.common.core.page.TableDataInfo;
import com.bonus.digital.dao.InspectionStationVo; import com.bonus.digital.dao.InspectionStationVo;
import com.bonus.digital.dao.PersonnelClassificationVo;
import com.bonus.digital.dao.PersonnelVo; import com.bonus.digital.dao.PersonnelVo;
import com.bonus.digital.dao.SelectDto;
import com.bonus.digital.service.PersonnelService; import com.bonus.digital.service.PersonnelService;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.springframework.security.access.prepost.PreAuthorize; import org.springframework.security.access.prepost.PreAuthorize;
@ -31,8 +31,7 @@ public class PersonnelController extends BaseController {
*/ */
@PreAuthorize("@ss.hasPermi('tb:personnel:list')") @PreAuthorize("@ss.hasPermi('tb:personnel:list')")
@GetMapping("/getPersonnelList") @GetMapping("/getPersonnelList")
public TableDataInfo getPersonnelList(PersonnelVo personnelVo) public TableDataInfo getPersonnelList(PersonnelVo personnelVo) {
{
try { try {
startPage(); startPage();
List<PersonnelVo> list = personnelService.getPersonnelList(personnelVo); List<PersonnelVo> list = personnelService.getPersonnelList(personnelVo);
@ -42,13 +41,22 @@ public class PersonnelController extends BaseController {
} }
} }
@GetMapping("/getInspectionStationSelect")
public AjaxResult getInspectionStationSelect(InspectionStationVo vo) {
try {
List<SelectDto> list = personnelService.getInspectionStationSelect(vo.getCategory());
return AjaxResult.success(list);
} catch (Exception e) {
return AjaxResult.error("接口异常");
}
}
/** /**
* 新增人员 * 新增人员
*/ */
@PreAuthorize("@ss.hasPermi('tb:personnel:add')") @PreAuthorize("@ss.hasPermi('tb:personnel:add')")
@PostMapping("/addPersonnel") @PostMapping("/addPersonnel")
public AjaxResult addPersonnel(@RequestBody PersonnelVo personnelVo) public AjaxResult addPersonnel(@RequestBody PersonnelVo personnelVo) {
{
try { try {
int res = personnelService.addPersonnel(personnelVo); int res = personnelService.addPersonnel(personnelVo);
if (res > 0) { if (res > 0) {
@ -66,8 +74,7 @@ public class PersonnelController extends BaseController {
*/ */
@PreAuthorize("@ss.hasPermi('tb:personnel:del')") @PreAuthorize("@ss.hasPermi('tb:personnel:del')")
@PostMapping("/delPersonnel") @PostMapping("/delPersonnel")
public AjaxResult delPersonnel(@RequestBody PersonnelVo personnelVo) public AjaxResult delPersonnel(@RequestBody PersonnelVo personnelVo) {
{
try { try {
int res = personnelService.delPersonnel(personnelVo); int res = personnelService.delPersonnel(personnelVo);
if (res > 0) { if (res > 0) {
@ -85,8 +92,7 @@ public class PersonnelController extends BaseController {
*/ */
@PreAuthorize("@ss.hasPermi('tb:personnel:update')") @PreAuthorize("@ss.hasPermi('tb:personnel:update')")
@PostMapping("/updatePersonnel") @PostMapping("/updatePersonnel")
public AjaxResult updatePersonnel(@RequestBody PersonnelVo personnelVo) public AjaxResult updatePersonnel(@RequestBody PersonnelVo personnelVo) {
{
try { try {
int res = personnelService.updatePersonnel(personnelVo); int res = personnelService.updatePersonnel(personnelVo);
if (res > 0) { if (res > 0) {

View File

@ -36,7 +36,7 @@ public class PlanMajorController extends BaseController {
{ {
try { try {
startPage(); startPage();
List<PersonnelVo> list = planMajorService.getPlanMajorList(planMajorVo); List<PlanMajorVo> list = planMajorService.getPlanMajorList(planMajorVo);
return getDataTable(list); return getDataTable(list);
}catch (Exception e) { }catch (Exception e) {
return getDataTable(null); return getDataTable(null);

View File

@ -0,0 +1,158 @@
package com.bonus.digital.dao;
import lombok.Data;
import java.util.Date;
/**
* @Authorliang.chao
* @Date2025/12/18 - 10:50
*/
@Data
public class DayPlanVo {
/**
* 日计划id
*/
private Integer dayPlanId;
/**
* 月计划填报id
*/
private Integer monthlyPlanId;
/**
* 计划日期
*/
private String dayPlan;
/**
* 计划工作量
*/
private String plannedWorkload;
/**
* 拟投入作业人员
*/
private String proposedPersonnel;
/**
* 计划投入熟练工人员数量
*/
private String proposedProficientPersonnel;
/**
* 计划投入熟练工人员投入工日
*/
private String proposedProficientDay;
/**
* 计划投入辅助工人员数量
*/
private String proposedAssistancePersonnel;
/**
* 计划投入辅助工人员投入工日
*/
private String proposedAssistanceDay;
/**
* 拟投入长租车
*/
private String proposedLongTimeCar;
/**
* 拟投入临租车
*/
private String proposedTemporaryCar;
/**
* 拟投入分包车
*/
private String proposedSubCar;
/**
* 实际投入熟练工人员数量
*/
private String actualProficientPersonnel;
/**
* 实际投入检修辅助工数量
*/
private String actualAssistancePersonnel;
/**
* 实际投入作业人员
*/
private String actualPersonnel;
/**
* 实际投入长租车
*/
private String actualLongTimeCar;
/**
* 实际投入临租车
*/
private String actualTemporaryCar;
/**
* 实际投入分包车
*/
private String actualSubCar;
/**
* 实际完成工作内容
*/
private String actualWorkContent;
/**
* 实际完成工作量
*/
private String actualWorkload;
/**
* 完成比例
*/
private String completionPercentage;
/**
* 作业计划完成情况
*/
private String planCompletionStatus;
/**
* 计划变更及未完成情况说明
*/
private String planChanges;
/**
* 修改时间
*/
private String updateTime;
/**
* 是否有效1有效0无效
*/
private String isActive;
/**
* 创建人
*/
private String createUser;
/**
* 创建时间
*/
private String createTime;
/**
* 修改人
*/
private String updateUser;
/**
* 填写状态0:计划1完成
*/
private String status;
}

View File

@ -0,0 +1,13 @@
package com.bonus.digital.dao;
import lombok.Data;
/**
* @Authorliang.chao
* @Date2025/12/18 - 11:00
*/
@Data
public class SelectDto {
private String id;
private String value;
}

View File

@ -1,6 +1,8 @@
package com.bonus.digital.mapper; package com.bonus.digital.mapper;
import com.bonus.digital.dao.PersonnelVo; import com.bonus.digital.dao.PersonnelVo;
import com.bonus.digital.dao.SelectDto;
import org.apache.ibatis.annotations.Param;
import java.util.List; import java.util.List;
@ -25,4 +27,6 @@ public interface PersonnelMapper {
* 修改人员 * 修改人员
*/ */
int updatePersonnel(PersonnelVo personnelVo); int updatePersonnel(PersonnelVo personnelVo);
List<SelectDto> getInspectionStationSelect(@Param("category") String category);
} }

View File

@ -10,7 +10,7 @@ public interface PlanMajorMapper {
/** /**
* 列表类别0计划专业1业务分类2计划类别 * 列表类别0计划专业1业务分类2计划类别
*/ */
List<PersonnelVo> getPlanMajorList(PlanMajorVo planMajorVo); List<PlanMajorVo> getPlanMajorList(PlanMajorVo planMajorVo);
/** /**
* 新增类别0计划专业1业务分类2计划类别 * 新增类别0计划专业1业务分类2计划类别

View File

@ -0,0 +1,9 @@
package com.bonus.digital.service;
/**
* @Authorliang.chao
* @Date2025/12/18 - 10:48
*/
public interface DayPlanService {
}

View File

@ -1,6 +1,7 @@
package com.bonus.digital.service; package com.bonus.digital.service;
import com.bonus.digital.dao.PersonnelVo; import com.bonus.digital.dao.PersonnelVo;
import com.bonus.digital.dao.SelectDto;
import java.util.List; import java.util.List;
@ -26,4 +27,6 @@ public interface PersonnelService {
* 修改人员 * 修改人员
*/ */
int updatePersonnel(PersonnelVo personnelVo); int updatePersonnel(PersonnelVo personnelVo);
List<SelectDto> getInspectionStationSelect(String category);
} }

View File

@ -11,7 +11,7 @@ public interface PlanMajorService {
/** /**
* 列表类别0计划专业1业务分类2计划类别 * 列表类别0计划专业1业务分类2计划类别
*/ */
List<PersonnelVo> getPlanMajorList(PlanMajorVo planMajorVo); List<PlanMajorVo> getPlanMajorList(PlanMajorVo planMajorVo);
/** /**
* 新增类别0计划专业1业务分类2计划类别 * 新增类别0计划专业1业务分类2计划类别

View File

@ -0,0 +1,12 @@
package com.bonus.digital.service.impl;
import com.bonus.digital.service.DayPlanService;
import org.springframework.stereotype.Service;
/**
* @Authorliang.chao
* @Date2025/12/18 - 10:48
*/
@Service
public class DayPlanServiceImpl implements DayPlanService {
}

View File

@ -2,6 +2,7 @@ package com.bonus.digital.service.impl;
import com.bonus.common.utils.SecurityUtils; import com.bonus.common.utils.SecurityUtils;
import com.bonus.digital.dao.PersonnelVo; import com.bonus.digital.dao.PersonnelVo;
import com.bonus.digital.dao.SelectDto;
import com.bonus.digital.mapper.PersonnelMapper; import com.bonus.digital.mapper.PersonnelMapper;
import com.bonus.digital.service.PersonnelService; import com.bonus.digital.service.PersonnelService;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
@ -60,4 +61,9 @@ public class PersonnelServiceImpl implements PersonnelService {
personnelVo.setUpdateTime(new Date()); personnelVo.setUpdateTime(new Date());
return personnelMapper.updatePersonnel(personnelVo); return personnelMapper.updatePersonnel(personnelVo);
} }
@Override
public List<SelectDto> getInspectionStationSelect(String category) {
return personnelMapper.getInspectionStationSelect(category);
}
} }

View File

@ -30,7 +30,7 @@ public class PlanMajorServiceImpl implements PlanMajorService {
* 列表类别0计划专业1业务分类2计划类别 * 列表类别0计划专业1业务分类2计划类别
*/ */
@Override @Override
public List<PersonnelVo> getPlanMajorList(PlanMajorVo planMajorVo) { public List<PlanMajorVo> getPlanMajorList(PlanMajorVo planMajorVo) {
return planMajorMapper.getPlanMajorList(planMajorVo); return planMajorMapper.getPlanMajorList(planMajorVo);
} }

View File

@ -93,4 +93,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</if> </if>
</where> </where>
</select> </select>
<select id="getInspectionStationSelect" resultType="com.bonus.digital.dao.SelectDto">
select inspection_station_id as id,
inspection_station_name as value
from tb_inspection_station where is_active = '1' and category = #{category}
</select>
</mapper> </mapper>

View File

@ -29,7 +29,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
update tb_plan_major set is_active ='0' where plan_major_id = #{planMajorId} update tb_plan_major set is_active ='0' where plan_major_id = #{planMajorId}
</delete> </delete>
<select id="getPlanMajorList" resultType="com.bonus.digital.dao.PersonnelVo"> <select id="getPlanMajorList" resultType="com.bonus.digital.dao.PlanMajorVo">
select plan_major_id,plan_major_name,remark,category select plan_major_id,plan_major_name,remark,category
from tb_plan_major where category = #{category} and is_active = '1' from tb_plan_major where category = #{category} and is_active = '1'
<if test="planMajorName != null and planMajorName !=''"> <if test="planMajorName != null and planMajorName !=''">