Merge remote-tracking branch 'origin/main'

# Conflicts:
#	yudao-module-mes/yudao-module-mes-biz/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/deviceledger/vo/DeviceLedgerSaveReqVO.java
main
liutao 2 months ago
commit 5999814527

@ -9,5 +9,6 @@ public interface DictTypeConstants {
String AUDIT_STATUS = "erp_audit_status"; // 审核状态 String AUDIT_STATUS = "erp_audit_status"; // 审核状态
String STOCK_RECORD_BIZ_TYPE = "erp_stock_record_biz_type"; // 库存明细的业务类型 String STOCK_RECORD_BIZ_TYPE = "erp_stock_record_biz_type"; // 库存明细的业务类型
String PRODUCT_CATEGORY_TYPE = "erp_product_category_type"; // 产品分类类型
} }

@ -10,6 +10,9 @@ public class ErpProductCategoryListReqVO {
@Schema(description = "分类名称", example = "芋艿") @Schema(description = "分类名称", example = "芋艿")
private String name; private String name;
@Schema(description = "分类类型", example = "1")
private Integer type;
@Schema(description = "开启状态", example = "1") @Schema(description = "开启状态", example = "1")
private Integer status; private Integer status;

@ -2,12 +2,14 @@ package cn.iocoder.yudao.module.erp.controller.admin.product.vo.category;
import cn.iocoder.yudao.framework.excel.core.annotations.DictFormat; import cn.iocoder.yudao.framework.excel.core.annotations.DictFormat;
import cn.iocoder.yudao.framework.excel.core.convert.DictConvert; import cn.iocoder.yudao.framework.excel.core.convert.DictConvert;
import cn.iocoder.yudao.module.system.enums.DictTypeConstants;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated; import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty; import com.alibaba.excel.annotation.ExcelProperty;
import io.swagger.v3.oas.annotations.media.Schema; import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data; import lombok.Data;
import static cn.iocoder.yudao.module.erp.enums.DictTypeConstants.PRODUCT_CATEGORY_TYPE;
import static cn.iocoder.yudao.module.system.enums.DictTypeConstants.COMMON_STATUS;
import java.time.LocalDateTime; import java.time.LocalDateTime;
@Schema(description = "管理后台 - ERP 产品分类 Response VO") @Schema(description = "管理后台 - ERP 产品分类 Response VO")
@ -35,9 +37,14 @@ public class ErpProductCategoryRespVO {
@ExcelProperty("分类排序") @ExcelProperty("分类排序")
private Integer sort; private Integer sort;
@Schema(description = "分类类型", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
@ExcelProperty(value = "分类类型", converter = DictConvert.class)
@DictFormat(PRODUCT_CATEGORY_TYPE)
private Integer type;
@Schema(description = "开启状态", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") @Schema(description = "开启状态", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
@ExcelProperty(value = "开启状态", converter = DictConvert.class) @ExcelProperty(value = "开启状态", converter = DictConvert.class)
@DictFormat(DictTypeConstants.COMMON_STATUS) @DictFormat(COMMON_STATUS)
private Integer status; private Integer status;
@Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED) @Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)

@ -29,6 +29,10 @@ public class ErpProductCategorySaveReqVO {
@NotNull(message = "分类排序不能为空") @NotNull(message = "分类排序不能为空")
private Integer sort; private Integer sort;
@Schema(description = "分类类型", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
@NotNull(message = "分类类型不能为空")
private Integer type;
@Schema(description = "开启状态", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") @Schema(description = "开启状态", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
@NotNull(message = "开启状态不能为空") @NotNull(message = "开启状态不能为空")
private Integer status; private Integer status;

@ -20,6 +20,9 @@ public class ErpProductPageReqVO extends PageParam {
@Schema(description = "产品分类编号", example = "11161") @Schema(description = "产品分类编号", example = "11161")
private Long categoryId; private Long categoryId;
@Schema(description = "产品分类类型", example = "1")
private Integer categoryType;
@Schema(description = "创建时间") @Schema(description = "创建时间")
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
private LocalDateTime[] createTime; private LocalDateTime[] createTime;

@ -44,6 +44,12 @@ public class ErpProductCategoryDO extends BaseDO {
* *
*/ */
private Integer sort; private Integer sort;
/**
*
*
* {@link cn.iocoder.yudao.module.erp.enums.DictTypeConstants#PRODUCT_CATEGORY_TYPE}
*/
private Integer type;
/** /**
* *
* *

@ -19,6 +19,7 @@ public interface ErpProductCategoryMapper extends BaseMapperX<ErpProductCategory
default List<ErpProductCategoryDO> selectList(ErpProductCategoryListReqVO reqVO) { default List<ErpProductCategoryDO> selectList(ErpProductCategoryListReqVO reqVO) {
return selectList(new LambdaQueryWrapperX<ErpProductCategoryDO>() return selectList(new LambdaQueryWrapperX<ErpProductCategoryDO>()
.likeIfPresent(ErpProductCategoryDO::getName, reqVO.getName()) .likeIfPresent(ErpProductCategoryDO::getName, reqVO.getName())
.eqIfPresent(ErpProductCategoryDO::getType, reqVO.getType())
.eqIfPresent(ErpProductCategoryDO::getStatus, reqVO.getStatus()) .eqIfPresent(ErpProductCategoryDO::getStatus, reqVO.getStatus())
.orderByDesc(ErpProductCategoryDO::getSort) .orderByDesc(ErpProductCategoryDO::getSort)
.orderByDesc(ErpProductCategoryDO::getId)); .orderByDesc(ErpProductCategoryDO::getId));

@ -10,12 +10,11 @@ import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProduc
import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ProductRelationRespVO; import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ProductRelationRespVO;
import cn.iocoder.yudao.module.erp.dal.dataobject.product.ErpProductDO; import cn.iocoder.yudao.module.erp.dal.dataobject.product.ErpProductDO;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.springframework.util.StringUtils; import org.springframework.util.StringUtils;
import java.util.ArrayList;
import java.util.Collection; import java.util.Collection;
import java.util.List; import java.util.List;
@ -34,15 +33,27 @@ public interface ErpProductMapper extends BaseMapperX<ErpProductDO> {
} }
default PageResult<ErpProductDO> selectPage(ErpProductPageReqVO reqVO) { default PageResult<ErpProductDO> selectPage(ErpProductPageReqVO reqVO) {
List<Long> categoryIds = selectCategoryIdsByType(reqVO.getCategoryType());
return selectPage(reqVO, new LambdaQueryWrapperX<ErpProductDO>() return selectPage(reqVO, new LambdaQueryWrapperX<ErpProductDO>()
.likeIfPresent(ErpProductDO::getName, reqVO.getName()) .likeIfPresent(ErpProductDO::getName, reqVO.getName())
.likeIfPresent(ErpProductDO::getBarCode, resolveCode(reqVO)) .likeIfPresent(ErpProductDO::getBarCode, resolveCode(reqVO))
.eqIfPresent(ErpProductDO::getCategoryId, reqVO.getCategoryId()) .eqIfPresent(ErpProductDO::getCategoryId, reqVO.getCategoryId())
.inIfPresent(ErpProductDO::getCategoryId, categoryIds)
.betweenIfPresent(ErpProductDO::getCreateTime, reqVO.getCreateTime()) .betweenIfPresent(ErpProductDO::getCreateTime, reqVO.getCreateTime())
.orderByDesc(ErpProductDO::getId)); .orderByDesc(ErpProductDO::getId));
} }
default List<Long> selectCategoryIdsByType(Integer categoryType) {
if (categoryType == null) {
return null;
}
return selectCategoryIdListByType(categoryType);
}
@Select("SELECT id FROM erp_product_category WHERE type = #{categoryType}")
List<Long> selectCategoryIdListByType(@Param("categoryType") Integer categoryType);
default List<ErpProductDO> selectList(ErpProductListReqVO reqVO) { default List<ErpProductDO> selectList(ErpProductListReqVO reqVO) {
return selectList(new LambdaQueryWrapperX<ErpProductDO>() return selectList(new LambdaQueryWrapperX<ErpProductDO>()
.inIfPresent(ErpProductDO::getId, reqVO.getIds()) .inIfPresent(ErpProductDO::getId, reqVO.getIds())

@ -99,4 +99,10 @@ public class DeviceLedgerPageReqVO extends PageParam {
@Schema(description = "产品Id") @Schema(description = "产品Id")
private Long productId; private Long productId;
@Schema(description = "出厂日期")
private LocalDateTime outgoingTime;
@Schema(description = "序列号")
private String sn;
} }

@ -175,4 +175,10 @@ public class DeviceLedgerRespVO extends BaseDO {
@Schema(description = "打印模板") @Schema(description = "打印模板")
private String templateJson; private String templateJson;
@Schema(description = "出厂日期")
private LocalDateTime outgoingTime;
@Schema(description = "序列号")
private String sn;
} }

@ -103,4 +103,10 @@ public class DeviceLedgerSaveReqVO {
@Schema(description = "设备关键件") @Schema(description = "设备关键件")
private List<DeviceCriticalComponentRespVO> componentList; private List<DeviceCriticalComponentRespVO> componentList;
@Schema(description = "出厂日期")
private LocalDate outgoingTime;
@Schema(description = "序列号")
private String sn;
} }

@ -54,6 +54,9 @@ public class DvRepairPageReqVO extends PageParam {
@Schema(description = "维修结果") @Schema(description = "维修结果")
private String repairResult; private String repairResult;
@Schema(description = "故障等级 1-一般 2-严重 3-紧急", example = "1")
private Integer faultLevel;
@Schema(description = "维修人员") @Schema(description = "维修人员")
private String acceptedBy; private String acceptedBy;

@ -91,6 +91,39 @@ public class DvRepairRespVO {
@ExcelProperty("维修结果") @ExcelProperty("维修结果")
private String repairResult; private String repairResult;
@Schema(description = "故障现象")
private String faultPhenomenon;
@Schema(description = "故障描述")
private String faultDescription;
@Schema(description = "故障等级 1-一般 2-严重 3-紧急", example = "1")
private Integer faultLevel;
@Schema(description = "故障图片,多个用逗号分隔")
private String faultImages;
@Schema(description = "停机时长")
private String downtimeDuration;
@Schema(description = "是否停机")
private Boolean isShutdown;
@Schema(description = "故障原因")
private String faultReason;
@Schema(description = "处理措施")
private String handlingMeasures;
@Schema(description = "更换配件")
private String replacementParts;
@Schema(description = "维修内容")
private String repairContent;
@Schema(description = "维修后图片,多个用逗号分隔")
private String repairedImages;
@Schema(description = "维修人员") @Schema(description = "维修人员")
@ExcelProperty("维修人员") @ExcelProperty("维修人员")
private String acceptedBy; private String acceptedBy;

@ -57,6 +57,39 @@ public class DvRepairSaveReqVO {
@Schema(description = "维修结果") @Schema(description = "维修结果")
private String repairResult; private String repairResult;
@Schema(description = "故障现象")
private String faultPhenomenon;
@Schema(description = "故障描述")
private String faultDescription;
@Schema(description = "故障等级 1-一般 2-严重 3-紧急", example = "1")
private Integer faultLevel;
@Schema(description = "故障图片,多个用逗号分隔")
private String faultImages;
@Schema(description = "停机时长")
private String downtimeDuration;
@Schema(description = "是否停机")
private Boolean isShutdown;
@Schema(description = "故障原因")
private String faultReason;
@Schema(description = "处理措施")
private String handlingMeasures;
@Schema(description = "更换配件")
private String replacementParts;
@Schema(description = "维修内容")
private String repairContent;
@Schema(description = "维修后图片,多个用逗号分隔")
private String repairedImages;
@Schema(description = "维修人员") @Schema(description = "维修人员")
private String acceptedBy; private String acceptedBy;

@ -34,9 +34,42 @@ public class DvRepirUpdateReqVO {
@NotBlank(message = "维修结果不能为空") @NotBlank(message = "维修结果不能为空")
private String repairResult; private String repairResult;
@Schema(description = "故障现象")
private String faultPhenomenon;
@Schema(description = "故障描述")
private String faultDescription;
@Schema(description = "故障图片,多个用逗号分隔")
private String faultImages;
@Schema(description = "停机时长")
private String downtimeDuration;
@Schema(description = "是否停机")
private Boolean isShutdown;
@Schema(description = "故障原因")
private String faultReason;
@Schema(description = "处理措施")
private String handlingMeasures;
@Schema(description = "更换配件")
private String replacementParts;
@Schema(description = "维修内容")
private String repairContent;
@Schema(description = "维修后图片,多个用逗号分隔")
private String repairedImages;
@Schema(description = "备注") @Schema(description = "备注")
private String remark; private String remark;
@Schema(description = "维修结果 0-待维修 1-通过 2-不通过")
private Integer repairStatus;
@Schema(description = "子列表") @Schema(description = "子列表")
@NotNull(message = "子列表不能为空") @NotNull(message = "子列表不能为空")
private List<DvRepairLineSaveReqVO> updateReqVOList; private List<DvRepairLineSaveReqVO> updateReqVOList;

@ -24,6 +24,9 @@ public class TaskManagementPageReqVO extends PageParam {
@Schema(description = "设备列表") @Schema(description = "设备列表")
private String deviceList; private String deviceList;
@Schema(description = "设备Id集合多选筛选")
private List<Long> deviceIds;
@Schema(description = "项目表单") @Schema(description = "项目表单")
private Long projectForm; private Long projectForm;

@ -79,6 +79,15 @@ public class TicketResultsController {
return success(BeanUtils.toBean(pageResult, TicketResultsRespVO.class)); return success(BeanUtils.toBean(pageResult, TicketResultsRespVO.class));
} }
@GetMapping("/list")
@Operation(summary = "获得工单检验结果分列表")
@PreAuthorize("@ss.hasPermission('mes:ticket-results:query')")
public CommonResult<List<TicketResultsRespVO>> getTicketResultsList(@Valid TicketResultsPageReqVO pageReqVO) {
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
List<TicketResultsDO> list = ticketResultsService.getTicketResultsPage(pageReqVO).getList();
return success(BeanUtils.toBean(list, TicketResultsRespVO.class));
}
@GetMapping("/export-excel") @GetMapping("/export-excel")
@Operation(summary = "导出工单检验结果 Excel") @Operation(summary = "导出工单检验结果 Excel")
@PreAuthorize("@ss.hasPermission('mes:ticket-results:export')") @PreAuthorize("@ss.hasPermission('mes:ticket-results:export')")

@ -7,6 +7,8 @@ import cn.iocoder.yudao.module.mes.dal.dataobject.criticalcomponent.CriticalComp
import cn.iocoder.yudao.module.mes.dal.dataobject.devicecriticalcomponent.DeviceCriticalComponentDO; import cn.iocoder.yudao.module.mes.dal.dataobject.devicecriticalcomponent.DeviceCriticalComponentDO;
import cn.iocoder.yudao.module.mes.dal.dataobject.dvrepair.DvRepairLineDO; import cn.iocoder.yudao.module.mes.dal.dataobject.dvrepair.DvRepairLineDO;
import cn.iocoder.yudao.module.mes.dal.dataobject.ticketresults.TicketResultsDO; import cn.iocoder.yudao.module.mes.dal.dataobject.ticketresults.TicketResultsDO;
import com.alibaba.excel.annotation.ExcelProperty;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*; import lombok.*;
import java.time.*; import java.time.*;
@ -210,6 +212,14 @@ public class DeviceLedgerDO extends BaseDO {
*/ */
private Integer dataCollectionCapacity; private Integer dataCollectionCapacity;
/**
*
*/
private LocalDate outgoingTime;
/**
*
*/
private String sn;
} }

@ -89,6 +89,52 @@ public class DvRepairDO extends BaseDO {
* *
*/ */
private String repairResult; private String repairResult;
/**
*
*/
private String faultPhenomenon;
/**
*
*/
private String faultDescription;
/**
*
*
* 1- 2- 3-
*/
private Integer faultLevel;
/**
*
*/
private String faultImages;
/**
*
*/
private String downtimeDuration;
/**
*
*/
private Boolean isShutdown;
/**
*
*/
private String faultReason;
/**
*
*/
private String handlingMeasures;
/**
*
*/
private String replacementParts;
/**
*
*/
private String repairContent;
/**
*
*/
private String repairedImages;
/** /**
* *
*/ */

@ -26,6 +26,7 @@ public interface DeviceLedgerMapper extends BaseMapperX<DeviceLedgerDO> {
deviceLedgerDOLambdaQueryWrapperX deviceLedgerDOLambdaQueryWrapperX
.likeIfPresent(DeviceLedgerDO::getDeviceCode, reqVO.getDeviceCode()) .likeIfPresent(DeviceLedgerDO::getDeviceCode, reqVO.getDeviceCode())
.likeIfPresent(DeviceLedgerDO::getDeviceName, reqVO.getDeviceName()) .likeIfPresent(DeviceLedgerDO::getDeviceName, reqVO.getDeviceName())
.likeIfPresent(DeviceLedgerDO::getSn, reqVO.getSn())
.eqIfPresent(DeviceLedgerDO::getDeviceStatus, reqVO.getDeviceStatus()) .eqIfPresent(DeviceLedgerDO::getDeviceStatus, reqVO.getDeviceStatus())
.eqIfPresent(DeviceLedgerDO::getDeviceBrand, reqVO.getDeviceBrand()) .eqIfPresent(DeviceLedgerDO::getDeviceBrand, reqVO.getDeviceBrand())
.eqIfPresent(DeviceLedgerDO::getDeviceModel, reqVO.getDeviceModel()) .eqIfPresent(DeviceLedgerDO::getDeviceModel, reqVO.getDeviceModel())

@ -1,10 +1,9 @@
package cn.iocoder.yudao.module.mes.dal.mysql.subjectplan; package cn.iocoder.yudao.module.mes.dal.mysql.subjectplan;
import cn.iocoder.yudao.framework.common.pojo.PageResult; import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX; import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.yudao.module.mes.dal.dataobject.subjectplan.SubjectPlanDO; import cn.iocoder.yudao.module.mes.dal.dataobject.subjectplan.SubjectPlanDO;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Mapper;
import cn.iocoder.yudao.module.mes.controller.admin.subjectplan.vo.*; import cn.iocoder.yudao.module.mes.controller.admin.subjectplan.vo.*;
@ -24,12 +23,9 @@ public interface SubjectPlanMapper extends BaseMapperX<SubjectPlanDO> {
.orderByDesc(SubjectPlanDO::getId)); .orderByDesc(SubjectPlanDO::getId));
} }
/** default void deleteByPlanId(Long planId) {
* delete(new LambdaQueryWrapperX<SubjectPlanDO>()
* .eq(SubjectPlanDO::getPlanId, planId));
* @param planId ID }
*/
@Delete("DELETE FROM besure.mes_subject_plan WHERE plan_id = #{planId}")
void deleteByPlanId(Long planId);
} }

@ -21,8 +21,6 @@ import cn.iocoder.yudao.module.mes.controller.admin.taskmanagement.vo.*;
public interface TaskManagementMapper extends BaseMapperX<TaskManagementDO> { public interface TaskManagementMapper extends BaseMapperX<TaskManagementDO> {
default PageResult<TaskManagementDO> selectPage(TaskManagementPageReqVO reqVO) { default PageResult<TaskManagementDO> selectPage(TaskManagementPageReqVO reqVO) {
LambdaQueryWrapperX<TaskManagementDO> taskManagementDOLambdaQueryWrapperX = new LambdaQueryWrapperX<>(); LambdaQueryWrapperX<TaskManagementDO> taskManagementDOLambdaQueryWrapperX = new LambdaQueryWrapperX<>();
taskManagementDOLambdaQueryWrapperX taskManagementDOLambdaQueryWrapperX
.likeIfPresent(TaskManagementDO::getName, reqVO.getName()) .likeIfPresent(TaskManagementDO::getName, reqVO.getName())
@ -37,6 +35,16 @@ public interface TaskManagementMapper extends BaseMapperX<TaskManagementDO> {
.betweenIfPresent(TaskManagementDO::getCreateTime, reqVO.getCreateTime()) .betweenIfPresent(TaskManagementDO::getCreateTime, reqVO.getCreateTime())
.orderByDesc(TaskManagementDO::getId); .orderByDesc(TaskManagementDO::getId);
if (reqVO.getDeviceIds() != null && !reqVO.getDeviceIds().isEmpty()) {
String deviceIdsSql = reqVO.getDeviceIds().stream()
.filter(Objects::nonNull)
.map(deviceId -> "FIND_IN_SET(" + deviceId + ", device_list) > 0")
.collect(Collectors.joining(" OR "));
if (StringUtils.isNotBlank(deviceIdsSql)) {
taskManagementDOLambdaQueryWrapperX.apply("(" + deviceIdsSql + ")");
}
}
// 单独处理 ids 条件 // 单独处理 ids 条件
if (StringUtils.isNotBlank(reqVO.getIds())) { if (StringUtils.isNotBlank(reqVO.getIds())) {
List<Long> idList = Arrays.stream(reqVO.getIds().split(",")) List<Long> idList = Arrays.stream(reqVO.getIds().split(","))

@ -27,7 +27,7 @@ public interface TicketManagementMapper extends BaseMapperX<TicketManagementDO>
ticketManagementDOLambdaQueryWrapperX ticketManagementDOLambdaQueryWrapperX
.eqIfPresent(TicketManagementDO::getTaskId, reqVO.getTaskId()) .eqIfPresent(TicketManagementDO::getTaskId, reqVO.getTaskId())
.eqIfPresent(TicketManagementDO::getPlanId, reqVO.getPlanId()) .eqIfPresent(TicketManagementDO::getPlanId, reqVO.getPlanId())
.eqIfPresent(TicketManagementDO::getPlanNo, reqVO.getPlanNo()) .likeIfPresent(TicketManagementDO::getPlanNo, reqVO.getPlanNo())
.likeIfPresent(TicketManagementDO::getDeviceName, reqVO.getDeviceName()) .likeIfPresent(TicketManagementDO::getDeviceName, reqVO.getDeviceName())
.eqIfPresent(TicketManagementDO::getPlanType, reqVO.getPlanType()) .eqIfPresent(TicketManagementDO::getPlanType, reqVO.getPlanType())
.likeIfPresent(TicketManagementDO::getConfigName, reqVO.getConfigName()) .likeIfPresent(TicketManagementDO::getConfigName, reqVO.getConfigName())

@ -75,7 +75,7 @@ public class DvRepairServiceImpl implements DvRepairService {
dvRepairMapper.insert(dvRepair); dvRepairMapper.insert(dvRepair);
// 插入子表 // 插入子表
createDvRepairLineList(dvRepair.getId(), createReqVO.getDvRepairLines()); // createDvRepairLineList(dvRepair.getId(), createReqVO.getDvRepairLines());
// 返回 // 返回
return dvRepair.getId(); return dvRepair.getId();
} }
@ -102,7 +102,7 @@ public class DvRepairServiceImpl implements DvRepairService {
dvRepairMapper.updateById(updateObj); dvRepairMapper.updateById(updateObj);
// 更新子表 // 更新子表
updateDvRepairLineList(updateReqVO.getId(), updateReqVO.getDvRepairLines()); // updateDvRepairLineList(updateReqVO.getId(), updateReqVO.getDvRepairLines());
} }
@ -195,8 +195,21 @@ public class DvRepairServiceImpl implements DvRepairService {
dvRepairDO.setFinishDate(updateReqVO.getFinishDate()); dvRepairDO.setFinishDate(updateReqVO.getFinishDate());
dvRepairDO.setConfirmDate(updateReqVO.getConfirmDate()); dvRepairDO.setConfirmDate(updateReqVO.getConfirmDate());
dvRepairDO.setRepairResult(updateReqVO.getRepairResult()); dvRepairDO.setRepairResult(updateReqVO.getRepairResult());
dvRepairDO.setFaultPhenomenon(updateReqVO.getFaultPhenomenon());
dvRepairDO.setFaultDescription(updateReqVO.getFaultDescription());
dvRepairDO.setFaultImages(updateReqVO.getFaultImages());
dvRepairDO.setDowntimeDuration(updateReqVO.getDowntimeDuration());
dvRepairDO.setIsShutdown(updateReqVO.getIsShutdown());
dvRepairDO.setFaultReason(updateReqVO.getFaultReason());
dvRepairDO.setHandlingMeasures(updateReqVO.getHandlingMeasures());
dvRepairDO.setReplacementParts(updateReqVO.getReplacementParts());
dvRepairDO.setRepairContent(updateReqVO.getRepairContent());
dvRepairDO.setRepairedImages(updateReqVO.getRepairedImages());
dvRepairDO.setRemark(updateReqVO.getRemark());
dvRepairDO.setRepairStatus(updateReqVO.getRepairStatus());
dvRepairDO.setStatus(RepairStatusEnum.COMPLETED.getCode());
dvRepairMapper.updateById(dvRepairDO); dvRepairMapper.updateById(dvRepairDO);
batchUpdateTicketResults(updateReqVO.getUpdateReqVOList()); // batchUpdateTicketResults(updateReqVO.getUpdateReqVOList());
} }

@ -141,7 +141,7 @@ public class PermissionServiceImpl implements PermissionService {
allEntries = true) // allEntries 清空所有缓存,主要一次更新涉及到的 menuIds 较多,反倒批量会更快 allEntries = true) // allEntries 清空所有缓存,主要一次更新涉及到的 menuIds 较多,反倒批量会更快
}) })
public void assignRoleMenu(Long roleId, Set<Long> menuIds) { public void assignRoleMenu(Long roleId, Set<Long> menuIds) {
validateMenuClientType(menuIds); // validateMenuClientType(menuIds);
// 获得角色拥有菜单编号 // 获得角色拥有菜单编号
Set<Long> dbMenuIds = convertSet(roleMenuMapper.selectListByRoleId(roleId), RoleMenuDO::getMenuId); Set<Long> dbMenuIds = convertSet(roleMenuMapper.selectListByRoleId(roleId), RoleMenuDO::getMenuId);
// 计算新增和删除的菜单编号 // 计算新增和删除的菜单编号

Loading…
Cancel
Save