自定义表格问题预览
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
1d42e5eab5
commit
7692037b67
2
.env.usa
2
.env.usa
|
@ -2,7 +2,7 @@
|
||||||
ENV = 'production'
|
ENV = 'production'
|
||||||
NODE_ENV = 'production'
|
NODE_ENV = 'production'
|
||||||
# base public path
|
# base public path
|
||||||
VUE_APP_BASE_PATH = 'https://ei-code-prod.s3.amazonaws.com/2024-01-19/'
|
VUE_APP_BASE_PATH = 'https://ei-code-prod.s3.amazonaws.com/2024-01-22/'
|
||||||
|
|
||||||
# 是否开启登陆限制 true:是 false:否
|
# 是否开启登陆限制 true:是 false:否
|
||||||
VUE_APP_LOGIN_FOR_PERMISSION = false
|
VUE_APP_LOGIN_FOR_PERMISSION = false
|
||||||
|
|
|
@ -239,7 +239,6 @@
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<template v-if="question.Childrens && question.Childrens.length>0 && question.Type !== 'table'">
|
<template v-if="question.Childrens && question.Childrens.length>0 && question.Type !== 'table'">
|
||||||
<QuestionFormItem
|
<QuestionFormItem
|
||||||
v-for="(item) in question.Childrens"
|
v-for="(item) in question.Childrens"
|
||||||
|
|
|
@ -75,7 +75,8 @@
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 文件类型 -->
|
<!-- 文件类型 -->
|
||||||
<el-form-item v-if="form.Type === 'upload'" :label="$t('trials:readingUnit:qsList:title:FileType')" prop="DataSource">
|
<el-form-item v-if="form.Type === 'upload'" :label="$t('trials:readingUnit:qsList:title:FileType')"
|
||||||
|
prop="DataSource">
|
||||||
<el-checkbox-group
|
<el-checkbox-group
|
||||||
v-model="form.FileType"
|
v-model="form.FileType"
|
||||||
@change="(v) => {
|
@change="(v) => {
|
||||||
|
@ -97,7 +98,8 @@
|
||||||
</el-checkbox-group>
|
</el-checkbox-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 最大字符数 -->
|
<!-- 最大字符数 -->
|
||||||
<el-form-item v-if="form.Type === 'input' || form.Type === 'textarea'" :label="$t('trials:readingUnit:qsList:title:MaxAnswerLength')">
|
<el-form-item v-if="form.Type === 'input' || form.Type === 'textarea'"
|
||||||
|
:label="$t('trials:readingUnit:qsList:title:MaxAnswerLength')">
|
||||||
<el-input v-model="form.MaxAnswerLength"/>
|
<el-input v-model="form.MaxAnswerLength"/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 自增序号前缀 -->
|
<!-- 自增序号前缀 -->
|
||||||
|
@ -120,7 +122,8 @@
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 问题数据来源 -->
|
<!-- 问题数据来源 -->
|
||||||
<el-form-item v-if="form.Type === 'number'" :label="$t('trials:readingUnit:qsList:title:dataSource')" prop="DataSource">
|
<el-form-item v-if="form.Type === 'number'" :label="$t('trials:readingUnit:qsList:title:dataSource')"
|
||||||
|
prop="DataSource">
|
||||||
<el-radio-group
|
<el-radio-group
|
||||||
v-model="form.DataSource"
|
v-model="form.DataSource"
|
||||||
>
|
>
|
||||||
|
@ -192,7 +195,8 @@
|
||||||
>
|
>
|
||||||
<el-input v-model="form.CustomUnit"/>
|
<el-input v-model="form.CustomUnit"/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<div v-if="form.Type === 'number' && form.DataSource === 1" style="background: #f8f8f8;padding: 10px 0px;border-radius: 10px;position: relative;margin-bottom: 10px;">
|
<div v-if="form.Type === 'number' && form.DataSource === 1"
|
||||||
|
style="background: #f8f8f8;padding: 10px 0px;border-radius: 10px;position: relative;margin-bottom: 10px;">
|
||||||
<!-- 运算类型 -->
|
<!-- 运算类型 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
:label="$t('trials:readingUnit:qsList:title:customCalculateMark')"
|
:label="$t('trials:readingUnit:qsList:title:customCalculateMark')"
|
||||||
|
@ -248,7 +252,9 @@
|
||||||
min-width="70"
|
min-width="70"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ scope.$index === 0 && [1, 2, 3, 4].includes(form.CustomCalculateMark) ? null : $fd('CustomCalculateMark', form.CustomCalculateMark) }}
|
{{
|
||||||
|
scope.$index === 0 && [1, 2, 3, 4].includes(form.CustomCalculateMark) ? null : $fd('CustomCalculateMark', form.CustomCalculateMark)
|
||||||
|
}}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- 表格名称 -->
|
<!-- 表格名称 -->
|
||||||
|
@ -261,7 +267,8 @@
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-select v-model="scope.row.QuestionId" clearable :disabled="!scope.row.IsTable">
|
<el-select v-model="scope.row.QuestionId" clearable :disabled="!scope.row.IsTable">
|
||||||
<el-option v-for="item of tableQuestions" :key="item.QuestionId" :label="item.QuestionName" :value="item.QuestionId" />
|
<el-option v-for="item of tableQuestions" :key="item.QuestionId" :label="item.QuestionName"
|
||||||
|
:value="item.QuestionId"/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
@ -274,10 +281,13 @@
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-select v-if="!scope.row.IsTable" v-model="scope.row.TableQuestionId" clearable>
|
<el-select v-if="!scope.row.IsTable" v-model="scope.row.TableQuestionId" clearable>
|
||||||
<el-option v-for="item of Questions" :key="item.QuestionId" :label="item.QuestionName" :value="item.QuestionId" />
|
<el-option v-for="item of Questions" :key="item.QuestionId" :label="item.QuestionName"
|
||||||
|
:value="item.QuestionId"/>
|
||||||
</el-select>
|
</el-select>
|
||||||
<el-select v-if="scope.row.IsTable" v-model="scope.row.TableQuestionId" clearable>
|
<el-select v-if="scope.row.IsTable" v-model="scope.row.TableQuestionId" clearable>
|
||||||
<el-option v-for="item of !scope.row.QuestionId ? [] : tableQuestions.find(v => v.QuestionId === scope.row.QuestionId).TableQuestions" :key="item.QuestionId" :label="item.QuestionName" :value="item.QuestionId" />
|
<el-option
|
||||||
|
v-for="item of !scope.row.QuestionId ? [] : tableQuestions.find(v => v.QuestionId === scope.row.QuestionId).TableQuestions"
|
||||||
|
:key="item.QuestionId" :label="item.QuestionName" :value="item.QuestionId"/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
@ -310,7 +320,9 @@
|
||||||
</el-table>
|
</el-table>
|
||||||
<div style="font-size: 12px;color:#666;padding: 0 15px 0;text-align: right">
|
<div style="font-size: 12px;color:#666;padding: 0 15px 0;text-align: right">
|
||||||
<!-- '请选择同级问题!': '请选择表格问题下的子问题!' -->
|
<!-- '请选择同级问题!': '请选择表格问题下的子问题!' -->
|
||||||
<i class="el-icon-info" />{{ [1, 2, 3, 4].includes(form.CustomCalculateMark) ? $t('trials:readingUnit:qsList:message:msg1') : $t('trials:readingUnit:qsList:message:msg2') }}
|
<i class="el-icon-info"/>{{
|
||||||
|
[1, 2, 3, 4].includes(form.CustomCalculateMark) ? $t('trials:readingUnit:qsList:message:msg1') : $t('trials:readingUnit:qsList:message:msg2')
|
||||||
|
}}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- 选项类型 -->
|
<!-- 选项类型 -->
|
||||||
|
@ -358,7 +370,8 @@
|
||||||
prop="ClassifyQuestionId"
|
prop="ClassifyQuestionId"
|
||||||
>
|
>
|
||||||
<el-select v-model="form.ClassifyQuestionId" clearable>
|
<el-select v-model="form.ClassifyQuestionId" clearable>
|
||||||
<el-option v-for="item of Questions" :key="item.QuestionId" :label="item.QuestionName" :value="item.QuestionId" />
|
<el-option v-for="item of Questions" :key="item.QuestionId" :label="item.QuestionName"
|
||||||
|
:value="item.QuestionId"/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
|
@ -480,7 +493,9 @@
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 是否必填 -->
|
<!-- 是否必填 -->
|
||||||
<el-form-item v-if="form.Type !== 'group' && form.Type !== 'table' && form.Type !== 'summary' || form.Type === 'class'" :label="$t('trials:readingUnit:qsList:title:isRequired')" prop="IsRequired">
|
<el-form-item
|
||||||
|
v-if="form.Type !== 'group' && form.Type !== 'table' && form.Type !== 'summary' || form.Type === 'class'"
|
||||||
|
:label="$t('trials:readingUnit:qsList:title:isRequired')" prop="IsRequired">
|
||||||
<el-radio-group
|
<el-radio-group
|
||||||
v-model="form.IsRequired"
|
v-model="form.IsRequired"
|
||||||
:disabled="form.IsJudgeQuestion===true || form.ShowQuestion===2"
|
:disabled="form.IsJudgeQuestion===true || form.ShowQuestion===2"
|
||||||
|
@ -515,7 +530,8 @@
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 显示时依赖父问题触发值 -->
|
<!-- 显示时依赖父问题触发值 -->
|
||||||
<el-form-item v-if="form.ParentId && form.ShowQuestion===1" :label="$t('trials:readingUnit:qsList:title:parentTriggerValueList')" prop="ParentTriggerValueList">
|
<el-form-item v-if="form.ParentId && form.ShowQuestion===1"
|
||||||
|
:label="$t('trials:readingUnit:qsList:title:parentTriggerValueList')" prop="ParentTriggerValueList">
|
||||||
<el-select v-model="form.ParentTriggerValueList" clearable multiple>
|
<el-select v-model="form.ParentTriggerValueList" clearable multiple>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item of parentTriggerValOptions"
|
v-for="item of parentTriggerValOptions"
|
||||||
|
@ -581,7 +597,8 @@
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 是否裁判问题 -->
|
<!-- 是否裁判问题 -->
|
||||||
<el-form-item v-if="form.Type === 'select' || form.Type === 'radio' || form.Type === 'number'" :label="$t('trials:readingUnit:qsList:title:isJudgeQuestion')">
|
<el-form-item v-if="form.Type === 'select' || form.Type === 'radio' || form.Type === 'number'"
|
||||||
|
:label="$t('trials:readingUnit:qsList:title:isJudgeQuestion')">
|
||||||
<el-radio-group
|
<el-radio-group
|
||||||
v-model="form.IsJudgeQuestion"
|
v-model="form.IsJudgeQuestion"
|
||||||
@change="((val)=>{isJudgeQuestionChange(val, form)})"
|
@change="((val)=>{isJudgeQuestionChange(val, form)})"
|
||||||
|
@ -595,16 +612,29 @@
|
||||||
</el-radio>
|
</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 限制显示 -->
|
||||||
|
<el-form-item :label="$t('trials:readingUnit:qsList:title:LimitShow')">
|
||||||
|
<el-radio-group v-model="form.LimitShow" @change="(v) => {
|
||||||
|
if (v !== 0) {
|
||||||
|
form.LimitEdit = v
|
||||||
|
}
|
||||||
|
}">
|
||||||
|
<el-radio v-for="item of $d.LimitShow" :key="item.id" :label="item.value">{{ item.label }}</el-radio>
|
||||||
|
</el-radio-group>
|
||||||
|
</el-form-item>
|
||||||
<!-- 限制编辑 -->
|
<!-- 限制编辑 -->
|
||||||
<el-form-item :label="$t('trials:readingUnit:qsList:title:limitEdit')">
|
<el-form-item :label="$t('trials:readingUnit:qsList:title:limitEdit')">
|
||||||
<el-radio-group v-model="form.LimitEdit">
|
<el-radio-group v-model="form.LimitEdit" :disabled="form.LimitShow !== 0">
|
||||||
<el-radio v-for="item of $d.LimitEdit" :key="item.id" :label="item.value">{{ item.label }}</el-radio>
|
<el-radio v-for="item of $d.LimitEdit" :key="item.id" :label="item.value">{{ item.label }}</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 全局阅片是否显示 -->
|
<!-- 全局阅片是否显示 -->
|
||||||
<el-form-item :label="$t('trials:readingUnit:qsList:title:globalReadingShowType')">
|
<el-form-item :label="$t('trials:readingUnit:qsList:title:globalReadingShowType')">
|
||||||
<el-radio-group v-model="form.GlobalReadingShowType">
|
<el-radio-group v-model="form.GlobalReadingShowType">
|
||||||
<el-radio v-for="item of $d.GlobalReadingShowType" :key="item.id" :label="item.value">{{ item.label }}</el-radio>
|
<el-radio v-for="item of $d.GlobalReadingShowType" :key="item.id" :label="item.value">{{
|
||||||
|
item.label
|
||||||
|
}}
|
||||||
|
</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
|
@ -636,7 +666,13 @@
|
||||||
</el-form>
|
</el-form>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { getCalculateQuestions, addOrUpdateReadingQuestionTrial, getTrialCriterionOtherQuestion, getTrialGroupNameList, getCriterionLesionType } from '@/api/trials'
|
import {
|
||||||
|
getCalculateQuestions,
|
||||||
|
addOrUpdateReadingQuestionTrial,
|
||||||
|
getTrialCriterionOtherQuestion,
|
||||||
|
getTrialGroupNameList,
|
||||||
|
getCriterionLesionType
|
||||||
|
} from '@/api/trials'
|
||||||
import {getBasicConfigSelect, getCriterionDictionaryList} from '@/api/dictionary'
|
import {getBasicConfigSelect, getCriterionDictionaryList} from '@/api/dictionary'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
@ -644,19 +680,27 @@ export default {
|
||||||
props: {
|
props: {
|
||||||
digitPlaces: {
|
digitPlaces: {
|
||||||
type: Number,
|
type: Number,
|
||||||
default() { return 0 }
|
default() {
|
||||||
|
return 0
|
||||||
|
}
|
||||||
},
|
},
|
||||||
list: {
|
list: {
|
||||||
type: Array,
|
type: Array,
|
||||||
default() { return [] }
|
default() {
|
||||||
|
return []
|
||||||
|
}
|
||||||
},
|
},
|
||||||
trialCriterionId: {
|
trialCriterionId: {
|
||||||
type: String,
|
type: String,
|
||||||
default() { return '' }
|
default() {
|
||||||
|
return ''
|
||||||
|
}
|
||||||
},
|
},
|
||||||
data: {
|
data: {
|
||||||
type: Object,
|
type: Object,
|
||||||
default() { return {} }
|
default() {
|
||||||
|
return {}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
isFromSystem: {
|
isFromSystem: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
|
@ -724,7 +768,8 @@ export default {
|
||||||
DictionaryCode: null,
|
DictionaryCode: null,
|
||||||
GroupId: null,
|
GroupId: null,
|
||||||
ClassifyQuestionId: null,
|
ClassifyQuestionId: null,
|
||||||
ClassifyAlgorithms: null
|
ClassifyAlgorithms: null,
|
||||||
|
LimitShow: null
|
||||||
// IsEnable: true
|
// IsEnable: true
|
||||||
},
|
},
|
||||||
rules: {
|
rules: {
|
||||||
|
@ -743,7 +788,11 @@ export default {
|
||||||
{required: true, message: this.$t('common:ruleMessage:select'), trigger: ['blur', 'change']}
|
{required: true, message: this.$t('common:ruleMessage:select'), trigger: ['blur', 'change']}
|
||||||
],
|
],
|
||||||
RelevanceId: [{required: true, message: this.$t('common:ruleMessage:select'), trigger: ['blur', 'change']}],
|
RelevanceId: [{required: true, message: this.$t('common:ruleMessage:select'), trigger: ['blur', 'change']}],
|
||||||
RelevanceValueList: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: ['blur', 'change'] }],
|
RelevanceValueList: [{
|
||||||
|
required: true,
|
||||||
|
message: this.$t('common:ruleMessage:select'),
|
||||||
|
trigger: ['blur', 'change']
|
||||||
|
}],
|
||||||
GroupName: [{required: true, message: this.$t('common:ruleMessage:specify'), trigger: ['blur', 'change']},
|
GroupName: [{required: true, message: this.$t('common:ruleMessage:specify'), trigger: ['blur', 'change']},
|
||||||
{max: 50, message: `${this.$t('common:ruleMessage:maxLength')} 50`}]
|
{max: 50, message: `${this.$t('common:ruleMessage:maxLength')} 50`}]
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue