fix(全局): 部分 bug 修复
This commit is contained in:
parent
2e8e11e13a
commit
2d51739c1c
|
@ -392,7 +392,7 @@
|
|||
// 如果模块下没有用例且有别的模块节点,正常展开
|
||||
node.expand();
|
||||
node.renderTree();
|
||||
window.minder.layout();
|
||||
node.layout();
|
||||
return;
|
||||
}
|
||||
// TODO:递归渲染存在的子节点
|
||||
|
@ -440,7 +440,7 @@
|
|||
node.expand();
|
||||
// node.renderTree();
|
||||
window.minder.renderNodeBatch(waitingRenderNodes);
|
||||
window.minder.layout();
|
||||
node.layout();
|
||||
window.minder.execCommand('camera', node, 100);
|
||||
if (node.data) {
|
||||
node.data.isLoaded = true;
|
||||
|
@ -458,10 +458,10 @@
|
|||
extraVisible.value = false;
|
||||
showDetailMenu.value = false;
|
||||
resetExtractInfo();
|
||||
if (node.children && node.children.length > 0) {
|
||||
if (node.children && node.children.length > 0 && node.data?.expandState === 'collapse') {
|
||||
node.expand();
|
||||
node.renderTree();
|
||||
window.minder.layout();
|
||||
node.layout();
|
||||
}
|
||||
}
|
||||
setPriorityView(true, 'P');
|
||||
|
|
|
@ -460,8 +460,11 @@
|
|||
[RunMode.PARALLEL]: 3,
|
||||
};
|
||||
|
||||
function getExecuteMethod(priority: number) {
|
||||
return priority === 2 ? RunMode.SERIAL : RunMode.PARALLEL;
|
||||
function getExecuteMethod(data: MinderJsonNodeData) {
|
||||
if (activePlanSet.value?.data.id === data.id) {
|
||||
return activePlanSet.value?.data.executeMethod;
|
||||
}
|
||||
return data.priority === 2 ? RunMode.SERIAL : RunMode.PARALLEL;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -740,13 +743,13 @@
|
|||
...node.data,
|
||||
id: undefined,
|
||||
num: nodeIndex,
|
||||
executeMethod: getExecuteMethod(node.data.priority),
|
||||
executeMethod: getExecuteMethod(node.data),
|
||||
});
|
||||
} else {
|
||||
tempMinderParams.value.editList.push({
|
||||
...node.data,
|
||||
num: nodeIndex,
|
||||
executeMethod: getExecuteMethod(node.data.priority),
|
||||
executeMethod: getExecuteMethod(node.data),
|
||||
});
|
||||
}
|
||||
return node.data.level < 2;
|
||||
|
|
|
@ -63,12 +63,7 @@
|
|||
<template #tag>
|
||||
<div v-for="org of orgList" :key="org.orgId" class="mb-[16px]">
|
||||
<MsTag class="h-[26px]" max-width="100%">
|
||||
<a-tooltip :content="org.orgName" position="left">
|
||||
<template #content>
|
||||
<span>{{ org.orgName }}</span>
|
||||
</template>
|
||||
<span>{{ org.orgName }}</span>
|
||||
</a-tooltip>
|
||||
<span>{{ org.orgName }}</span>
|
||||
</MsTag>
|
||||
<br />
|
||||
<MsTag
|
||||
|
@ -77,12 +72,7 @@
|
|||
class="!mr-[8px] mt-[8px] !bg-[rgb(var(--primary-1))] !text-[rgb(var(--primary-5))]"
|
||||
max-width="100%"
|
||||
>
|
||||
<a-tooltip :content="project.projectName" position="left">
|
||||
<template #content>
|
||||
<span>{{ project.projectName }}</span>
|
||||
</template>
|
||||
<span>{{ project.projectName }}</span>
|
||||
</a-tooltip>
|
||||
<span>{{ project.projectName }}</span>
|
||||
</MsTag>
|
||||
</div>
|
||||
</template>
|
||||
|
|
|
@ -151,7 +151,7 @@
|
|||
}
|
||||
);
|
||||
|
||||
const _specialHeight = props.hasBreadcrumb ? 32 + props.specialHeight : props.specialHeight; // 有面包屑的话,默认面包屑高度32
|
||||
const _specialHeight = props.hasBreadcrumb ? 32 + props.specialHeight : props.specialHeight; // 有面包屑的话,默认面包屑高度24+8间距
|
||||
|
||||
// TODO:卡片高度调整,写上数值的注释
|
||||
const cardOverHeight = computed(() => {
|
||||
|
@ -169,9 +169,9 @@
|
|||
}
|
||||
if (props.hideFooter) {
|
||||
// 没有底部
|
||||
return props.noContentPadding ? 120 + _specialHeight : 168 + _specialHeight;
|
||||
return props.noContentPadding ? 130 + _specialHeight : 168 + _specialHeight;
|
||||
}
|
||||
return 230 + _specialHeight;
|
||||
return 220 + _specialHeight;
|
||||
});
|
||||
|
||||
const getComputedContentStyle = computed(() => {
|
||||
|
|
|
@ -38,7 +38,10 @@
|
|||
{{ tag }}
|
||||
</MsTag>
|
||||
<template #overflow="{ number }">
|
||||
<a-tooltip :content="(Array.isArray(item.value) ? item.value : [item.value]).join(',')">
|
||||
<a-tooltip
|
||||
:content="(Array.isArray(item.value) ? item.value : [item.value]).join(',')"
|
||||
position="tl"
|
||||
>
|
||||
<MsTag
|
||||
:theme="item.tagTheme || 'outline'"
|
||||
:type="item.tagType || 'primary'"
|
||||
|
@ -98,6 +101,7 @@
|
|||
<a-tooltip
|
||||
:content="`${item.value}`"
|
||||
:disabled="item.value === undefined || item.value === null || item.value?.toString() === ''"
|
||||
position="tl"
|
||||
>
|
||||
<div>
|
||||
{{
|
||||
|
|
|
@ -325,7 +325,7 @@
|
|||
});
|
||||
}
|
||||
|
||||
const shortcutTriggerVisible = ref(false);
|
||||
// const shortcutTriggerVisible = ref(false);
|
||||
|
||||
onMounted(() => {
|
||||
nextTick(() => {
|
||||
|
|
|
@ -99,7 +99,7 @@
|
|||
if (val && node) {
|
||||
setTimeout(() => {
|
||||
window.minder.execCommand('camera', node, 100);
|
||||
}, 0);
|
||||
}, 100);
|
||||
}
|
||||
}
|
||||
);
|
||||
|
|
|
@ -854,6 +854,7 @@
|
|||
requestVModel.value.method = RequestMethods.GET;
|
||||
}
|
||||
}
|
||||
localStorage.setItem('currentProtocol', requestVModel.value.protocol);
|
||||
handleActiveDebugChange();
|
||||
}
|
||||
|
||||
|
|
|
@ -155,11 +155,12 @@
|
|||
}
|
||||
|
||||
const initDefaultId = `debug-${Date.now()}`;
|
||||
const localProtocol = localStorage.getItem('currentProtocol');
|
||||
const defaultDebugParams: RequestParam = {
|
||||
type: 'api',
|
||||
id: initDefaultId,
|
||||
moduleId: 'root',
|
||||
protocol: 'HTTP',
|
||||
protocol: localProtocol || 'HTTP',
|
||||
url: '',
|
||||
activeTab: RequestComposition.HEADER,
|
||||
label: t('apiTestDebug.newApi'),
|
||||
|
@ -229,11 +230,12 @@
|
|||
|
||||
function addDebugTab(defaultProps?: Partial<TabItem>) {
|
||||
const id = `debug-${Date.now()}`;
|
||||
const protocol = localStorage.getItem('currentProtocol');
|
||||
debugTabs.value.push({
|
||||
...cloneDeep(defaultDebugParams),
|
||||
id,
|
||||
isNew: !defaultProps?.id, // 新开的tab标记为前端新增的调试,因为此时都已经有id了;但是如果是查看打开的会有携带id
|
||||
protocol: activeDebug.value.protocol || defaultDebugParams.protocol, // 新开的tab默认使用当前激活的tab的协议
|
||||
protocol: protocol || activeDebug.value.protocol || defaultDebugParams.protocol, // 新开的tab默认使用当前激活的tab的协议
|
||||
...defaultProps,
|
||||
});
|
||||
activeDebug.value = debugTabs.value[debugTabs.value.length - 1];
|
||||
|
|
|
@ -226,12 +226,13 @@
|
|||
});
|
||||
|
||||
const initDefaultId = `definition-${Date.now()}`;
|
||||
const localProtocol = localStorage.getItem('currentProtocol');
|
||||
const defaultDefinitionParams: RequestParam = {
|
||||
type: 'api',
|
||||
definitionActiveKey: 'definition',
|
||||
id: initDefaultId,
|
||||
moduleId: props.activeModule === 'all' ? 'root' : props.activeModule,
|
||||
protocol: 'HTTP',
|
||||
protocol: localProtocol || 'HTTP',
|
||||
tags: [],
|
||||
status: RequestDefinitionStatus.PROCESSING,
|
||||
description: '',
|
||||
|
@ -299,6 +300,7 @@
|
|||
|
||||
function addApiTab(defaultProps?: Partial<TabItem>) {
|
||||
const id = `definition-${Date.now()}`;
|
||||
const protocol = localStorage.getItem('currentProtocol');
|
||||
apiTabs.value.push({
|
||||
...cloneDeep(defaultDefinitionParams),
|
||||
moduleId: props.activeModule === 'all' ? 'root' : props.activeModule,
|
||||
|
@ -306,7 +308,7 @@
|
|||
id,
|
||||
isNew: !defaultProps?.id, // 新开的tab标记为前端新增的调试,因为此时都已经有id了;但是如果是查看打开的会有携带id
|
||||
definitionActiveKey: !defaultProps ? 'definition' : 'preview',
|
||||
protocol: activeApiTab.value.protocol || defaultDefinitionParams.protocol, // 新开的tab默认使用当前激活的tab的协议
|
||||
protocol: protocol || activeApiTab.value.protocol || defaultDefinitionParams.protocol, // 新开的tab默认使用当前激活的tab的协议
|
||||
...defaultProps,
|
||||
});
|
||||
activeApiTab.value = apiTabs.value[apiTabs.value.length - 1];
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
class="scenario-csv-trigger"
|
||||
:popup-translate="[-2, 244]"
|
||||
>
|
||||
<MsButton type="text" class="!mr-0" @click="handleRecordConfig(record)">
|
||||
<MsButton type="text" class="!mr-0" size="mini" @click="handleRecordConfig(record)">
|
||||
{{ t('apiScenario.params.config') }}
|
||||
</MsButton>
|
||||
<template #content>
|
||||
|
|
|
@ -618,8 +618,8 @@
|
|||
.case-item--active {
|
||||
@apply relative;
|
||||
|
||||
border: 1px solid rgb(var(--primary-5));
|
||||
background-color: rgb(var(--primary-1));
|
||||
box-shadow: inset 0 0 0.5px 0.5px rgb(var(--primary-5));
|
||||
}
|
||||
}
|
||||
.case-detail-label {
|
||||
|
|
Loading…
Reference in New Issue