refactor(权限管理): 测试跟踪权限 track header

This commit is contained in:
Captain.B 2021-05-21 16:55:01 +08:00 committed by 刘瑞斌
parent 2ad4b4fa3b
commit fb69a5cf81
42 changed files with 579 additions and 527 deletions

View File

@ -49,8 +49,8 @@
<el-tab-pane name="add">
<template v-slot:label>
<el-dropdown @command="handleCommand" v-tester>
<el-button type="primary" plain icon="el-icon-plus" size="mini" v-tester/>
<el-dropdown @command="handleCommand">
<el-button type="primary" plain icon="el-icon-plus" size="mini"/>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="ADD"
v-permission="['PROJECT_API_SCENARIO:READ+CREATE']">

View File

@ -29,7 +29,7 @@
</el-dropdown-menu>
</el-dropdown>
<template v-slot:default="scope">
<show-more-btn v-tester :is-show="scope.row.showMore" :buttons="buttons" :size="selectDataCounts"/>
<show-more-btn :is-show="scope.row.showMore" :buttons="buttons" :size="selectDataCounts"/>
</template>
</el-table-column>
<el-table-column :label="$t('commons.name')" width="200" show-overflow-tooltip prop="name">

View File

@ -26,7 +26,7 @@
<el-table-column v-if="!referenced" width="30" min-width="30" :resizable="false" align="center">
<template v-slot:default="scope">
<show-more-btn :is-show="scope.row.showMore" :buttons="trashEnable ? trashButtons: buttons"
:size="selectDataCounts" v-tester/>
:size="selectDataCounts"/>
</template>
</el-table-column>
<template v-for="(item, index) in tableLabel">
@ -137,9 +137,9 @@
<template v-slot:default="{row}">
<div v-if="trashEnable">
<ms-table-operator-button :tip="$t('commons.reduction')" icon="el-icon-refresh-left"
@exec="reductionApi(row)" v-tester/>
@exec="reductionApi(row)"/>
<ms-table-operator-button :tip="$t('api_test.automation.remove')" icon="el-icon-delete"
@exec="remove(row)" type="danger" v-tester/>
@exec="remove(row)" type="danger"/>
</div>
<div v-else>
<ms-table-operator-button :tip="$t('api_test.automation.edit')" icon="el-icon-edit" @exec="edit(row)"

View File

@ -7,7 +7,8 @@
<div class="ms-opt-btn">
<el-link type="primary" style="margin-right: 20px" @click="openHis" v-if="path === '/api/automation/update'">{{$t('operating_log.change_history')}}</el-link>
<el-button id="inputDelay" type="primary" size="small" v-prevent-re-click @click="editScenario" title="ctrl + s" v-tester>
<el-button id="inputDelay" type="primary" size="small" v-prevent-re-click @click="editScenario"
title="ctrl + s">
{{ $t('commons.save') }}
</el-button>
</div>
@ -119,23 +120,28 @@
<el-col :span="3" class="ms-col-one ms-font">
{{$t('api_test.automation.step_total')}}{{scenarioDefinition.length}}
</el-col>
<el-col :span="3" class="ms-col-one ms-font" v-tester>
<el-link class="head" @click="showScenarioParameters">{{$t('api_test.automation.scenario_total')}}</el-link>
<el-col :span="3" class="ms-col-one ms-font">
<el-link class="head" @click="showScenarioParameters">{{ $t('api_test.automation.scenario_total') }}
</el-link>
{{ getVariableSize() }}
</el-col>
<el-col :span="3" class="ms-col-one ms-font">
<el-checkbox v-model="enableCookieShare">共享cookie</el-checkbox>
</el-col>
<el-col :span="5">
<env-popover :disabled="scenarioDefinition.length < 1" :env-map="projectEnvMap" :project-ids="projectIds" @setProjectEnvMap="setProjectEnvMap" :result="envResult"
:isReadOnly="scenarioDefinition.length < 1" @showPopover="showPopover" :project-list="projectList" ref="envPopover" v-tester/>
<env-popover :disabled="scenarioDefinition.length < 1" :env-map="projectEnvMap"
:project-ids="projectIds" @setProjectEnvMap="setProjectEnvMap" :result="envResult"
:isReadOnly="scenarioDefinition.length < 1" @showPopover="showPopover"
:project-list="projectList" ref="envPopover"/>
</el-col>
<el-col :span="4">
<el-button :disabled="scenarioDefinition.length < 1" size="mini" type="primary" v-prevent-re-click @click="runDebug" v-tester>{{$t('api_test.request.debug')}}</el-button>
<el-button :disabled="scenarioDefinition.length < 1" size="mini" type="primary" v-prevent-re-click
@click="runDebug">{{ $t('api_test.request.debug') }}
</el-button>
<el-tooltip class="item" effect="dark" :content="$t('commons.refresh')" placement="right-start">
<el-button :disabled="scenarioDefinition.length < 1" size="mini" icon="el-icon-refresh" v-prevent-re-click @click="getApiScenario"></el-button>
</el-tooltip>
<font-awesome-icon class="alt-ico" :icon="['fa', 'expand-alt']" size="lg" @click="fullScreen" v-tester/>
<font-awesome-icon class="alt-ico" :icon="['fa', 'expand-alt']" size="lg" @click="fullScreen"/>
</el-col>
</el-row>
</div>
@ -165,7 +171,7 @@
</el-col>
<!-- 按钮列表 -->
<el-col :span="3">
<div @click="fabClick" v-tester>
<div @click="fabClick">
<vue-fab id="fab" mainBtnColor="#783887" size="small" :global-options="globalOptions"
:click-auto-close="false" v-outside-click="outsideClick">
<fab-item

View File

@ -19,7 +19,8 @@
</span>
<span :class="isMax?'ms-step-name':'scenario-name'" v-else>
{{data.name}}
<i class="el-icon-edit" style="cursor:pointer" @click="editName" v-tester v-if="data.referenced!='REF' && !data.disabled" @click.stop/>
<i class="el-icon-edit" style="cursor:pointer" @click="editName"
v-if="data.referenced!='REF' && !data.disabled" @click.stop/>
</span>
</slot>
<slot name="behindHeaderLeft" v-if="!isMax"></slot>

View File

@ -5,10 +5,16 @@
<el-icon class="el-icon-more"></el-icon>
</el-link>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="remove" v-tester>{{this.$t('api_test.automation.delete_step')}}</el-dropdown-item>
<el-dropdown-item command="scenarioVar" v-tester v-if="data.type==='scenario'">{{this.$t("api_test.automation.view_scene_variables")}}</el-dropdown-item>
<el-dropdown-item command="openScenario" v-tester v-if="data.type==='scenario' && data.referenced==='REF'">{{this.$t("api_test.automation.open_scene")}}</el-dropdown-item>
<el-dropdown-item command="saveAs" v-tester v-if="allSamplers.indexOf(data.type)!=-1 && data.referenced ==='Created' ">{{this.$t("api_test.automation.save_as_api")}}</el-dropdown-item>
<el-dropdown-item command="remove">{{ this.$t('api_test.automation.delete_step') }}</el-dropdown-item>
<el-dropdown-item command="scenarioVar" v-if="data.type==='scenario'">
{{ this.$t("api_test.automation.view_scene_variables") }}
</el-dropdown-item>
<el-dropdown-item command="openScenario" v-if="data.type==='scenario' && data.referenced==='REF'">
{{ this.$t("api_test.automation.open_scene") }}
</el-dropdown-item>
<el-dropdown-item command="saveAs" v-if="allSamplers.indexOf(data.type)!=-1 && data.referenced ==='Created' ">
{{ this.$t("api_test.automation.save_as_api") }}
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
<ms-variable-list ref="scenarioParameters"/>

View File

@ -3,7 +3,7 @@
<el-input :placeholder="$t('test_track.module.search')" v-model="condition.filterText" size="small">
<template v-slot:append>
<el-dropdown v-if="!isReadOnly" size="small" split-button type="primary" class="ms-api-button" @click="handleCommand('add-api')"
v-tester
@command="handleCommand">
<el-button icon="el-icon-folder-add" @click="addScenario"></el-button>
<el-dropdown-menu slot="dropdown">

View File

