CDISC导出配置更改
continuous-integration/drone/push Build is passing Details

uat_us
caiyiling 2025-01-02 15:36:00 +08:00
parent d127637922
commit d381b10bcd
3 changed files with 66 additions and 25 deletions

View File

@ -1,11 +1,11 @@
<template> <template>
<div style="text-align: right"> <div style="text-align: right">
<el-tabs v-model="exportType"> <el-tabs v-model="activeName">
<el-tab-pane <el-tab-pane
label="报表导出" label="报表导出"
name="report" name="report"
> >
<el-tabs type="border-card" v-model="trialReadingCriterionId"> <el-tabs type="border-card" v-model="reportCriterionId">
<el-tab-pane <el-tab-pane
:label="i.TrialReadingCriterionName" :label="i.TrialReadingCriterionName"
:name="i.TrialReadingCriterionId" :name="i.TrialReadingCriterionId"
@ -13,7 +13,7 @@
:key="i.TrialReadingCriterionId" :key="i.TrialReadingCriterionId"
> >
<exportList <exportList
v-if="trialReadingCriterionId === i.TrialReadingCriterionId && exportType === 'report'" v-if="reportCriterionId === i.TrialReadingCriterionId && activeName === 'report'"
:trialReadingCriterionId="i.TrialReadingCriterionId" :trialReadingCriterionId="i.TrialReadingCriterionId"
:data="data" :data="data"
/> />
@ -29,7 +29,7 @@
label="报表导出配置" label="报表导出配置"
name="reportConfig" name="reportConfig"
> >
<el-tabs type="border-card" v-model="configTrialReadingCriterionId"> <el-tabs type="border-card" v-model="reportConfigCriterionId">
<el-tab-pane <el-tab-pane
:label="i.TrialReadingCriterionName" :label="i.TrialReadingCriterionName"
:name="i.TrialReadingCriterionId" :name="i.TrialReadingCriterionId"
@ -37,8 +37,9 @@
:key="i.TrialReadingCriterionId" :key="i.TrialReadingCriterionId"
> >
<configList <configList
v-if="configTrialReadingCriterionId === i.TrialReadingCriterionId && exportType === 'reportConfig'" v-if="reportConfigCriterionId === i.TrialReadingCriterionId && activeName === 'reportConfig'"
:trialReadingCriterionId="i.TrialReadingCriterionId" :trialReadingCriterionId="i.TrialReadingCriterionId"
:exportType="0"
/> />
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
@ -47,6 +48,20 @@
label="CDISC导出配置" label="CDISC导出配置"
name="CDISCConfig" name="CDISCConfig"
> >
<el-tabs type="border-card" v-model="CDISCCriterionId">
<el-tab-pane
:label="i.TrialReadingCriterionName"
:name="i.TrialReadingCriterionId"
v-for="i of trialCriterionList"
:key="i.TrialReadingCriterionId"
>
<configList
v-if="CDISCCriterionId === i.TrialReadingCriterionId && activeName === 'CDISCConfig'"
:trialReadingCriterionId="i.TrialReadingCriterionId"
:exportType="1"
/>
</el-tab-pane>
</el-tabs>
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
@ -67,10 +82,11 @@ export default {
return { return {
loading: false, loading: false,
trialCriterionList: [], trialCriterionList: [],
trialReadingCriterionId: null, reportCriterionId: null,
trialId: null, trialId: null,
exportType:'report', activeName: 'report',
configTrialReadingCriterionId: '' reportConfigCriterionId: '',
CDISCCriterionId: ''
} }
}, },
props: { props: {
@ -91,8 +107,9 @@ export default {
let res = await getTrialCriterionList(this.trialId) let res = await getTrialCriterionList(this.trialId)
if (res.IsSuccess) { if (res.IsSuccess) {
this.trialCriterionList = res.Result this.trialCriterionList = res.Result
this.trialReadingCriterionId = this.trialCriterionList[0].TrialReadingCriterionId this.reportCriterionId = this.trialCriterionList[0].TrialReadingCriterionId
this.configTrialReadingCriterionId = this.trialCriterionList[0].TrialReadingCriterionId this.reportConfigCriterionId = this.trialCriterionList[0].TrialReadingCriterionId
this.CDISCCriterionId = this.trialCriterionList[0].TrialReadingCriterionId
} }
} catch(e) { } catch(e) {
console.log(e) console.log(e)

View File

@ -10,9 +10,15 @@
default-expand-all default-expand-all
:tree-props="{ children: 'Children', hasChildren: 'hasChildren' }" :tree-props="{ children: 'Children', hasChildren: 'hasChildren' }"
> >
<el-table-column prop="QuestionName" label="问题名称" width="300"> <el-table-column
prop="QuestionName"
label="问题名称"
width="300">
</el-table-column> </el-table-column>
<el-table-column :key="item.Code" v-for="item in exportInfo.DicList" :label="item.ValueCN" > <el-table-column
v-for="item in exportInfo.DicList"
:key="item.Code"
:label="item.ValueCN" >
<template v-slot="scope"> <template v-slot="scope">
<el-checkbox <el-checkbox
@change="() => changeState(scope, item.Code)" @change="() => changeState(scope, item.Code)"
@ -20,6 +26,17 @@
</el-checkbox> </el-checkbox>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column
v-if="exportType === 1"
prop="CDISCCode"
label="CDISC编码"
width="500"
>
<template v-slot="scope">
<el-input v-model="scope.row.CDISCCode" placeholder="CDISC编码"></el-input>
</template>
</el-table-column>
</el-table> </el-table>
</div> </div>
</template> </template>
@ -31,6 +48,10 @@ export default {
trialReadingCriterionId: { trialReadingCriterionId: {
type: String, type: String,
required: true required: true
},
exportType: {
type: Number,
required: true
} }
}, },
data() { data() {
@ -60,6 +81,7 @@ export default {
this.loading = true this.loading = true
try { try {
let params= { let params= {
exportType: this.exportType,
questionList: [], questionList: [],
tableQuestionList: [] tableQuestionList: []
} }
@ -67,7 +89,8 @@ export default {
return { return {
questionId: i.QuestionId, questionId: i.QuestionId,
tableQuestionId: i.TableQuestionId, tableQuestionId: i.TableQuestionId,
exportResult: i.ExportResult exportResult: i.ExportResult,
CDISCCode: i.CDISCCode
} }
}) })
this.exportInfo.QuestionList.forEach(i => { this.exportInfo.QuestionList.forEach(i => {
@ -76,6 +99,7 @@ export default {
questionId: i.QuestionId, questionId: i.QuestionId,
tableQuestionId: k.TableQuestionId, tableQuestionId: k.TableQuestionId,
exportResult: k.ExportResult, exportResult: k.ExportResult,
CDISCCode: k.CDISCCode
} }
}) })
params.tableQuestionList = params.tableQuestionList.concat(childlist) params.tableQuestionList = params.tableQuestionList.concat(childlist)
@ -92,11 +116,11 @@ export default {
}, },
// //
getCheckState(item, code) { getCheckState(item, code) {
return item.row.ExportResult.indexOf(code) > -1; return item.row.ExportResult.indexOf(code) > -1
}, },
// //
changeState(item, code) { changeState(item, code) {
item.row.ExportResult.indexOf(code)>-1?item.row.ExportResult.splice(item.row.ExportResult.indexOf(code), 1):item.row.ExportResult.push(code); item.row.ExportResult.indexOf(code) > -1 ? item.row.ExportResult.splice(item.row.ExportResult.indexOf(code), 1) : item.row.ExportResult.push(code);
}, },
} }
} }

View File

@ -837,7 +837,7 @@
:title="$t('trials:reviewTrack:button:export')" :title="$t('trials:reviewTrack:button:export')"
:visible.sync="exportVisible" :visible.sync="exportVisible"
:close-on-click-modal="false" :close-on-click-modal="false"
width="80%" width="60%"
append-to-body> append-to-body>
<ReviewResults :data="searchData" /> <ReviewResults :data="searchData" />
</el-dialog> </el-dialog>