fix(接口测试): 请求体取消自动格式化
This commit is contained in:
parent
8e4ada8e18
commit
d02f530538
|
@ -1 +1 @@
|
||||||
Subproject commit 419c75bca64b7c5bfbd1194d7f0fd9919f0caa04
|
Subproject commit 57d6f78efa4b0300be188e8b024511ceef0873ed
|
|
@ -20,7 +20,7 @@
|
||||||
:description="$t('api_test.request.parameters_desc')"
|
:description="$t('api_test.request.parameters_desc')"
|
||||||
v-if="body.isKV()"/>
|
v-if="body.isKV()"/>
|
||||||
<div class="body-raw" v-if="body.type == 'Raw'">
|
<div class="body-raw" v-if="body.type == 'Raw'">
|
||||||
<ms-code-edit :mode="body.format" :read-only="isReadOnly" :data.sync="body.raw" :modes="modes" ref="codeEdit"/>
|
<ms-code-edit :mode="body.format" :enable-format="false" :read-only="isReadOnly" :data.sync="body.raw" :modes="modes" ref="codeEdit"/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -28,6 +28,12 @@
|
||||||
init: {
|
init: {
|
||||||
type: Function
|
type: Function
|
||||||
},
|
},
|
||||||
|
enableFormat: {
|
||||||
|
type: Boolean,
|
||||||
|
default() {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
},
|
||||||
readOnly: {
|
readOnly: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default() {
|
default() {
|
||||||
|
@ -74,6 +80,7 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
format() {
|
format() {
|
||||||
|
if (this.enableFormat) {
|
||||||
switch (this.mode) {
|
switch (this.mode) {
|
||||||
case 'json':
|
case 'json':
|
||||||
this.formatData = formatJson(this.data);
|
this.formatData = formatJson(this.data);
|
||||||
|
@ -89,6 +96,9 @@
|
||||||
this.formatData = this.data;
|
this.formatData = this.data;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
this.formatData = this.data;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit 33bbdb3f528c914bf333b2c1839dd6d3bbd9b569
|
Subproject commit 71d57ae5d7f8bb5c93a29504ac6f2300dc189ce9
|
Loading…
Reference in New Issue