@ -13,7 +13,7 @@
<el-col :span="18">
<el-input :disabled="isReadOnly" v-model="form.cronValue" class="inp"
:placeholder="$t('schedule.please_input_cron_expression')"/>
<el-button :disabled="isReadOnly" type="primary" @click="saveCron" v-tester>{{
<el-button :disabled="isReadOnly" type="primary" @click="saveCron">{{
$t('commons.save')
}}
</el-button>

View File

@ -120,8 +120,8 @@
<el-tab-pane name="add">
<template v-slot:label>
<el-dropdown @command="handleCommand" v-tester>
<el-button type="primary" plain icon="el-icon-plus" size="mini" v-tester/>
<el-dropdown @command="handleCommand">
<el-button type="primary" plain icon="el-icon-plus" size="mini"/>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="debug" v-permission="['PROJECT_API_DEFINITION:READ+DEBUG']">
{{ $t('api_test.definition.request.fast_debug') }}

View File

@ -54,7 +54,8 @@
</div>
</el-col>
<el-col :span="1" v-if="!(isReadOnly || isCaseEdit)">
<el-button size="small" type="primary" @click="addCase" v-tester>+{{$t('api_test.definition.request.case')}}</el-button>
<el-button size="small" type="primary" @click="addCase">+{{ $t('api_test.definition.request.case') }}
</el-button>
</el-col>
</el-row>
</el-card>

View File

@ -28,7 +28,7 @@
@blur="saveTestCase(apiCase,true)" :placeholder="$t('commons.input_name')" ref="nameEdit"/>
<span v-else>
<span>{{ apiCase.id ? apiCase.name : '' }}</span>
<i class="el-icon-edit" style="cursor:pointer" @click="showInput(apiCase)" v-tester/>
<i class="el-icon-edit" style="cursor:pointer" @click="showInput(apiCase)"/>
</span>
<el-link type="primary" style="margin-left: 10px" @click="openHis(apiCase)" v-if="apiCase.id">{{$t('operating_log.change_history')}}</el-link>
@ -64,12 +64,12 @@
<el-col :span="4">
<span @click.stop>
<ms-tip-button @click="singleRun(apiCase)" :tip="$t('api_test.run')" icon="el-icon-video-play"
style="background-color: #409EFF;color: white" size="mini" :disabled="!apiCase.id" circle v-tester/>
style="background-color: #409EFF;color: white" size="mini" :disabled="!apiCase.id" circle/>
<ms-tip-button @click="copyCase(apiCase)" :tip="$t('commons.copy')" icon="el-icon-document-copy"
size="mini" :disabled="!apiCase.id || isCaseEdit" circle v-tester/>
size="mini" :disabled="!apiCase.id || isCaseEdit" circle/>
<ms-tip-button @click="deleteCase(index,apiCase)" :tip="$t('commons.delete')" icon="el-icon-delete"
size="mini" :disabled="!apiCase.id || isCaseEdit" circle v-tester/>
<ms-api-extend-btns :is-case-edit="isCaseEdit" :environment="environment" :row="apiCase" v-tester/>
size="mini" :disabled="!apiCase.id || isCaseEdit" circle/>
<ms-api-extend-btns :is-case-edit="isCaseEdit" :environment="environment" :row="apiCase"/>
</span>
</el-col>
@ -112,7 +112,8 @@
<ms-jmx-step :request="apiCase.request" :response="apiCase.responseData"/>
<!-- 保存操作 -->
<el-button type="primary" size="small" style="margin: 20px; float: right" @click="saveTestCase(apiCase)" v-tester v-if="type!=='detail'">
<el-button type="primary" size="small" style="margin: 20px; float: right" @click="saveTestCase(apiCase)"
v-if="type!=='detail'">
{{ $t('commons.save') }}
</el-button>
</div>

View File

@ -6,9 +6,11 @@
<el-col>
<!--操作按钮-->
<div style="float: right;margin-right: 20px;margin-top: 20px">
<el-link type="primary" style="margin-right: 20px" @click="openHis" v-if="basisData.id">{{$t('operating_log.change_history')}}</el-link>
<el-button type="primary" size="small" @click="saveApi" title="ctrl + s" v-tester>{{ $t('commons.save') }}</el-button>
<el-button type="primary" size="small" @click="runTest" v-tester>{{ $t('commons.test') }}</el-button>
<el-link type="primary" style="margin-right: 20px" @click="openHis" v-if="basisData.id">
{{ $t('operating_log.change_history') }}
</el-link>
<el-button type="primary" size="small" @click="saveApi" title="ctrl + s">{{ $t('commons.save') }}</el-button>
<el-button type="primary" size="small" @click="runTest">{{ $t('commons.test') }}</el-button>
</div>
</el-col>
</el-row>

View File

@ -5,9 +5,11 @@
<el-form :model="httpForm" :rules="rule" ref="httpForm" label-width="80px" label-position="right">
<!-- 操作按钮 -->
<div style="float: right;margin-right: 20px">
<el-link type="primary" style="margin-right: 20px" @click="openHis" v-if="httpForm.id">{{$t('operating_log.change_history')}}</el-link>
<el-button type="primary" size="small" @click="saveApi" title="ctrl + s" v-tester>{{ $t('commons.save') }}</el-button>
<el-button type="primary" size="small" @click="runTest" v-tester>{{ $t('commons.test') }}</el-button>
<el-link type="primary" style="margin-right: 20px" @click="openHis" v-if="httpForm.id">
{{ $t('operating_log.change_history') }}
</el-link>
<el-button type="primary" size="small" @click="saveApi" title="ctrl + s">{{ $t('commons.save') }}</el-button>
<el-button type="primary" size="small" @click="runTest">{{ $t('commons.test') }}</el-button>
</div>
<br/>
<p class="tip">{{ $t('test_track.plan_view.base_info') }} </p>

View File

@ -5,9 +5,11 @@
<el-col>
<!--操作按钮-->
<div style="float: right;margin-right: 20px;margin-top: 20px">
<el-link type="primary" style="margin-right: 20px" @click="openHis" v-if="basisData.id">{{$t('operating_log.change_history')}}</el-link>
<el-button type="primary" size="small" @click="saveApi" title="ctrl + s" v-tester>{{ $t('commons.save') }}</el-button>
<el-button type="primary" size="small" @click="runTest" v-tester>{{ $t('commons.test') }}</el-button>
<el-link type="primary" style="margin-right: 20px" @click="openHis" v-if="basisData.id">
{{ $t('operating_log.change_history') }}
</el-link>
<el-button type="primary" size="small" @click="saveApi" title="ctrl + s">{{ $t('commons.save') }}</el-button>
<el-button type="primary" size="small" @click="runTest">{{ $t('commons.test') }}</el-button>
</div>
</el-col>
</el-row>

View File

@ -5,9 +5,11 @@
<el-col>
<!--操作按钮-->
<div style="float: right;margin-right: 20px;margin-top: 20px">
<el-link type="primary" style="margin-right: 20px" @click="openHis" v-if="basisData.id">{{$t('operating_log.change_history')}}</el-link>
<el-button type="primary" size="small" @click="saveApi" title="ctrl + s" v-tester>{{ $t('commons.save') }}</el-button>
<el-button type="primary" size="small" @click="runTest" v-tester>{{ $t('commons.test') }}</el-button>
<el-link type="primary" style="margin-right: 20px" @click="openHis" v-if="basisData.id">
{{ $t('operating_log.change_history') }}
</el-link>
<el-button type="primary" size="small" @click="saveApi" title="ctrl + s">{{ $t('commons.save') }}</el-button>
<el-button type="primary" size="small" @click="runTest">{{ $t('commons.test') }}</el-button>
</div>
</el-col>
</el-row>

View File

@ -10,7 +10,7 @@
prop="cronValue">
<el-input :disabled="isReadOnly" v-model="form.cronValue" class="inp"
:placeholder="$t('schedule.please_input_cron_expression')"/>
<el-button :disabled="isReadOnly" type="primary" @click="saveCron" v-tester>{{
<el-button :disabled="isReadOnly" type="primary" @click="saveCron">{{
$t('commons.save')
}}
</el-button>

View File

@ -107,11 +107,11 @@
icon="el-icon-video-play"
@exec="runTestCase(scope.row)"/>
<ms-table-operator-button :tip="$t('commons.edit')" icon="el-icon-edit" @exec="handleTestCase(scope.row)"
v-tester/>
/>
<ms-table-operator-button :tip="$t('commons.delete')" icon="el-icon-delete" @exec="handleDelete(scope.row)"
type="danger" v-tester/>
type="danger"/>
<ms-api-case-table-extend-btns @showCaseRef="showCaseRef" @showEnvironment="showEnvironment"
@createPerformance="createPerformance" :row="scope.row" v-tester/>
@createPerformance="createPerformance" :row="scope.row"/>
</template>
</el-table-column>

View File

@ -40,9 +40,9 @@
<template v-slot:default="scope">
<ms-table-operator-button :tip="$t('commons.copy')" icon="el-icon-copy-document"
@exec="copyExpect(scope.row)"
v-tester/>
/>
<ms-table-operator-button :tip="$t('commons.edit')" icon="el-icon-delete" @exec="removeExpect(scope.row)"
v-tester/>
/>
</template>
</el-table-column>
</el-table>

View File

@ -15,7 +15,7 @@
type="selection"/>
<el-table-column width="40" :resizable="false" align="center">
<template v-slot:default="scope">
<show-more-btn v-tester :is-show="scope.row.showMore" :buttons="buttons" :size="selectRows.size"/>
<show-more-btn :is-show="scope.row.showMore" :buttons="buttons" :size="selectRows.size"/>
</template>
</el-table-column>
<el-table-column :label="$t('commons.name')" width="200" show-overflow-tooltip prop="name">

View File

@ -72,7 +72,7 @@
<ms-table-operator-button :tip="$t('api_test.automation.copy')"
icon="el-icon-document-copy" @exec="copy(row)"/>
<ms-table-operator-button :tip="$t('api_test.automation.remove')"
icon="el-icon-delete" @exec="remove(row)" type="danger" v-tester/>
icon="el-icon-delete" @exec="remove(row)" type="danger"/>
</template>
</el-table-column>
</el-table>

View File

@ -26,7 +26,7 @@
<ms-table-operator-button :tip="$t('commons.update')" icon="el-icon-edit"
type="primary" @exec="edit(row)"/>
<ms-table-operator-button :tip="$t('api_test.automation.remove')"
icon="el-icon-delete" @exec="remove(row)" type="danger" v-tester/>
icon="el-icon-delete" @exec="remove(row)" type="danger"/>
</template>
</el-table-column>
</el-table>

View File

@ -1,7 +1,7 @@
<template>
<el-input class="ms-search-bar" :placeholder="$t('test_track.module.search')" v-model="condition.filterText" size="small">
<template v-if="showOperator" v-slot:append>
<el-dropdown v-tester>
<el-dropdown>
<el-button type="primary">
<span class="tip-font">{{ $t('commons.more_operator') }}</span>
<i class="el-icon-arrow-down el-icon--right"/>

View File

@ -26,7 +26,7 @@
:resizable="false" align="center">
<template v-slot:default="scope">
<!-- 选中记录后浮现的按钮提供对记录的批量操作 -->
<show-more-btn :is-show="scope.row.showMore" :buttons="batchOperators" :size="selectDataCounts" v-tester/>
<show-more-btn :is-show="scope.row.showMore" :buttons="batchOperators" :size="selectDataCounts"/>
</template>
</el-table-column>

View File

@ -20,7 +20,7 @@
type="selection"/>
<el-table-column width="40" :resizable="false" align="center">
<template v-slot:default="scope">
<show-more-btn v-tester :is-show="scope.row.showMore" :buttons="buttons" :size="selectRows.size"/>
<show-more-btn :is-show="scope.row.showMore" :buttons="buttons" :size="selectRows.size"/>
</template>
</el-table-column>
<el-table-column

View File

@ -12,9 +12,15 @@
</el-input>
</el-col>
<el-col :span="12" :offset="2">
<el-link type="primary" style="margin-right: 20px" @click="openHis" v-if="test.id">{{$t('operating_log.change_history')}}</el-link>
<el-button :disabled="isReadOnly" type="primary" plain @click="save">{{ $t('commons.save') }}</el-button>
<el-button :disabled="isReadOnly" type="primary" plain @click="saveAndRun">
<el-link type="primary" style="margin-right: 20px" @click="openHis" v-if="test.id">
{{ $t('operating_log.change_history') }}
</el-link>
<el-button :disabled="isReadOnly" type="primary" plain @click="save"
v-permission="['PROJECT_PERFORMANCE:READ+RUN']"
>{{ $t('commons.save') }}
</el-button>
<el-button :disabled="isReadOnly" type="primary" plain @click="saveAndRun"
v-permission="['PROJECT_PERFORMANCE:READ+RUN']">
{{ $t('load_test.save_and_run') }}
</el-button>
<el-button :disabled="isReadOnly" type="warning" plain @click="cancel">{{ $t('commons.cancel') }}
@ -96,7 +102,7 @@ export default {
id: '2',
component: 'PerformanceAdvancedConfig'
}]
}
};
},
watch: {
'$route'(to) {
@ -129,7 +135,7 @@ export default {
this.importAPITest();
},
methods: {
openHis(){
openHis() {
this.$refs.changeHistory.open(this.test.id);
},
importAPITest() {
@ -179,7 +185,7 @@ export default {
this.result = this.$request(options, () => {
this.$success(this.$t('commons.save_success'));
this.$refs.advancedConfig.cancelAllEdit();
this.$router.push({path: '/performance/test/all'})
this.$router.push({path: '/performance/test/all'});
// 广 head
PerformanceEvent.$emit(LIST_CHANGE);
});
@ -196,10 +202,10 @@ export default {
this.$success(this.$t('commons.save_success'));
this.result = this.$post(this.runPath, {id: this.test.id, triggerMode: 'MANUAL'}, (response) => {
let reportId = response.data;
this.$router.push({path: '/performance/report/view/' + reportId})
this.$router.push({path: '/performance/report/view/' + reportId});
// 广 head
PerformanceEvent.$emit(LIST_CHANGE);
})
});
});
},
getSaveOption() {
@ -223,7 +229,7 @@ export default {
// filejson
let requestJson = JSON.stringify(this.test, function (key, value) {
return key === "file" ? undefined : value
return key === "file" ? undefined : value;
});
formData.append('request', new Blob([requestJson], {
@ -240,7 +246,7 @@ export default {
};
},
cancel() {
this.$router.push({path: '/performance/test/all'})
this.$router.push({path: '/performance/test/all'});
},
validTest() {
let currentProjectId = getCurrentProjectID();
@ -309,11 +315,11 @@ export default {
return {
pass: false,
info: this.$t('load_test.schedule_tip')
}
};
}
return {
pass: true
}
};
},
fileChange(threadGroups) {
let handler = this.$refs.pressureConfig;
@ -341,7 +347,7 @@ export default {
handler.calculateTotalChart();
}
}
}
};
</script>
<style scoped>

View File

@ -26,26 +26,26 @@
:right-tip="$t('test_track.case.minder')"
:right-content="$t('test_track.case.minder')"
:middle-button-enable="false">
<test-case-list
v-if="activeDom === 'left'"
:checkRedirectID="checkRedirectID"
:isRedirectEdit="isRedirectEdit"
:tree-nodes="treeNodes"
@testCaseEdit="editTestCase"
@testCaseCopy="copyTestCase"
@testCaseDetail="showTestCaseDetail"
@refresh="refresh"
@refreshAll="refreshAll"
@setCondition="setCondition"
:custom-num="custom_num"
ref="testCaseList">
</test-case-list>
<test-case-minder
:tree-nodes="treeNodes"
:project-id="projectId"
:condition="condition"
v-if="activeDom === 'right'"
ref="minder"/>
<test-case-list
v-if="activeDom === 'left'"
:checkRedirectID="checkRedirectID"
:isRedirectEdit="isRedirectEdit"
:tree-nodes="treeNodes"
@testCaseEdit="editTestCase"
@testCaseCopy="copyTestCase"
@testCaseDetail="showTestCaseDetail"
@refresh="refresh"
@refreshAll="refreshAll"
@setCondition="setCondition"
:custom-num="custom_num"
ref="testCaseList">
</test-case-list>
<test-case-minder
:tree-nodes="treeNodes"
:project-id="projectId"
:condition="condition"
v-if="activeDom === 'right'"
ref="minder"/>
</ms-tab-button>
</el-tab-pane>
<el-tab-pane
@ -73,10 +73,12 @@
</el-tab-pane>
<el-tab-pane name="add">
<template v-slot:label>
<el-dropdown @command="handleCommand" v-tester>
<el-button type="primary" plain icon="el-icon-plus" size="mini" v-tester/>
<el-dropdown @command="handleCommand">
<el-button type="primary" plain icon="el-icon-plus" size="mini"/>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="ADD">{{ $t('test_track.case.create') }}</el-dropdown-item>
<el-dropdown-item command="ADD" v-permission="['PROJECT_TRACK_CASE:READ+CREATE']">
{{ $t('test_track.case.create') }}
</el-dropdown-item>
<el-dropdown-item command="CLOSE_ALL">{{ $t('api_test.definition.request.close_all_label') }}
</el-dropdown-item>
</el-dropdown-menu>
@ -127,12 +129,12 @@ export default {
condition: {},
activeName: 'default',
tabs: [],
renderComponent:true,
renderComponent: true,
loading: false,
type:'',
type: '',
activeDom: 'left',
custom_num: false
}
};
},
mounted() {
this.getProject();
@ -174,7 +176,7 @@ export default {
},
projectId() {
return this.$store.state.projectId
return this.$store.state.projectId;
},
selectNodeIds() {
return this.$store.state.testCaseSelectNodeIds;
@ -221,7 +223,7 @@ export default {
let label = this.$t('test_track.case.create');
let name = getUUID().substring(0, 8);
this.activeName = name;
this.type='add'
this.type = 'add';
this.tabs.push({label: label, name: name, testCaseInfo: {testCaseModuleId: "", id: getUUID()}});
}
if (tab.name === 'edit') {
@ -249,15 +251,15 @@ export default {
this.activeName = this.tabs[this.tabs.length - 1].name;
this.addListener(); //
} else {
this.activeName = "default"
this.activeName = "default";
}
},
exportTestCase(){
exportTestCase() {
if (this.activeDom !== 'left') {
this.$warning('请切换成接口列表导出!');
return;
}
this.$refs.testCaseList.exportTestCase()
this.$refs.testCaseList.exportTestCase();
},
addListener() {
let index = this.tabs.findIndex(item => item.name === this.activeName); // tabindex
@ -284,7 +286,7 @@ export default {
if (caseId) {
this.$get('test/case/get/' + caseId, response => {
let testCase = response.data;
this.editTestCase(testCase)
this.editTestCase(testCase);
});
} else {
this.addTab({name: 'add'});
@ -296,7 +298,7 @@ export default {
this.activeName = "default";
},
refreshTable() {
if ( this.$refs.testCaseList) {
if (this.$refs.testCaseList) {
this.$refs.testCaseList.initTableData();
}
this.$refs.nodeTree.list();
@ -333,7 +335,7 @@ export default {
}
},
copyTestCase(testCase) {
this.type="copy"
this.type = "copy";
this.testCaseReadOnly = false;
testCase.isCopy = true;
this.addTab({name: 'edit', testCaseInfo: testCase});
@ -388,10 +390,10 @@ export default {
if (data) {
this.custom_num = data.customNum;
}
})
});
}
}
}
};
</script>
<style scoped>
@ -400,7 +402,7 @@ export default {
padding: 15px;
}
/deep/ .el-button-group>.el-button:first-child {
/deep/ .el-button-group > .el-button:first-child {
padding: 4px 1px !important;
}

View File

@ -5,21 +5,21 @@
<ms-table-header :is-tester-permission="true" :condition.sync="condition" @search="initTableData"
:tip="$t('commons.search_by_name_or_id')" title="" :show-create="false"/>
<el-table
border
:data="tableData"
@sort-change="sort"
@filter-change="filter"
@select-all="handleSelectAll"
@select="handleSelect"
@header-dragend="headerDragend"
@cell-mouse-enter="showPopover"
:height="screenHeight"
row-key="id"
class="test-content adjust-table ms-select-all-fixed"
ref="table" @row-click="handleEdit">
border
:data="tableData"
@sort-change="sort"
@filter-change="filter"
@select-all="handleSelectAll"
@select="handleSelect"
@header-dragend="headerDragend"
@cell-mouse-enter="showPopover"
:height="screenHeight"
row-key="id"
class="test-content adjust-table ms-select-all-fixed"
ref="table" @row-click="handleEdit">
<el-table-column
width="50"
type="selection"/>
width="50"
type="selection"/>
<ms-table-header-select-popover v-show="total>0"
:page-size="pageSize > total ? total : pageSize"
@ -36,59 +36,59 @@
<template v-for="(item, index) in tableLabel">
<el-table-column
v-if="item.id === 'num' && !customNum"
prop="num"
sortable="custom"
:label="$t('commons.id')"
:key="index"
min-width="80"
show-overflow-tooltip>
v-if="item.id === 'num' && !customNum"
prop="num"
sortable="custom"
:label="$t('commons.id')"
:key="index"
min-width="80"
show-overflow-tooltip>
</el-table-column>
<el-table-column
v-if="item.id === 'num' && customNum"
prop="customNum"
sortable="custom"
:label="$t('commons.id')"
:key="index"
min-width="80"
show-overflow-tooltip>
v-if="item.id === 'num' && customNum"
prop="customNum"
sortable="custom"
:label="$t('commons.id')"
:key="index"
min-width="80"
show-overflow-tooltip>
</el-table-column>
<el-table-column
v-if="item.id == 'name'"
prop="name"
:label="$t('commons.name')"
show-overflow-tooltip
:key="index"
min-width="120"
v-if="item.id == 'name'"
prop="name"
:label="$t('commons.name')"
show-overflow-tooltip
:key="index"
min-width="120"
>
</el-table-column>
<el-table-column
v-if="item.id == 'priority'"
prop="priority"
:filters="priorityFilters"
column-key="priority"
sortable="custom"
min-width="120px"
:label="$t('test_track.case.priority')"
show-overflow-tooltip
:key="index">
v-if="item.id == 'priority'"
prop="priority"
:filters="priorityFilters"
column-key="priority"
sortable="custom"
min-width="120px"
:label="$t('test_track.case.priority')"
show-overflow-tooltip
:key="index">
<template v-slot:default="scope">
<priority-table-item :value="scope.row.priority"/>
</template>
</el-table-column>
<el-table-column
v-if="item.id=='reviewStatus'"
column-key="reviewStatus"
min-width="100px"
:label="$t('test_track.case.status')"
:key="index">
v-if="item.id=='reviewStatus'"
column-key="reviewStatus"
min-width="100px"
:label="$t('test_track.case.status')"
:key="index">
<template v-slot:default="scope">
<span class="el-dropdown-link">
<review-status :value="scope.row.reviewStatus"/>
</span>
</template>
</el-table-column>
<el-table-column v-if="item.id=='tags'" prop="tags" :label="$t('commons.tag')" min-width="80" :key="index">
<el-table-column v-if="item.id=='tags'" prop="tags" :label="$t('commons.tag')" min-width="80" :key="index">
<template v-slot:default="scope">
<ms-tag v-for="(itemName,index) in scope.row.tags" :key="index" type="success" effect="plain"
:content="itemName" style="margin-left: 0px; margin-right: 2px"/>
@ -96,36 +96,38 @@
</el-table-column>
<el-table-column
v-if="item.id=='nodePath'"
prop="nodePath"
:label="$t('test_track.case.module')"
min-width="150px"
show-overflow-tooltip
:key="index">
v-if="item.id=='nodePath'"
prop="nodePath"
:label="$t('test_track.case.module')"
min-width="150px"
show-overflow-tooltip
:key="index">
</el-table-column>
<el-table-column
v-if="item.id=='updateTime'"
prop="updateTime"
sortable="custom"
:label="$t('commons.update_time')"
min-width="150px"
show-overflow-tooltip
:key="index">
v-if="item.id=='updateTime'"
prop="updateTime"
sortable="custom"
:label="$t('commons.update_time')"
min-width="150px"
show-overflow-tooltip
:key="index">
<template v-slot:default="scope">
<span>{{ scope.row.updateTime | timestampFormatDate }}</span>
</template>
</el-table-column>
</template>
<el-table-column fixed="right" min-width="120">
<el-table-column fixed="right" min-width="150">
<template slot="header">
<header-label-operate @exec="customHeader"/>
</template>
<template v-slot:default="scope">
<ms-table-operator :is-tester-permission="true" @editClick="handleEdit(scope.row)"
<ms-table-operator v-permission="['PROJECT_TRACK_CASE:READ+EDIT','PROJECT_TRACK_CASE:READ+DELETE']"
@editClick="handleEdit(scope.row)"
@deleteClick="handleDelete(scope.row)">
<template v-slot:middle>
<ms-table-operator-button :is-tester-permission="true" :tip="$t('commons.copy')"
<ms-table-operator-button v-permission="['PROJECT_TRACK_CASE:READ+COPY']"
:tip="$t('commons.copy')"
icon="el-icon-document-copy"
type="success" @exec="handleCopy(scope.row)"/>
</template>
@ -218,7 +220,7 @@ export default {
data() {
return {
type: TEST_CASE_LIST,
screenHeight: document.documentElement.clientHeight-310,
screenHeight: document.documentElement.clientHeight - 310,
headerItems: Track_Test_Case,
tableLabel: [],
result: {},
@ -259,11 +261,15 @@ export default {
showMore: false,
buttons: [
{
name: this.$t('test_track.case.batch_edit_case'), handleClick: this.handleBatchEdit
name: this.$t('test_track.case.batch_edit_case'),
handleClick: this.handleBatchEdit,
permissions: ['PROJECT_TRACK_CASE:READ+EDIT']
}, {
name: this.$t('test_track.case.batch_move_case'), handleClick: this.handleBatchMove
}, {
name: this.$t('test_track.case.batch_delete_case'), handleClick: this.handleDeleteBatch
name: this.$t('test_track.case.batch_delete_case'),
handleClick: this.handleDeleteBatch,
permissions: ['PROJECT_TRACK_CASE:READ+DELETE']
}
],
typeArr: [
@ -293,7 +299,7 @@ export default {
currentCaseId: null,
selectDataCounts: 0,
selectDataRange: "all"
}
};
},
props: {
treeNodes: {
@ -423,14 +429,14 @@ export default {
})*/
this.tableData.forEach((item) => {
item.tags = JSON.parse(item.tags);
})
});
this.$nextTick(() => {
if (this.$refs.table) {
setTimeout(this.$refs.table.doLayout, 200);
}
this.checkTableRowIsSelect();
})
});
});
}
},
@ -454,7 +460,7 @@ export default {
this.selectRows.delete(row);
}
}
})
});
}
},
search() {
@ -475,7 +481,7 @@ export default {
handleCopy(testCase) {
this.$get('test/case/get/' + testCase.id, response => {
let testCase = response.data;
testCase.name = 'copy_' + testCase.name
testCase.name = 'copy_' + testCase.name;
this.$emit('testCaseCopy', testCase);
});
},
@ -569,7 +575,7 @@ export default {
aTag.download = filename;
aTag.href = URL.createObjectURL(blob);
aTag.click();
URL.revokeObjectURL(aTag.href)
URL.revokeObjectURL(aTag.href);
} else {
navigator.msSaveBlob(blob, filename);
}
@ -664,7 +670,7 @@ export default {
});
}
}
}
};
</script>
<style scoped>

