阅片顺序手动修改添加限制条件
continuous-integration/drone/push Build encountered an error Details

uat
wangxiaoshuang 2025-06-16 17:24:14 +08:00
parent 108d01f81c
commit 48633a1ed4
1 changed files with 11 additions and 4 deletions

View File

@ -188,8 +188,9 @@
sortable="custom" show-overflow-tooltip> sortable="custom" show-overflow-tooltip>
<template slot-scope="scope"> <template slot-scope="scope">
<el-input-number v-model="scope.row.RandomOrder" <el-input-number v-model="scope.row.RandomOrder"
@change="(value, old) => handleChange(scope.row, value, old)" :min="1" style="width: 150px;" @change="(value, old) => handleChange(scope.row, value, old)" :min="0" style="width: 150px;"
:disabled="scope.row.ReadingTaskState === 1"></el-input-number> v-if="scope.row.ReadingTaskState !== 1"></el-input-number>
<span v-else>{{ scope.row.RandomOrder }}</span>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -278,6 +279,7 @@ export default {
async handleChange(row, value, old) { async handleChange(row, value, old) {
try { try {
if (!this.searchData.DoctorUserId || !this.searchData.TrialReadingCriterionId) return false if (!this.searchData.DoctorUserId || !this.searchData.TrialReadingCriterionId) return false
if (!value) throw this.$t('trials:readOrder:message:min1')
let data = { let data = {
TrialId: this.$route.query.trialId, TrialId: this.$route.query.trialId,
TrialReadingCriterionId: this.searchData.TrialReadingCriterionId, TrialReadingCriterionId: this.searchData.TrialReadingCriterionId,
@ -298,6 +300,8 @@ export default {
} catch (err) { } catch (err) {
row.RandomOrder = old row.RandomOrder = old
console.log(err) console.log(err)
this.$message.warning(err)
this.getList()
this.loading = false this.loading = false
} }
}, },
@ -364,8 +368,11 @@ export default {
getReadingTaskList(this.searchData) getReadingTaskList(this.searchData)
.then((res) => { .then((res) => {
this.loading = false this.loading = false
this.list = res.Result.CurrentPageData this.list = []
this.total = res.Result.TotalCount this.$nextTick(() => {
this.list = res.Result.CurrentPageData
this.total = res.Result.TotalCount
})
}) })
.catch(() => { .catch(() => {
this.loading = false this.loading = false