fix(系统管理): 修复资源池更新日志问题
--bug=1039332 --user=郭雨琦 https://www.tapd.cn/55049933/bugtrace/bugs/view/1155049933001039332
This commit is contained in:
parent
a260e98116
commit
43d696670f
|
@ -36,7 +36,7 @@ public class TestResourcePoolController {
|
|||
@CacheNode // 把监控节点缓存起来
|
||||
@Operation(summary = "系统设置-系统-资源池-更新资源池")
|
||||
@RequiresPermissions(PermissionConstants.SYSTEM_TEST_RESOURCE_POOL_READ_UPDATE)
|
||||
@Log(type = OperationLogType.UPDATE, expression = "#msClass.updateLog(#request.getId())", msClass = TestResourcePoolService.class)
|
||||
@Log(type = OperationLogType.UPDATE, expression = "#msClass.updateLog(#request)", msClass = TestResourcePoolService.class)
|
||||
public void updateTestResourcePool(@Validated({Updated.class}) @RequestBody TestResourcePoolRequest request) {
|
||||
TestResourcePoolDTO testResourcePool = new TestResourcePoolDTO();
|
||||
BeanUtils.copyBean(testResourcePool, request);
|
||||
|
|
|
@ -9,10 +9,7 @@ import io.metersphere.sdk.util.CommonBeanFactory;
|
|||
import io.metersphere.sdk.util.JSON;
|
||||
import io.metersphere.sdk.util.Translator;
|
||||
import io.metersphere.system.domain.*;
|
||||
import io.metersphere.system.dto.pool.TestResourceDTO;
|
||||
import io.metersphere.system.dto.pool.TestResourcePoolDTO;
|
||||
import io.metersphere.system.dto.pool.TestResourcePoolReturnDTO;
|
||||
import io.metersphere.system.dto.pool.TestResourceReturnDTO;
|
||||
import io.metersphere.system.dto.pool.*;
|
||||
import io.metersphere.system.dto.sdk.OptionDTO;
|
||||
import io.metersphere.system.dto.sdk.QueryResourcePoolRequest;
|
||||
import io.metersphere.system.log.constants.OperationLogModule;
|
||||
|
@ -236,8 +233,8 @@ public class TestResourcePoolService {
|
|||
return testResourcePoolMapper.selectByPrimaryKey(testResourcePoolId);
|
||||
}
|
||||
|
||||
public LogDTO updateLog(String resourcePoolId) {
|
||||
TestResourcePool pool = testResourcePoolMapper.selectByPrimaryKey(resourcePoolId);
|
||||
public LogDTO updateLog(TestResourcePoolRequest request) {
|
||||
TestResourcePool pool = testResourcePoolMapper.selectByPrimaryKey(request.getId());
|
||||
if (pool != null) {
|
||||
LogDTO dto = new LogDTO(
|
||||
OperationLogConstants.SYSTEM,
|
||||
|
@ -246,7 +243,7 @@ public class TestResourcePoolService {
|
|||
pool.getCreateUser(),
|
||||
OperationLogType.UPDATE.name(),
|
||||
OperationLogModule.SETTING_SYSTEM_RESOURCE_POOL,
|
||||
pool.getName());
|
||||
request.getName());
|
||||
|
||||
dto.setPath("/update");
|
||||
dto.setMethod(HttpMethodConstants.POST.name());
|
||||
|
|
Loading…
Reference in New Issue