fix(接口测试): 大数据量时的接口列表虚拟滚动高度计算调优
--bug=1027497 --user=白奇 【接口测试】 github#25304在使用平台做测试时chrome经常出现崩溃问题 https://www.tapd.cn/55049933/s/1389144
This commit is contained in:
parent
627b884d8c
commit
ae0d601c53
|
@ -17,7 +17,7 @@
|
|||
"@fortawesome/free-regular-svg-icons": "^5.12.0",
|
||||
"@fortawesome/free-solid-svg-icons": "^5.12.0",
|
||||
"@fortawesome/vue-fontawesome": "^0.1.9",
|
||||
"@ba1q1/vue-easy-tree": "^1.0.4",
|
||||
"@ba1q1/vue-easy-tree": "^1.1.0",
|
||||
"axios": "^0.27.2",
|
||||
"diffable-html": "^4.0.0",
|
||||
"echarts": "^5.0.2",
|
||||
|
|
|
@ -141,8 +141,7 @@
|
|||
@saveRefresh="setDomain"
|
||||
:has-option-group="true"
|
||||
ref="envPopover"
|
||||
class="ml-10"
|
||||
/>
|
||||
class="ml-10" />
|
||||
|
||||
<el-tooltip class="mt-2 ml-10" v-if="!debugLoading" content="Ctrl + R" placement="top">
|
||||
<el-dropdown
|
||||
|
@ -271,15 +270,15 @@
|
|||
</el-row>
|
||||
<el-row>
|
||||
<!-- 场景步骤内容 -->
|
||||
<div ref="stepInfo" style="height: calc(100vh - 170px);">
|
||||
<div ref="stepInfo" style="height: calc(100vh - 170px)">
|
||||
<vue-easy-tree
|
||||
node-key="resourceId"
|
||||
node-key="id"
|
||||
height="calc(100vh - 170px)"
|
||||
:minItemSize="43"
|
||||
:sizeDependencies="['expanded']"
|
||||
:props="props"
|
||||
:data="scenarioDefinition"
|
||||
:buffer="200"
|
||||
:buffer="300"
|
||||
class="ms-tree"
|
||||
:expand-on-click-node="false"
|
||||
:allow-drop="allowDrop"
|
||||
|
@ -325,7 +324,14 @@
|
|||
:show-size="false"
|
||||
style="margin-right: 10px" />
|
||||
</span>
|
||||
<span style="width: calc(100% - 40px)">
|
||||
<span
|
||||
v-if="
|
||||
stepFilter.get('ALlSamplerStep').indexOf(data.type) === -1 ||
|
||||
!node.parent ||
|
||||
!node.parent.data ||
|
||||
stepFilter.get('AllSamplerProxy').indexOf(node.parent.data.type) === -1
|
||||
"
|
||||
style="width: calc(100% - 40px)">
|
||||
<!-- 步骤组件-->
|
||||
<ms-component-config
|
||||
:scenario-definition="scenarioDefinition"
|
||||
|
@ -348,25 +354,14 @@
|
|||
@setDomain="setDomain"
|
||||
@openScenario="openScenario"
|
||||
@editScenarioAdvance="editScenarioAdvance"
|
||||
ref="componentConfig"
|
||||
v-if="
|
||||
stepFilter.get('ALlSamplerStep').indexOf(data.type) === -1 ||
|
||||
!node.parent ||
|
||||
!node.parent.data ||
|
||||
stepFilter.get('AllSamplerProxy').indexOf(node.parent.data.type) === -1
|
||||
" />
|
||||
<div v-else class="el-tree-node is-hidden is-focusable is-leaf" style="display: none">
|
||||
{{ hideNode(node) }}
|
||||
</div>
|
||||
ref="componentConfig" />
|
||||
</span>
|
||||
</el-row>
|
||||
</vue-easy-tree>
|
||||
</div>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="21">
|
||||
|
||||
</el-col>
|
||||
<el-col :span="21"> </el-col>
|
||||
<!-- 按钮列表 -->
|
||||
<el-col :span="3">
|
||||
<div
|
||||
|
@ -1182,8 +1177,11 @@ export default {
|
|||
},
|
||||
margeTransaction(item, console, arr) {
|
||||
arr.forEach((sub) => {
|
||||
if (item.data && item.data.id + '_' + item.data.parentIndex === sub.resourceId
|
||||
&& item.data.requestResult.length === 0) {
|
||||
if (
|
||||
item.data &&
|
||||
item.data.id + '_' + item.data.parentIndex === sub.resourceId &&
|
||||
item.data.requestResult.length === 0
|
||||
) {
|
||||
sub.responseResult.console = console;
|
||||
item.data.requestResult.push(sub);
|
||||
// 更新父节点状态
|
||||
|
@ -1767,7 +1765,7 @@ export default {
|
|||
this.clearResult(this.scenarioDefinition);
|
||||
this.clearNodeStatus(this.$refs.stepTree.root.childNodes);
|
||||
runScenario.run = false;
|
||||
this.message = "STOP";
|
||||
this.message = 'STOP';
|
||||
return;
|
||||
}
|
||||
let hasRequest = runScenario && runScenario.hasRequest;
|
||||
|
|
Loading…
Reference in New Issue