From a1caf1d545507e39b96d5902b1541e52faed5ae5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=99=88=E8=A3=95=E8=B4=A2?= Date: Wed, 27 Jul 2022 01:17:38 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../xm/core/xmQuestion/XmQuestionEdit.vue | 27 +++++++++ .../core/xmTestPlanCase/XmTestPlanCaseMng.vue | 57 ++++++++++++------- 2 files changed, 62 insertions(+), 22 deletions(-) diff --git a/src/views/xm/core/xmQuestion/XmQuestionEdit.vue b/src/views/xm/core/xmQuestion/XmQuestionEdit.vue index 2761d907..782900f7 100644 --- a/src/views/xm/core/xmQuestion/XmQuestionEdit.vue +++ b/src/views/xm/core/xmQuestion/XmQuestionEdit.vue @@ -181,6 +181,10 @@ + + + + @@ -308,6 +312,7 @@ activateTabPaneName:'12', funcVisible:false, stepConfigVisible:false, + caseVisible:false, /**end 在上面加自定义属性**/ }//end return },//end data @@ -518,6 +523,8 @@ params.productId=$event.productId params.funcId=$event.id params.funcName=$event.name + }else if(fieldName==='caseId'){ + params=Object.assign(params,$event) }else{ params[fieldName]=$event } @@ -613,12 +620,32 @@ } this.editFormBak={...this.editForm} + }, + onTestPlanCaseSelected(xmTestPlanCase){ + var params={}; + params.planId=xmTestPlanCase.planId + params.productId=xmTestPlanCase.productId + params.productName=xmTestPlanCase.productName + params.caseId=xmTestPlanCase.caseId + params.caseName=xmTestPlanCase.caseName + params.casedbId=xmTestPlanCase.casedbId + params.funcId=xmTestPlanCase.funcId + params.funcName=xmTestPlanCase.funcName + params.menuId=xmTestPlanCase.menuId + params.menuName=xmTestPlanCase.menuName + params.opStep=xmTestPlanCase.testStep + params.name=xmTestPlanCase.caseName + params.projectId=xmTestPlanCase.projectId + Object.assign(this.editForm,params) + this.editXmQuestionSomeFields(this.editForm,"caseId",params) + this.caseVisible=false; } },//end method components: { //在下面添加其它组件 'xm-question-edit':XmQuestionEdit 'upload': AttachmentUpload,XmGroupMng,VueEditor,XmTaskList,xmMenuSelect,XmQuestionHandleMng,TagMng,XmProjectSelect, XmMyDoFocus,XmFuncSelect,MdpSelectUserXm,TestStepConfig,TestStepResult, + xmTestPlanCaseMng:()=>import('../xmTestPlanCase/XmTestPlanCaseMng') }, mounted() { this.initData(); diff --git a/src/views/xm/core/xmTestPlanCase/XmTestPlanCaseMng.vue b/src/views/xm/core/xmTestPlanCase/XmTestPlanCaseMng.vue index adeaf331..9f798129 100644 --- a/src/views/xm/core/xmTestPlanCase/XmTestPlanCaseMng.vue +++ b/src/views/xm/core/xmTestPlanCase/XmTestPlanCaseMng.vue @@ -26,11 +26,6 @@ --> - - - - - - - - - - - - - + + + @@ -88,10 +98,13 @@ export default { components: { XmTestPlanCaseEdit,XmTestCaseSelect,XmFuncSelect, }, - props:['visible','xmTestPlan','xmTestCasedb','xmTestCase'], + props:['visible','xmTestPlan','xmTestCasedb','xmTestCase','xmProduct','select'], computed: { ...mapGetters(['userInfo']), xmProductCpd(){ + if(this.xmProduct&& this.xmProduct.id){ + return this.xmProduct + } if(this.xmTestCasedb && this.xmTestCasedb.id){ return {id:this.xmTestCasedb.productId,productName:this.xmTestCasedb.productName} }