fix(接口自动化): 修复引用状态问题

This commit is contained in:
fit2-zhao 2020-12-24 18:51:52 +08:00
parent 2ec31650d0
commit f9d3e9be95
1 changed files with 2 additions and 0 deletions

View File

@ -127,10 +127,12 @@
if (this.request.id && this.request.referenced === 'REF') {
let requestResult = this.request.requestResult;
let url = this.request.refType && this.request.refType === 'CASE' ? "/api/testcase/get/" : "/api/definition/get/";
let enable = this.request.enable;
this.$get(url + this.request.id, response => {
if (response.data) {
Object.assign(this.request, JSON.parse(response.data.request));
this.request.name = response.data.name;
this.request.enable = enable;
if (response.data.path && response.data.path != null) {
this.request.path = response.data.path;
this.request.url = response.data.path;