fix(接口测试): 修复未输入url,仍然可以执行的缺陷

--bug=1037938 --user=王孝刚 【接口测试】接口调试-不输入url点执行,提示参数校验失败,建议明确提示信息
https://www.tapd.cn/55049933/s/1502172
This commit is contained in:
wxg0103 2024-04-19 15:40:41 +08:00 committed by 刘瑞斌
parent 4c885325a7
commit 291e2f3104
4 changed files with 11 additions and 6 deletions

View File

@ -611,7 +611,7 @@
select
a.id as id,
max(a.num) as num,
max(a.name) as resourceName,
max(a.name) as resource_name,
'API' as resourceType,
ass.ref_type as refType,
max(p.id) as projectId ,

View File

@ -92,7 +92,7 @@ public class UserLocalConfigService {
public void update(UserLocalConfigUpdateRequest request) {
UserLocalConfig userLocalConfig = checkResourceById(request.getId());
userLocalConfig.setUserUrl(request.getUserUrl());
userLocalConfigMapper.updateByPrimaryKeySelective(userLocalConfig);
userLocalConfigMapper.updateByPrimaryKey(userLocalConfig);
LogDTO dto = LogDTOBuilder.builder()
.projectId(OperationLogConstants.SYSTEM)
.organizationId(OperationLogConstants.SYSTEM)

View File

@ -98,6 +98,7 @@
v-else-if="!requestVModel.executeLoading"
class="mr-[12px]"
type="primary"
:disabled="requestVModel.executeLoading || (isHttpProtocol && !requestVModel.url)"
@click="() => execute('serverExec')"
>
{{ t('apiTestDebug.serverExec') }}

View File

@ -94,10 +94,14 @@
value: `${key}-PENDING`,
label: t(`report.detail.pendingCount`),
},
{
value: `${key}-scriptIdentifier`,
label: t(`report.detail.api.scriptError`),
},
...(key === ScenarioStepType.API_SCENARIO
? []
: [
{
value: `${key}-scriptIdentifier`,
label: t(`report.detail.api.scriptError`),
},
]),
];
const cascaderOptions = ref<CascaderOption[]>([
{