fix(接口测试): 接口swagger通过url导入暂时隐藏digest认证方式问题

--user=郭雨琦
This commit is contained in:
guoyuqi 2022-10-14 19:12:53 +08:00 committed by f2c-ci-robot[bot]
parent 239c182d1c
commit f56681a788
2 changed files with 13 additions and 2 deletions

View File

@ -68,6 +68,10 @@ export default {
default: true,
},
isReadOnly: Boolean,
isSwagger:{
type: Boolean,
default: false,
}
},
watch: {
request() {
@ -75,11 +79,18 @@ export default {
}
},
created() {
if (this.isSwagger) {
this.options = this.swaggerOptions;
}else {
this.options = this.originalOptions;
}
this.initData();
},
data() {
return {
options: [{name: "No Auth"}, {name: "Basic Auth"}, {name: "Digest Auth"}],
originalOptions: [{name: "No Auth"}, {name: "Basic Auth"}, {name: "Digest Auth"}],
swaggerOptions:[{name: "No Auth"}, {name: "Basic Auth"}],
options: [],
encryptOptions: [{id: false, name: this.$t('commons.encrypted')}],
activeName: "verified",
rule: {},

View File

@ -97,7 +97,7 @@
<div style="margin-top: 10px">
<span>{{ $t('api_test.definition.request.auth_config') }}{{ $t('api_test.api_import.optional') }}</span>
</div>
<ms-api-auth-config :is-read-only="isReadOnly" :request="authConfig" :encryptShow="false" ref="importAuth"/>
<ms-api-auth-config :is-read-only="isReadOnly" :request="authConfig" :encryptShow="false" :is-swagger="true" ref="importAuth"/>
</el-col>
<el-col :span="12"