feat(接口测试): 场景步骤重构优化
This commit is contained in:
parent
a1f3cc8701
commit
777e62dbb8
|
@ -19,7 +19,6 @@
|
||||||
"@fortawesome/vue-fontawesome": "^0.1.9",
|
"@fortawesome/vue-fontawesome": "^0.1.9",
|
||||||
"axios": "^0.21.3",
|
"axios": "^0.21.3",
|
||||||
"core-js": "^3.4.3",
|
"core-js": "^3.4.3",
|
||||||
"default-passive-events": "^2.0.0",
|
|
||||||
"diffable-html": "^4.0.0",
|
"diffable-html": "^4.0.0",
|
||||||
"echarts": "^5.0.2",
|
"echarts": "^5.0.2",
|
||||||
"el-table-infinite-scroll": "^1.0.10",
|
"el-table-infinite-scroll": "^1.0.10",
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<template>
|
<template>
|
||||||
<ms-container v-if="renderComponent" v-loading="loading">
|
<ms-container v-if="renderComponent" v-loading="loading">
|
||||||
<ms-aside-container>
|
<ms-aside-container v-show="isAsideHidden">
|
||||||
<ms-api-scenario-module
|
<ms-api-scenario-module
|
||||||
:show-operator="true"
|
:show-operator="true"
|
||||||
@nodeSelectEvent="nodeChange"
|
@nodeSelectEvent="nodeChange"
|
||||||
|
@ -162,7 +162,8 @@ export default {
|
||||||
//影响API表格刷新的操作。 为了防止高频率刷新模块列表用。如果是模块更新而造成的表格刷新,则不回调模块刷新方法
|
//影响API表格刷新的操作。 为了防止高频率刷新模块列表用。如果是模块更新而造成的表格刷新,则不回调模块刷新方法
|
||||||
initApiTableOpretion: 'init',
|
initApiTableOpretion: 'init',
|
||||||
isLeave: false,
|
isLeave: false,
|
||||||
isSave: false
|
isSave: false,
|
||||||
|
isAsideHidden: true,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
@ -201,6 +202,7 @@ export default {
|
||||||
this.activeName = "default";
|
this.activeName = "default";
|
||||||
},
|
},
|
||||||
activeName() {
|
activeName() {
|
||||||
|
this.isAsideHidden = this.activeName === 'default';
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
@ -502,7 +504,9 @@ export default {
|
||||||
this.$refs.nodeTree.list();
|
this.$refs.nodeTree.list();
|
||||||
},
|
},
|
||||||
refreshTree() {
|
refreshTree() {
|
||||||
|
if (this.$refs.nodeTree) {
|
||||||
this.$refs.nodeTree.list();
|
this.$refs.nodeTree.list();
|
||||||
|
}
|
||||||
},
|
},
|
||||||
refreshAll() {
|
refreshAll() {
|
||||||
this.$refs.nodeTree.list();
|
this.$refs.nodeTree.list();
|
||||||
|
|
|
@ -1,54 +1,26 @@
|
||||||
<template>
|
<template>
|
||||||
<el-card>
|
<ms-container>
|
||||||
<div class="card-content">
|
<ms-aside-container>
|
||||||
<div class="ms-main-div" @click="showAll" v-if="type!=='detail'">
|
<div @click="showAll">
|
||||||
|
|
||||||
<!--操作按钮-->
|
|
||||||
<div class="ms-opt-btn">
|
|
||||||
<el-tooltip :content="$t('commons.follow')" placement="bottom" effect="dark" v-if="!showFollow">
|
|
||||||
<i class="el-icon-star-off" style="color: #783987; font-size: 25px; margin-right: 5px;cursor: pointer;position: relative; top: 5px; " @click="saveFollow"/>
|
|
||||||
</el-tooltip>
|
|
||||||
<el-tooltip :content="$t('commons.cancel')" placement="bottom" effect="dark" v-if="showFollow">
|
|
||||||
<i class="el-icon-star-on" style="color: #783987; font-size: 28px; margin-right: 5px;cursor: pointer;position: relative; top: 5px; " @click="saveFollow"/>
|
|
||||||
</el-tooltip>
|
|
||||||
<el-link type="primary" style="margin-right: 5px" @click="openHis" v-if="path === '/api/automation/update'">{{ $t('operating_log.change_history') }}</el-link>
|
|
||||||
<!-- 版本历史 -->
|
|
||||||
<ms-version-history v-xpack
|
|
||||||
ref="versionHistory"
|
|
||||||
:version-data="versionData"
|
|
||||||
:current-id="currentScenario.id"
|
|
||||||
@compare="compare" @checkout="checkout" @create="create" @del="del"/>
|
|
||||||
<el-button id="inputDelay" type="primary" size="small" v-prevent-re-click @click="editScenario"
|
|
||||||
title="ctrl + s" v-permission="['PROJECT_API_SCENARIO:READ+EDIT', 'PROJECT_API_SCENARIO:READ+CREATE', 'PROJECT_API_SCENARIO:READ+COPY']">
|
|
||||||
{{ $t('commons.save') }}
|
|
||||||
</el-button>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="tip">{{ $t('test_track.plan_view.base_info') }}</div>
|
<div class="tip">{{ $t('test_track.plan_view.base_info') }}</div>
|
||||||
<el-form :model="currentScenario" label-position="right" label-width="80px" size="small" :rules="rules"
|
<el-form :model="currentScenario" label-position="right" label-width="80px" size="small" :rules="rules"
|
||||||
ref="currentScenario" style="margin-right: 20px">
|
ref="currentScenario">
|
||||||
<!-- 基础信息 -->
|
<!-- 基础信息 -->
|
||||||
<el-row>
|
|
||||||
<el-col :span="7">
|
|
||||||
<el-form-item :label="$t('commons.name')" prop="name">
|
<el-form-item :label="$t('commons.name')" prop="name">
|
||||||
<el-input class="ms-scenario-input" size="small" v-model="currentScenario.name"/>
|
<el-input class="ms-scenario-input" size="small" v-model="currentScenario.name"/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
|
||||||
<el-col :span="7">
|
|
||||||
<el-form-item :label="$t('test_track.module.module')" prop="apiScenarioModuleId">
|
<el-form-item :label="$t('test_track.module.module')" prop="apiScenarioModuleId">
|
||||||
<ms-select-tree size="small" :data="moduleOptions" :defaultKey="currentScenario.apiScenarioModuleId" @getValue="setModule" :obj="moduleObj" clearable checkStrictly/>
|
<ms-select-tree size="small" :data="moduleOptions" :defaultKey="currentScenario.apiScenarioModuleId" @getValue="setModule" :obj="moduleObj" clearable checkStrictly/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
|
||||||
<el-col :span="7">
|
|
||||||
<el-form-item :label="$t('commons.status')" prop="status">
|
<el-form-item :label="$t('commons.status')" prop="status">
|
||||||
<el-select class="ms-scenario-input" size="small" v-model="currentScenario.status">
|
<el-select class="ms-scenario-input" size="small" v-model="currentScenario.status">
|
||||||
<el-option v-for="item in options" :key="item.id" :label="$t(item.label)" :value="item.id"/>
|
<el-option v-for="item in options" :key="item.id" :label="$t(item.label)" :value="item.id"/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
<el-row>
|
|
||||||
<el-col :span="7">
|
|
||||||
<el-form-item :label="$t('api_test.definition.request.responsible')" prop="principal">
|
<el-form-item :label="$t('api_test.definition.request.responsible')" prop="principal">
|
||||||
<el-select v-model="currentScenario.principal"
|
<el-select v-model="currentScenario.principal"
|
||||||
:placeholder="$t('api_test.definition.request.responsible')" filterable size="small"
|
:placeholder="$t('api_test.definition.request.responsible')" filterable size="small"
|
||||||
|
@ -61,22 +33,17 @@
|
||||||
</el-option>
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
|
||||||
<el-col :span="7">
|
|
||||||
<el-form-item :label="$t('test_track.case.priority')" prop="level">
|
<el-form-item :label="$t('test_track.case.priority')" prop="level">
|
||||||
<el-select class="ms-scenario-input" size="small" v-model="currentScenario.level">
|
<el-select class="ms-scenario-input" size="small" v-model="currentScenario.level">
|
||||||
<el-option v-for="item in levels" :key="item.id" :label="item.label" :value="item.id"/>
|
<el-option v-for="item in levels" :key="item.id" :label="item.label" :value="item.id"/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
|
||||||
<el-col :span="7">
|
|
||||||
<el-form-item :label="$t('api_test.automation.tag')" prop="tags">
|
<el-form-item :label="$t('api_test.automation.tag')" prop="tags">
|
||||||
<ms-input-tag :currentScenario="currentScenario" ref="tag"/>
|
<ms-input-tag :currentScenario="currentScenario" ref="tag"/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
<el-row>
|
|
||||||
<el-col :span="7">
|
|
||||||
<el-form-item :label="$t('commons.description')" prop="description">
|
<el-form-item :label="$t('commons.description')" prop="description">
|
||||||
<el-input class="ms-http-textarea"
|
<el-input class="ms-http-textarea"
|
||||||
v-model="currentScenario.description"
|
v-model="currentScenario.description"
|
||||||
|
@ -84,50 +51,37 @@
|
||||||
:autosize="{ minRows: 1, maxRows: 10}"
|
:autosize="{ minRows: 1, maxRows: 10}"
|
||||||
:rows="1" size="small"/>
|
:rows="1" size="small"/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
<el-form-item label="ID" prop="customNum" v-if="customNum">
|
||||||
<el-col :span="7" v-if="customNum">
|
|
||||||
<el-form-item label="ID" prop="customNum">
|
|
||||||
<el-input v-model.trim="currentScenario.customNum" size="small"></el-input>
|
<el-input v-model.trim="currentScenario.customNum" size="small"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
|
|
||||||
</el-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
<!-- 场景步骤-->
|
</ms-aside-container>
|
||||||
<div v-loading="loading">
|
|
||||||
<div @click="showAll">
|
<!-- 右侧部分 -->
|
||||||
<p class="tip">{{ $t('api_test.automation.scenario_step') }} </p>
|
<ms-main-container style="overflow: hidden" class="ms-scenario-main-container">
|
||||||
</div>
|
<!-- header 调试部分 -->
|
||||||
<el-row>
|
<div class="ms-debug-div" @click="showAll" ref="debugHeader">
|
||||||
<el-col :span="21">
|
|
||||||
<!-- 调试部分 -->
|
|
||||||
<div class="ms-debug-div" @click="showAll" :class="{'is-top' : isTop}" ref="debugHeader">
|
|
||||||
<el-row style="margin: 5px">
|
<el-row style="margin: 5px">
|
||||||
<el-col :span="4" class="ms-col-one ms-font">
|
<el-col :span="1" class="ms-col-one ms-font" v-show="scenarioDefinition.length > 1">
|
||||||
<el-tooltip placement="top" effect="light">
|
<el-tooltip :content="$t('test_track.case.batch_operate')" placement="top" effect="light" v-show="!isBatchProcess">
|
||||||
<template v-slot:content>
|
<font-awesome-icon class="ms-batch-btn" :icon="['fa', 'bars']" v-prevent-re-click @click="batchProcessing"/>
|
||||||
<div>{{
|
</el-tooltip>
|
||||||
currentScenario.name === undefined || '' ? $t('api_test.scenario.name') : currentScenario.name
|
<el-checkbox v-show="isBatchProcess" v-model="isCheckedAll" @change="checkedAll"/>
|
||||||
}}
|
<el-tooltip :content="$t('commons.cancel')" placement="top" effect="light" v-show="isBatchProcess">
|
||||||
</div>
|
<font-awesome-icon class="ms-batch-btn" :icon="['fa', 'times']" v-prevent-re-click @click="cancelBatchProcessing"/>
|
||||||
</template>
|
|
||||||
<span class="scenario-name">
|
|
||||||
{{
|
|
||||||
currentScenario.name === undefined || '' ? $t('api_test.scenario.name') : currentScenario.name
|
|
||||||
}}
|
|
||||||
</span>
|
|
||||||
</el-tooltip>
|
</el-tooltip>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="3" class="ms-col-one ms-font">
|
<el-col :span="2" class="ms-col-one ms-font">
|
||||||
{{ $t('api_test.automation.step_total') }}:{{ scenarioDefinition.length }}
|
{{ $t('api_test.automation.step_total') }}:{{ scenarioDefinition.length }}
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="3" class="ms-col-one ms-font">
|
<el-col :span="2" class="ms-col-one ms-font">
|
||||||
<el-link class="head" @click="showScenarioParameters">{{ $t('api_test.automation.scenario_total') }}
|
<el-link class="head" @click="showScenarioParameters">{{ $t('api_test.automation.scenario_total') }}
|
||||||
</el-link>
|
</el-link>
|
||||||
:{{ getVariableSize() }}
|
:{{ getVariableSize() }}
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="3" class="ms-col-one ms-font">
|
<el-col :span="2" class="ms-col-one ms-font">
|
||||||
<el-checkbox v-model="enableCookieShare"><span style="font-size: 13px;">{{ $t('api_test.scenario.share_cookie') }}</span></el-checkbox>
|
<el-checkbox v-model="enableCookieShare"><span style="font-size: 13px;">{{ $t('api_test.scenario.share_cookie') }}</span></el-checkbox>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="3" class="ms-col-one ms-font">
|
<el-col :span="3" class="ms-col-one ms-font">
|
||||||
|
@ -135,7 +89,7 @@
|
||||||
</el-col>
|
</el-col>
|
||||||
|
|
||||||
<el-col :span="7">
|
<el-col :span="7">
|
||||||
<div style="float: right;width: 300px">
|
<div style="float: right;width: 330px">
|
||||||
<env-popover :disabled="scenarioDefinition.length < 1" :env-map="projectEnvMap"
|
<env-popover :disabled="scenarioDefinition.length < 1" :env-map="projectEnvMap"
|
||||||
:project-ids="projectIds" :result="envResult"
|
:project-ids="projectIds" :result="envResult"
|
||||||
:environment-type.sync="environmentType" :isReadOnly="scenarioDefinition.length < 1"
|
:environment-type.sync="environmentType" :isReadOnly="scenarioDefinition.length < 1"
|
||||||
|
@ -153,56 +107,83 @@
|
||||||
</el-dropdown>
|
</el-dropdown>
|
||||||
</el-tooltip>
|
</el-tooltip>
|
||||||
<el-button size="mini" type="primary" v-else @click="stop">{{ $t('report.stop_btn') }}</el-button>
|
<el-button size="mini" type="primary" v-else @click="stop">{{ $t('report.stop_btn') }}</el-button>
|
||||||
|
|
||||||
|
<el-button id="inputDelay" type="primary" size="mini" v-prevent-re-click @click="editScenario"
|
||||||
|
title="ctrl + s" v-permission="['PROJECT_API_SCENARIO:READ+EDIT', 'PROJECT_API_SCENARIO:READ+CREATE', 'PROJECT_API_SCENARIO:READ+COPY']">
|
||||||
|
{{ $t('commons.save') }}
|
||||||
|
</el-button>
|
||||||
|
|
||||||
<el-tooltip class="item" effect="dark" :content="$t('commons.refresh')" placement="top-start">
|
<el-tooltip class="item" effect="dark" :content="$t('commons.refresh')" placement="top-start">
|
||||||
<el-button :disabled="scenarioDefinition.length < 1" size="mini" icon="el-icon-refresh"
|
<el-button :disabled="scenarioDefinition.length < 1" size="mini" icon="el-icon-refresh"
|
||||||
v-prevent-re-click @click="getApiScenario"></el-button>
|
v-prevent-re-click @click="getApiScenario"></el-button>
|
||||||
</el-tooltip>
|
</el-tooltip>
|
||||||
<el-tooltip class="item" effect="dark" :content="$t('commons.full_screen_editing')"
|
|
||||||
placement="top-start">
|
|
||||||
<font-awesome-icon class="alt-ico" :icon="['fa', 'expand-alt']" size="lg" @click="fullScreen"/>
|
|
||||||
</el-tooltip>
|
|
||||||
</div>
|
</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
<!--操作按钮-->
|
||||||
|
<el-link type="primary" @click.stop @click="showHistory" style="margin-right: 10px">
|
||||||
|
{{ $t("commons.debug_history") }}
|
||||||
|
</el-link>
|
||||||
|
|
||||||
|
<el-tooltip :content="$t('commons.follow')" placement="bottom" effect="dark" v-show="!showFollow">
|
||||||
|
<i class="el-icon-star-off" style="color: #783987; font-size: 25px; margin-right: 5px;cursor: pointer;position: relative; top: 5px; " @click="saveFollow"/>
|
||||||
|
</el-tooltip>
|
||||||
|
<el-tooltip :content="$t('commons.cancel')" placement="bottom" effect="dark" v-show="showFollow">
|
||||||
|
<i class="el-icon-star-on" style="color: #783987; font-size: 28px; margin-right: 5px;cursor: pointer;position: relative; top: 5px; " @click="saveFollow"/>
|
||||||
|
</el-tooltip>
|
||||||
|
<el-link type="primary" style="margin-right: 5px" @click="openHis" v-show="path === '/api/automation/update'">{{ $t('operating_log.change_history') }}</el-link>
|
||||||
|
<!-- 版本历史 -->
|
||||||
|
<ms-version-history v-xpack
|
||||||
|
ref="versionHistory"
|
||||||
|
:version-data="versionData"
|
||||||
|
:current-id="currentScenario.id"
|
||||||
|
@compare="compare" @checkout="checkout" @create="create" @del="del"/>
|
||||||
|
|
||||||
|
<el-tooltip effect="dark" :content="$t('commons.full_screen_editing')"
|
||||||
|
placement="top-start" style="margin-top: 6px">
|
||||||
|
<font-awesome-icon class="alt-ico" :icon="['fa', 'expand-alt']" size="lg" @click="fullScreen"/>
|
||||||
|
</el-tooltip>
|
||||||
</el-row>
|
</el-row>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- 场景步骤内容 -->
|
<div class="card-content">
|
||||||
<div ref="stepInfo">
|
<!-- 场景步骤-->
|
||||||
<el-tooltip :content="$t('api_test.automation.open_expansion')" placement="top" effect="light">
|
<div v-loading="loading">
|
||||||
<i class="el-icon-circle-plus-outline ms-open-btn ms-open-btn-left" v-prevent-re-click @click="openExpansion"/>
|
<el-row>
|
||||||
</el-tooltip>
|
<el-col :span="21">
|
||||||
<el-tooltip :content="$t('api_test.automation.close_expansion')" placement="top" effect="light">
|
<div class="ms-debug-result" v-show="debug">
|
||||||
<i class="el-icon-remove-outline ms-open-btn" size="mini" v-prevent-re-click @click="closeExpansion"/>
|
|
||||||
</el-tooltip>
|
|
||||||
<el-tooltip :content="$t('api_test.scenario.disable')" placement="top" effect="light" v-if="!stepEnable">
|
|
||||||
<font-awesome-icon class="ms-open-btn" :icon="['fas', 'toggle-off']" v-prevent-re-click @click="enableAll"/>
|
|
||||||
</el-tooltip>
|
|
||||||
<el-tooltip :content="$t('api_test.scenario.enable')" placement="top" effect="light" v-else>
|
|
||||||
<font-awesome-icon class="ms-open-btn" :icon="['fas', 'toggle-on']" v-prevent-re-click @click="disableAll"/>
|
|
||||||
</el-tooltip>
|
|
||||||
<el-link style="float:right;margin-right: 20px;margin-top: 3px" type="primary" @click.stop @click="showHistory">
|
|
||||||
{{ $t("commons.debug_history") }}
|
|
||||||
</el-link>
|
|
||||||
<div class="ms-debug-result" v-if="debug">
|
|
||||||
<span class="ms-message-right"> {{ reqTotalTime }} ms </span>
|
<span class="ms-message-right"> {{ reqTotalTime }} ms </span>
|
||||||
<span class="ms-message-right">{{ $t('api_test.automation.request_total') }} {{ reqTotal }}</span>
|
<span class="ms-message-right">{{ $t('api_test.automation.request_total') }} {{ reqTotal }}</span>
|
||||||
<span class="ms-message-right">{{ $t('api_test.automation.request_success') }} {{ reqSuccess }}</span>
|
<span class="ms-message-right">{{ $t('api_test.automation.request_success') }} {{ reqSuccess }}</span>
|
||||||
<span class="ms-message-right"> {{ $t('api_test.automation.request_error') }} {{ reqError }}</span>
|
<span class="ms-message-right"> {{ $t('api_test.automation.request_error') }} {{ reqError }}</span>
|
||||||
</div>
|
</div>
|
||||||
|
</el-col>
|
||||||
|
<el-col></el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="21">
|
||||||
|
<!-- 场景步骤内容 -->
|
||||||
|
<div ref="stepInfo">
|
||||||
<el-tree node-key="resourceId" :props="props" :data="scenarioDefinition" class="ms-tree"
|
<el-tree node-key="resourceId" :props="props" :data="scenarioDefinition" class="ms-tree"
|
||||||
:default-expanded-keys="expandedNode"
|
:default-expanded-keys="expandedNode"
|
||||||
:expand-on-click-node="false"
|
:expand-on-click-node="false"
|
||||||
|
:allow-drop="allowDrop"
|
||||||
|
:empty-text="$t('api_test.scenario.step_info')"
|
||||||
highlight-current
|
highlight-current
|
||||||
|
:show-checkbox="isBatchProcess"
|
||||||
|
@check-change="chooseHeadsUp"
|
||||||
@node-expand="nodeExpand"
|
@node-expand="nodeExpand"
|
||||||
@node-collapse="nodeCollapse"
|
@node-collapse="nodeCollapse"
|
||||||
:allow-drop="allowDrop" @node-drag-end="allowDrag" @node-click="nodeClick" draggable ref="stepTree" v-if="showHideTree">
|
@node-drag-end="allowDrag" @node-click="nodeClick" draggable ref="stepTree">
|
||||||
|
|
||||||
<el-row class="custom-tree-node" :gutter="18" type="flex" align="middle" slot-scope="{node, data}" style="width: 100%">
|
<el-row class="custom-tree-node" :gutter="18" type="flex" align="middle" slot-scope="{node, data}" style="width: 100%">
|
||||||
<el-col class="custom-tree-node-col" style="padding-left:0px;padding-right:0px" v-if="node && data.hashTree && data.hashTree.length > 0 && !data.isLeaf">
|
<el-col class="custom-tree-node-col" style="padding-left:0px;padding-right:0px" v-show="node && data.hashTree && data.hashTree.length > 0 && !data.isLeaf">
|
||||||
<span v-if="!node.expanded" class="el-icon-circle-plus-outline custom-node_e" @click="openOrClose(node)"/>
|
<span v-show="!node.expanded" class="el-icon-circle-plus-outline custom-node_e" @click="openOrClose(node)"/>
|
||||||
<span v-else class="el-icon-remove-outline custom-node_e" @click="openOrClose(node)"/>
|
<span v-show="node.expanded" class="el-icon-remove-outline custom-node_e" @click="openOrClose(node)"/>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col class="custom-tree-node-col" style="padding-left:0px;padding-right:0px" v-else>
|
<!-- 批量操作 -->
|
||||||
|
<el-col :class="data.checkBox? 'custom-tree-node-hide' : 'custom-tree-node-col'" style="padding-left: 0px; padding-right: 0px;"
|
||||||
|
v-show="(data.hashTree && data.hashTree.length === 0 )|| data.isLeaf">
|
||||||
|
<show-more-btn :is-show="node.checked" :buttons="batchOperators" :size="selectDataCounts" v-show="data.checkBox" style="margin-right: 3px"/>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col>
|
<el-col>
|
||||||
<!-- 步骤组件-->
|
<!-- 步骤组件-->
|
||||||
|
@ -351,17 +332,17 @@
|
||||||
ref="maximizeScenario"/>
|
ref="maximizeScenario"/>
|
||||||
</ms-drawer>
|
</ms-drawer>
|
||||||
<ms-change-history ref="changeHistory"/>
|
<ms-change-history ref="changeHistory"/>
|
||||||
<el-backtop target=".card-content" :visibility-height="100" :right="50"></el-backtop>
|
<el-backtop target=".card-content" :visibility-height="100" :right="20"></el-backtop>
|
||||||
</div>
|
</div>
|
||||||
<ms-task-center ref="taskCenter" :show-menu="false"/>
|
<ms-task-center ref="taskCenter" :show-menu="false"/>
|
||||||
|
|
||||||
|
<!--版本对比-->
|
||||||
<el-dialog
|
<el-dialog
|
||||||
:fullscreen="true"
|
:fullscreen="true"
|
||||||
:visible.sync="dialogVisible"
|
:visible.sync="dialogVisible"
|
||||||
:destroy-on-close="true"
|
:destroy-on-close="true"
|
||||||
@close="closeDiff"
|
@close="closeDiff"
|
||||||
width="100%"
|
width="100%">
|
||||||
>
|
|
||||||
<scenario-diff
|
<scenario-diff
|
||||||
v-if="dialogVisible"
|
v-if="dialogVisible"
|
||||||
:old-data="oldData"
|
:old-data="oldData"
|
||||||
|
@ -377,11 +358,11 @@
|
||||||
:old-on-sample-error="onSampleError"
|
:old-on-sample-error="onSampleError"
|
||||||
:new-on-sample-error="newOnSampleError"
|
:new-on-sample-error="newOnSampleError"
|
||||||
:project-list="projectList"
|
:project-list="projectList"
|
||||||
:type="type"
|
:type="type"/>
|
||||||
></scenario-diff>
|
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
||||||
</el-card>
|
</ms-main-container>
|
||||||
|
</ms-container>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
@ -446,6 +427,10 @@ export default {
|
||||||
MsChangeHistory: () => import("../../../history/ChangeHistory"),
|
MsChangeHistory: () => import("../../../history/ChangeHistory"),
|
||||||
MsTaskCenter: () => import("../../../task/TaskCenter"),
|
MsTaskCenter: () => import("../../../task/TaskCenter"),
|
||||||
MsApiVariableAdvance: () => import("./../../definition/components/ApiVariableAdvance"),
|
MsApiVariableAdvance: () => import("./../../definition/components/ApiVariableAdvance"),
|
||||||
|
MsMainContainer: () => import("@/business/components/common/components/MsMainContainer"),
|
||||||
|
MsAsideContainer: () => import("@/business/components/common/components/MsAsideContainer"),
|
||||||
|
MsContainer: () => import("@/business/components/common/components/MsContainer"),
|
||||||
|
ShowMoreBtn: () => import( "@/business/components/track/case/components/ShowMoreBtn"),
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
@ -455,7 +440,8 @@ export default {
|
||||||
props: {
|
props: {
|
||||||
label: "label",
|
label: "label",
|
||||||
isLeaf: "isLeaf",
|
isLeaf: "isLeaf",
|
||||||
children: "hashTree"
|
children: "hashTree",
|
||||||
|
disabled: false
|
||||||
},
|
},
|
||||||
moduleObj: {
|
moduleObj: {
|
||||||
id: 'id',
|
id: 'id',
|
||||||
|
@ -483,7 +469,7 @@ export default {
|
||||||
levels: PRIORITY,
|
levels: PRIORITY,
|
||||||
scenario: {},
|
scenario: {},
|
||||||
loading: false,
|
loading: false,
|
||||||
showHideTree: true,
|
renderComponent: true,
|
||||||
apiListVisible: false,
|
apiListVisible: false,
|
||||||
customizeVisible: false,
|
customizeVisible: false,
|
||||||
isBtnHide: false,
|
isBtnHide: false,
|
||||||
|
@ -547,7 +533,37 @@ export default {
|
||||||
newScenarioDefinition: [],
|
newScenarioDefinition: [],
|
||||||
oldScenarioDefinition: [],
|
oldScenarioDefinition: [],
|
||||||
currentItem: {},
|
currentItem: {},
|
||||||
pluginDelStep: false
|
pluginDelStep: false,
|
||||||
|
isBatchProcess: false,
|
||||||
|
isCheckedAll: false,
|
||||||
|
selectDataCounts: 0,
|
||||||
|
batchOperators: [
|
||||||
|
{
|
||||||
|
name: this.$t('api_test.automation.bulk_activation_steps'),
|
||||||
|
handleClick: this.enableAll,
|
||||||
|
permissions: ['PROJECT_API_SCENARIO:READ+DELETE']
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: this.$t('api_test.automation.batch_disable_steps'),
|
||||||
|
handleClick: this.disableAll,
|
||||||
|
permissions: ['PROJECT_API_SCENARIO:READ+DELETE']
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: this.$t('api_test.automation.open_expansion'),
|
||||||
|
handleClick: this.openExpansion,
|
||||||
|
permissions: ['PROJECT_API_SCENARIO:READ+DELETE']
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: this.$t('api_test.automation.close_expansion'),
|
||||||
|
handleClick: this.closeExpansion,
|
||||||
|
permissions: ['PROJECT_API_SCENARIO:READ+DELETE']
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: this.$t('api_test.definition.request.batch_delete') + "步骤",
|
||||||
|
handleClick: this.handleDeleteBatch,
|
||||||
|
permissions: ['PROJECT_API_SCENARIO:READ+DELETE']
|
||||||
|
},
|
||||||
|
],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
|
@ -583,7 +599,7 @@ export default {
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.addListener();
|
this.addListener();
|
||||||
});
|
});
|
||||||
if (!this.currentScenario.name) {
|
if (!this.currentScenario.name && this.$refs.refFab) {
|
||||||
this.$refs.refFab.openMenu();
|
this.$refs.refFab.openMenu();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -597,6 +613,52 @@ export default {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
chooseHeadsUp() {
|
||||||
|
if (this.$refs.stepTree) {
|
||||||
|
this.selectDataCounts = this.$refs.stepTree.getCheckedNodes().length;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
checkedAll(v) {
|
||||||
|
if (this.$refs.stepTree && this.$refs.stepTree.root && this.$refs.stepTree.root.childNodes) {
|
||||||
|
this.stepCheckedAll(v, this.$refs.stepTree.root.childNodes);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
stepCheckedAll(v, array) {
|
||||||
|
if (array) {
|
||||||
|
array.forEach(item => {
|
||||||
|
if (item.childNodes && item.childNodes.length > 0) {
|
||||||
|
this.stepCheckedAll(v, item.childNodes);
|
||||||
|
}
|
||||||
|
item.checked = v;
|
||||||
|
})
|
||||||
|
}
|
||||||
|
},
|
||||||
|
batchProcessing() {
|
||||||
|
this.isBatchProcess = true;
|
||||||
|
this.expandedNode = [];
|
||||||
|
this.hideAllTreeNode(this.scenarioDefinition);
|
||||||
|
this.$refs.stepTree.root.expanded = true;
|
||||||
|
this.reloadTreeStatus();
|
||||||
|
},
|
||||||
|
cancelBatchProcessing() {
|
||||||
|
this.isBatchProcess = false;
|
||||||
|
this.isCheckedAll = false;
|
||||||
|
if (this.$refs.stepTree && this.$refs.stepTree.root && this.$refs.stepTree.root.childNodes) {
|
||||||
|
this.stepCheckedAll(false, this.$refs.stepTree.root.childNodes);
|
||||||
|
}
|
||||||
|
this.selectDataCounts = 0;
|
||||||
|
this.commandTreeNode();
|
||||||
|
this.reloadTreeStatus();
|
||||||
|
},
|
||||||
|
reloadTreeStatus() {
|
||||||
|
this.$nextTick(() => {
|
||||||
|
let row = {resourceId: "ms-reload-test"};
|
||||||
|
if (this.$refs.stepTree && this.$refs.stepTree.root.data) {
|
||||||
|
this.$refs.stepTree.root.data.push(row);
|
||||||
|
this.$refs.stepTree.root.data.splice(this.$refs.stepTree.root.data.length - 1, 1);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
openOrClose(node) {
|
openOrClose(node) {
|
||||||
node.expanded = !node.expanded;
|
node.expanded = !node.expanded;
|
||||||
if (node.expanded) {
|
if (node.expanded) {
|
||||||
|
@ -609,17 +671,35 @@ export default {
|
||||||
node.isLeaf = true;
|
node.isLeaf = true;
|
||||||
node.visible = false;
|
node.visible = false;
|
||||||
},
|
},
|
||||||
hideTreeNode(node, array) {
|
hideAllTreeNode(array) {
|
||||||
|
array.forEach(item => {
|
||||||
|
if (item.hashTree && item.hashTree.length > 0) {
|
||||||
|
this.hideAllTreeNode(item.hashTree);
|
||||||
|
}
|
||||||
|
item.isLeaf = this.isBatchProcess;
|
||||||
|
item.isBatchProcess = this.isBatchProcess;
|
||||||
|
item.checkBox = this.isBatchProcess;
|
||||||
|
})
|
||||||
|
},
|
||||||
|
commandTreeNode(node, array) {
|
||||||
|
if (!array) {
|
||||||
|
array = this.scenarioDefinition;
|
||||||
|
}
|
||||||
let isLeaf = true;
|
let isLeaf = true;
|
||||||
array.forEach(item => {
|
array.forEach(item => {
|
||||||
if (this.stepFilter.get('ALlSamplerStep').indexOf(item.type) === -1) {
|
item.checkBox = false;
|
||||||
|
if (isLeaf && this.stepFilter.get('ALlSamplerStep').indexOf(item.type) === -1) {
|
||||||
isLeaf = false;
|
isLeaf = false;
|
||||||
}
|
}
|
||||||
if (item.hashTree && item.hashTree.length > 0) {
|
if (item.hashTree && item.hashTree.length > 0) {
|
||||||
this.hideTreeNode(item, item.hashTree);
|
this.commandTreeNode(item, item.hashTree);
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
if (node) {
|
||||||
|
node.isBatchProcess = this.isBatchProcess;
|
||||||
|
node.checkBox = false;
|
||||||
node.isLeaf = isLeaf;
|
node.isLeaf = isLeaf;
|
||||||
|
}
|
||||||
},
|
},
|
||||||
currentUser: () => {
|
currentUser: () => {
|
||||||
return getCurrentUser();
|
return getCurrentUser();
|
||||||
|
@ -652,7 +732,8 @@ export default {
|
||||||
let data = JSON.parse(res.data);
|
let data = JSON.parse(res.data);
|
||||||
if (data.hashTree) {
|
if (data.hashTree) {
|
||||||
this.sort(data.hashTree);
|
this.sort(data.hashTree);
|
||||||
this.scenarioDefinition = data.hashTree;
|
Object.assign(this.scenarioDefinition, data.hashTree)
|
||||||
|
this.cancelBatchProcessing();
|
||||||
if (this.$store.state.currentApiCase) {
|
if (this.$store.state.currentApiCase) {
|
||||||
this.$store.state.currentApiCase.resetDataSource = getUUID();
|
this.$store.state.currentApiCase.resetDataSource = getUUID();
|
||||||
} else {
|
} else {
|
||||||
|
@ -718,7 +799,7 @@ export default {
|
||||||
this.clearNodeStatus(this.$refs.stepTree.root.childNodes);
|
this.clearNodeStatus(this.$refs.stepTree.root.childNodes);
|
||||||
this.clearDebug();
|
this.clearDebug();
|
||||||
this.$success(this.$t('report.test_stop_success'));
|
this.$success(this.$t('report.test_stop_success'));
|
||||||
this.showHide();
|
this.forceRerender();
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
this.debugLoading = false;
|
this.debugLoading = false;
|
||||||
}
|
}
|
||||||
|
@ -980,14 +1061,10 @@ export default {
|
||||||
addListener() {
|
addListener() {
|
||||||
document.addEventListener("keydown", this.createCtrlSHandle);
|
document.addEventListener("keydown", this.createCtrlSHandle);
|
||||||
document.addEventListener("keydown", this.createCtrlRHandle);
|
document.addEventListener("keydown", this.createCtrlRHandle);
|
||||||
document.addEventListener("scroll", this.handleScroll, true);
|
|
||||||
window.addEventListener("resize", this.handleScroll);
|
|
||||||
},
|
},
|
||||||
removeListener() {
|
removeListener() {
|
||||||
document.removeEventListener("keydown", this.createCtrlSHandle);
|
document.removeEventListener("keydown", this.createCtrlSHandle);
|
||||||
document.removeEventListener("keydown", this.createCtrlRHandle);
|
document.removeEventListener("keydown", this.createCtrlRHandle);
|
||||||
document.removeEventListener("scroll", this.handleScroll, true);
|
|
||||||
window.removeEventListener("onresize", this.handleScroll);
|
|
||||||
},
|
},
|
||||||
createCtrlSHandle(event) {
|
createCtrlSHandle(event) {
|
||||||
handleCtrlSEvent(event, this.editScenario);
|
handleCtrlSEvent(event, this.editScenario);
|
||||||
|
@ -1101,7 +1178,6 @@ export default {
|
||||||
// 添加debug结果
|
// 添加debug结果
|
||||||
stepArray[i].parentIndex = fullPath ? fullPath + "_" + stepArray[i].index : stepArray[i].index;
|
stepArray[i].parentIndex = fullPath ? fullPath + "_" + stepArray[i].index : stepArray[i].index;
|
||||||
if (stepArray[i].hashTree && stepArray[i].hashTree.length > 0) {
|
if (stepArray[i].hashTree && stepArray[i].hashTree.length > 0) {
|
||||||
this.hideTreeNode(stepArray[i], stepArray[i].hashTree);
|
|
||||||
this.stepSize += stepArray[i].hashTree.length;
|
this.stepSize += stepArray[i].hashTree.length;
|
||||||
this.sort(stepArray[i].hashTree, stepArray[i].projectId, stepArray[i].parentIndex);
|
this.sort(stepArray[i].hashTree, stepArray[i].projectId, stepArray[i].parentIndex);
|
||||||
}
|
}
|
||||||
|
@ -1214,7 +1290,7 @@ export default {
|
||||||
const index = hashTree.findIndex(d => d.resourceId !== undefined && row.resourceId !== undefined && d.resourceId === row.resourceId)
|
const index = hashTree.findIndex(d => d.resourceId !== undefined && row.resourceId !== undefined && d.resourceId === row.resourceId)
|
||||||
hashTree.splice(index, 1);
|
hashTree.splice(index, 1);
|
||||||
this.sort();
|
this.sort();
|
||||||
this.showHide();
|
this.forceRerender();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -1253,10 +1329,9 @@ export default {
|
||||||
this.loading = false
|
this.loading = false
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
showHide() {
|
forceRerender() {
|
||||||
this.showHideTree = false
|
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.showHideTree = true
|
this.$store.state.forceRerenderIndex = getUUID();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
runDebug(runScenario) {
|
runDebug(runScenario) {
|
||||||
|
@ -1376,7 +1451,7 @@ export default {
|
||||||
allowDrag(draggingNode, dropNode, dropType) {
|
allowDrag(draggingNode, dropNode, dropType) {
|
||||||
if (dropNode && draggingNode && dropType) {
|
if (dropNode && draggingNode && dropType) {
|
||||||
this.sort();
|
this.sort();
|
||||||
this.showHide();
|
this.forceRerender();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
nodeExpand(data, node) {
|
nodeExpand(data, node) {
|
||||||
|
@ -1420,7 +1495,6 @@ export default {
|
||||||
if (this.currentScenario.tags instanceof String) {
|
if (this.currentScenario.tags instanceof String) {
|
||||||
this.currentScenario.tags = JSON.parse(this.currentScenario.tags);
|
this.currentScenario.tags = JSON.parse(this.currentScenario.tags);
|
||||||
}
|
}
|
||||||
this.$emit('refresh', this.currentScenario);
|
|
||||||
this.pluginDelStep = false;
|
this.pluginDelStep = false;
|
||||||
resolve();
|
resolve();
|
||||||
});
|
});
|
||||||
|
@ -1442,7 +1516,10 @@ export default {
|
||||||
},
|
},
|
||||||
getApiScenario() {
|
getApiScenario() {
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
|
this.isBatchProcess = false;
|
||||||
this.stepEnable = true;
|
this.stepEnable = true;
|
||||||
|
this.isCheckedAll = false;
|
||||||
|
this.selectDataCounts = 0;
|
||||||
if (this.currentScenario.tags !== undefined && this.currentScenario.tags) {
|
if (this.currentScenario.tags !== undefined && this.currentScenario.tags) {
|
||||||
if (!(this.currentScenario.tags instanceof Array)) {
|
if (!(this.currentScenario.tags instanceof Array)) {
|
||||||
this.currentScenario.tags = JSON.parse(this.currentScenario.tags);
|
this.currentScenario.tags = JSON.parse(this.currentScenario.tags);
|
||||||
|
@ -1501,7 +1578,6 @@ export default {
|
||||||
}
|
}
|
||||||
this.dataProcessing(obj.hashTree);
|
this.dataProcessing(obj.hashTree);
|
||||||
this.scenarioDefinition = obj.hashTree;
|
this.scenarioDefinition = obj.hashTree;
|
||||||
this.scenarioDefinitionOrg = obj.hashTree;
|
|
||||||
let v1 = {
|
let v1 = {
|
||||||
apiScenarioModuleId: this.currentScenario.apiScenarioModuleId,
|
apiScenarioModuleId: this.currentScenario.apiScenarioModuleId,
|
||||||
name: this.currentScenario.name,
|
name: this.currentScenario.name,
|
||||||
|
@ -1510,7 +1586,7 @@ export default {
|
||||||
level: this.currentScenario.level,
|
level: this.currentScenario.level,
|
||||||
tags: this.currentScenario.tags,
|
tags: this.currentScenario.tags,
|
||||||
description: this.currentScenario.description,
|
description: this.currentScenario.description,
|
||||||
scenarioDefinition: this.scenarioDefinitionOrg
|
scenarioDefinition: this.scenarioDefinition
|
||||||
};
|
};
|
||||||
this.currentScenario.scenarioDefinitionOrg = v1
|
this.currentScenario.scenarioDefinitionOrg = v1
|
||||||
this.oldScenarioDefinition = obj.hashTree;
|
this.oldScenarioDefinition = obj.hashTree;
|
||||||
|
@ -1532,6 +1608,7 @@ export default {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.setDomain();
|
this.setDomain();
|
||||||
this.sort();
|
this.sort();
|
||||||
|
this.commandTreeNode();
|
||||||
// 初始化resourceId
|
// 初始化resourceId
|
||||||
if (this.scenarioDefinition) {
|
if (this.scenarioDefinition) {
|
||||||
this.resetResourceId(this.scenarioDefinition);
|
this.resetResourceId(this.scenarioDefinition);
|
||||||
|
@ -1695,9 +1772,10 @@ export default {
|
||||||
this.envResult.loading = false;
|
this.envResult.loading = false;
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
changeNodeStatus(nodes) {
|
changeNodeStatus(resourceIds, nodes) {
|
||||||
for (let i in nodes) {
|
for (let i in nodes) {
|
||||||
if (nodes[i]) {
|
if (nodes[i]) {
|
||||||
|
if (resourceIds.indexOf(nodes[i].resourceId) !== -1) {
|
||||||
if (this.expandedStatus) {
|
if (this.expandedStatus) {
|
||||||
this.expandedNode.push(nodes[i].resourceId);
|
this.expandedNode.push(nodes[i].resourceId);
|
||||||
}
|
}
|
||||||
|
@ -1705,27 +1783,42 @@ export default {
|
||||||
if (this.stepSize > 35 && this.expandedStatus) {
|
if (this.stepSize > 35 && this.expandedStatus) {
|
||||||
nodes[i].active = false;
|
nodes[i].active = false;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
if (nodes[i].hashTree != undefined && nodes[i].hashTree.length > 0) {
|
if (nodes[i].hashTree != undefined && nodes[i].hashTree.length > 0) {
|
||||||
this.changeNodeStatus(nodes[i].hashTree);
|
this.changeNodeStatus(nodes[i].hashTree);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
getAllResourceIds() {
|
||||||
|
let selectValueArr = [];
|
||||||
|
if (this.$refs.stepTree) {
|
||||||
|
let checkNodes = this.$refs.stepTree.getCheckedNodes();
|
||||||
|
for (let node of checkNodes) {
|
||||||
|
selectValueArr.push(node.resourceId);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return selectValueArr;
|
||||||
|
},
|
||||||
openExpansion() {
|
openExpansion() {
|
||||||
this.expandedNode = [];
|
this.expandedNode = [];
|
||||||
this.expandedStatus = true;
|
this.expandedStatus = true;
|
||||||
this.changeNodeStatus(this.scenarioDefinition);
|
let resourceIds = this.getAllResourceIds();
|
||||||
|
this.changeNodeStatus(resourceIds, this.scenarioDefinition);
|
||||||
},
|
},
|
||||||
closeExpansion() {
|
closeExpansion() {
|
||||||
this.expandedStatus = false;
|
this.expandedStatus = false;
|
||||||
this.expandedNode = [];
|
this.expandedNode = [];
|
||||||
this.changeNodeStatus(this.scenarioDefinition);
|
let resourceIds = this.getAllResourceIds();
|
||||||
this.showHide();
|
this.changeNodeStatus(resourceIds, this.scenarioDefinition);
|
||||||
|
this.forceRerender();
|
||||||
},
|
},
|
||||||
stepStatus(nodes) {
|
stepStatus(resourceIds, nodes) {
|
||||||
for (let i in nodes) {
|
for (let i in nodes) {
|
||||||
if (nodes[i]) {
|
if (nodes[i]) {
|
||||||
|
if (resourceIds.indexOf(nodes[i].resourceId) !== -1) {
|
||||||
nodes[i].enable = this.stepEnable;
|
nodes[i].enable = this.stepEnable;
|
||||||
|
}
|
||||||
if (nodes[i].hashTree != undefined && nodes[i].hashTree.length > 0) {
|
if (nodes[i].hashTree != undefined && nodes[i].hashTree.length > 0) {
|
||||||
this.stepStatus(nodes[i].hashTree);
|
this.stepStatus(nodes[i].hashTree);
|
||||||
}
|
}
|
||||||
|
@ -1734,24 +1827,31 @@ export default {
|
||||||
},
|
},
|
||||||
enableAll() {
|
enableAll() {
|
||||||
this.stepEnable = true;
|
this.stepEnable = true;
|
||||||
this.stepStatus(this.scenarioDefinition);
|
let resourceIds = this.getAllResourceIds();
|
||||||
|
this.stepStatus(resourceIds, this.scenarioDefinition);
|
||||||
},
|
},
|
||||||
disableAll() {
|
disableAll() {
|
||||||
this.stepEnable = false;
|
this.stepEnable = false;
|
||||||
this.stepStatus(this.scenarioDefinition);
|
let resourceIds = this.getAllResourceIds();
|
||||||
|
this.stepStatus(resourceIds, this.scenarioDefinition);
|
||||||
},
|
},
|
||||||
handleScroll() {
|
handleDeleteBatch() {
|
||||||
let stepInfo = this.$refs.stepInfo;
|
this.getAllResourceIds().forEach(item => {
|
||||||
let debugHeader = this.$refs.debugHeader;
|
this.recursionDelete(item, this.scenarioDefinition);
|
||||||
if (debugHeader) {
|
});
|
||||||
let originWidth = debugHeader.parentElement.clientWidth;
|
this.sort();
|
||||||
if (stepInfo.getBoundingClientRect().top <= 178) {
|
this.forceRerender();
|
||||||
this.isTop = true;
|
},
|
||||||
if (originWidth > 0) {
|
recursionDelete(resourceId, nodes) {
|
||||||
debugHeader.style.width = originWidth + 'px';
|
for (let i in nodes) {
|
||||||
}
|
if (nodes[i]) {
|
||||||
|
if (resourceId === nodes[i].resourceId) {
|
||||||
|
nodes.splice(i, 1);
|
||||||
} else {
|
} else {
|
||||||
this.isTop = false;
|
if (nodes[i].hashTree != undefined && nodes[i].hashTree.length > 0) {
|
||||||
|
this.recursionDelete(resourceId, nodes[i].hashTree);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -1903,7 +2003,7 @@ export default {
|
||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
.card-content {
|
.card-content {
|
||||||
height: calc(100vh - 156px);
|
height: calc(100vh - 200px);
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1918,7 +2018,7 @@ export default {
|
||||||
.ms-debug-div {
|
.ms-debug-div {
|
||||||
border: 1px #DCDFE6 solid;
|
border: 1px #DCDFE6 solid;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
margin-right: 20px;
|
margin-right: 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.ms-scenario-button {
|
.ms-scenario-button {
|
||||||
|
@ -1944,7 +2044,7 @@ export default {
|
||||||
}
|
}
|
||||||
|
|
||||||
#fab {
|
#fab {
|
||||||
right: 90px;
|
right: 60px;
|
||||||
bottom: 120px;
|
bottom: 120px;
|
||||||
z-index: 5;
|
z-index: 5;
|
||||||
}
|
}
|
||||||
|
@ -2004,6 +2104,10 @@ export default {
|
||||||
transform: rotate(0deg);
|
transform: rotate(0deg);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.ms-tree >>> .el-tree-node__content > .el-tree-node__expand-icon {
|
||||||
|
padding: 3px;
|
||||||
|
}
|
||||||
|
|
||||||
.ms-tree >>> .el-icon-caret-right:before {
|
.ms-tree >>> .el-icon-caret-right:before {
|
||||||
/*content: '\e723';*/
|
/*content: '\e723';*/
|
||||||
padding: 0;
|
padding: 0;
|
||||||
|
@ -2041,6 +2145,11 @@ export default {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.el-icon-more:hover {
|
||||||
|
color: #7C3985;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
.scenario-name {
|
.scenario-name {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
margin: 0 5px;
|
margin: 0 5px;
|
||||||
|
@ -2064,10 +2173,19 @@ export default {
|
||||||
color: #67C23A;
|
color: #67C23A;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.ms-batch-btn {
|
||||||
|
margin-left: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ms-batch-btn:hover {
|
||||||
|
cursor: pointer;
|
||||||
|
color: #6D317C;
|
||||||
|
}
|
||||||
|
|
||||||
.ms-debug-result {
|
.ms-debug-result {
|
||||||
float: right;
|
|
||||||
margin-right: 30px;
|
|
||||||
margin-top: 3px;
|
margin-top: 3px;
|
||||||
|
height: 20px;
|
||||||
|
float: right;
|
||||||
}
|
}
|
||||||
|
|
||||||
.ms-open-btn-left {
|
.ms-open-btn-left {
|
||||||
|
@ -2094,5 +2212,23 @@ export default {
|
||||||
.custom-tree-node-col {
|
.custom-tree-node-col {
|
||||||
width: 20px;
|
width: 20px;
|
||||||
padding: 0px;
|
padding: 0px;
|
||||||
|
margin-left: 5px;
|
||||||
|
vertical-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.custom-tree-node-hide {
|
||||||
|
width: 2px;
|
||||||
|
padding: 0px;
|
||||||
|
vertical-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
/deep/ .show-more-btn {
|
||||||
|
width: 0px;
|
||||||
|
height: 17px;
|
||||||
|
line-height: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/deep/ .ms-main-container {
|
||||||
|
padding: 5px 5px 5px 10px;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -25,7 +25,7 @@ export function STEP() {
|
||||||
['GenericController', getAll()],
|
['GenericController', getAll()],
|
||||||
['AllSamplerProxy', ['HTTPSamplerProxy', 'DubboSampler', 'JDBCSampler', 'TCPSampler', 'Sampler', 'AbstractSampler', 'JSR223Processor', 'API']],
|
['AllSamplerProxy', ['HTTPSamplerProxy', 'DubboSampler', 'JDBCSampler', 'TCPSampler', 'Sampler', 'AbstractSampler', 'JSR223Processor', 'API']],
|
||||||
['DEFINITION', ['HTTPSamplerProxy', 'DubboSampler', 'JDBCSampler', 'TCPSampler']],
|
['DEFINITION', ['HTTPSamplerProxy', 'DubboSampler', 'JDBCSampler', 'TCPSampler']],
|
||||||
['ALlSamplerStep', ['JSR223Processor', 'JSR223PreProcessor', 'JSR223PostProcessor', 'JDBCPreProcessor', 'JDBCPostProcessor', 'Assertions', 'Extract','ConstantTimer']],
|
['ALlSamplerStep', ['JSR223PreProcessor', 'JSR223PostProcessor', 'JDBCPreProcessor', 'JDBCPostProcessor', 'Assertions', 'Extract', 'ConstantTimer']],
|
||||||
['AllCanExecType', ['HTTPSamplerProxy', 'DubboSampler', 'JDBCSampler', 'TCPSampler', 'JSR223Processor', 'AbstractSampler']]]);
|
['AllCanExecType', ['HTTPSamplerProxy', 'DubboSampler', 'JDBCSampler', 'TCPSampler', 'JSR223Processor', 'AbstractSampler']]]);
|
||||||
return map
|
return map
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
<div class="header" @click="active(data)">
|
<div class="header" @click="active(data)">
|
||||||
<slot name="beforeHeaderLeft">
|
<slot name="beforeHeaderLeft">
|
||||||
<div v-if="data.index" class="el-step__icon is-text enable-switch" :style="{'color': color, 'background-color': backgroundColor}">
|
<div v-if="data.index" class="el-step__icon is-text enable-switch" :style="{'color': color, 'background-color': backgroundColor}">
|
||||||
<div class="el-step__icon-inner">{{ data.index }}</div>
|
<div class="el-step__icon-inner" :key="$store.state.forceRerenderIndex">{{ data.index }}</div>
|
||||||
</div>
|
</div>
|
||||||
<slot name="behindHeaderLeft" v-if="!isMax"></slot>
|
<slot name="behindHeaderLeft" v-if="!isMax"></slot>
|
||||||
<el-tag class="ms-left-btn" size="small" :style="{'color': color, 'background-color': backgroundColor}">{{ title }}</el-tag>
|
<el-tag class="ms-left-btn" size="small" :style="{'color': color, 'background-color': backgroundColor}">{{ title }}</el-tag>
|
||||||
|
@ -18,10 +18,8 @@
|
||||||
|
|
||||||
<span :class="showVersion?'scenario-unscroll':'scenario-version'" id="moveout" @mouseenter="enter($event)" @mouseleave="leave($event)" v-else>
|
<span :class="showVersion?'scenario-unscroll':'scenario-version'" id="moveout" @mouseenter="enter($event)" @mouseleave="leave($event)" v-else>
|
||||||
<i class="el-icon-edit" style="cursor:pointer;" @click="editName"
|
<i class="el-icon-edit" style="cursor:pointer;" @click="editName"
|
||||||
v-if="data.referenced!='REF' && !data.disabled"/>
|
v-show="data.referenced!='REF' && !data.disabled"/>
|
||||||
<el-tooltip placement="top" :content="data.name">
|
|
||||||
<span>{{ data.name }}</span>
|
<span>{{ data.name }}</span>
|
||||||
</el-tooltip>
|
|
||||||
<el-tag size="mini" v-if="data.method && !data.pluginId" style="margin-left: 1rem">{{ getMethod() }}</el-tag>
|
<el-tag size="mini" v-if="data.method && !data.pluginId" style="margin-left: 1rem">{{ getMethod() }}</el-tag>
|
||||||
<slot name="afterTitle"/>
|
<slot name="afterTitle"/>
|
||||||
</span>
|
</span>
|
||||||
|
@ -38,7 +36,7 @@
|
||||||
<el-button v-if="showVersion" size="mini" icon="el-icon-copy-document" circle @click="copyRow" style="padding: 5px"
|
<el-button v-if="showVersion" size="mini" icon="el-icon-copy-document" circle @click="copyRow" style="padding: 5px"
|
||||||
:disabled="(data.disabled && !data.root) || !showVersion "/>
|
:disabled="(data.disabled && !data.root) || !showVersion "/>
|
||||||
|
|
||||||
<el-button v-if="showVersion && stepFilter.get('ALlSamplerStep').indexOf(data.type) !==-1" size="mini" icon="el-icon-delete" type="danger" style="padding: 5px" circle @click="remove"/>
|
<el-button v-show="isSingleButton" size="mini" icon="el-icon-delete" type="danger" style="padding: 5px" circle @click="remove"/>
|
||||||
<step-extend-btns style="display: contents"
|
<step-extend-btns style="display: contents"
|
||||||
:data="data"
|
:data="data"
|
||||||
:environmentType="environmentType"
|
:environmentType="environmentType"
|
||||||
|
@ -47,7 +45,7 @@
|
||||||
@copy="copyRow"
|
@copy="copyRow"
|
||||||
@remove="remove"
|
@remove="remove"
|
||||||
@openScenario="openScenario"
|
@openScenario="openScenario"
|
||||||
v-if="showBtn && (!data.disabled || data.root) && showVersion && stepFilter.get('ALlSamplerStep').indexOf(data.type) ===-1"/>
|
v-show="isMoreButton"/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
@ -87,6 +85,10 @@ export default {
|
||||||
},
|
},
|
||||||
props: {
|
props: {
|
||||||
draggable: Boolean,
|
draggable: Boolean,
|
||||||
|
innerStep: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false,
|
||||||
|
},
|
||||||
isMax: {
|
isMax: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: false,
|
default: false,
|
||||||
|
@ -145,7 +147,7 @@ export default {
|
||||||
} else {
|
} else {
|
||||||
this.colorStyle = "";
|
this.colorStyle = "";
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
if (!this.data.name) {
|
if (!this.data.name) {
|
||||||
|
@ -162,6 +164,20 @@ export default {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
computed: {
|
||||||
|
isSingleButton() {
|
||||||
|
if (this.data.type === 'ConstantTimer') {
|
||||||
|
return (this.innerStep && this.showVersion && this.stepFilter.get('ALlSamplerStep').indexOf(this.data.type) !== -1)
|
||||||
|
}
|
||||||
|
return (this.showVersion && this.stepFilter.get('ALlSamplerStep').indexOf(this.data.type) !== -1);
|
||||||
|
},
|
||||||
|
isMoreButton() {
|
||||||
|
if (this.data.type === 'ConstantTimer') {
|
||||||
|
return (!this.innerStep || this.showBtn && (!this.data.disabled || this.data.root) && this.showVersion && this.stepFilter.get('ALlSamplerStep').indexOf(this.data.type) === -1);
|
||||||
|
}
|
||||||
|
return (this.showBtn && (!this.data.disabled || this.data.root) && this.showVersion && this.stepFilter.get('ALlSamplerStep').indexOf(this.data.type) === -1);
|
||||||
|
},
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
active() {
|
active() {
|
||||||
this.$emit('active');
|
this.$emit('active');
|
||||||
|
@ -204,8 +220,6 @@ export default {
|
||||||
$event.currentTarget.className = "scenario-version"
|
$event.currentTarget.className = "scenario-version"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -110,11 +110,13 @@ export default {
|
||||||
}
|
}
|
||||||
this.reload();
|
this.reload();
|
||||||
},
|
},
|
||||||
|
'node.data.isBatchProcess'() {
|
||||||
|
if (this.node.data && this.node.data.isBatchProcess && this.node.data.referenced === 'REF') {
|
||||||
|
this.node.expanded = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
/*if (!this.scenario.projectId) {
|
|
||||||
this.scenario.projectId = getCurrentProjectID();
|
|
||||||
}*/
|
|
||||||
if (this.scenario.num) {
|
if (this.scenario.num) {
|
||||||
this.isShowNum = true;
|
this.isShowNum = true;
|
||||||
this.getWorkspaceId(this.scenario.projectId);
|
this.getWorkspaceId(this.scenario.projectId);
|
||||||
|
@ -202,8 +204,12 @@ export default {
|
||||||
},
|
},
|
||||||
active() {
|
active() {
|
||||||
if (this.node) {
|
if (this.node) {
|
||||||
|
if (this.node.data && this.node.data.isBatchProcess && this.node.data.referenced === 'REF') {
|
||||||
|
this.node.expanded = false;
|
||||||
|
} else {
|
||||||
this.node.expanded = !this.node.expanded;
|
this.node.expanded = !this.node.expanded;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
this.reload();
|
this.reload();
|
||||||
},
|
},
|
||||||
copyRow() {
|
copyRow() {
|
||||||
|
|
|
@ -6,6 +6,7 @@
|
||||||
:draggable="draggable"
|
:draggable="draggable"
|
||||||
:show-collapse="false"
|
:show-collapse="false"
|
||||||
:is-max="isMax"
|
:is-max="isMax"
|
||||||
|
:inner-step="innerStep"
|
||||||
color="#67C23A"
|
color="#67C23A"
|
||||||
background-color="#F2F9EE"
|
background-color="#F2F9EE"
|
||||||
:title="$t('api_test.automation.wait_controller')">
|
:title="$t('api_test.automation.wait_controller')">
|
||||||
|
@ -26,6 +27,10 @@ export default {
|
||||||
components: {ApiBaseComponent},
|
components: {ApiBaseComponent},
|
||||||
props: {
|
props: {
|
||||||
timer: {},
|
timer: {},
|
||||||
|
innerStep: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false,
|
||||||
|
},
|
||||||
node: {},
|
node: {},
|
||||||
isMax: {
|
isMax: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
|
|
|
@ -123,7 +123,7 @@
|
||||||
:draggable="false"
|
:draggable="false"
|
||||||
@remove="remove" @copyRow="copyRow" @suggestClick="suggestClick"
|
@remove="remove" @copyRow="copyRow" @suggestClick="suggestClick"
|
||||||
@refReload="refReload" @openScenario="openScenario"
|
@refReload="refReload" @openScenario="openScenario"
|
||||||
v-if="selectedTreeNode && selectedNode && stepFilter.get('ALlSamplerStep').indexOf(item.type) ===-1"/>
|
v-show="selectedTreeNode && selectedNode && stepFilter.get('ALlSamplerStep').indexOf(item.type) ===-1"/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -53,7 +53,7 @@
|
||||||
color="#B8741A"
|
color="#B8741A"
|
||||||
background-color="#F9F1EA"/>
|
background-color="#F9F1EA"/>
|
||||||
|
|
||||||
<ms-constant-timer :timer="data" :node="node" v-if="data.type ==='ConstantTimer'" @remove="remove"/>
|
<ms-constant-timer :inner-step="true" :timer="data" :node="node" v-if="data.type ==='ConstantTimer'" @remove="remove"/>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div v-if="tabType ==='post'">
|
<div v-if="tabType ==='post'">
|
||||||
|
@ -225,7 +225,7 @@ export default {
|
||||||
this.$emit('reload');
|
this.$emit('reload');
|
||||||
},
|
},
|
||||||
add() {
|
add() {
|
||||||
this.request.active = false;
|
this.request.active = true;
|
||||||
if (this.tabType === 'pre') {
|
if (this.tabType === 'pre') {
|
||||||
if (this.preOperate === 'script') {
|
if (this.preOperate === 'script') {
|
||||||
this.addPre();
|
this.addPre();
|
||||||
|
@ -340,6 +340,7 @@ export default {
|
||||||
this.request.hashTree.splice(index, 1);
|
this.request.hashTree.splice(index, 1);
|
||||||
this.sort();
|
this.sort();
|
||||||
this.reload();
|
this.reload();
|
||||||
|
this.forceRerender();
|
||||||
},
|
},
|
||||||
copyRow(row) {
|
copyRow(row) {
|
||||||
let obj = JSON.parse(JSON.stringify(row));
|
let obj = JSON.parse(JSON.stringify(row));
|
||||||
|
@ -352,6 +353,7 @@ export default {
|
||||||
}
|
}
|
||||||
this.sort();
|
this.sort();
|
||||||
this.reload();
|
this.reload();
|
||||||
|
this.forceRerender();
|
||||||
},
|
},
|
||||||
allowDrop(draggingNode, dropNode, dropType) {
|
allowDrop(draggingNode, dropNode, dropType) {
|
||||||
// 增加插件权限控制
|
// 增加插件权限控制
|
||||||
|
@ -364,8 +366,14 @@ export default {
|
||||||
if (dropNode && draggingNode && dropType) {
|
if (dropNode && draggingNode && dropType) {
|
||||||
this.reload();
|
this.reload();
|
||||||
this.filter();
|
this.filter();
|
||||||
|
this.forceRerender();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
forceRerender() {
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$store.state.forceRerenderIndex = getUUID();
|
||||||
|
});
|
||||||
|
},
|
||||||
reload() {
|
reload() {
|
||||||
this.isReloadData = true
|
this.isReloadData = true
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
|
|
|
@ -29,7 +29,6 @@ import formCreate from "@form-create/element-ui"
|
||||||
import mavonEditor from 'mavon-editor'
|
import mavonEditor from 'mavon-editor'
|
||||||
import 'mavon-editor/dist/css/index.css'
|
import 'mavon-editor/dist/css/index.css'
|
||||||
import 'element-ui/lib/theme-chalk/display.css';
|
import 'element-ui/lib/theme-chalk/display.css';
|
||||||
import 'default-passive-events'
|
|
||||||
Vue.use(mavonEditor)
|
Vue.use(mavonEditor)
|
||||||
|
|
||||||
Vue.use(vueMinderEditor)
|
Vue.use(vueMinderEditor)
|
||||||
|
|
|
@ -1316,8 +1316,10 @@ export default {
|
||||||
case_reduction_error_text: "Please restore first"
|
case_reduction_error_text: "Please restore first"
|
||||||
},
|
},
|
||||||
automation: {
|
automation: {
|
||||||
open_expansion: "One-click expansion",
|
open_expansion: "Batch Folding Steps",
|
||||||
close_expansion: "One-click storage",
|
close_expansion: "Bulk Expand Steps",
|
||||||
|
bulk_activation_steps: "Bulk activation steps",
|
||||||
|
batch_disable_steps: "Batch disable steps",
|
||||||
all: "all",
|
all: "all",
|
||||||
constant: "constant",
|
constant: "constant",
|
||||||
counter: "counter",
|
counter: "counter",
|
||||||
|
@ -1463,6 +1465,7 @@ export default {
|
||||||
scenario_error: "Cannot reference or copy itself!",
|
scenario_error: "Cannot reference or copy itself!",
|
||||||
integrated: "Integrated",
|
integrated: "Integrated",
|
||||||
independent: "Independent",
|
independent: "Independent",
|
||||||
|
step_info: "Add a scene step on the right",
|
||||||
},
|
},
|
||||||
request: {
|
request: {
|
||||||
debug: "Debug",
|
debug: "Debug",
|
||||||
|
|
|
@ -1321,8 +1321,10 @@ export default {
|
||||||
case_reduction_error_text: "请先恢复"
|
case_reduction_error_text: "请先恢复"
|
||||||
},
|
},
|
||||||
automation: {
|
automation: {
|
||||||
open_expansion: "一键展开",
|
open_expansion: "批量展开步骤",
|
||||||
close_expansion: "一键收起",
|
close_expansion: "批量折叠步骤",
|
||||||
|
bulk_activation_steps: "批量启用步骤",
|
||||||
|
batch_disable_steps: "批量禁用步骤",
|
||||||
all: "全部",
|
all: "全部",
|
||||||
constant: "常量",
|
constant: "常量",
|
||||||
counter: "计数器",
|
counter: "计数器",
|
||||||
|
@ -1467,6 +1469,7 @@ export default {
|
||||||
scenario_error: "不能引用或复制自身!",
|
scenario_error: "不能引用或复制自身!",
|
||||||
integrated: "集合",
|
integrated: "集合",
|
||||||
independent: "独立",
|
independent: "独立",
|
||||||
|
step_info: "在右侧添加场景步骤",
|
||||||
},
|
},
|
||||||
request: {
|
request: {
|
||||||
debug: "调试",
|
debug: "调试",
|
||||||
|
|
|
@ -1321,8 +1321,10 @@ export default {
|
||||||
case_reduction_error_text: "請先恢復"
|
case_reduction_error_text: "請先恢復"
|
||||||
},
|
},
|
||||||
automation: {
|
automation: {
|
||||||
open_expansion: "一鍵展開",
|
open_expansion: "批量展開步驟",
|
||||||
close_expansion: "一鍵收起",
|
close_expansion: "批量折疊步驟",
|
||||||
|
bulk_activation_steps: "批量啟用步驟",
|
||||||
|
batch_disable_steps: "批量禁用步驟",
|
||||||
all: "全部",
|
all: "全部",
|
||||||
constant: "常量",
|
constant: "常量",
|
||||||
counter: "計數器",
|
counter: "計數器",
|
||||||
|
@ -1467,6 +1469,7 @@ export default {
|
||||||
scenario_error: "不能引用或復製自身!",
|
scenario_error: "不能引用或復製自身!",
|
||||||
integrated: "集合",
|
integrated: "集合",
|
||||||
independent: "獨立",
|
independent: "獨立",
|
||||||
|
step_info: "在右側添加場景步驟",
|
||||||
},
|
},
|
||||||
request: {
|
request: {
|
||||||
debug: "調試",
|
debug: "調試",
|
||||||
|
|
|
@ -34,7 +34,8 @@ const state = {
|
||||||
apiStatus: new Map(),
|
apiStatus: new Map(),
|
||||||
testCaseMap: new Map(),
|
testCaseMap: new Map(),
|
||||||
curTabId: null,
|
curTabId: null,
|
||||||
testCaseDefaultValue: {}
|
testCaseDefaultValue: {},
|
||||||
|
forceRerenderIndex: "",
|
||||||
}
|
}
|
||||||
|
|
||||||
const store = new Vuex.Store({
|
const store = new Vuex.Store({
|
||||||
|
|
Loading…
Reference in New Issue