fix(接口自动化): 修复展开步骤时卡死问题

This commit is contained in:
fit2-zhao 2021-02-05 09:50:56 +08:00
parent 039898c635
commit d1a9332188
7 changed files with 19 additions and 6 deletions

View File

@ -107,7 +107,8 @@
},
methods: {
active() {
this.$set(this.data, 'active', !this.data.active);
//
//this.$set(this.data, 'active', !this.data.active);
this.$emit('active');
},
copyRow() {

View File

@ -3,6 +3,7 @@
v-loading="loading"
@copy="copyRow"
@remove="remove"
@active="active"
:is-show-name-input="!isDeletedOrRef"
:data="request"
:draggable="true"
@ -95,7 +96,6 @@
if (!this.request.requestResult) {
this.request.requestResult = {responseResult: {}};
}
console.log(this.request)
//
this.getApiInfo();
if (this.request.protocol === 'HTTP') {

View File

@ -3,6 +3,7 @@
v-loading="loading"
@copy="copyRow"
@remove="remove"
@active="active"
:data="scenario"
:show-collapse="false"
:is-show-name-input="!isDeletedOrRef"

View File

@ -2,6 +2,7 @@
<api-base-component
@copy="copyRow"
@remove="remove"
@active="active"
:data="jsr223Processor"
:draggable="draggable"
:color="color"
@ -57,6 +58,10 @@
copyRow() {
this.$emit('copyRow', this.jsr223Processor, this.node);
},
active() {
this.jsr223Processor.active = !this.jsr223Processor.active;
this.reload();
},
}
}
</script>

View File

@ -301,6 +301,7 @@
this.activeName = this.requestResult && this.requestResult.scenarios && this.requestResult.scenarios != null && this.requestResult.scenarios.length > 0 ? this.requestResult.scenarios[0].name : "";
//
this.setResult(this.controller.hashTree);
this.$emit('refReload');
} catch (e) {
throw e;
}

View File

@ -131,7 +131,7 @@
})
},
active() {
// item.active = !item.active;
this.assertions.active = !this.assertions.active;
this.reload();
},
remove() {

View File

@ -2,12 +2,13 @@
<api-base-component
@copy="copyRow"
@remove="remove"
@active="active"
:data="extract"
:draggable="draggable"
color="#015478"
background-color="#E6EEF2"
:title="$t('api_test.definition.request.extract_param')">
<div style="margin: 20px">
<div style="margin: 20px" v-loading="loading">
<div class="extract-description">
{{$t('api_test.request.extract.description')}}
</div>
@ -99,8 +100,8 @@
this.loading = false
})
},
active(item) {
item.active = !item.active;
active() {
this.extract.active = !this.extract.active;
this.reload();
},
suggestJsonOpen() {
@ -157,6 +158,10 @@
border-radius: 5px;
}
.icon.is-active {
transform: rotate(90deg);
}
/deep/ .el-card__body {
padding: 15px;
}