fix: 全选回收站用例生成关系图报错
This commit is contained in:
parent
b1b9a870c9
commit
9a3654a430
|
@ -624,6 +624,11 @@
|
||||||
<if test="request.protocol != null">
|
<if test="request.protocol != null">
|
||||||
AND api_definition.protocol = #{request.protocol}
|
AND api_definition.protocol = #{request.protocol}
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
|
<if test="request.notEqStatus != null">
|
||||||
|
and (api_definition.status is null or api_definition.status != #{request.notEqStatus})
|
||||||
|
</if>
|
||||||
|
|
||||||
<if test="request.id != null">
|
<if test="request.id != null">
|
||||||
AND api_definition.id = #{request.id}
|
AND api_definition.id = #{request.id}
|
||||||
</if>
|
</if>
|
||||||
|
|
|
@ -183,6 +183,11 @@
|
||||||
or api_scenario.num like CONCAT('%', #{request.name},'%')
|
or api_scenario.num like CONCAT('%', #{request.name},'%')
|
||||||
or api_scenario.custom_num like CONCAT('%', #{request.name},'%'))
|
or api_scenario.custom_num like CONCAT('%', #{request.name},'%'))
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
|
<if test="request.notEqStatus != null">
|
||||||
|
and (api_scenario.status is null or api_scenario.status != #{request.notEqStatus})
|
||||||
|
</if>
|
||||||
|
|
||||||
<if test="request.workspaceId != null">
|
<if test="request.workspaceId != null">
|
||||||
AND project.workspace_id = #{request.workspaceId}
|
AND project.workspace_id = #{request.workspaceId}
|
||||||
</if>
|
</if>
|
||||||
|
|
|
@ -355,6 +355,10 @@
|
||||||
<if test="request.statusIsNot != null">
|
<if test="request.statusIsNot != null">
|
||||||
and (test_case.status is null or test_case.status != #{request.statusIsNot})
|
and (test_case.status is null or test_case.status != #{request.statusIsNot})
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
|
<if test="request.notEqStatus != null">
|
||||||
|
and (test_case.status is null or test_case.status != #{request.notEqStatus})
|
||||||
|
</if>
|
||||||
<if test="request.name != null">
|
<if test="request.name != null">
|
||||||
and (test_case.name like CONCAT('%', #{request.name},'%')
|
and (test_case.name like CONCAT('%', #{request.name},'%')
|
||||||
or test_case.num like CONCAT('%', #{request.name},'%')
|
or test_case.num like CONCAT('%', #{request.name},'%')
|
||||||
|
|
|
@ -14,6 +14,11 @@ public class BaseQueryRequest {
|
||||||
|
|
||||||
private String name;
|
private String name;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 状态不等于 notEqStatus
|
||||||
|
*/
|
||||||
|
private String notEqStatus;
|
||||||
|
|
||||||
private String workspaceId;
|
private String workspaceId;
|
||||||
|
|
||||||
private List<String> ids;
|
private List<String> ids;
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit ec08189a4f2c3aebf0688f4b9798af2993002d25
|
Subproject commit a58811e4dc08813267cdece3e0c24ab1136475fd
|
|
@ -1,6 +1,6 @@
|
||||||
<template>
|
<template>
|
||||||
<chart
|
<chart
|
||||||
:style="{'height': height + 'px'}"
|
:style="{'height': chartHeight, 'width': width}"
|
||||||
class="ms-chart"
|
class="ms-chart"
|
||||||
:init-options="defaultInitOptions"
|
:init-options="defaultInitOptions"
|
||||||
:option="options"
|
:option="options"
|
||||||
|
@ -19,25 +19,52 @@ export default {
|
||||||
props: {
|
props: {
|
||||||
options: Object,
|
options: Object,
|
||||||
theme: [String, Object],
|
theme: [String, Object],
|
||||||
initOptions: Object,
|
initOptions: {
|
||||||
|
type: Object,
|
||||||
|
default() {
|
||||||
|
return {
|
||||||
|
renderer: 'canvas'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
group: String,
|
group: String,
|
||||||
autoresize: Boolean,
|
autoresize: Boolean,
|
||||||
watchShallow: Boolean,
|
watchShallow: Boolean,
|
||||||
manualUpdate: Boolean,
|
manualUpdate: Boolean,
|
||||||
height: {
|
height: {
|
||||||
type: Number,
|
type: [Number, String],
|
||||||
default() {
|
default() {
|
||||||
return 400
|
return 400
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
|
width: [Number, String],
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
defaultInitOptions: this.initOptions
|
defaultInitOptions: this.initOptions
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
computed: {
|
||||||
|
chartHeight() {
|
||||||
|
if (this.height instanceof String) {
|
||||||
|
return this.height;
|
||||||
|
} else {
|
||||||
|
return this.height + 'px';
|
||||||
|
}
|
||||||
|
},
|
||||||
|
chartWidth() {
|
||||||
|
if (!this.width) {
|
||||||
|
return this.width;
|
||||||
|
}
|
||||||
|
if (this.width instanceof String) {
|
||||||
|
return this.width;
|
||||||
|
} else {
|
||||||
|
return this.width + 'px';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.defaultInitOptions = this.defaultInitOptions || {};
|
// this.defaultInitOptions = this.defaultInitOptions || {};
|
||||||
// 默认渲染svg
|
// 默认渲染svg
|
||||||
// BUG: 渲染svg之后 图上的legend 太多会不显示
|
// BUG: 渲染svg之后 图上的legend 太多会不显示
|
||||||
// if (!this.defaultInitOptions.renderer) {
|
// if (!this.defaultInitOptions.renderer) {
|
||||||
|
@ -49,8 +76,8 @@ export default {
|
||||||
this.$emit('onClick', params.data);
|
this.$emit('onClick', params.data);
|
||||||
},
|
},
|
||||||
exportCharts(fileName, type) {
|
exportCharts(fileName, type) {
|
||||||
if (document.getElementById('chartsShow')) {
|
if (document.getElementsByClassName('ms-chart')) {
|
||||||
let chartsCanvas = document.getElementById('chartsShow').querySelectorAll('canvas')[0];
|
let chartsCanvas = document.getElementsByClassName('ms-chart')[0].querySelectorAll('canvas')[0];
|
||||||
let mime = 'image/png';
|
let mime = 'image/png';
|
||||||
if (chartsCanvas) {
|
if (chartsCanvas) {
|
||||||
// toDataURL()是canvas对象的一种方法,用于将canvas对象转换为base64位编码
|
// toDataURL()是canvas对象的一种方法,用于将canvas对象转换为base64位编码
|
||||||
|
|
|
@ -146,14 +146,14 @@
|
||||||
</template>
|
</template>
|
||||||
</ms-table-column >
|
</ms-table-column >
|
||||||
|
|
||||||
<ms-table-column
|
<!-- <ms-table-column-->
|
||||||
prop="status"
|
<!-- prop="status"-->
|
||||||
:filters="statusFilters"
|
<!-- :filters="statusFilters"-->
|
||||||
:field="item"
|
<!-- :field="item"-->
|
||||||
:fields-width="fieldsWidth"
|
<!-- :fields-width="fieldsWidth"-->
|
||||||
min-width="100px"
|
<!-- min-width="100px"-->
|
||||||
:label="$t('api_test.definition.api_case_status')">
|
<!-- :label="$t('api_test.definition.api_case_status')">-->
|
||||||
</ms-table-column>
|
<!-- </ms-table-column>-->
|
||||||
|
|
||||||
<ms-table-column v-for="field in testCaseTemplate.customFields" :key="field.id"
|
<ms-table-column v-for="field in testCaseTemplate.customFields" :key="field.id"
|
||||||
:filters="field.name === '用例等级' ? priorityFilters : null"
|
:filters="field.name === '用例等级' ? priorityFilters : null"
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit 41c1f55d34da48de279d8e9e4675d2a735822c3a
|
Subproject commit 3beb86a57a5816e94d3b93ed7b9b7f465832a70f
|
|
@ -8,7 +8,8 @@ import 'echarts/lib/component/title'
|
||||||
import 'echarts/lib/component/toolbox';
|
import 'echarts/lib/component/toolbox';
|
||||||
import 'echarts/lib/component/dataZoom';
|
import 'echarts/lib/component/dataZoom';
|
||||||
import 'echarts/lib/component/legend';
|
import 'echarts/lib/component/legend';
|
||||||
import 'zrender/lib/svg/svg'
|
import 'zrender/lib/svg/svg' // initOption 支持使用svg
|
||||||
|
import 'zrender/lib/canvas/canvas' // initOption 支持使用canvas
|
||||||
import 'echarts/lib/component/grid'
|
import 'echarts/lib/component/grid'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
|
|
@ -186,7 +186,7 @@ export let CUSTOM_TABLE_HEADER = {
|
||||||
{id: 'createUser', key: '7', label: 'commons.create_user'},
|
{id: 'createUser', key: '7', label: 'commons.create_user'},
|
||||||
{id: 'createTime', key: '8', label: 'commons.create_time'},
|
{id: 'createTime', key: '8', label: 'commons.create_time'},
|
||||||
{id: 'desc', key: '9', label: 'test_track.case.case_desc'},
|
{id: 'desc', key: '9', label: 'test_track.case.case_desc'},
|
||||||
{id: 'status', key: '10', label: 'api_test.definition.api_case_status'},
|
// {id: 'status', key: 'a', label: 'api_test.definition.api_case_status'},
|
||||||
{id: 'projectName', key: 'c', label: 'commons.project'},
|
{id: 'projectName', key: 'c', label: 'commons.project'},
|
||||||
{id: 'caseStatus', key: 'd', label: 'commons.status'},
|
{id: 'caseStatus', key: 'd', label: 'commons.status'},
|
||||||
],
|
],
|
||||||
|
|
Loading…
Reference in New Issue