一致性分析完全随机、受试者随机分配规则修改
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
45f392492d
commit
302cad8b57
|
@ -10,39 +10,105 @@
|
||||||
>
|
>
|
||||||
<div class="base-dialog-body">
|
<div class="base-dialog-body">
|
||||||
<!-- 访视数 -->
|
<!-- 访视数 -->
|
||||||
<el-form-item :label="$t('trials:consistencyAnalysisRule:table:visitNum')" prop="PlanVisitCount">
|
<el-form-item
|
||||||
<el-input-number v-model="form.PlanVisitCount" :disabled="isDisable" :min="1" controls-position="right" />
|
:label="$t('trials:consistencyAnalysisRule:table:visitNum')"
|
||||||
|
prop="PlanVisitCount"
|
||||||
|
>
|
||||||
|
<el-input-number
|
||||||
|
v-model="form.PlanVisitCount"
|
||||||
|
:disabled="isDisable"
|
||||||
|
:min="1"
|
||||||
|
controls-position="right"
|
||||||
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 所选访视是否有阅片期 -->
|
<!-- 所选访视是否有阅片期 -->
|
||||||
<el-form-item :label="$t('trials:consistencyAnalysisRule:table:isReadingPeriod')" prop="IsHaveReadingPeriod">
|
<el-form-item
|
||||||
<el-radio-group v-model="form.IsHaveReadingPeriod" :disabled="isDisable" @change="form.IsGenerateGlobalTask = form.IsHaveReadingPeriod">
|
:label="$t('trials:consistencyAnalysisRule:table:isReadingPeriod')"
|
||||||
<el-radio v-for="item of $d.YesOrNo" :key="'form.IsHaveReadingPeriod' + item.value" :label="item.value">{{ item.label }}</el-radio>
|
prop="IsHaveReadingPeriod"
|
||||||
|
>
|
||||||
|
<el-radio-group
|
||||||
|
v-model="form.IsHaveReadingPeriod"
|
||||||
|
:disabled="isDisable || ruleOtherInfo.IsReadingTaskViewInOrder !== 1"
|
||||||
|
@change="form.IsGenerateGlobalTask = form.IsHaveReadingPeriod"
|
||||||
|
>
|
||||||
|
<el-radio
|
||||||
|
v-for="item of $d.YesOrNo"
|
||||||
|
:key="'form.IsHaveReadingPeriod' + item.value"
|
||||||
|
:label="item.value"
|
||||||
|
>{{ item.label }}</el-radio
|
||||||
|
>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 间隔周期(周) -->
|
<!-- 间隔周期(周) -->
|
||||||
<el-form-item v-if="isSelfAnalysis" :label="$t('trials:consistencyAnalysisRule:table:intervalPeriod')" prop="IntervalWeeks">
|
<el-form-item
|
||||||
<el-input-number v-model="form.IntervalWeeks" :min="0" :disabled="isDisable" controls-position="right" />
|
v-if="isSelfAnalysis"
|
||||||
|
:label="$t('trials:consistencyAnalysisRule:table:intervalPeriod')"
|
||||||
|
prop="IntervalWeeks"
|
||||||
|
>
|
||||||
|
<el-input-number
|
||||||
|
v-model="form.IntervalWeeks"
|
||||||
|
:min="0"
|
||||||
|
:disabled="isDisable"
|
||||||
|
controls-position="right"
|
||||||
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 计划病例数 -->
|
<!-- 计划病例数 -->
|
||||||
<el-form-item :label="$t('trials:consistencyAnalysisRule:table:plannedNum')" prop="PlanSubjectCount">
|
<el-form-item
|
||||||
<el-input-number v-model="form.PlanSubjectCount" :min="0" :disabled="isDisable" controls-position="right" />
|
:label="$t('trials:consistencyAnalysisRule:table:plannedNum')"
|
||||||
|
prop="PlanSubjectCount"
|
||||||
|
>
|
||||||
|
<el-input-number
|
||||||
|
v-model="form.PlanSubjectCount"
|
||||||
|
:min="0"
|
||||||
|
:disabled="isDisable"
|
||||||
|
controls-position="right"
|
||||||
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 虚拟中心编号 -->
|
<!-- 虚拟中心编号 -->
|
||||||
<el-form-item :label="$t('trials:consistencyAnalysisRule:table:siteCode')" prop="BlindTrialSiteCode">
|
<el-form-item
|
||||||
<el-input v-model="form.BlindTrialSiteCode" maxlength="10" style="width: 140px;" :disabled="!!Result.BlindTrialSiteCode || !!OtherInfo.VitrualSiteCode" @input="(v)=>(form.BlindTrialSiteCode = v.replace(/[^\a-\z\A-\Z0-9]/g, ''))"/>
|
:label="$t('trials:consistencyAnalysisRule:table:siteCode')"
|
||||||
|
prop="BlindTrialSiteCode"
|
||||||
|
>
|
||||||
|
<el-input
|
||||||
|
v-model="form.BlindTrialSiteCode"
|
||||||
|
maxlength="10"
|
||||||
|
style="width: 140px"
|
||||||
|
:disabled="!!Result.BlindTrialSiteCode || !!OtherInfo.VitrualSiteCode"
|
||||||
|
@input="
|
||||||
|
(v) =>
|
||||||
|
(form.BlindTrialSiteCode = v.replace(/[^\a-\z\A-\Z0-9]/g, ''))
|
||||||
|
"
|
||||||
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 虚拟受试者位数 -->
|
<!-- 虚拟受试者位数 -->
|
||||||
<el-form-item :label="$t('trials:consistencyAnalysisRule:table:subjectNum')" prop="BlindSubjectNumberOfPlaces">
|
<el-form-item
|
||||||
<el-input-number v-model="form.BlindSubjectNumberOfPlaces" :min="1" :disabled="isDisable" :max="5" controls-position="right" />
|
:label="$t('trials:consistencyAnalysisRule:table:subjectNum')"
|
||||||
|
prop="BlindSubjectNumberOfPlaces"
|
||||||
|
>
|
||||||
|
<el-input-number
|
||||||
|
v-model="form.BlindSubjectNumberOfPlaces"
|
||||||
|
:min="1"
|
||||||
|
:disabled="isDisable"
|
||||||
|
:max="5"
|
||||||
|
controls-position="right"
|
||||||
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 是否生成全局阅片任务 -->
|
<!-- 是否生成全局阅片任务 -->
|
||||||
<el-form-item :label="$t('trials:consistencyAnalysisRule:table:isGenerateGlobalTask')" prop="IsGenerateGlobalTask">
|
<el-form-item
|
||||||
|
:label="$t('trials:consistencyAnalysisRule:table:isGenerateGlobalTask')"
|
||||||
|
prop="IsGenerateGlobalTask"
|
||||||
|
>
|
||||||
<el-radio-group v-model="form.IsGenerateGlobalTask" disabled>
|
<el-radio-group v-model="form.IsGenerateGlobalTask" disabled>
|
||||||
<el-radio v-for="item of $d.YesOrNo" :key="'form.IsGenerateGlobalTask' + item.value" :label="item.value">{{ item.label }}</el-radio>
|
<el-radio
|
||||||
|
v-for="item of $d.YesOrNo"
|
||||||
|
:key="'form.IsGenerateGlobalTask' + item.value"
|
||||||
|
:label="item.value"
|
||||||
|
>{{ item.label }}</el-radio
|
||||||
|
>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
<div class="base-dialog-footer" style="text-align:right;margin-top:10px;">
|
<div class="base-dialog-footer" style="text-align: right; margin-top: 10px">
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<!-- 取消 -->
|
<!-- 取消 -->
|
||||||
<el-button
|
<el-button
|
||||||
|
@ -51,64 +117,73 @@
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="close"
|
@click="close"
|
||||||
>
|
>
|
||||||
{{ $t('common:button:cancel') }}
|
{{ $t("common:button:cancel") }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<!-- 保存 -->
|
<!-- 保存 -->
|
||||||
<el-button size="small" type="primary" :loading="btnLoading" :disabled="isDisable" @click="save">
|
<el-button
|
||||||
{{ $t('common:button:save') }}
|
size="small"
|
||||||
|
type="primary"
|
||||||
|
:loading="btnLoading"
|
||||||
|
:disabled="isDisable"
|
||||||
|
@click="save"
|
||||||
|
>
|
||||||
|
{{ $t("common:button:save") }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
</el-form>
|
</el-form>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { getConsistentRule, addOrUpdateTaskConsistentRule } from '@/api/trials/reading'
|
import {
|
||||||
|
getConsistentRule,
|
||||||
|
addOrUpdateTaskConsistentRule,
|
||||||
|
} from "@/api/trials/reading";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'AddOrUpdateTaskAllocationRuleData',
|
name: "AddOrUpdateTaskAllocationRuleData",
|
||||||
props: {
|
props: {
|
||||||
TrialReadingCriterionId: {
|
TrialReadingCriterionId: {
|
||||||
type: String,
|
type: String,
|
||||||
default() {
|
default() {
|
||||||
return ''
|
return "";
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
OtherInfo: {
|
OtherInfo: {
|
||||||
type: Object,
|
type: Object,
|
||||||
default() {
|
default() {
|
||||||
return {}
|
return {};
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
trialCriterionList: {
|
trialCriterionList: {
|
||||||
type: Array,
|
type: Array,
|
||||||
default() {
|
default() {
|
||||||
return []
|
return [];
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
data: {
|
data: {
|
||||||
type: Object,
|
type: Object,
|
||||||
default() {
|
default() {
|
||||||
return {}
|
return {};
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
isDisable: {
|
isDisable: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default() {
|
default() {
|
||||||
return true
|
return true;
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
isSelfAnalysis: {
|
isSelfAnalysis: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default() {
|
default() {
|
||||||
return true
|
return true;
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
doctorUserList: {
|
doctorUserList: {
|
||||||
type: Array,
|
type: Array,
|
||||||
default() {
|
default() {
|
||||||
return []
|
return [];
|
||||||
}
|
},
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
@ -120,81 +195,133 @@ export default {
|
||||||
IntervalWeeks: 3,
|
IntervalWeeks: 3,
|
||||||
IsHaveReadingPeriod: null,
|
IsHaveReadingPeriod: null,
|
||||||
IsGenerateGlobalTask: null,
|
IsGenerateGlobalTask: null,
|
||||||
BlindTrialSiteCode: '',
|
BlindTrialSiteCode: "",
|
||||||
BlindSubjectNumberOfPlaces: 3,
|
BlindSubjectNumberOfPlaces: 3,
|
||||||
IsEnable: true,
|
IsEnable: true,
|
||||||
Note: ''
|
Note: "",
|
||||||
},
|
},
|
||||||
Result:{}, // 接口返回弹窗数据,用于虚拟中心可编辑校验
|
Result: {}, // 接口返回弹窗数据,用于虚拟中心可编辑校验
|
||||||
rules: {
|
rules: {
|
||||||
IsHaveReadingPeriod: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
IsHaveReadingPeriod: [
|
||||||
IsGenerateGlobalTask: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
{
|
||||||
PlanSubjectCount: [{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' }],
|
required: true,
|
||||||
IntervalWeeks: [{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' }],
|
message: this.$t("common:ruleMessage:select"),
|
||||||
PlanVisitCount: [{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' }],
|
trigger: "blur",
|
||||||
BlindTrialSiteCode: [{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' }],
|
},
|
||||||
BlindSubjectNumberOfPlaces: [{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' }],
|
],
|
||||||
|
IsGenerateGlobalTask: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t("common:ruleMessage:select"),
|
||||||
|
trigger: "blur",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
PlanSubjectCount: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t("common:ruleMessage:specify"),
|
||||||
|
trigger: "blur",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
IntervalWeeks: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t("common:ruleMessage:specify"),
|
||||||
|
trigger: "blur",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
PlanVisitCount: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t("common:ruleMessage:specify"),
|
||||||
|
trigger: "blur",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
BlindTrialSiteCode: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t("common:ruleMessage:specify"),
|
||||||
|
trigger: "blur",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
BlindSubjectNumberOfPlaces: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t("common:ruleMessage:specify"),
|
||||||
|
trigger: "blur",
|
||||||
|
},
|
||||||
|
],
|
||||||
},
|
},
|
||||||
loading: false,
|
loading: false,
|
||||||
btnLoading: false
|
btnLoading: false,
|
||||||
}
|
ruleOtherInfo: {},
|
||||||
|
};
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
// this.form.TrialId = this.$route.query.trialId
|
// this.form.TrialId = this.$route.query.trialId
|
||||||
// if (Object.keys(this.data).length && this.data.Id) {
|
// if (Object.keys(this.data).length && this.data.Id) {
|
||||||
// this.form = { ...this.data }
|
// this.form = { ...this.data }
|
||||||
// }
|
// }
|
||||||
this.getFrom()
|
this.getFrom();
|
||||||
},
|
},
|
||||||
watch:{
|
watch: {
|
||||||
"OtherInfo.VitrualSiteCode":{
|
"OtherInfo.VitrualSiteCode": {
|
||||||
handler(){
|
handler() {
|
||||||
this.form.BlindTrialSiteCode = this.OtherInfo.VitrualSiteCode;
|
this.form.BlindTrialSiteCode = this.OtherInfo.VitrualSiteCode;
|
||||||
}
|
},
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getFrom() {
|
getFrom() {
|
||||||
getConsistentRule({
|
getConsistentRule({
|
||||||
TrialId: this.$route.query.trialId,
|
TrialId: this.$route.query.trialId,
|
||||||
IsSelfAnalysis: this.isSelfAnalysis,
|
IsSelfAnalysis: this.isSelfAnalysis,
|
||||||
TrialReadingCriterionId: this.TrialReadingCriterionId
|
TrialReadingCriterionId: this.TrialReadingCriterionId,
|
||||||
}).then(res => {
|
}).then((res) => {
|
||||||
if (res.Result) {
|
this.ruleOtherInfo =
|
||||||
this.form = res.Result;
|
{ IsReadingTaskViewInOrder: res.Result.IsReadingTaskViewInOrder } ||
|
||||||
this.Result = JSON.parse(JSON.stringify(res.Result));
|
{};
|
||||||
|
if (res.Result.ConsistentRuleBasic) {
|
||||||
|
this.form = res.Result.ConsistentRuleBasic;
|
||||||
|
this.Result = JSON.parse(
|
||||||
|
JSON.stringify(res.Result.ConsistentRuleBasic)
|
||||||
|
);
|
||||||
} else {
|
} else {
|
||||||
let o = this.trialCriterionList.find(v => {
|
let o = this.trialCriterionList.find((v) => {
|
||||||
return v.TrialReadingCriterionId === this.TrialReadingCriterionId
|
return v.TrialReadingCriterionId === this.TrialReadingCriterionId;
|
||||||
})
|
});
|
||||||
this.form.IsHaveReadingPeriod = o.IsReadingPeriod
|
this.form.IsHaveReadingPeriod = o.IsReadingPeriod;
|
||||||
this.form.IsGenerateGlobalTask = o.IsReadingPeriod
|
this.form.IsGenerateGlobalTask = o.IsReadingPeriod;
|
||||||
}
|
}
|
||||||
this.form.BlindTrialSiteCode = this.OtherInfo.VitrualSiteCode
|
this.form.BlindTrialSiteCode = this.OtherInfo.VitrualSiteCode;
|
||||||
})
|
});
|
||||||
},
|
},
|
||||||
save() {
|
save() {
|
||||||
this.$refs.taskAllocationRuleDataForm.validate(valid => {
|
this.$refs.taskAllocationRuleDataForm.validate((valid) => {
|
||||||
if (!valid) return
|
if (!valid) return;
|
||||||
this.btnLoading = true
|
this.btnLoading = true;
|
||||||
this.loading = true
|
this.loading = true;
|
||||||
this.form.IsSelfAnalysis = this.isSelfAnalysis
|
this.form.IsSelfAnalysis = this.isSelfAnalysis;
|
||||||
this.form.TrialReadingCriterionId = this.TrialReadingCriterionId
|
this.form.TrialReadingCriterionId = this.TrialReadingCriterionId;
|
||||||
addOrUpdateTaskConsistentRule(this.form).then(res => {
|
addOrUpdateTaskConsistentRule(this.form)
|
||||||
this.loading = false
|
.then((res) => {
|
||||||
this.btnLoading = false
|
this.loading = false;
|
||||||
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
this.btnLoading = false;
|
||||||
this.$emit('close')
|
this.$message.success(this.$t("common:message:savedSuccessfully"));
|
||||||
this.$emit('getList')
|
this.$emit("close");
|
||||||
}).catch(() => {
|
this.$emit("getList");
|
||||||
this.loading = false
|
|
||||||
this.btnLoading = false
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
|
.catch(() => {
|
||||||
|
this.loading = false;
|
||||||
|
this.btnLoading = false;
|
||||||
|
});
|
||||||
|
});
|
||||||
},
|
},
|
||||||
close() { this.$emit('close') }
|
close() {
|
||||||
}
|
this.$emit("close");
|
||||||
}
|
},
|
||||||
|
},
|
||||||
|
};
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
</style>
|
</style>
|
||||||
|
|
Loading…
Reference in New Issue