diff --git a/frontend/src/business/components/api/definition/components/case/ApiCaseItem.vue b/frontend/src/business/components/api/definition/components/case/ApiCaseItem.vue
index 80690d7952..da4f783627 100644
--- a/frontend/src/business/components/api/definition/components/case/ApiCaseItem.vue
+++ b/frontend/src/business/components/api/definition/components/case/ApiCaseItem.vue
@@ -77,7 +77,7 @@
-
+
@@ -88,11 +88,14 @@
+ size="mini" :disabled="!apiCase.id || isCaseEdit || loaded" circle v-if="!loaded"/>
+
+
+
@@ -352,6 +355,7 @@ export default {
this.selectedEvent.currentTarget = $event.currentTarget;
$event.currentTarget.className = "el-card is-always-shadow is-selected";
this.currentApi.request = item.request;
+ this.currentApi.request.changeId = getUUID();
}
},
changePriority(row) {
diff --git a/frontend/src/business/components/api/definition/components/request/http/ApiHttpRequestForm.vue b/frontend/src/business/components/api/definition/components/request/http/ApiHttpRequestForm.vue
index c044dfedd5..cc0af27bde 100644
--- a/frontend/src/business/components/api/definition/components/request/http/ApiHttpRequestForm.vue
+++ b/frontend/src/business/components/api/definition/components/request/http/ApiHttpRequestForm.vue
@@ -187,6 +187,20 @@ export default {
}
this.init();
},
+ watch: {
+ 'request.changeId'() {
+ if (this.request.headers && this.request.headers.length > 1) {
+ this.activeName = 'headers';
+ }
+ if (this.request.rest && this.request.rest.length > 1) {
+ this.activeName = 'rest';
+ }
+ if (this.request.arguments && this.request.arguments.length > 1) {
+ this.activeName = 'parameters';
+ }
+ this.reload();
+ }
+ },
methods: {
hasPermission,
hasLicense,