refactor: 合并分支 feature_1000439 解决冲突
合并分支 feature_1000439 解决冲突
This commit is contained in:
parent
1909c4267f
commit
a70b8b31ab
|
@ -387,7 +387,7 @@ public class APITestController {
|
|||
HashTree hashTree = runRequest.getTestElement().generateHashTree();
|
||||
String jmxString = runRequest.getTestElement().getJmx(hashTree);
|
||||
JmxInfoDTO dto = new JmxInfoDTO();
|
||||
dto.setName(runRequest.getName()+".JMX");
|
||||
dto.setName(runRequest.getName()+".jmx");
|
||||
dto.setXml(jmxString);
|
||||
return dto;
|
||||
}
|
||||
|
|
|
@ -610,7 +610,7 @@ public class ApiAutomationService {
|
|||
|
||||
testPlan.toHashTree(jmeterHashTree, testPlan.getHashTree(), new ParameterConfig());
|
||||
String jmx = testPlan.getJmx(jmeterHashTree);
|
||||
String name = request.getName() + ".JMX";
|
||||
String name = request.getName() + ".jmx";
|
||||
|
||||
JmxInfoDTO dto = new JmxInfoDTO();
|
||||
dto.setName(name);
|
||||
|
|
|
@ -4,7 +4,8 @@
|
|||
:is-api-list-enable="isApiListEnable"
|
||||
@isApiListEnableChange="isApiListEnableChange">
|
||||
|
||||
<el-input placeholder="搜索" @blur="search" @keyup.enter.native="search" class="search-input" size="small" v-model="condition.name"/>
|
||||
<el-input placeholder="搜索" @blur="search" @keyup.enter.native="search" class="search-input" size="small"
|
||||
v-model="condition.name"/>
|
||||
|
||||
<el-table v-loading="result.loading"
|
||||
ref="caseTable"
|
||||
|
@ -22,10 +23,10 @@
|
|||
</span>
|
||||
<el-dropdown-menu slot="dropdown">
|
||||
<el-dropdown-item @click.native.stop="isSelectDataAll(true)">
|
||||
{{$t('api_test.batch_menus.select_all_data',[total])}}
|
||||
{{ $t('api_test.batch_menus.select_all_data', [total]) }}
|
||||
</el-dropdown-item>
|
||||
<el-dropdown-item @click.native.stop="isSelectDataAll(false)">
|
||||
{{$t('api_test.batch_menus.select_show_data',[tableData.length])}}
|
||||
{{ $t('api_test.batch_menus.select_show_data', [tableData.length]) }}
|
||||
</el-dropdown-item>
|
||||
</el-dropdown-menu>
|
||||
</el-dropdown>
|
||||
|
@ -72,8 +73,12 @@
|
|||
<el-table-column v-if="!isReadOnly" :label="$t('commons.operating')" min-width="130" align="center">
|
||||
<template v-slot:default="scope">
|
||||
<!--<el-button type="text" @click="reductionApi(scope.row)" v-if="trashEnable">{{$t('commons.reduction')}}</el-button>-->
|
||||
<el-button type="text" @click="handleTestCase(scope.row)" v-if="!trashEnable">{{$t('commons.edit')}}</el-button>
|
||||
<el-button type="text" @click="handleDelete(scope.row)" style="color: #F56C6C">{{$t('commons.delete')}}</el-button>
|
||||
<el-button type="text" @click="handleTestCase(scope.row)" v-if="!trashEnable">{{ $t('commons.edit') }}
|
||||
</el-button>
|
||||
<el-button type="text" @click="handleDelete(scope.row)" style="color: #F56C6C">{{ $t('commons.delete') }}
|
||||
</el-button>
|
||||
<ms-api-case-table-extend-btns @showCaseRef="showCaseRef" @showEnvironment="showEnvironment" @createPerformance="createPerformance" :row="scope.row" v-tester/>
|
||||
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
|
@ -95,33 +100,34 @@
|
|||
|
||||
<script>
|
||||
|
||||
import MsTableOperator from "../../../../common/components/MsTableOperator";
|
||||
import MsTableOperatorButton from "../../../../common/components/MsTableOperatorButton";
|
||||
import {LIST_CHANGE, TrackEvent} from "@/business/components/common/head/ListEvent";
|
||||
import MsTablePagination from "../../../../common/pagination/TablePagination";
|
||||
import MsTag from "../../../../common/components/MsTag";
|
||||
import MsApiCaseList from "../case/ApiCaseList";
|
||||
import MsContainer from "../../../../common/components/MsContainer";
|
||||
import MsBottomContainer from "../BottomContainer";
|
||||
import ShowMoreBtn from "../../../../track/case/components/ShowMoreBtn";
|
||||
import MsBatchEdit from "../basis/BatchEdit";
|
||||
import {API_METHOD_COLOUR, CASE_PRIORITY} from "../../model/JsonData";
|
||||
import {getCurrentProjectID} from "@/common/js/utils";
|
||||
import ApiListContainer from "./ApiListContainer";
|
||||
import PriorityTableItem from "../../../../track/common/tableItems/planview/PriorityTableItem";
|
||||
import ApiCaseList from "../case/ApiCaseList";
|
||||
import {_filter, _sort} from "../../../../../../common/js/utils";
|
||||
import TestPlanCaseListHeader from "../../../../track/plan/view/comonents/api/TestPlanCaseListHeader";
|
||||
import MsEnvironmentSelect from "../case/MsEnvironmentSelect";
|
||||
import {_handleSelect, _handleSelectAll} from "../../../../../../common/js/tableUtils";
|
||||
import MsApiCaseTableExtendBtns from "../reference/ApiCaseTableExtendBtns";
|
||||
import MsReferenceView from "../reference/ReferenceView";
|
||||
import MsSetEnvironment from "@/business/components/api/definition/components/basis/SetEnvironment";
|
||||
import TestPlan from "@/business/components/api/definition/components/jmeter/components/test-plan";
|
||||
import ThreadGroup from "@/business/components/api/definition/components/jmeter/components/thread-group";
|
||||
import {parseEnvironment} from "@/business/components/api/test/model/EnvironmentModel";
|
||||
import MsTableOperator from "../../../../common/components/MsTableOperator";
|
||||
import MsTableOperatorButton from "../../../../common/components/MsTableOperatorButton";
|
||||
import {LIST_CHANGE, TrackEvent} from "@/business/components/common/head/ListEvent";
|
||||
import MsTablePagination from "../../../../common/pagination/TablePagination";
|
||||
import MsTag from "../../../../common/components/MsTag";
|
||||
import MsApiCaseList from "../case/ApiCaseList";
|
||||
import MsContainer from "../../../../common/components/MsContainer";
|
||||
import MsBottomContainer from "../BottomContainer";
|
||||
import ShowMoreBtn from "../../../../track/case/components/ShowMoreBtn";
|
||||
import MsBatchEdit from "../basis/BatchEdit";
|
||||
import {API_METHOD_COLOUR, CASE_PRIORITY, REQ_METHOD} from "../../model/JsonData";
|
||||
|
||||
export default {
|
||||
import {getBodyUploadFiles,getCurrentProjectID} from "@/common/js/utils";
|
||||
import ApiListContainer from "./ApiListContainer";
|
||||
import PriorityTableItem from "../../../../track/common/tableItems/planview/PriorityTableItem";
|
||||
import ApiCaseList from "../case/ApiCaseList";
|
||||
import {_filter, _sort} from "../../../../../../common/js/utils";
|
||||
import TestPlanCaseListHeader from "../../../../track/plan/view/comonents/api/TestPlanCaseListHeader";
|
||||
import MsEnvironmentSelect from "../case/MsEnvironmentSelect";
|
||||
import {_handleSelect, _handleSelectAll} from "../../../../../../common/js/tableUtils";
|
||||
import MsApiCaseTableExtendBtns from "../reference/ApiCaseTableExtendBtns";
|
||||
import MsReferenceView from "../reference/ReferenceView";
|
||||
import MsSetEnvironment from "@/business/components/api/definition/components/basis/SetEnvironment";
|
||||
import TestPlan from "@/business/components/api/definition/components/jmeter/components/test-plan";
|
||||
import ThreadGroup from "@/business/components/api/definition/components/jmeter/components/thread-group";
|
||||
import {parseEnvironment} from "@/business/components/api/test/model/EnvironmentModel";
|
||||
|
||||
export default {
|
||||
name: "ApiCaseSimpleList",
|
||||
components: {
|
||||
MsSetEnvironment,
|
||||
|
@ -479,8 +485,7 @@
|
|||
this.clickRow = row;
|
||||
this.$refs.setEnvironment.open(row);
|
||||
},
|
||||
},
|
||||
createPerformance(row,environment){
|
||||
createPerformance(row, environment) {
|
||||
/**
|
||||
* 思路:调用后台创建性能测试的方法,把当前案例的hashTree在后台转化为jmx并文件创建性能测试。
|
||||
* 然后跳转到修改性能测试的页面
|
||||
|
@ -494,7 +499,7 @@
|
|||
}
|
||||
let runData = [];
|
||||
let singleLoading = true;
|
||||
row.request = JSON.parse( row.request );
|
||||
row.request = JSON.parse(row.request);
|
||||
row.request.name = row.id;
|
||||
row.request.useEnvironment = environment.id;
|
||||
runData.push(row.request);
|
||||
|
@ -506,10 +511,11 @@
|
|||
runData.forEach(item => {
|
||||
threadGroup.hashTree.push(item);
|
||||
})
|
||||
let reqObj = {id: row.id,
|
||||
let reqObj = {
|
||||
id: row.id,
|
||||
testElement: testPlan,
|
||||
name:row.name,
|
||||
projectId:getCurrentProjectID(),
|
||||
name: row.name,
|
||||
projectId: getCurrentProjectID(),
|
||||
};
|
||||
let bodyFiles = getBodyUploadFiles(reqObj, runData);
|
||||
reqObj.reportId = "run";
|
||||
|
@ -536,32 +542,31 @@
|
|||
}, erro => {
|
||||
this.$emit('runRefresh', {});
|
||||
});
|
||||
|
||||
},
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.operate-button > div {
|
||||
.operate-button > div {
|
||||
display: inline-block;
|
||||
margin-left: 10px;
|
||||
}
|
||||
}
|
||||
|
||||
.request-method {
|
||||
.request-method {
|
||||
padding: 0 5px;
|
||||
color: #1E90FF;
|
||||
}
|
||||
}
|
||||
|
||||
.api-el-tag {
|
||||
.api-el-tag {
|
||||
color: white;
|
||||
}
|
||||
}
|
||||
|
||||
.search-input {
|
||||
.search-input {
|
||||
float: right;
|
||||
width: 300px;
|
||||
/*margin-bottom: 20px;*/
|
||||
margin-right: 20px;
|
||||
}
|
||||
}
|
||||
|
||||
</style>
|
||||
|
|
Loading…
Reference in New Issue