From 3805e40f729b75eafea4a549eb139c66140318d9 Mon Sep 17 00:00:00 2001 From: W23123 <1021720039@qq.com> Date: Thu, 19 Mar 2020 16:10:55 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B5=84=E6=BA=90=E6=B1=A0=E8=A1=A8=E5=A2=9E?= =?UTF-8?q?=E5=8A=A0=20type=E3=80=81info=20=E5=AD=97=E6=AE=B5=20=E5=92=8C?= =?UTF-8?q?=20=E8=B5=84=E6=BA=90=E6=B1=A0=20table=20=E5=88=86=E9=A1=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../base/domain/TestResourcePool.java | 20 +++ .../base/domain/TestResourcePoolExample.java | 140 +++++++++++++++++ .../base/mapper/TestResourcePoolMapper.xml | 44 +++++- .../commons/constants/ResourceTypeEnum.java | 12 ++ .../TestResourcePoolController.java | 13 +- .../QueryResourcePoolRequest.java | 14 ++ .../service/TestResourcePoolService.java | 15 +- .../src/main/resources/generatorConfig.xml | 26 ++-- .../settings/system/TestResourcePool.vue | 141 ++++++++++++++---- 9 files changed, 368 insertions(+), 57 deletions(-) create mode 100644 backend/src/main/java/io/metersphere/commons/constants/ResourceTypeEnum.java create mode 100644 backend/src/main/java/io/metersphere/controller/request/resourcepool/QueryResourcePoolRequest.java diff --git a/backend/src/main/java/io/metersphere/base/domain/TestResourcePool.java b/backend/src/main/java/io/metersphere/base/domain/TestResourcePool.java index 5fa9508260..887cb33d4a 100644 --- a/backend/src/main/java/io/metersphere/base/domain/TestResourcePool.java +++ b/backend/src/main/java/io/metersphere/base/domain/TestResourcePool.java @@ -7,10 +7,14 @@ public class TestResourcePool implements Serializable { private String name; + private String type; + private String description; private String status; + private String info; + private Long createTime; private Long updateTime; @@ -33,6 +37,14 @@ public class TestResourcePool implements Serializable { this.name = name == null ? null : name.trim(); } + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type == null ? null : type.trim(); + } + public String getDescription() { return description; } @@ -49,6 +61,14 @@ public class TestResourcePool implements Serializable { this.status = status == null ? null : status.trim(); } + public String getInfo() { + return info; + } + + public void setInfo(String info) { + this.info = info == null ? null : info.trim(); + } + public Long getCreateTime() { return createTime; } diff --git a/backend/src/main/java/io/metersphere/base/domain/TestResourcePoolExample.java b/backend/src/main/java/io/metersphere/base/domain/TestResourcePoolExample.java index dd93e7a994..94527d4086 100644 --- a/backend/src/main/java/io/metersphere/base/domain/TestResourcePoolExample.java +++ b/backend/src/main/java/io/metersphere/base/domain/TestResourcePoolExample.java @@ -244,6 +244,76 @@ public class TestResourcePoolExample { return (Criteria) this; } + public Criteria andTypeIsNull() { + addCriterion("type is null"); + return (Criteria) this; + } + + public Criteria andTypeIsNotNull() { + addCriterion("type is not null"); + return (Criteria) this; + } + + public Criteria andTypeEqualTo(String value) { + addCriterion("type =", value, "type"); + return (Criteria) this; + } + + public Criteria andTypeNotEqualTo(String value) { + addCriterion("type <>", value, "type"); + return (Criteria) this; + } + + public Criteria andTypeGreaterThan(String value) { + addCriterion("type >", value, "type"); + return (Criteria) this; + } + + public Criteria andTypeGreaterThanOrEqualTo(String value) { + addCriterion("type >=", value, "type"); + return (Criteria) this; + } + + public Criteria andTypeLessThan(String value) { + addCriterion("type <", value, "type"); + return (Criteria) this; + } + + public Criteria andTypeLessThanOrEqualTo(String value) { + addCriterion("type <=", value, "type"); + return (Criteria) this; + } + + public Criteria andTypeLike(String value) { + addCriterion("type like", value, "type"); + return (Criteria) this; + } + + public Criteria andTypeNotLike(String value) { + addCriterion("type not like", value, "type"); + return (Criteria) this; + } + + public Criteria andTypeIn(List values) { + addCriterion("type in", values, "type"); + return (Criteria) this; + } + + public Criteria andTypeNotIn(List values) { + addCriterion("type not in", values, "type"); + return (Criteria) this; + } + + public Criteria andTypeBetween(String value1, String value2) { + addCriterion("type between", value1, value2, "type"); + return (Criteria) this; + } + + public Criteria andTypeNotBetween(String value1, String value2) { + addCriterion("type not between", value1, value2, "type"); + return (Criteria) this; + } + public Criteria andDescriptionIsNull() { addCriterion("description is null"); return (Criteria) this; @@ -384,6 +454,76 @@ public class TestResourcePoolExample { return (Criteria) this; } + public Criteria andInfoIsNull() { + addCriterion("info is null"); + return (Criteria) this; + } + + public Criteria andInfoIsNotNull() { + addCriterion("info is not null"); + return (Criteria) this; + } + + public Criteria andInfoEqualTo(String value) { + addCriterion("info =", value, "info"); + return (Criteria) this; + } + + public Criteria andInfoNotEqualTo(String value) { + addCriterion("info <>", value, "info"); + return (Criteria) this; + } + + public Criteria andInfoGreaterThan(String value) { + addCriterion("info >", value, "info"); + return (Criteria) this; + } + + public Criteria andInfoGreaterThanOrEqualTo(String value) { + addCriterion("info >=", value, "info"); + return (Criteria) this; + } + + public Criteria andInfoLessThan(String value) { + addCriterion("info <", value, "info"); + return (Criteria) this; + } + + public Criteria andInfoLessThanOrEqualTo(String value) { + addCriterion("info <=", value, "info"); + return (Criteria) this; + } + + public Criteria andInfoLike(String value) { + addCriterion("info like", value, "info"); + return (Criteria) this; + } + + public Criteria andInfoNotLike(String value) { + addCriterion("info not like", value, "info"); + return (Criteria) this; + } + + public Criteria andInfoIn(List values) { + addCriterion("info in", values, "info"); + return (Criteria) this; + } + + public Criteria andInfoNotIn(List values) { + addCriterion("info not in", values, "info"); + return (Criteria) this; + } + + public Criteria andInfoBetween(String value1, String value2) { + addCriterion("info between", value1, value2, "info"); + return (Criteria) this; + } + + public Criteria andInfoNotBetween(String value1, String value2) { + addCriterion("info not between", value1, value2, "info"); + return (Criteria) this; + } + public Criteria andCreateTimeIsNull() { addCriterion("create_time is null"); return (Criteria) this; diff --git a/backend/src/main/java/io/metersphere/base/mapper/TestResourcePoolMapper.xml b/backend/src/main/java/io/metersphere/base/mapper/TestResourcePoolMapper.xml index cfa558d633..26dbfd11ed 100644 --- a/backend/src/main/java/io/metersphere/base/mapper/TestResourcePoolMapper.xml +++ b/backend/src/main/java/io/metersphere/base/mapper/TestResourcePoolMapper.xml @@ -4,8 +4,10 @@ + + @@ -68,7 +70,7 @@ - id, name, description, status, create_time, update_time + id, name, type, description, status, info, create_time, update_time