Commit 40059239 by Jony.L

算力资源重构-算力资源SPU管理、资源配置管理修改

parent fd70eb73
...@@ -8,9 +8,10 @@ import com.luhu.computility.framework.common.exception.ErrorCode; ...@@ -8,9 +8,10 @@ import com.luhu.computility.framework.common.exception.ErrorCode;
* Compute 系统,使用 1-020-000-000 段 * Compute 系统,使用 1-020-000-000 段
*/ */
public interface ErrorCodeConstants { public interface ErrorCodeConstants {
// ========== 算力资源分类表(仅用于算力服务器分类) 1-020-001-000 ==========
ErrorCode RESOURCE_CATEGORY_NOT_EXISTS = new ErrorCode(1_030_001_000, "算力资源分类表(仅用于算力服务器分类)不存在"); ErrorCode RESOURCE_CATEGORY_NOT_EXISTS = new ErrorCode(1_030_001_000, "算力资源分类表(仅用于算力服务器分类)不存在");
ErrorCode RESOURCE_SKU_NOT_EXISTS = new ErrorCode(1_030_002_000, "算力资源SKU表(价格和租赁信息)不存在"); ErrorCode RESOURCE_SKU_NOT_EXISTS = new ErrorCode(1_030_002_000, "算力资源SKU表(价格和租赁信息)不存在");
ErrorCode RESOURCE_SPU_NOT_EXISTS = new ErrorCode(1_030_003_000, "算力资源SPU表(基础配置信息)不存在"); ErrorCode RESOURCE_SPU_NOT_EXISTS = new ErrorCode(1_030_003_000, "算力资源SPU表(基础配置信息)不存在");
ErrorCode RESOURCE_ORDER_NOT_EXISTS = new ErrorCode(1_030_004_000, "算力资源订单不存在"); ErrorCode RESOURCE_ORDER_NOT_EXISTS = new ErrorCode(1_030_004_000, "算力资源订单不存在");
ErrorCode RESOURCE_CONFIG_NOT_EXISTS = new ErrorCode(1_030_005_000, "算力资源配置不存在");
} }
\ No newline at end of file
package com.luhu.computility.module.compute.enums;
import lombok.Getter;
/**
* @Author: jony
* @Date : 2025/9/30 14:56
* @VERSION v1.0
*/
@Getter
public enum ResourceEnableStatus {
ENABLE(0,"启用"),
DISABLE(1,"禁用");
private Integer value;
private String label;
private ResourceEnableStatus(Integer value, String label) {
this.value = value;
this.label = label;
}
public static ResourceEnableStatus getByValue(int value) {
for (ResourceEnableStatus o : ResourceEnableStatus.values()) {
if (o.getValue() == value) {
return o;
}
}
return null;
}
public static String getLabelByValue(Integer value) {
for (ResourceEnableStatus status : values()) {
if (status.getValue() == value) {
return status.getLabel();
}
}
return null;
}
}
...@@ -38,6 +38,12 @@ public class ResourceCategoryController { ...@@ -38,6 +38,12 @@ public class ResourceCategoryController {
@Resource @Resource
private ResourceCategoryService resourceCategoryService; private ResourceCategoryService resourceCategoryService;
@GetMapping("/list-simple")
@Operation(summary = "获取精简算力资源分类列表")
public CommonResult<List<ResourceCategorySimpleRespVO>> getSimpleCategory(){
return success(BeanUtils.toBean(resourceCategoryService.getAllCategory(), ResourceCategorySimpleRespVO.class));
}
@PostMapping("/create") @PostMapping("/create")
@Operation(summary = "创建算力资源分类表(仅用于算力服务器分类)") @Operation(summary = "创建算力资源分类表(仅用于算力服务器分类)")
@PreAuthorize("@ss.hasPermission('compute:resource-category:create')") @PreAuthorize("@ss.hasPermission('compute:resource-category:create')")
......
package com.luhu.computility.module.compute.controller.admin.resourcecategory.vo;
import com.alibaba.excel.annotation.ExcelProperty;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
/**
* @Author: jony
* @Date : 2025/9/30 16:46
* @VERSION v1.0
*/
@Data
public class ResourceCategorySimpleRespVO {
@Schema(description = "分类编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "13591")
@ExcelProperty("分类编号")
private Long id;
@Schema(description = "分类名称(如:高性能计算服务资源)", requiredMode = Schema.RequiredMode.REQUIRED, example = "王五")
@ExcelProperty("分类名称(如:高性能计算服务资源)")
private String name;
}
package com.luhu.computility.module.compute.controller.admin.resourceconfig;
import org.springframework.web.bind.annotation.*;
import javax.annotation.Resource;
import org.springframework.validation.annotation.Validated;
import org.springframework.security.access.prepost.PreAuthorize;
import io.swagger.v3.oas.annotations.tags.Tag;
import io.swagger.v3.oas.annotations.Parameter;
import io.swagger.v3.oas.annotations.Operation;
import javax.validation.constraints.*;
import javax.validation.*;
import javax.servlet.http.*;
import java.util.*;
import java.io.IOException;
import com.luhu.computility.framework.common.pojo.PageParam;
import com.luhu.computility.framework.common.pojo.PageResult;
import com.luhu.computility.framework.common.pojo.CommonResult;
import com.luhu.computility.framework.common.util.object.BeanUtils;
import static com.luhu.computility.framework.common.pojo.CommonResult.success;
import com.luhu.computility.framework.excel.core.util.ExcelUtils;
import com.luhu.computility.framework.apilog.core.annotation.ApiAccessLog;
import static com.luhu.computility.framework.apilog.core.enums.OperateTypeEnum.*;
import com.luhu.computility.module.compute.controller.admin.resourceconfig.vo.*;
import com.luhu.computility.module.compute.dal.dataobject.resourceconfig.ResourceConfigDO;
import com.luhu.computility.module.compute.service.resourceconfig.ResourceConfigService;
@Tag(name = "管理后台 - 算力资源配置")
@RestController
@RequestMapping("/compute/resource-config")
@Validated
public class ResourceConfigController {
@Resource
private ResourceConfigService resourceConfigService;
@GetMapping("/list-simple-config-by-category")
@Operation(summary = "精简资源配置列表")
public CommonResult<List<ResourceConfigSimpleRespVO>> listSimpleConfigByCategory(String category){
List<ResourceConfigDO> configDOList = resourceConfigService.listSimpleConfigByCategory(category);
return success(BeanUtils.toBean(configDOList, ResourceConfigSimpleRespVO.class));
}
@PostMapping("/create")
@Operation(summary = "创建算力资源配置")
@PreAuthorize("@ss.hasPermission('compute:resource-config:create')")
public CommonResult<Long> createResourceConfig(@Valid @RequestBody ResourceConfigSaveReqVO createReqVO) {
return success(resourceConfigService.createResourceConfig(createReqVO));
}
@PutMapping("/update")
@Operation(summary = "更新算力资源配置")
@PreAuthorize("@ss.hasPermission('compute:resource-config:update')")
public CommonResult<Boolean> updateResourceConfig(@Valid @RequestBody ResourceConfigSaveReqVO updateReqVO) {
resourceConfigService.updateResourceConfig(updateReqVO);
return success(true);
}
@DeleteMapping("/delete")
@Operation(summary = "删除算力资源配置")
@Parameter(name = "id", description = "编号", required = true)
@PreAuthorize("@ss.hasPermission('compute:resource-config:delete')")
public CommonResult<Boolean> deleteResourceConfig(@RequestParam("id") Long id) {
resourceConfigService.deleteResourceConfig(id);
return success(true);
}
@DeleteMapping("/delete-list")
@Parameter(name = "ids", description = "编号", required = true)
@Operation(summary = "批量删除算力资源配置")
@PreAuthorize("@ss.hasPermission('compute:resource-config:delete')")
public CommonResult<Boolean> deleteResourceConfigList(@RequestParam("ids") List<Long> ids) {
resourceConfigService.deleteResourceConfigListByIds(ids);
return success(true);
}
@GetMapping("/get")
@Operation(summary = "获得算力资源配置")
@Parameter(name = "id", description = "编号", required = true, example = "1024")
@PreAuthorize("@ss.hasPermission('compute:resource-config:query')")
public CommonResult<ResourceConfigRespVO> getResourceConfig(@RequestParam("id") Long id) {
ResourceConfigDO resourceConfig = resourceConfigService.getResourceConfig(id);
return success(BeanUtils.toBean(resourceConfig, ResourceConfigRespVO.class));
}
@GetMapping("/page")
@Operation(summary = "获得算力资源配置分页")
@PreAuthorize("@ss.hasPermission('compute:resource-config:query')")
public CommonResult<PageResult<ResourceConfigRespVO>> getResourceConfigPage(@Valid ResourceConfigPageReqVO pageReqVO) {
PageResult<ResourceConfigDO> pageResult = resourceConfigService.getResourceConfigPage(pageReqVO);
return success(BeanUtils.toBean(pageResult, ResourceConfigRespVO.class));
}
@GetMapping("/export-excel")
@Operation(summary = "导出算力资源配置 Excel")
@PreAuthorize("@ss.hasPermission('compute:resource-config:export')")
@ApiAccessLog(operateType = EXPORT)
public void exportResourceConfigExcel(@Valid ResourceConfigPageReqVO pageReqVO,
HttpServletResponse response) throws IOException {
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
List<ResourceConfigDO> list = resourceConfigService.getResourceConfigPage(pageReqVO).getList();
// 导出 Excel
ExcelUtils.write(response, "算力资源配置.xls", "数据", ResourceConfigRespVO.class,
BeanUtils.toBean(list, ResourceConfigRespVO.class));
}
}
\ No newline at end of file
package com.luhu.computility.module.compute.controller.admin.resourceconfig.vo;
import lombok.*;
import java.util.*;
import io.swagger.v3.oas.annotations.media.Schema;
import com.luhu.computility.framework.common.pojo.PageParam;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDateTime;
import static com.luhu.computility.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
@Schema(description = "管理后台 - 算力资源配置分页 Request VO")
@Data
public class ResourceConfigPageReqVO extends PageParam {
@Schema(description = "配置类别")
private String configCategory;
@Schema(description = "配置选项")
private String configOption;
@Schema(description = "排序")
private Integer sort;
@Schema(description = "状态:0=启用,1=禁用", example = "2")
private Integer status;
@Schema(description = "详情备注(如:i7-13700K 16核24线程)", example = "你猜")
private String detailRemark;
@Schema(description = "创建时间")
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
private LocalDateTime[] createTime;
}
\ No newline at end of file
package com.luhu.computility.module.compute.controller.admin.resourceconfig.vo;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import java.util.*;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDateTime;
import com.alibaba.excel.annotation.*;
@Schema(description = "管理后台 - 算力资源配置 Response VO")
@Data
@ExcelIgnoreUnannotated
public class ResourceConfigRespVO {
@Schema(description = "主键ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "11532")
@ExcelProperty("主键ID")
private Long id;
@Schema(description = "配置类别", requiredMode = Schema.RequiredMode.REQUIRED)
@ExcelProperty("配置类别")
private String configCategory;
@Schema(description = "配置选项", requiredMode = Schema.RequiredMode.REQUIRED)
@ExcelProperty("配置选项")
private String configOption;
@Schema(description = "排序")
@ExcelProperty("排序")
private Integer sort;
@Schema(description = "状态:0=启用,1=禁用", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
@ExcelProperty("状态:0=启用,1=禁用")
private Integer status;
@Schema(description = "详情备注(如:i7-13700K 16核24线程)", example = "你猜")
@ExcelProperty("详情备注(如:i7-13700K 16核24线程)")
private String detailRemark;
@Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
@ExcelProperty("创建时间")
private LocalDateTime createTime;
}
\ No newline at end of file
package com.luhu.computility.module.compute.controller.admin.resourceconfig.vo;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import java.util.*;
import javax.validation.constraints.*;
@Schema(description = "管理后台 - 算力资源配置新增/修改 Request VO")
@Data
public class ResourceConfigSaveReqVO {
@Schema(description = "主键ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "11532")
private Long id;
@Schema(description = "配置类别", requiredMode = Schema.RequiredMode.REQUIRED)
@NotEmpty(message = "配置类别不能为空")
private String configCategory;
@Schema(description = "配置选项", requiredMode = Schema.RequiredMode.REQUIRED)
@NotEmpty(message = "配置选项不能为空")
private String configOption;
@Schema(description = "排序")
private Integer sort;
@Schema(description = "状态:0=启用,1=禁用", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
@NotNull(message = "状态:0=启用,1=禁用不能为空")
private Integer status;
@Schema(description = "详情备注(如:i7-13700K 16核24线程)", example = "你猜")
private String detailRemark;
}
\ No newline at end of file
package com.luhu.computility.module.compute.controller.admin.resourceconfig.vo;
import com.alibaba.excel.annotation.ExcelProperty;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
/**
* @Author: jony
* @Date : 2025/9/30 14:50
* @VERSION v1.0
*/
@Schema(description = "管理后台 - 精简算力资源配置 Response VO")
@Data
public class ResourceConfigSimpleRespVO {
@Schema(description = "主键ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "11532")
@ExcelProperty("主键ID")
private Long id;
@Schema(description = "配置类别", requiredMode = Schema.RequiredMode.REQUIRED)
@ExcelProperty("配置类别")
private String configCategory;
@Schema(description = "配置选项", requiredMode = Schema.RequiredMode.REQUIRED)
@ExcelProperty("配置选项")
private String configOption;
}
package com.luhu.computility.module.compute.dal.dataobject.resourceconfig;
import lombok.*;
import java.util.*;
import java.time.LocalDateTime;
import java.time.LocalDateTime;
import com.baomidou.mybatisplus.annotation.*;
import com.luhu.computility.framework.mybatis.core.dataobject.BaseDO;
/**
* 算力资源配置 DO
*
* @author 呼啦啦
*/
@TableName("compute_resource_config")
@KeySequence("compute_resource_config_seq") // 用于 Oracle、PostgreSQL、Kingbase、DB2、H2 数据库的主键自增。如果是 MySQL 等数据库,可不写。
@Data
@EqualsAndHashCode(callSuper = true)
@ToString(callSuper = true)
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class ResourceConfigDO extends BaseDO {
/**
* 主键ID
*/
@TableId
private Long id;
/**
* 配置类别
*/
private String configCategory;
/**
* 配置选项
*/
private String configOption;
/**
* 排序
*/
private Integer sort;
/**
* 状态:0=启用,1=禁用
*/
private Integer status;
/**
* 详情备注(如:i7-13700K 16核24线程)
*/
private String detailRemark;
}
\ No newline at end of file
package com.luhu.computility.module.compute.dal.mysql.resourceconfig;
import java.util.*;
import com.luhu.computility.framework.common.pojo.PageResult;
import com.luhu.computility.framework.mybatis.core.query.LambdaQueryWrapperX;
import com.luhu.computility.framework.mybatis.core.mapper.BaseMapperX;
import com.luhu.computility.module.compute.dal.dataobject.resourceconfig.ResourceConfigDO;
import org.apache.ibatis.annotations.Mapper;
import com.luhu.computility.module.compute.controller.admin.resourceconfig.vo.*;
/**
* 算力资源配置 Mapper
*
* @author 呼啦啦
*/
@Mapper
public interface ResourceConfigMapper extends BaseMapperX<ResourceConfigDO> {
default PageResult<ResourceConfigDO> selectPage(ResourceConfigPageReqVO reqVO) {
return selectPage(reqVO, new LambdaQueryWrapperX<ResourceConfigDO>()
.eqIfPresent(ResourceConfigDO::getConfigCategory, reqVO.getConfigCategory())
.eqIfPresent(ResourceConfigDO::getConfigOption, reqVO.getConfigOption())
.eqIfPresent(ResourceConfigDO::getSort, reqVO.getSort())
.eqIfPresent(ResourceConfigDO::getStatus, reqVO.getStatus())
.eqIfPresent(ResourceConfigDO::getDetailRemark, reqVO.getDetailRemark())
.betweenIfPresent(ResourceConfigDO::getCreateTime, reqVO.getCreateTime())
.orderByDesc(ResourceConfigDO::getId));
}
}
\ No newline at end of file
...@@ -15,6 +15,12 @@ import com.luhu.computility.framework.common.pojo.PageParam; ...@@ -15,6 +15,12 @@ import com.luhu.computility.framework.common.pojo.PageParam;
public interface ResourceCategoryService { public interface ResourceCategoryService {
/** /**
*
*
* @return
*/
List<ResourceCategoryDO> getAllCategory();
/**
* 创建算力资源分类表(仅用于算力服务器分类) * 创建算力资源分类表(仅用于算力服务器分类)
* *
* @param createReqVO 创建信息 * @param createReqVO 创建信息
......
...@@ -19,6 +19,7 @@ import static com.luhu.computility.framework.common.exception.util.ServiceExcept ...@@ -19,6 +19,7 @@ import static com.luhu.computility.framework.common.exception.util.ServiceExcept
import static com.luhu.computility.framework.common.util.collection.CollectionUtils.convertList; import static com.luhu.computility.framework.common.util.collection.CollectionUtils.convertList;
import static com.luhu.computility.framework.common.util.collection.CollectionUtils.diffList; import static com.luhu.computility.framework.common.util.collection.CollectionUtils.diffList;
import static com.luhu.computility.module.compute.enums.ErrorCodeConstants.*; import static com.luhu.computility.module.compute.enums.ErrorCodeConstants.*;
import static com.luhu.computility.module.compute.enums.ResourceEnableStatus.ENABLE;
/** /**
* 算力资源分类表(仅用于算力服务器分类) Service 实现类 * 算力资源分类表(仅用于算力服务器分类) Service 实现类
...@@ -33,6 +34,14 @@ public class ResourceCategoryServiceImpl implements ResourceCategoryService { ...@@ -33,6 +34,14 @@ public class ResourceCategoryServiceImpl implements ResourceCategoryService {
private ResourceCategoryMapper resourceCategoryMapper; private ResourceCategoryMapper resourceCategoryMapper;
@Override @Override
public List<ResourceCategoryDO> getAllCategory() {
ResourceCategoryPageReqVO reqVO = new ResourceCategoryPageReqVO();
reqVO.setStatus(ENABLE.getValue()).setPageSize(PageParam.PAGE_SIZE_NONE);
List<ResourceCategoryDO> list = resourceCategoryMapper.selectPage(reqVO).getList();
return list;
}
@Override
public Long createResourceCategory(ResourceCategorySaveReqVO createReqVO) { public Long createResourceCategory(ResourceCategorySaveReqVO createReqVO) {
// 插入 // 插入
ResourceCategoryDO resourceCategory = BeanUtils.toBean(createReqVO, ResourceCategoryDO.class); ResourceCategoryDO resourceCategory = BeanUtils.toBean(createReqVO, ResourceCategoryDO.class);
......
package com.luhu.computility.module.compute.service.resourceconfig;
import java.util.*;
import javax.validation.*;
import com.luhu.computility.module.compute.controller.admin.resourceconfig.vo.*;
import com.luhu.computility.module.compute.dal.dataobject.resourceconfig.ResourceConfigDO;
import com.luhu.computility.framework.common.pojo.PageResult;
import com.luhu.computility.framework.common.pojo.PageParam;
/**
* 算力资源配置 Service 接口
*
* @author 呼啦啦
*/
public interface ResourceConfigService {
/**
* 通过配置类别获取配置
*
* @param category
* @return
*/
List<ResourceConfigDO> listSimpleConfigByCategory(String category);
/**
* 创建算力资源配置
*
* @param createReqVO 创建信息
* @return 编号
*/
Long createResourceConfig(@Valid ResourceConfigSaveReqVO createReqVO);
/**
* 更新算力资源配置
*
* @param updateReqVO 更新信息
*/
void updateResourceConfig(@Valid ResourceConfigSaveReqVO updateReqVO);
/**
* 删除算力资源配置
*
* @param id 编号
*/
void deleteResourceConfig(Long id);
/**
* 批量删除算力资源配置
*
* @param ids 编号
*/
void deleteResourceConfigListByIds(List<Long> ids);
/**
* 获得算力资源配置
*
* @param id 编号
* @return 算力资源配置
*/
ResourceConfigDO getResourceConfig(Long id);
/**
* 获得算力资源配置分页
*
* @param pageReqVO 分页查询
* @return 算力资源配置分页
*/
PageResult<ResourceConfigDO> getResourceConfigPage(ResourceConfigPageReqVO pageReqVO);
}
\ No newline at end of file
package com.luhu.computility.module.compute.service.resourceconfig;
import cn.hutool.core.util.ObjectUtil;
import com.luhu.computility.framework.common.pojo.PageResult;
import com.luhu.computility.framework.common.util.object.BeanUtils;
import com.luhu.computility.module.compute.controller.admin.resourceconfig.vo.ResourceConfigPageReqVO;
import com.luhu.computility.module.compute.controller.admin.resourceconfig.vo.ResourceConfigSaveReqVO;
import com.luhu.computility.module.compute.dal.dataobject.resourceconfig.ResourceConfigDO;
import com.luhu.computility.module.compute.dal.mysql.resourceconfig.ResourceConfigMapper;
import org.springframework.stereotype.Service;
import org.springframework.validation.annotation.Validated;
import javax.annotation.Resource;
import java.util.Collections;
import java.util.List;
import static com.luhu.computility.framework.common.exception.util.ServiceExceptionUtil.exception;
import static com.luhu.computility.module.compute.enums.ErrorCodeConstants.RESOURCE_CONFIG_NOT_EXISTS;
import static com.luhu.computility.module.compute.enums.ResourceEnableStatus.ENABLE;
/**
* 算力资源配置 Service 实现类
*
* @author 呼啦啦
*/
@Service
@Validated
public class ResourceConfigServiceImpl implements ResourceConfigService {
@Resource
private ResourceConfigMapper resourceConfigMapper;
@Override
public List<ResourceConfigDO> listSimpleConfigByCategory(String category) {
ResourceConfigPageReqVO queryVo = new ResourceConfigPageReqVO();
if (ObjectUtil.isEmpty(category)) {
queryVo.setConfigCategory(null);
} else {
queryVo.setConfigCategory(category);
}
queryVo.setStatus(ENABLE.getValue());
List<ResourceConfigDO> list = resourceConfigMapper.selectPage(queryVo).getList();
return list;
}
@Override
public Long createResourceConfig(ResourceConfigSaveReqVO createReqVO) {
// 插入
ResourceConfigDO resourceConfig = BeanUtils.toBean(createReqVO, ResourceConfigDO.class);
resourceConfigMapper.insert(resourceConfig);
// 返回
return resourceConfig.getId();
}
@Override
public void updateResourceConfig(ResourceConfigSaveReqVO updateReqVO) {
// 校验存在
validateResourceConfigExists(updateReqVO.getId());
// 更新
ResourceConfigDO updateObj = BeanUtils.toBean(updateReqVO, ResourceConfigDO.class);
resourceConfigMapper.updateById(updateObj);
}
@Override
public void deleteResourceConfig(Long id) {
// 校验存在
validateResourceConfigExists(id);
// 删除
resourceConfigMapper.deleteById(id);
}
@Override
public void deleteResourceConfigListByIds(List<Long> ids) {
// 删除
resourceConfigMapper.deleteByIds(ids);
}
private void validateResourceConfigExists(Long id) {
if (resourceConfigMapper.selectById(id) == null) {
throw exception(RESOURCE_CONFIG_NOT_EXISTS);
}
}
@Override
public ResourceConfigDO getResourceConfig(Long id) {
return resourceConfigMapper.selectById(id);
}
@Override
public PageResult<ResourceConfigDO> getResourceConfigPage(ResourceConfigPageReqVO pageReqVO) {
return resourceConfigMapper.selectPage(pageReqVO);
}
}
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.luhu.computility.module.compute.dal.mysql.resourceconfig.ResourceConfigMapper">
<!--
一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。
无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。
代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。
文档可见:https://www.iocoder.cn/MyBatis/x-plugins/
-->
</mapper>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment