fix(测试用例): 用例快捷创建缺陷处理人入参有误
--bug=1042300 --user=宋昌昌 【测试用例】用例详情-缺陷-新建缺陷-选择了处理人-缺陷创建完成后处理人字段显示- https://www.tapd.cn/55049933/s/1530525
This commit is contained in:
parent
c0eb21dc22
commit
4c4fed22d7
|
@ -15,6 +15,7 @@ import io.metersphere.sdk.util.LogUtils;
|
||||||
import io.metersphere.system.uid.IDGenerator;
|
import io.metersphere.system.uid.IDGenerator;
|
||||||
import jakarta.annotation.Resource;
|
import jakarta.annotation.Resource;
|
||||||
import org.apache.commons.collections4.CollectionUtils;
|
import org.apache.commons.collections4.CollectionUtils;
|
||||||
|
import org.apache.commons.collections4.MapUtils;
|
||||||
import org.apache.commons.lang3.StringUtils;
|
import org.apache.commons.lang3.StringUtils;
|
||||||
import org.springframework.data.redis.core.ListOperations;
|
import org.springframework.data.redis.core.ListOperations;
|
||||||
import org.springframework.data.redis.core.RedisTemplate;
|
import org.springframework.data.redis.core.RedisTemplate;
|
||||||
|
@ -278,7 +279,9 @@ public class TestPlanExecuteService {
|
||||||
this.setRedisForList(genQueueKey(queueId, queueType), childrenQueue.stream().map(JSON::toJSONString).toList());
|
this.setRedisForList(genQueueKey(queueId, queueType), childrenQueue.stream().map(JSON::toJSONString).toList());
|
||||||
|
|
||||||
// 更新报告的执行时间
|
// 更新报告的执行时间
|
||||||
|
if (MapUtils.isNotEmpty(reportMap)) {
|
||||||
extTestPlanReportMapper.batchUpdateExecuteTimeAndStatus(System.currentTimeMillis(), reportMap.values().stream().toList());
|
extTestPlanReportMapper.batchUpdateExecuteTimeAndStatus(System.currentTimeMillis(), reportMap.values().stream().toList());
|
||||||
|
}
|
||||||
|
|
||||||
if (StringUtils.equalsIgnoreCase(executionQueue.getRunMode(), ApiBatchRunMode.SERIAL.name())) {
|
if (StringUtils.equalsIgnoreCase(executionQueue.getRunMode(), ApiBatchRunMode.SERIAL.name())) {
|
||||||
//串行
|
//串行
|
||||||
|
@ -296,7 +299,9 @@ public class TestPlanExecuteService {
|
||||||
} else {
|
} else {
|
||||||
Map<String, String> reportMap = testPlanReportService.genReportByExecution(executionQueue.getPrepareReportId(), genReportRequest, executionQueue.getCreateUser());
|
Map<String, String> reportMap = testPlanReportService.genReportByExecution(executionQueue.getPrepareReportId(), genReportRequest, executionQueue.getCreateUser());
|
||||||
executionQueue.setPrepareReportId(reportMap.get(executionQueue.getSourceID()));
|
executionQueue.setPrepareReportId(reportMap.get(executionQueue.getSourceID()));
|
||||||
|
if (MapUtils.isNotEmpty(reportMap)) {
|
||||||
extTestPlanReportMapper.batchUpdateExecuteTimeAndStatus(System.currentTimeMillis(), reportMap.values().stream().toList());
|
extTestPlanReportMapper.batchUpdateExecuteTimeAndStatus(System.currentTimeMillis(), reportMap.values().stream().toList());
|
||||||
|
}
|
||||||
this.executeTestPlan(executionQueue);
|
this.executeTestPlan(executionQueue);
|
||||||
return executionQueue.getPrepareReportId();
|
return executionQueue.getPrepareReportId();
|
||||||
}
|
}
|
||||||
|
|
|
@ -125,10 +125,11 @@
|
||||||
if (!errors) {
|
if (!errors) {
|
||||||
drawerLoading.value = true;
|
drawerLoading.value = true;
|
||||||
templateCustomFields.value.forEach((item: any) => {
|
templateCustomFields.value.forEach((item: any) => {
|
||||||
if (item.id === 'current_owner') {
|
if (item.key === 'handleUser') {
|
||||||
item.value = form.value.handleUserId;
|
item.value = form.value.handleUserId;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
delete form.value.handleUserId;
|
||||||
try {
|
try {
|
||||||
await createOrUpdateBug({
|
await createOrUpdateBug({
|
||||||
request: { ...form.value, customFields: templateCustomFields.value, ...props.extraParams },
|
request: { ...form.value, customFields: templateCustomFields.value, ...props.extraParams },
|
||||||
|
@ -167,6 +168,7 @@
|
||||||
templateCustomFields.value = result.customFields.map((item: any) => {
|
templateCustomFields.value = result.customFields.map((item: any) => {
|
||||||
return {
|
return {
|
||||||
id: item.fieldId,
|
id: item.fieldId,
|
||||||
|
key: item.fieldKey,
|
||||||
name: item.fieldName,
|
name: item.fieldName,
|
||||||
type: item.type,
|
type: item.type,
|
||||||
value: (Array.isArray(item.defaultValue) ? JSON.stringify(item.defaultValue) : item.defaultValue) || '',
|
value: (Array.isArray(item.defaultValue) ? JSON.stringify(item.defaultValue) : item.defaultValue) || '',
|
||||||
|
|
Loading…
Reference in New Issue