View File

@ -59,15 +59,20 @@ export default {
operators: [
{
label: this.$t('test_track.case.create'),
callback: this.addTestCase
callback: this.addTestCase,
permissions: ['PROJECT_TRACK_CASE:READ+CREATE']
},
{
label: this.$t('api_test.api_import.label'),
callback: this.handleImport
callback: this.handleImport,
permissions: ['PROJECT_TRACK_CASE:READ+IMPORT']
},
{
label: this.$t('api_test.export_config'),
callback: () => {this.$emit('exportTestCase')}
callback: () => {
this.$emit('exportTestCase');
},
permissions: ['PROJECT_TRACK_CASE:READ+EXPORT']
}
]
};

View File

@ -9,7 +9,7 @@
<el-menu-item :index="'/track/home'">
{{ $t("i18n.home") }}
</el-menu-item>
<el-menu-item :index="'/track/case/all'" v-permission="['test_manager','test_user','test_viewer']">
<el-menu-item :index="'/track/case/all'" v-permission="['PROJECT_TRACK_CASE:READ']">
{{ $t("test_track.case.test_case") }}
</el-menu-item>
<!--

View File

@ -19,7 +19,7 @@
<el-col :span="18">
<el-input :disabled="isReadOnly" v-model="form.cronValue" class="inp"
:placeholder="$t('schedule.please_input_cron_expression')"/>
<el-button :disabled="isReadOnly" type="primary" @click="saveCron" v-tester>{{
<el-button :disabled="isReadOnly" type="primary" @click="saveCron">{{
$t('commons.save')
}}
</el-button>

View File

@ -1,7 +1,7 @@
<template>
<el-card class="table-card" v-loading="result.loading">
<template v-slot:header>
<ms-table-header :is-tester-permission="true" :condition.sync="condition"
<ms-table-header v-permission="['PROJECT_TRACK_PLAN:READ+CREATE']" :condition.sync="condition"
@search="initTableData" @create="testPlanCreate"
:create-tip="$t('test_track.plan.create_plan')"
:title="$t('test_track.plan.test_plan')"
@ -163,30 +163,34 @@
</el-table-column>
</template>
<el-table-column
min-width="150"
min-width="180"
:label="$t('commons.operating')">
<template slot="header">
<header-label-operate @exec="customHeader"/>
</template>
<template v-slot:default="scope">
<ms-table-operator :is-tester-permission="true" @editClick="handleEdit(scope.row)"
<ms-table-operator v-permission="['PROJECT_TRACK_PLAN:READ+EDIT', 'PROJECT_TRACK_PLAN:READ+DELETE']"
@editClick="handleEdit(scope.row)"
@deleteClick="handleDelete(scope.row)">
<template v-slot:middle>
<ms-table-operator-button :isTesterPermission="true"
<ms-table-operator-button v-permission="['PROJECT_TRACK_PLAN:READ+EDIT']"
style="background-color: #85888E;border-color: #85888E"
v-if="!scope.row.reportId"
:tip="$t('test_track.plan_view.create_report')" icon="el-icon-s-data"
@exec="openTestReportTemplate(scope.row)"/>
<ms-table-operator-button v-if="scope.row.reportId"
v-permission="['PROJECT_TRACK_PLAN:READ+EDIT']"
:tip="$t('test_track.plan_view.view_report')" icon="el-icon-s-data"
@exec="openReport(scope.row.id, scope.row.reportId)"/>
</template>
</ms-table-operator>
<ms-table-operator-button style="margin-left: 10px;color:#85888E;border-color: #85888E; border-width: thin;"
v-permission="['PROJECT_TRACK_PLAN:READ+SCHEDULE']"
v-if="!scope.row.scheduleOpen" type="text"
:tip="$t('commons.trigger_mode.schedule')" icon="el-icon-time"
@exec="scheduleTask(scope.row)"/>
<ms-table-operator-button style="margin-left: 10px;color:#6C317C; border-color: #6C317C; border-width: thin;"
v-permission="['PROJECT_TRACK_PLAN:READ+SCHEDULE']"
v-if="scope.row.scheduleOpen" type="text"
:tip="$t('commons.trigger_mode.schedule')" icon="el-icon-time"
@exec="scheduleTask(scope.row)"/>

View File

@ -3,13 +3,13 @@
<el-card class="card-content" v-loading="result.loading">
<template v-slot:header>
<test-plan-case-list-header
:project-id="getProjectId()"
:condition="condition"
:plan-id="planId"
@refresh="initTable"
@relevanceCase="$emit('relevanceCase')"
@setEnvironment="setEnvironment"
v-if="isPlanModel"/>
:project-id="getProjectId()"
:condition="condition"
:plan-id="planId"
@refresh="initTable"
@relevanceCase="$emit('relevanceCase')"
@setEnvironment="setEnvironment"
v-if="isPlanModel"/>
</template>
<el-table v-loading="result.loading" ref="table"
@ -38,57 +38,57 @@
:label="$t('api_test.definition.api_name')" show-overflow-tooltip :key="index"/>
<el-table-column
v-if="item.id == 'priority'"
prop="priority"
:filters="priorityFilters"
sortable="custom"
column-key="priority"
:label="$t('test_track.case.priority')"
show-overflow-tooltip
min-width="120"
:key="index">
v-if="item.id == 'priority'"
prop="priority"
:filters="priorityFilters"
sortable="custom"
column-key="priority"
:label="$t('test_track.case.priority')"
show-overflow-tooltip
min-width="120"
:key="index">
<template v-slot:default="scope">
<priority-table-item :value="scope.row.priority"/>
</template>
</el-table-column>
<el-table-column
v-if="item.id == 'path'"
min-width="100"
prop="path"
:label="$t('api_test.definition.api_path')"
show-overflow-tooltip
:key="index"/>
v-if="item.id == 'path'"
min-width="100"
prop="path"
:label="$t('api_test.definition.api_path')"
show-overflow-tooltip
:key="index"/>
<el-table-column
v-if="item.id == 'createUser'"
prop="createUser"
column-key="user_id"
sortable="custom"
min-width="100"
:filters="userFilters"
:label="'创建人'"
show-overflow-tooltip
:key="index"/>
v-if="item.id == 'createUser'"
prop="createUser"
column-key="user_id"
sortable="custom"
min-width="100"
:filters="userFilters"
:label="'创建人'"
show-overflow-tooltip
:key="index"/>
<el-table-column
v-if="item.id == 'custom'"
sortable="custom"
min-width="160"
:label="$t('api_test.definition.api_last_time')"
prop="updateTime"
:key="index">
v-if="item.id == 'custom'"
sortable="custom"
min-width="160"
:label="$t('api_test.definition.api_last_time')"
prop="updateTime"
:key="index">
<template v-slot:default="scope">
<span>{{ scope.row.updateTime | timestampFormatDate }}</span>
</template>
</el-table-column>
<el-table-column
v-if="item.id == 'tags'"
prop="tags"
min-width="100"
:label="$t('commons.tag')"
:key="index">
v-if="item.id == 'tags'"
prop="tags"
min-width="100"
:label="$t('commons.tag')"
:key="index">
<template v-slot:default="scope">
<ms-tag v-for="(itemName,index) in scope.row.tags" :key="index" type="success" effect="plain"
:content="itemName" style="margin-left: 0px; margin-right: 2px"/>
@ -120,11 +120,13 @@
<header-label-operate @exec="customHeader"/>
</template>
<template v-slot:default="scope">
<ms-table-operator-button class="run-button" :is-tester-permission="true" :tip="$t('api_test.run')"
<ms-table-operator-button class="run-button" v-permission="['PROJECT_API_DEFINITION:READ+RUN']"
:tip="$t('api_test.run')"
icon="el-icon-video-play"
@exec="singleRun(scope.row)" v-tester/>
<ms-table-operator-button :is-tester-permission="true" :tip="$t('test_track.plan_view.cancel_relevance')"
icon="el-icon-unlock" type="danger" @exec="handleDelete(scope.row)" v-tester/>
@exec="singleRun(scope.row)"/>
<ms-table-operator-button v-permission="['PROJECT_TRACK_PLAN:READ+RELEVANCE_OR_CANCEL']"
:tip="$t('test_track.plan_view.cancel_relevance')"
icon="el-icon-unlock" type="danger" @exec="handleDelete(scope.row)"/>
</template>
</el-table-column>

View File

@ -79,11 +79,14 @@
<header-label-operate @exec="customHeader"/>
</template>
<template v-slot:default="{row}">
<ms-table-operator-button class="run-button" :is-tester-permission="true" :tip="$t('api_test.run')"
<ms-table-operator-button class="run-button"
v-permission="['PROJECT_API_SCENARIO:READ+RUN']"
:tip="$t('api_test.run')"
icon="el-icon-video-play"
@exec="execute(row)" v-tester/>
<ms-table-operator-button :is-tester-permission="true" :tip="$t('test_track.plan_view.cancel_relevance')"
icon="el-icon-unlock" type="danger" @exec="remove(row)" v-tester/>
@exec="execute(row)"/>
<ms-table-operator-button v-permission="['PROJECT_TRACK_PLAN:READ+RELEVANCE_OR_CANCEL']"
:tip="$t('test_track.plan_view.cancel_relevance')"
icon="el-icon-unlock" type="danger" @exec="remove(row)"/>
</template>
</el-table-column>
</el-table>

View File

@ -1,14 +1,14 @@
<template>
<ms-table-header :is-tester-permission="true"
:condition="condition"
@search="$emit('refresh')"
:show-create="false"
:tip="$t('commons.search_by_id_name_tag')">
<ms-table-header
:condition="condition"
@search="$emit('refresh')"
:show-create="false"
:tip="$t('commons.search_by_id_name_tag')">
<template v-slot:title>
{{ $t('api_test.home_page.failed_case_list.table_value.case_type.api') }}
</template>
<template v-slot:button>
<ms-table-button :is-tester-permission="true" icon="el-icon-connection"
<ms-table-button v-permission="['PROJECT_TRACK_PLAN:READ+RELEVANCE_OR_CANCEL']" icon="el-icon-connection"
:content="$t('test_track.plan_view.relevance_test_case')"
@click="$emit('relevanceCase')"/>
</template>
@ -17,32 +17,33 @@
</template>
<script>
import MsTableHeader from "../../../../../common/components/MsTableHeader";
import MsTableButton from "../../../../../common/components/MsTableButton";
import MsEnvironmentSelect from "../../../../../api/definition/components/case/MsEnvironmentSelect";
export default {
name: "TestPlanCaseListHeader",
components: {MsEnvironmentSelect, MsTableButton, MsTableHeader},
props: ['condition', 'projectId', 'isReadOnly', 'planId'],
methods: {
setEnvironment(data) {
if (this.planId) {
let param = {};
param.id = this.planId;
param.environmentId = data.id;
this.$post('/test/plan/edit', param, () => {
this.$emit('setEnvironment', data);
});
}
}
import MsTableHeader from "../../../../../common/components/MsTableHeader";
import MsTableButton from "../../../../../common/components/MsTableButton";
import MsEnvironmentSelect from "../../../../../api/definition/components/case/MsEnvironmentSelect";
export default {
name: "TestPlanCaseListHeader",
components: {MsEnvironmentSelect, MsTableButton, MsTableHeader},
props: ['condition', 'projectId', 'isReadOnly', 'planId'],
methods: {
setEnvironment(data) {
if (this.planId) {
let param = {};
param.id = this.planId;
param.environmentId = data.id;
this.$post('/test/plan/edit', param, () => {
this.$emit('setEnvironment', data);
});
}
}
}
};
</script>
<style scoped>
/deep/ .environment-select {
margin-right: 10px;
}
/deep/ .environment-select {
margin-right: 10px;
}
</style>

View File

@ -1,14 +1,14 @@
<template>
<ms-table-header :is-tester-permission="true"
:condition="condition"
@search="$emit('refresh')"
:show-create="false"
:tip="$t('commons.search_by_id_name_tag')">
<ms-table-header
:condition="condition"
@search="$emit('refresh')"
:show-create="false"
:tip="$t('commons.search_by_id_name_tag')">
<template v-slot:title>
场景用例
场景用例
</template>
<template v-slot:button>
<ms-table-button :is-tester-permission="true" icon="el-icon-connection"
<ms-table-button v-permission="['PROJECT_TRACK_PLAN:READ+RELEVANCE_OR_CANCEL']" icon="el-icon-connection"
:content="$t('test_track.plan_view.relevance_test_case')"
@click="$emit('relevanceCase')"/>
</template>
@ -17,22 +17,22 @@
</template>
<script>
import MsTableHeader from "../../../../../common/components/MsTableHeader";
import MsTableButton from "../../../../../common/components/MsTableButton";
import MsEnvironmentSelect from "../../../../../api/definition/components/case/MsEnvironmentSelect";
export default {
name: "TestPlanScenarioListHeader",
components: {MsEnvironmentSelect, MsTableButton, MsTableHeader},
props: ['condition', 'isReadOnly'],
methods: {
}
}
import MsTableHeader from "../../../../../common/components/MsTableHeader";
import MsTableButton from "../../../../../common/components/MsTableButton";
import MsEnvironmentSelect from "../../../../../api/definition/components/case/MsEnvironmentSelect";
export default {
name: "TestPlanScenarioListHeader",
components: {MsEnvironmentSelect, MsTableButton, MsTableHeader},
props: ['condition', 'isReadOnly'],
methods: {}
};
</script>
<style scoped>
/deep/ .environment-select {
margin-right: 10px;
}
/deep/ .environment-select {
margin-right: 10px;
}
</style>

View File

@ -9,11 +9,11 @@
</template>
<template v-slot:button>
<ms-table-button :is-tester-permission="true" v-if="!showMyTestCase" icon="el-icon-s-custom"
<ms-table-button v-permission="['PROJECT_TRACK_CASE:READ']" v-if="!showMyTestCase" icon="el-icon-s-custom"
:content="$t('test_track.plan_view.my_case')" @click="searchMyTestCase"/>
<ms-table-button :is-tester-permission="true" v-if="showMyTestCase" icon="el-icon-files"
<ms-table-button v-permission="['PROJECT_TRACK_CASE:READ']" v-if="showMyTestCase" icon="el-icon-files"
:content="$t('test_track.plan_view.all_case')" @click="searchMyTestCase"/>
<ms-table-button :is-tester-permission="true" icon="el-icon-connection"
<ms-table-button v-permission="['PROJECT_TRACK_PLAN:READ+RELEVANCE_OR_CANCEL']" icon="el-icon-connection"
:content="$t('test_track.plan_view.relevance_test_case')"
@click="$emit('openTestCaseRelevanceDialog')"/>
</template>
@ -235,9 +235,11 @@
<header-label-operate @exec="customHeader"/>
</template>
<template v-slot:default="scope">
<ms-table-operator-button :is-tester-permission="true" :tip="$t('commons.edit')" icon="el-icon-edit"
<ms-table-operator-button v-permission="['PROJECT_TRACK_CASE:READ+EDIT']" :tip="$t('commons.edit')"
icon="el-icon-edit"
@exec="handleEdit(scope.row)"/>
<ms-table-operator-button :is-tester-permission="true" :tip="$t('test_track.plan_view.cancel_relevance')"
<ms-table-operator-button v-permission="['PROJECT_TRACK_PLAN:READ+RELEVANCE_OR_CANCEL']"
:tip="$t('test_track.plan_view.cancel_relevance')"
icon="el-icon-unlock" type="danger" @exec="handleDelete(scope.row)"/>
</template>
</el-table-column>

View File

@ -16,15 +16,15 @@
:right-tip="$t('test_track.case.minder')"
:right-content="$t('test_track.case.minder')"
:middle-button-enable="false">
<functional-test-case-list
class="table-list"
v-if="activeDom === 'left'"
@openTestCaseRelevanceDialog="openTestCaseRelevanceDialog"
@refresh="refresh"
:plan-id="planId"
:clickType="clickType"
:select-node-ids="selectNodeIds"
ref="testPlanTestCaseList"/>
<functional-test-case-list
class="table-list"
v-if="activeDom === 'left'"
@openTestCaseRelevanceDialog="openTestCaseRelevanceDialog"
@refresh="refresh"
:plan-id="planId"
:clickType="clickType"
:select-node-ids="selectNodeIds"
ref="testPlanTestCaseList"/>
<test-plan-minder
:tree-nodes="treeNodes"
:project-id="projectId"
@ -43,111 +43,111 @@
</template>
<script>
import NodeTree from "../../../../common/NodeTree";
import TestCaseRelevance from "./TestCaseFunctionalRelevance";
import MsTestPlanCommonComponent from "../base/TestPlanCommonComponent";
import TestCaseFunctionalRelevance from "./TestCaseFunctionalRelevance";
import FunctionalTestCaseList from "./FunctionalTestCaseList";
import MsTabButton from "@/business/components/common/components/MsTabButton";
import TestPlanMinder from "@/business/components/track/common/minder/TestPlanMinder";
import NodeTree from "../../../../common/NodeTree";
import TestCaseRelevance from "./TestCaseFunctionalRelevance";
import TestCaseFunctionalRelevance from "./TestCaseFunctionalRelevance";
import MsTestPlanCommonComponent from "../base/TestPlanCommonComponent";
import FunctionalTestCaseList from "./FunctionalTestCaseList";
import MsTabButton from "@/business/components/common/components/MsTabButton";
import TestPlanMinder from "@/business/components/track/common/minder/TestPlanMinder";
export default {
name: "TestPlanFunctional",
components: {
TestPlanMinder,
MsTabButton,
FunctionalTestCaseList,
TestCaseFunctionalRelevance,
MsTestPlanCommonComponent,
TestCaseRelevance,
NodeTree,
},
data() {
return {
result: {},
selectNodeIds: [],
treeNodes: [],
activeDom: 'left',
selectNode: {}
}
},
props: [
'planId',
'redirectCharType',
'clickType'
],
mounted() {
this.initData();
},
computed: {
projectId() {
return this.$store.state.projectId
},
},
activated(){
this.initData();
this.openTestCaseEdit(this.$route.path);
},
watch: {
'$route'(to, from) {
this.openTestCaseEdit(to.path);
},
planId() {
this.initData();
}
},
methods: {
refresh() {
this.selectNodeIds = [];
this.$store.commit('setTestPlanViewSelectNode', {});
this.$refs.testCaseRelevance.search();
this.getNodeTreeByPlanId();
},
initData() {
this.getNodeTreeByPlanId();
},
openTestCaseRelevanceDialog() {
this.$refs.testCaseRelevance.open();
},
nodeChange(node, nodeIds, pNodes) {
this.selectNodeIds = nodeIds;
this.$store.commit('setTestPlanViewSelectNode', node);
// node
if (this.$refs.testPlanTestCaseList) {
this.$refs.testPlanTestCaseList.currentPage = 1;
this.$refs.testPlanTestCaseList.pageSize = 10;
}
},
getNodeTreeByPlanId() {
if (this.planId) {
let url = "/case/node/list/plan/" + this.planId;
if(this.clickType){
url = url+"/"+this.clickType;
}
this.result = this.$get(url, response => {
this.treeNodes = response.data;
});
}
},
openTestCaseEdit(path) {
if (path.indexOf("/plan/view/edit") >= 0) {
let caseId = this.$route.params.caseId;
this.$get('/test/plan/case/get/' + caseId, response => {
let testCase = response.data;
if (testCase) {
this.$refs.testPlanTestCaseList.handleEdit(testCase);
this.$router.push('/track/plan/view/' + testCase.planId);
}
});
}
},
}
export default {
name: "TestPlanFunctional",
components: {
TestPlanMinder,
MsTabButton,
FunctionalTestCaseList,
TestCaseFunctionalRelevance,
MsTestPlanCommonComponent,
TestCaseRelevance,
NodeTree,
},
data() {
return {
result: {},
selectNodeIds: [],
treeNodes: [],
activeDom: 'left',
selectNode: {}
};
},
props: [
'planId',
'redirectCharType',
'clickType'
],
mounted() {
this.initData();
},
computed: {
projectId() {
return this.$store.state.projectId;
},
},
activated() {
this.initData();
this.openTestCaseEdit(this.$route.path);
},
watch: {
'$route'(to, from) {
this.openTestCaseEdit(to.path);
},
planId() {
this.initData();
}
},
methods: {
refresh() {
this.selectNodeIds = [];
this.$store.commit('setTestPlanViewSelectNode', {});
this.$refs.testCaseRelevance.search();
this.getNodeTreeByPlanId();
},
initData() {
this.getNodeTreeByPlanId();
},
openTestCaseRelevanceDialog() {
this.$refs.testCaseRelevance.open();
},
nodeChange(node, nodeIds, pNodes) {
this.selectNodeIds = nodeIds;
this.$store.commit('setTestPlanViewSelectNode', node);
// node
if (this.$refs.testPlanTestCaseList) {
this.$refs.testPlanTestCaseList.currentPage = 1;
this.$refs.testPlanTestCaseList.pageSize = 10;
}
},
getNodeTreeByPlanId() {
if (this.planId) {
let url = "/case/node/list/plan/" + this.planId;
if (this.clickType) {
url = url + "/" + this.clickType;
}
this.result = this.$get(url, response => {
this.treeNodes = response.data;
});
}
},
openTestCaseEdit(path) {
if (path.indexOf("/plan/view/edit") >= 0) {
let caseId = this.$route.params.caseId;
this.$get('/test/plan/case/get/' + caseId, response => {
let testCase = response.data;
if (testCase) {
this.$refs.testPlanTestCaseList.handleEdit(testCase);
this.$router.push('/track/plan/view/' + testCase.planId);
}
});
}
},
}
};
</script>
<style scoped>
/deep/ .el-button-group>.el-button:first-child {
/deep/ .el-button-group > .el-button:first-child {
padding: 4px 1px !important;
}
</style>

View File

@ -117,11 +117,14 @@
<header-label-operate @exec="customHeader"/>
</template>
<template v-slot:default="scope">
<ms-table-operator-button class="run-button" :is-tester-permission="true" :tip="$t('api_test.run')"
<ms-table-operator-button class="run-button"
v-permission="['PROJECT_PERFORMANCE:READ+RUN']"
:tip="$t('api_test.run')"
icon="el-icon-video-play"
@exec="run(scope.row)" v-tester/>
<ms-table-operator-button :is-tester-permission="true" :tip="$t('test_track.plan_view.cancel_relevance')"
icon="el-icon-unlock" type="danger" @exec="handleDelete(scope.row)" v-tester/>
@exec="run(scope.row)"/>
<ms-table-operator-button v-permission="['PROJECT_TRACK_PLAN:READ+RELEVANCE_OR_CANCEL']"
:tip="$t('test_track.plan_view.cancel_relevance')"
icon="el-icon-unlock" type="danger" @exec="handleDelete(scope.row)"/>
</template>
</el-table-column>
</el-table>

View File

@ -1,14 +1,14 @@
<template>
<ms-table-header :is-tester-permission="true"
:condition="condition"
@search="$emit('refresh')"
:show-create="false"
:tip="$t('commons.search_by_name_or_id')">
<ms-table-header
:condition="condition"
@search="$emit('refresh')"
:show-create="false"
:tip="$t('commons.search_by_name_or_id')">
<template v-slot:title>
{{ $t('test_track.plan.load_case.case') }}
</template>
<template v-slot:button>
<ms-table-button :is-tester-permission="true" icon="el-icon-connection"
<ms-table-button v-permission="['PROJECT_TRACK_PLAN:READ+RELEVANCE_OR_CANCEL']" icon="el-icon-connection"
:content="$t('test_track.plan_view.relevance_test_case')"
@click="$emit('relevanceCase')"/>
</template>
@ -24,7 +24,7 @@ export default {
name: "TestPlanLoadCaseListHeader",
components: {MsTableButton, MsTableHeader},
props: ['condition'],
}
};
</script>
<style scoped>

View File

@ -22,7 +22,7 @@
<el-table-column width="30" :resizable="false" align="center">
<template v-slot:default="scope">
<show-more-btn :is-show="scope.row.showMore" :buttons="buttons" :size="selectDataCounts" v-tester/>
<show-more-btn :is-show="scope.row.showMore" :buttons="buttons" :size="selectDataCounts"/>
</template>
</el-table-column>
@ -51,7 +51,7 @@
<ms-table-operator-button :tip="$t('test_track.plan_view.view_report')" icon="el-icon-document"
@exec="openReport(scope.row.id)"/>
<ms-table-operator-button type="danger" :tip="$t('commons.delete')" icon="el-icon-delete"
@exec="handleDelete(scope.row)" v-tester/>
@exec="handleDelete(scope.row)"/>
</template>
</el-table-column>
</el-table>

View File

@ -1,7 +1,7 @@
<template>
<el-card class="table-card" v-loading="result.loading">
<template v-slot:header>
<ms-table-header :is-tester-permission="true" :condition.sync="condition"
<ms-table-header v-permission="['PROJECT_TRACK_REVIEW:READ+CREATE']" :condition.sync="condition"
@search="initTableData" @create="testCaseReviewCreate"
:create-tip="$t('test_track.review.create_review')"
:title="$t('test_track.review.test_review')"/>
@ -94,7 +94,8 @@
<header-label-operate @exec="customHeader"/>
</template>
<template v-slot:default="scope">
<ms-table-operator :is-tester-permission="true" @editClick="handleEdit(scope.row)"
<ms-table-operator v-permission="['PROJECT_TRACK_REVIEW:READ+EDIT', 'PROJECT_TRACK_REVIEW:READ+DELETE']"
@editClick="handleEdit(scope.row)"
@deleteClick="handleDelete(scope.row)">
</ms-table-operator>
</template>
@ -118,14 +119,11 @@ import MsDialogFooter from "../../../common/components/MsDialogFooter";
import MsTableHeader from "../../../common/components/MsTableHeader";
import MsCreateBox from "../../../settings/CreateBox";
import MsTablePagination from "../../../common/pagination/TablePagination";
import {
checkoutTestManagerOrTestUser,
getCurrentWorkspaceId
} from "../../../../../common/js/utils";
import {checkoutTestManagerOrTestUser, getCurrentWorkspaceId} from "@/common/js/utils";
import {_filter, _sort, getLabel} from "@/common/js/tableUtils";
import PlanStatusTableItem from "../../common/tableItems/plan/PlanStatusTableItem";
import {Test_Case_Review} from "@/business/components/common/model/JsonData";
import {TEST_CASE_LIST, TEST_CASE_REVIEW_LIST} from "@/common/js/constants";
import {TEST_CASE_REVIEW_LIST} from "@/common/js/constants";
import HeaderCustom from "@/business/components/common/head/HeaderCustom";
import HeaderLabelOperate from "@/business/components/common/head/HeaderLabelOperate";
import MsTag from "@/business/components/common/components/MsTag";
@ -162,7 +160,7 @@ export default {
{text: this.$t('test_track.plan.plan_status_running'), value: 'Underway'},
{text: this.$t('test_track.plan.plan_status_completed'), value: 'Completed'}
],
}
};
},
watch: {
'$route'(to) {
@ -177,12 +175,12 @@ export default {
},
computed: {
projectId() {
return this.$store.state.projectId
return this.$store.state.projectId;
},
},
methods: {
customHeader() {
this.$refs.headerCustom.open(this.tableLabel)
this.$refs.headerCustom.open(this.tableLabel);
},
initTableData() {
@ -200,7 +198,7 @@ export default {
if (item.tags && item.tags.length > 0) {
item.tags = JSON.parse(item.tags);
}
})
});
for (let i = 0; i < this.tableData.length; i++) {
let path = "/test/case/review/project";
this.$post(path, {id: this.tableData[i].id}, res => {
@ -214,7 +212,7 @@ export default {
let userIds = arr.map(data => data.id);
this.$set(this.tableData[i], "reviewer", reviewer);
this.$set(this.tableData[i], "userIds", userIds);
})
});
}
});
getLabel(this, TEST_CASE_REVIEW_LIST);
@ -254,7 +252,7 @@ export default {
this.initTableData();
},
}
}
};
</script>
<style scoped>

