fix(接口测试): 修改文档分享协议为空警告
This commit is contained in:
parent
f05e536cb3
commit
d05ee1ef71
|
@ -68,7 +68,6 @@
|
||||||
import { ProtocolItem } from '@/models/apiTest/common';
|
import { ProtocolItem } from '@/models/apiTest/common';
|
||||||
import { ModuleTreeNode } from '@/models/common';
|
import { ModuleTreeNode } from '@/models/common';
|
||||||
import {
|
import {
|
||||||
ProtocolKeyEnum,
|
|
||||||
RequestAuthType,
|
RequestAuthType,
|
||||||
RequestComposition,
|
RequestComposition,
|
||||||
RequestDefinitionStatus,
|
RequestDefinitionStatus,
|
||||||
|
@ -95,14 +94,13 @@
|
||||||
(e: 'exportShare', all: boolean): void;
|
(e: 'exportShare', all: boolean): void;
|
||||||
}>();
|
}>();
|
||||||
|
|
||||||
const localProtocol = localStorage.getItem(ProtocolKeyEnum.API_NEW_PROTOCOL);
|
|
||||||
const initDefaultId = `definition-${Date.now()}`;
|
const initDefaultId = `definition-${Date.now()}`;
|
||||||
const defaultDefinitionParams: RequestParam = {
|
const defaultDefinitionParams: RequestParam = {
|
||||||
type: 'api',
|
type: 'api',
|
||||||
definitionActiveKey: 'definition',
|
definitionActiveKey: 'definition',
|
||||||
id: initDefaultId,
|
id: initDefaultId,
|
||||||
moduleId: '',
|
moduleId: '',
|
||||||
protocol: localProtocol || 'HTTP',
|
protocol: 'HTTP',
|
||||||
tags: [],
|
tags: [],
|
||||||
status: RequestDefinitionStatus.PROCESSING,
|
status: RequestDefinitionStatus.PROCESSING,
|
||||||
description: '',
|
description: '',
|
||||||
|
@ -226,6 +224,7 @@
|
||||||
() => props.apiInfo,
|
() => props.apiInfo,
|
||||||
(val) => {
|
(val) => {
|
||||||
if (val) {
|
if (val) {
|
||||||
|
activeApiDetail.value.protocol = val.attachInfo.protocol;
|
||||||
initDetail();
|
initDetail();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue