From 2dd2bd86f85d516ac3d92942f3d0e25309729491 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=99=88=E8=A3=95=E8=B4=A2?= Date: Mon, 20 Feb 2023 15:04:03 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E7=8E=AF=E5=A2=83=E5=8F=98?= =?UTF-8?q?=E9=87=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/xm/core/entity/XmTestPlan.java | 23 +++++++++++- .../com/xm/core/entity/XmTestPlanCase.java | 5 +-- .../xm/core/dao/XmTestPlanCaseMapper.xml | 12 +++---- .../mapper/xm/core/dao/XmTestPlanMapper.xml | 36 ++++++++++++++++--- 4 files changed, 59 insertions(+), 17 deletions(-) diff --git a/xm-core/src/main/java/com/xm/core/entity/XmTestPlan.java b/xm-core/src/main/java/com/xm/core/entity/XmTestPlan.java index 851a488b..a629cc68 100644 --- a/xm-core/src/main/java/com/xm/core/entity/XmTestPlan.java +++ b/xm-core/src/main/java/com/xm/core/entity/XmTestPlan.java @@ -9,7 +9,7 @@ import java.math.BigDecimal; /** * 组织 com 顶级模块 xm 大模块 core 小模块
* 实体 XmTestPlan所有属性名:
- * "id","测试计划编号","name","计划名称","casedbId","用例库编号","casedbName","用例库名称","projectId","项目编号","projectName","项目名称","cuserid","创建人编号","cusername","创建人名称","ctime","创建时间","stime","开始时间","etime","结束时间","status","状态0-未开始,1-进行中,2已结束","tcode","测试结果0未通过,1已通过","totalCases","总用例数","okCases","通过用例数","errCases","失败用例数","igCases","忽略用例数","blCases","阻塞用例数","toTestCases","未测用例数","productId","产品编号","productName","产品名称","flowState","评审结果0-待评审,1-已评审通过,2-已拒绝","bugCnt","bug数目","closedBugs","已关闭bug总数","resolvedBugs","已解决bug总数","activeBugs","激活的bug总数","confirmedBugs","已解决bug总数","menus","需求数目","funcs","功能模块数","budgetWorkload","预算工时","actWorkload","实际工时","summaryRemark","报告总结","cbranchId","创建机构编号","pbranchId","产品归属企业","ptype","计划类型0-普通测试,2-迭代测试,1-发布测试,","envJson","环境变量列表","testType","测试方式0-手工,1-自动";
+ * "id","测试计划编号","name","计划名称","casedbId","用例库编号","casedbName","用例库名称","projectId","项目编号","projectName","项目名称","cuserid","创建人编号","cusername","创建人名称","ctime","创建时间","stime","开始时间","etime","结束时间","status","状态0-未开始,1-进行中,2已结束","tcode","测试结果0未通过,1已通过","totalCases","总用例数","okCases","通过用例数","errCases","失败用例数","igCases","忽略用例数","blCases","阻塞用例数","toTestCases","未测用例数","productId","产品编号","productName","产品名称","flowState","评审结果0-待评审,1-已评审通过,2-已拒绝","bugCnt","bug数目","closedBugs","已关闭bug总数","resolvedBugs","已解决bug总数","activeBugs","激活的bug总数","confirmedBugs","已解决bug总数","menus","需求数目","funcs","功能模块数","budgetWorkload","预算工时","actWorkload","实际工时","summaryRemark","报告总结","cbranchId","创建机构编号","pbranchId","产品归属企业","ptype","计划类型0-普通测试,2-迭代测试,1-发布测试,","envJson","环境变量列表","testType","测试方式0-手工,1-自动","execCfgCron","执行计划","execCfgTimes","循环执行次数","execCfgThreads","线程数","execTimes","总请求次数","execStime","开始执行时间","execEtime","结束执行时间","execStatus","执行状态0-未开始,1待执行,2-执行中,3-执行结束";
* 当前主键(包括多主键):
* id;
*/ @@ -130,6 +130,27 @@ public class XmTestPlan implements java.io.Serializable { @ApiModelProperty(notes="测试方式0-手工,1-自动",allowEmptyValue=true,example="",allowableValues="") String testType; + + @ApiModelProperty(notes="执行计划",allowEmptyValue=true,example="",allowableValues="") + String execCfgCron; + + @ApiModelProperty(notes="循环执行次数",allowEmptyValue=true,example="",allowableValues="") + Date execCfgTimes; + + @ApiModelProperty(notes="线程数",allowEmptyValue=true,example="",allowableValues="") + Integer execCfgThreads; + + @ApiModelProperty(notes="总请求次数",allowEmptyValue=true,example="",allowableValues="") + Integer execTimes; + + @ApiModelProperty(notes="开始执行时间",allowEmptyValue=true,example="",allowableValues="") + Date execStime; + + @ApiModelProperty(notes="结束执行时间",allowEmptyValue=true,example="",allowableValues="") + Date execEtime; + + @ApiModelProperty(notes="执行状态0-未开始,1待执行,2-执行中,3-执行结束",allowEmptyValue=true,example="",allowableValues="") + String execStatus; /** *测试计划编号 diff --git a/xm-core/src/main/java/com/xm/core/entity/XmTestPlanCase.java b/xm-core/src/main/java/com/xm/core/entity/XmTestPlanCase.java index b29fa1f4..18940346 100644 --- a/xm-core/src/main/java/com/xm/core/entity/XmTestPlanCase.java +++ b/xm-core/src/main/java/com/xm/core/entity/XmTestPlanCase.java @@ -9,7 +9,7 @@ import java.math.BigDecimal; /** * 组织 com 顶级模块 xm 大模块 core 小模块
* 实体 XmTestPlanCase所有属性名:
- * "bugs","bug数目","execUserid","执行人","caseId","测试用例编号","ltime","更新时间","ctime","创建时间","execStatus","0-未测,1-通过,2-受阻,3-忽略,4-失败","execUsername","执行人姓名","priority","优先级","remark","执行备注","testStep","测试步骤","planId","计划编号","projectId","项目编号","budgetWorkload","预算工时","actWorkload","实际工时","initWorkload","原估工时","execDate","执行日期,以执行状态变更日期为准yyyy-MM-dd型","execType","执行类型0-手工,1-自动化","productId","归属产品","autoStep","自动化测试";
+ * "bugs","bug数目","execUserid","执行人","caseId","测试用例编号","ltime","更新时间","ctime","创建时间","execStatus","0-未测,1-通过,2-受阻,3-忽略,4-失败","execUsername","执行人姓名","priority","优先级","remark","执行备注","testStep","测试步骤","planId","计划编号","projectId","项目编号","budgetWorkload","预算工时","actWorkload","实际工时","initWorkload","原估工时","execDate","执行日期,以执行状态变更日期为准yyyy-MM-dd型","execType","执行类型0-手工,1-自动化","productId","归属产品";
* 当前主键(包括多主键):
* case_id,plan_id;
*/ @@ -73,9 +73,6 @@ public class XmTestPlanCase implements java.io.Serializable { @ApiModelProperty(notes="归属产品",allowEmptyValue=true,example="",allowableValues="") String productId; - - @ApiModelProperty(notes="自动化测试",allowEmptyValue=true,example="",allowableValues="") - String autoStep; /** *测试用例编号,计划编号 diff --git a/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmTestPlanCaseMapper.xml b/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmTestPlanCaseMapper.xml index 6f442350..e7608af4 100644 --- a/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmTestPlanCaseMapper.xml +++ b/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmTestPlanCaseMapper.xml @@ -199,7 +199,7 @@ insert into xm_test_plan_case( ) values ( - #{bugs},#{execUserid},#{caseId},#{ltime},#{ctime},#{execStatus},#{execUsername},#{priority},#{remark},#{testStep},#{planId},#{projectId},#{budgetWorkload},#{actWorkload},#{initWorkload},#{execDate},#{execType},#{productId},#{autoStep} + #{bugs},#{execUserid},#{caseId},#{ltime},#{ctime},#{execStatus},#{execUsername},#{priority},#{remark},#{testStep},#{planId},#{projectId},#{budgetWorkload},#{actWorkload},#{initWorkload},#{execDate},#{execType},#{productId} ) @@ -274,7 +274,7 @@ - bugs,exec_userid,case_id,ltime,ctime,exec_status,exec_username,priority,remark,test_step,plan_id,project_id,budget_workload,act_workload,init_workload,exec_date,exec_type,product_id,auto_step + bugs,exec_userid,case_id,ltime,ctime,exec_status,exec_username,priority,remark,test_step,plan_id,project_id,budget_workload,act_workload,init_workload,exec_date,exec_type,product_id @@ -297,7 +297,6 @@ and res.exec_date = #{execDate} and res.exec_type = #{execType} and res.product_id = #{productId} - and res.auto_step = #{autoStep} @@ -316,8 +315,7 @@ init_workload = #{initWorkload}, exec_date = #{execDate}, exec_type = #{execType}, - product_id = #{productId}, - auto_step = #{autoStep} + product_id = #{productId} bugs = #{bugs}, @@ -336,7 +334,6 @@ exec_date = #{execDate}, exec_type = #{execType}, product_id = #{productId}, - auto_step = #{autoStep}, @@ -355,7 +352,6 @@ init_workload = #{item.initWorkload}, exec_date = #{item.execDate}, exec_type = #{item.execType}, - product_id = #{item.productId}, - auto_step = #{item.autoStep} + product_id = #{item.productId} \ No newline at end of file diff --git a/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmTestPlanMapper.xml b/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmTestPlanMapper.xml index 5997840b..a533390b 100644 --- a/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmTestPlanMapper.xml +++ b/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmTestPlanMapper.xml @@ -132,7 +132,7 @@ insert into xm_test_plan( ) values ( - #{id},#{name},#{casedbId},#{casedbName},#{projectId},#{projectName},#{cuserid},#{cusername},#{ctime},#{stime},#{etime},#{status},#{tcode},#{totalCases},#{okCases},#{errCases},#{igCases},#{blCases},#{toTestCases},#{productId},#{productName},#{flowState},#{bugCnt},#{closedBugs},#{resolvedBugs},#{activeBugs},#{confirmedBugs},#{menus},#{funcs},#{budgetWorkload},#{actWorkload},#{summaryRemark},#{cbranchId},#{pbranchId},#{ptype},#{envJson},#{testType} + #{id},#{name},#{casedbId},#{casedbName},#{projectId},#{projectName},#{cuserid},#{cusername},#{ctime},#{stime},#{etime},#{status},#{tcode},#{totalCases},#{okCases},#{errCases},#{igCases},#{blCases},#{toTestCases},#{productId},#{productName},#{flowState},#{bugCnt},#{closedBugs},#{resolvedBugs},#{activeBugs},#{confirmedBugs},#{menus},#{funcs},#{budgetWorkload},#{actWorkload},#{summaryRemark},#{cbranchId},#{pbranchId},#{ptype},#{envJson},#{testType},#{execCfgCron},#{execCfgTimes},#{execCfgThreads},#{execTimes},#{execStime},#{execEtime},#{execStatus} ) @@ -207,7 +207,7 @@ - id,name,casedb_id,casedb_name,project_id,project_name,cuserid,cusername,ctime,stime,etime,status,tcode,total_cases,ok_cases,err_cases,ig_cases,bl_cases,to_test_cases,product_id,product_name,flow_state,bug_cnt,closed_bugs,resolved_bugs,active_bugs,confirmed_bugs,menus,funcs,budget_workload,act_workload,summary_remark,cbranch_id,pbranch_id,ptype,env_json,test_type + id,name,casedb_id,casedb_name,project_id,project_name,cuserid,cusername,ctime,stime,etime,status,tcode,total_cases,ok_cases,err_cases,ig_cases,bl_cases,to_test_cases,product_id,product_name,flow_state,bug_cnt,closed_bugs,resolved_bugs,active_bugs,confirmed_bugs,menus,funcs,budget_workload,act_workload,summary_remark,cbranch_id,pbranch_id,ptype,env_json,test_type,exec_cfg_cron,exec_cfg_times,exec_cfg_threads,exec_times,exec_stime,exec_etime,exec_status @@ -249,6 +249,13 @@ and res.ptype = #{ptype} and res.env_json = #{envJson} and res.test_type = #{testType} + and res.exec_cfg_cron = #{execCfgCron} + and date_format(res.exec_cfg_times,'%Y-%m-%d') = date_format(#{execCfgTimes},'%Y-%m-%d') + and res.exec_cfg_threads = #{execCfgThreads} + and res.exec_times = #{execTimes} + and date_format(res.exec_stime,'%Y-%m-%d') = date_format(#{execStime},'%Y-%m-%d') + and date_format(res.exec_etime,'%Y-%m-%d') = date_format(#{execEtime},'%Y-%m-%d') + and res.exec_status = #{execStatus} @@ -287,7 +294,14 @@ pbranch_id = #{pbranchId}, ptype = #{ptype}, env_json = #{envJson}, - test_type = #{testType} + test_type = #{testType}, + exec_cfg_cron = #{execCfgCron}, + exec_cfg_times = #{execCfgTimes}, + exec_cfg_threads = #{execCfgThreads}, + exec_times = #{execTimes}, + exec_stime = #{execStime}, + exec_etime = #{execEtime}, + exec_status = #{execStatus} name = #{name}, @@ -326,6 +340,13 @@ ptype = #{ptype}, env_json = #{envJson}, test_type = #{testType}, + exec_cfg_cron = #{execCfgCron}, + exec_cfg_times = #{execCfgTimes}, + exec_cfg_threads = #{execCfgThreads}, + exec_times = #{execTimes}, + exec_stime = #{execStime}, + exec_etime = #{execEtime}, + exec_status = #{execStatus}, @@ -364,6 +385,13 @@ pbranch_id = #{item.pbranchId}, ptype = #{item.ptype}, env_json = #{item.envJson}, - test_type = #{item.testType} + test_type = #{item.testType}, + exec_cfg_cron = #{item.execCfgCron}, + exec_cfg_times = #{item.execCfgTimes}, + exec_cfg_threads = #{item.execCfgThreads}, + exec_times = #{item.execTimes}, + exec_stime = #{item.execStime}, + exec_etime = #{item.execEtime}, + exec_status = #{item.execStatus} \ No newline at end of file