View File

@ -3,9 +3,9 @@
<ms-table-header :tester-permission="true" :condition.sync="condition" @search="initTableData"
:show-create="false" :tip="$t('commons.search_by_name_or_id')">
<template v-slot:button>
<ms-table-button :is-tester-permission="true" icon="el-icon-video-play"
<ms-table-button v-permission="['PROJECT_TRACK_REVIEW:READ+REVIEW']" icon="el-icon-video-play"
:content="$t('test_track.review_view.start_review')" @click="startReview"/>
<ms-table-button :is-tester-permission="true" icon="el-icon-connection"
<ms-table-button v-permission="['PROJECT_TRACK_REVIEW:READ+RELEVANCE_OR_CANCEL']" icon="el-icon-connection"
:content="$t('test_track.review_view.relevance_case')"
@click="$emit('openTestReviewRelevanceDialog')"/>
</template>
@ -16,19 +16,19 @@
<status-edit ref="statusEdit" :plan-id="reviewId"
:select-ids="new Set(Array.from(this.selectRows).map(row => row.id))" @refresh="initTableData"/>
<el-table
v-loading="result.loading"
class="test-content adjust-table ms-select-all-fixed"
border
@select-all="handleSelectAll"
@filter-change="filter"
@sort-change="sort"
@select="handleSelectionChange"
row-key="id"
:height="screenHeight"
style="margin-top: 5px"
@row-click="showDetail"
ref="caseTable"
:data="tableData">
v-loading="result.loading"
class="test-content adjust-table ms-select-all-fixed"
border
@select-all="handleSelectAll"
@filter-change="filter"
@sort-change="sort"
@select="handleSelectionChange"
row-key="id"
:height="screenHeight"
style="margin-top: 5px"
@row-click="showDetail"
ref="caseTable"
:data="tableData">
<el-table-column width="50" type="selection"/>
@ -45,88 +45,88 @@
</el-table-column>
<template v-for="(item, index) in tableLabel">
<el-table-column
v-if="item.id == 'num'"
prop="customNum"
sortable="custom"
min-width="100"
:label="$t('commons.id')"
show-overflow-tooltip
:key="index"
v-if="item.id == 'num'"
prop="customNum"
sortable="custom"
min-width="100"
:label="$t('commons.id')"
show-overflow-tooltip
:key="index"
>
</el-table-column>
<el-table-column
v-if="item.id == 'name'"
prop="name"
min-width="100"
:label="$t('commons.name')"
show-overflow-tooltip
:key="index"
v-if="item.id == 'name'"
prop="name"
min-width="100"
:label="$t('commons.name')"
show-overflow-tooltip
:key="index"
>
</el-table-column>
<el-table-column
v-if="item.id == 'priority'"
prop="priority"
:filters="priorityFilters"
column-key="priority"
sortable="custom"
min-width="120px"
:label="$t('test_track.case.priority')"
:key="index">
v-if="item.id == 'priority'"
prop="priority"
:filters="priorityFilters"
column-key="priority"
sortable="custom"
min-width="120px"
:label="$t('test_track.case.priority')"
:key="index">
<template v-slot:default="scope">
<priority-table-item :value="scope.row.priority" ref="priority"/>
</template>
</el-table-column>
<el-table-column
v-if="item.id == 'type'"
prop="type"
:filters="typeFilters"
column-key="type"
min-width="100"
:label="$t('test_track.case.type')"
show-overflow-tooltip
:key="index">
v-if="item.id == 'type'"
prop="type"
:filters="typeFilters"
column-key="type"
min-width="100"
:label="$t('test_track.case.type')"
show-overflow-tooltip
:key="index">
<template v-slot:default="scope">
<type-table-item :value="scope.row.type"/>
</template>
</el-table-column>
<el-table-column
v-if="item.id=='nodePath'"
prop="nodePath"
min-width="180"
:label="$t('test_track.case.module')"
show-overflow-tooltip
:key="index"
v-if="item.id=='nodePath'"
prop="nodePath"
min-width="180"
:label="$t('test_track.case.module')"
show-overflow-tooltip
:key="index"
>
</el-table-column>
<el-table-column
v-if="item.id=='projectName'"
prop="projectName"
min-width="180"
:label="$t('test_track.review.review_project')"
show-overflow-tooltip
:key="index">
v-if="item.id=='projectName'"
prop="projectName"
min-width="180"
:label="$t('test_track.review.review_project')"
show-overflow-tooltip
:key="index">
</el-table-column>
<el-table-column
v-if="item.id=='reviewerName'"
prop="reviewerName"
min-width="80"
:label="$t('test_track.review.reviewer')"
show-overflow-tooltip
:key="index"
v-if="item.id=='reviewerName'"
prop="reviewerName"
min-width="80"
:label="$t('test_track.review.reviewer')"
show-overflow-tooltip
:key="index"
>
</el-table-column>
<el-table-column
v-if="item.id=='reviewStatus'"
:filters="statusFilters"
column-key="status"
min-width="100"
:label="$t('test_track.review_view.execute_result')"
:key="index">
v-if="item.id=='reviewStatus'"
:filters="statusFilters"
column-key="status"
min-width="100"
:label="$t('test_track.review_view.execute_result')"
:key="index">
<template v-slot:default="scope">
<span class="el-dropdown-link">
<review-status :value="scope.row.reviewStatus"/>
@ -135,30 +135,32 @@
</el-table-column>
<el-table-column
v-if="item.id=='updateTime'"
sortable
prop="updateTime"
:label="$t('commons.update_time')"
show-overflow-tooltip
min-width="120"
:key="index">
v-if="item.id=='updateTime'"
sortable
prop="updateTime"
:label="$t('commons.update_time')"
show-overflow-tooltip
min-width="120"
:key="index">
<template v-slot:default="scope">
<span>{{ scope.row.updateTime | timestampFormatDate }}</span>
</template>
</el-table-column>
</template>
<el-table-column
min-width="100"
fixed="right"
:label="$t('commons.operating')"
min-width="100"
fixed="right"
:label="$t('commons.operating')"
>
<template slot="header">
<header-label-operate @exec="customHeader"/>
</template>
<template v-slot:default="scope">
<ms-table-operator-button :is-tester-permission="true" :tip="$t('commons.edit')" icon="el-icon-edit"
<ms-table-operator-button v-permission="['PROJECT_TRACK_CASE:READ+EDIT']" :tip="$t('commons.edit')"
icon="el-icon-edit"
@exec="handleEdit(scope.row)"/>
<ms-table-operator-button :is-tester-permission="true" :tip="$t('test_track.plan_view.cancel_relevance')"
<ms-table-operator-button v-permission="['PROJECT_TRACK_REVIEW:READ+RELEVANCE_OR_CANCEL']"
:tip="$t('test_track.plan_view.cancel_relevance')"
icon="el-icon-unlock" type="danger" @exec="handleDelete(scope.row)"/>
</template>
</el-table-column>
@ -170,11 +172,11 @@
:total="total"/>
<test-review-test-case-edit
ref="testReviewTestCaseEdit"
:search-param="condition"
@refresh="initTableData"
:is-read-only="isReadOnly"
@refreshTable="search"/>
ref="testReviewTestCaseEdit"
:search-param="condition"
@refresh="initTableData"
:is-read-only="isReadOnly"
@refreshTable="search"/>
<batch-edit ref="batchEdit" @batchEdit="batchEdit"
@ -199,30 +201,25 @@ import MsTableButton from "../../../../common/components/MsTableButton";
import ShowMoreBtn from "../../../case/components/ShowMoreBtn";
import BatchEdit from "../../../case/components/BatchEdit";
import MsTablePagination from '../../../../common/pagination/TablePagination';
import {checkoutTestManagerOrTestUser, getCurrentUser, hasRoles} from "../../../../../../common/js/utils";
import {checkoutTestManagerOrTestUser, hasRoles} from "../../../../../../common/js/utils";
import {TEST_CASE_CONFIGS} from "../../../../common/components/search/search-components";
import {
ROLE_TEST_MANAGER,
ROLE_TEST_USER,
TEST_CASE_LIST,
TEST_CASE_REVIEW_CASE_LIST, TEST_PLAN_LIST
} from "../../../../../../common/js/constants";
import {ROLE_TEST_MANAGER, ROLE_TEST_USER, TEST_CASE_REVIEW_CASE_LIST} from "../../../../../../common/js/constants";
import TestReviewTestCaseEdit from "./TestReviewTestCaseEdit";
import ReviewStatus from "@/business/components/track/case/components/ReviewStatus";
import {
_filter,
_handleSelect,
_handleSelectAll,
buildBatchParam,
initCondition,
_sort,
buildBatchParam,
getLabel,
getSelectDataCounts,
initCondition,
setUnSelectIds,
toggleAllSelection
} from "@/common/js/tableUtils";
import HeaderCustom from "@/business/components/common/head/HeaderCustom";
import {Test_Case_Review_Case_List, Track_Test_Case} from "@/business/components/common/model/JsonData";
import {Test_Case_Review_Case_List} from "@/business/components/common/model/JsonData";
import HeaderLabelOperate from "@/business/components/common/head/HeaderLabelOperate";
import MsTableHeaderSelectPopover from "@/business/components/common/components/table/MsTableHeaderSelectPopover";
@ -234,7 +231,7 @@ export default {
MsTableOperatorButton, MsTableOperator, MethodTableItem, TypeTableItem,
StatusTableItem, PriorityTableItem, StatusEdit,
ExecutorEdit, MsTipButton, TestReviewTestCaseEdit, MsTableHeader,
NodeBreadcrumb, MsTableButton, ShowMoreBtn, BatchEdit, MsTablePagination, ReviewStatus,MsTableHeaderSelectPopover
NodeBreadcrumb, MsTableButton, ShowMoreBtn, BatchEdit, MsTablePagination, ReviewStatus, MsTableHeaderSelectPopover
},
data() {
return {
@ -252,7 +249,7 @@ export default {
testReview: {},
isReadOnly: false,
isTestManagerOrTestUser: false,
selectDataCounts:0,
selectDataCounts: 0,
priorityFilters: [
{text: 'P0', value: 'P0'},
{text: 'P1', value: 'P1'},
@ -292,7 +289,7 @@ export default {
{name: this.$t('test_track.review.un_pass'), id: 'UnPass'},
]
},
}
};
},
props: {
reviewId: {
@ -318,7 +315,7 @@ export default {
},
methods: {
customHeader() {
this.$refs.headerCustom.open(this.tableLabel)
this.$refs.headerCustom.open(this.tableLabel);
},
initTableData() {
initCondition(this.condition, this.condition.selectAll);
@ -346,7 +343,7 @@ export default {
setTimeout(this.$refs.caseTable.doLayout, 200);
}
this.checkTableRowIsSelect();
})
});
});
}
getLabel(this, TEST_CASE_REVIEW_CASE_LIST);
@ -372,7 +369,7 @@ export default {
this.selectRows.delete(row);
}
}
})
});
}
},
showDetail(row, event, column) {
@ -469,7 +466,7 @@ export default {
this.selectRows.clear();
this.tableData.forEach(row => {
this.$set(row, "showMore", false);
})
});
}
},
handleSelectionChange(selection, row) {
@ -528,7 +525,7 @@ export default {
},
}
}
};
</script>
<style scoped>