996 lines
36 KiB
Plaintext
996 lines
36 KiB
Plaintext
/* eslint-disable */
|
|
<template>
|
|
<BaseContainer>
|
|
<template slot="search-container">
|
|
<el-form :inline="true">
|
|
<el-form-item :label="$t('trials:consistencyCheck:table:siteId')">
|
|
<el-select v-model="searchData.SiteId" clearable filterable style="width:120px;">
|
|
<el-option
|
|
v-for="(item,index) of siteOptions"
|
|
:key="index"
|
|
:label="item.TrialSiteCode"
|
|
:value="item.SiteId"
|
|
/>
|
|
</el-select>
|
|
</el-form-item>
|
|
<!-- 受试者编号 -->
|
|
<el-form-item :label="$t('trials:consistencyCheck:table:subjectId')">
|
|
<el-input v-model="searchData.SubjectCode" style="width:100px;" />
|
|
</el-form-item>
|
|
<el-form-item style="margin-bottom:10px" label="访视/阅片期名称">
|
|
<el-input
|
|
v-model="searchData.TaskName"
|
|
style="width:100px;"
|
|
clearable
|
|
/>
|
|
</el-form-item>
|
|
<el-form-item style="margin-bottom:10px" label="阅片人">
|
|
<el-select v-model="searchData.DoctorUserId" clearable style="width:120px;">
|
|
<el-option v-for="item of DoctorUserList" :key="'DoctorUserId' + item.DoctorUserId" :value="item.DoctorUserId" :label="item.UserName" />
|
|
</el-select>
|
|
</el-form-item>
|
|
<el-form-item style="margin-bottom:10px" label="是否加急">
|
|
<el-select v-model="searchData.IsUrgent" clearable style="width:120px;">
|
|
<el-option v-for="item of $d.YesOrNo" :key="'IsUrgent' + item.label" :value="item.value" :label="item.label" />
|
|
</el-select>
|
|
</el-form-item>
|
|
<el-form-item style="margin-bottom:10px" label="任务状态">
|
|
<el-select v-model="searchData.TaskState" clearable style="width:120px;">
|
|
<el-option v-for="item of $d.TaskState" :key="'TaskState' + item.label" :value="item.value" :label="item.label" />
|
|
</el-select>
|
|
</el-form-item>
|
|
<el-form-item style="margin-bottom:10px" label="任务类型">
|
|
<el-select v-model="searchData.ReadingCategory" clearable style="width:120px;">
|
|
<el-option v-for="item of $d.ReadingCategory" :key="'ReadingCategory' + item.label" :value="item.value" :label="item.label" />
|
|
</el-select>
|
|
</el-form-item>
|
|
<el-form-item style="margin-bottom:10px" label="分配状态">
|
|
<el-select v-model="searchData.TaskAllocationState" clearable style="width:120px;">
|
|
<el-option v-for="item of $d.TaskAllocationState" :key="'TaskAllocationState' + item.label" :value="item.value" :label="item.label" />
|
|
</el-select>
|
|
</el-form-item>
|
|
<el-form-item style="margin-bottom:10px" label="分配时间">
|
|
<el-date-picker
|
|
v-model="timeList"
|
|
value-format="yyyy-MM-dd HH:mm:ss"
|
|
type="datetimerange"
|
|
range-separator="至"
|
|
start-placeholder="开始日期"
|
|
end-placeholder="结束日期"
|
|
@change="changeTimeList"
|
|
/>
|
|
</el-form-item>
|
|
<el-form-item style="margin-bottom:10px">
|
|
<el-button type="primary" icon="el-icon-search" @click="handleSearch">
|
|
{{ $t('common:button:search') }}
|
|
</el-button>
|
|
<el-button type="primary" icon="el-icon-refresh-left" @click="handleReset">
|
|
{{ $t('common:button:reset') }}
|
|
</el-button>
|
|
</el-form-item>
|
|
</el-form>
|
|
</template>
|
|
<template slot="main-container">
|
|
<el-table
|
|
v-adaptive="{bottomOffset:60}"
|
|
v-loading="loading"
|
|
:data="list"
|
|
stripe
|
|
height="100"
|
|
@sort-change="handleSortChange"
|
|
>
|
|
<el-table-column
|
|
prop="OriginalReReadingTask.IsUrgent"
|
|
:label="$t('trials:consistencyCheck:table:isUrgent')"
|
|
show-overflow-tooltip
|
|
min-width="100"
|
|
sortable="custom"
|
|
>
|
|
<template slot-scope="scope">
|
|
<el-tag v-if="scope.row.IsUrgent" type="danger">{{ $fd('YesOrNo', scope.row.OriginalReReadingTask.IsUrgent) }}</el-tag>
|
|
<el-tag v-else type="primary">{{ $fd('YesOrNo', scope.row.OriginalReReadingTask.IsUrgent) }}</el-tag>
|
|
</template>
|
|
</el-table-column>
|
|
<el-table-column
|
|
prop="OriginalReReadingTask.TaskCode"
|
|
label="任务编号"
|
|
min-width="100"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
/>
|
|
<el-table-column
|
|
prop="OriginalReReadingTask.TrialSiteCode"
|
|
label="中心编号"
|
|
min-width="100"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
/>
|
|
<el-table-column
|
|
prop="OriginalReReadingTask.SubjectCode"
|
|
label="受试者编号"
|
|
min-width="120"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
/>
|
|
<el-table-column
|
|
prop="OriginalReReadingTask.TaskName"
|
|
label="访视/阅片期名称"
|
|
min-width="160"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
/>
|
|
<el-table-column
|
|
prop="OriginalReReadingTask.TaskBlindName"
|
|
label="访视盲态名称"
|
|
min-width="140"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
/>
|
|
<el-table-column
|
|
prop="OriginalReReadingTask.CreateTime"
|
|
label="任务创建时间"
|
|
min-width="140"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
/>
|
|
<el-table-column
|
|
prop="OriginalReReadingTask.TaskState"
|
|
label="任务状态"
|
|
min-width="100"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
>
|
|
<template slot-scope="scope">
|
|
<el-tag v-if="scope.row.OriginalReReadingTask.TaskState === 0" type="primary">{{ $fd('TaskState', scope.row.OriginalReReadingTask.TaskState) }}</el-tag>
|
|
<el-tag v-if="scope.row.OriginalReReadingTask.TaskState === 1" type="info">{{ $fd('TaskState', scope.row.OriginalReReadingTask.TaskState) }}</el-tag>
|
|
<el-tag v-if="scope.row.OriginalReReadingTask.TaskState === 3" type="danger">{{ $fd('TaskState', scope.row.OriginalReReadingTask.TaskState) }}</el-tag>
|
|
<el-tag v-if="scope.row.OriginalReReadingTask.TaskState === 4" type="warning">{{ $fd('TaskState', scope.row.OriginalReReadingTask.TaskState) }}</el-tag>
|
|
</template>
|
|
</el-table-column>
|
|
<el-table-column
|
|
prop="OriginalReReadingTask.ReadingCategory"
|
|
label="任务类型"
|
|
min-width="100"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
>
|
|
<template slot-scope="scope">
|
|
<el-tag v-if="scope.row.OriginalReReadingTask.ReadingCategory === 1" type="primary">{{ $fd('ReadingCategory', scope.row.OriginalReReadingTask.ReadingCategory) }}</el-tag>
|
|
<el-tag v-if="scope.row.OriginalReReadingTask.ReadingCategory === 2" type="info">{{ $fd('ReadingCategory', scope.row.OriginalReReadingTask.ReadingCategory) }}</el-tag>
|
|
<el-tag v-if="scope.row.OriginalReReadingTask.ReadingCategory === 4" type="danger">{{ $fd('ReadingCategory', scope.row.OriginalReReadingTask.ReadingCategory) }}</el-tag>
|
|
<el-tag v-if="scope.row.OriginalReReadingTask.ReadingCategory === 5" type="warning">{{ $fd('ReadingCategory', scope.row.OriginalReReadingTask.ReadingCategory) }}</el-tag>
|
|
</template>
|
|
</el-table-column>
|
|
<el-table-column
|
|
prop="OriginalReReadingTask.ArmEnum"
|
|
label="角色"
|
|
min-width="80"
|
|
show-overflow-tooltip
|
|
>
|
|
<template slot-scope="scope">
|
|
<el-tag v-if="scope.row.OriginalReReadingTask.ArmEnum === 1" type="primary">{{ $fd('ArmEnum', scope.row.OriginalReReadingTask.ArmEnum) }}</el-tag>
|
|
<el-tag v-if="scope.row.OriginalReReadingTask.ArmEnum === 2" type="success">{{ $fd('ArmEnum', scope.row.OriginalReReadingTask.ArmEnum) }}</el-tag>
|
|
<el-tag v-if="scope.row.OriginalReReadingTask.ArmEnum === 3" type="info">{{ $fd('ArmEnum', scope.row.OriginalReReadingTask.ArmEnum) }}</el-tag>
|
|
<el-tag v-if="scope.row.OriginalReReadingTask.ArmEnum === 4" type="danger">{{ $fd('ArmEnum', scope.row.OriginalReReadingTask.ArmEnum) }}</el-tag>
|
|
<el-tag v-if="scope.row.OriginalReReadingTask.ArmEnum === 5" type="warning">{{ $fd('ArmEnum', scope.row.OriginalReReadingTask.ArmEnum) }}</el-tag>
|
|
</template>
|
|
</el-table-column>
|
|
<el-table-column
|
|
prop="OriginalReReadingTask.UserName"
|
|
label="阅片人"
|
|
min-width="100"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
>
|
|
<template slot-scope="scope">
|
|
{{ scope.row.OriginalReReadingTask.UserName }}({{ scope.row.OriginalReReadingTask.FullName }})
|
|
</template>
|
|
</el-table-column>
|
|
<el-table-column
|
|
prop="OriginalReReadingTask.SignTime"
|
|
label="阅片完成时间"
|
|
min-width="180"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
/>
|
|
<el-table-column
|
|
prop="OriginalReReadingTask.RequestReReadingType"
|
|
label="重阅申请类型"
|
|
min-width="140"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
>
|
|
<template slot-scope="scope">
|
|
<div v-if="scope.row.RequestReReadingType">
|
|
<el-tag v-if="scope.row.RequestReReadingType === 2" type="danger">{{ $fd('RequestReReadingType', scope.row.RequestReReadingType) }}</el-tag>
|
|
<el-tag v-else type="primary">{{ $fd('RequestReReadingType', scope.row.RequestReReadingType) }}</el-tag>
|
|
</div>
|
|
</template>
|
|
</el-table-column>
|
|
<el-table-column
|
|
prop="RequestReReadingTime"
|
|
label="申请时间"
|
|
min-width="100"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
/>
|
|
<el-table-column
|
|
prop="RequestReReadingReason"
|
|
label="申请原因"
|
|
min-width="100"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
/>
|
|
<el-table-column
|
|
prop="AllocateTime"
|
|
label="审批结果"
|
|
min-width="100"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
>
|
|
<template slot-scope="scope">
|
|
<div v-if="scope.row.RequestReReadingResultEnum">
|
|
<el-tooltip v-if="scope.row.RequestReReadingResultEnum === 2" class="item" effect="dark" placement="top">
|
|
<div slot="content">
|
|
{{ scope.row.RequestReReadingRejectReason }}
|
|
</div>
|
|
<el-tag type="danger">{{ $fd('RequestReReadingResult', scope.row.RequestReReadingResultEnum) }}</el-tag>
|
|
</el-tooltip>
|
|
<el-tag v-else type="primary">{{ $fd('RequestReReadingResult', scope.row.RequestReReadingResultEnum) }}</el-tag>
|
|
</div>
|
|
</template>
|
|
</el-table-column>
|
|
<el-table-column
|
|
prop="ReReadingNewTaskCode"
|
|
label="新任务编号"
|
|
min-width="120"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
/>
|
|
<el-table-column
|
|
fixed="right"
|
|
label="操作"
|
|
width="210"
|
|
>
|
|
<template slot-scope="scope">
|
|
<el-button
|
|
:disabled="!!scope.row.RequestReReadingResultEnum || scope.row.RequestReReadingType === 1"
|
|
icon="el-icon-check"
|
|
circle
|
|
title="同意"
|
|
@click="openReReadingOrBackList(scope.row,1)"
|
|
/>
|
|
<el-button
|
|
:disabled="!!scope.row.RequestReReadingResultEnum || scope.row.RequestReReadingType === 1"
|
|
icon="el-icon-close"
|
|
circle
|
|
title="拒绝"
|
|
@click="confirmReReading(scope.row,2, true)"
|
|
/>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table>
|
|
<!-- 分页组件 -->
|
|
<pagination class="page" :total="total" :page.sync="searchData.PageIndex" :limit.sync="searchData.PageSize" @pagination="getList" />
|
|
<el-dialog
|
|
v-if="ConfirmReReadingVisible"
|
|
title="驳回"
|
|
:visible.sync="ConfirmReReadingVisible"
|
|
width="600px"
|
|
append-to-body
|
|
:close-on-click-modal="false"
|
|
custom-class="base-dialog-wrapper"
|
|
>
|
|
<div style="padding:10px;border: 1px solid #e0e0e0;max-height:650px;overflow-y: auto;">
|
|
<el-form
|
|
ref="reasonForm"
|
|
:rules="rules"
|
|
:model="ConfirmReReadingForm"
|
|
class="demo-ruleForm"
|
|
size="small"
|
|
label-width="120px"
|
|
>
|
|
<el-form-item label="驳回原因" prop="RequestReReadingRejectReason">
|
|
<el-input
|
|
v-model="ConfirmReReadingForm.RequestReReadingRejectReason"
|
|
type="textarea"
|
|
:autosize="{ minRows: 2, maxRows: 4}"
|
|
:placeholder="$t('common:ruleMessage:specify')"
|
|
maxlength="500"
|
|
show-word-limit
|
|
/>
|
|
</el-form-item>
|
|
</el-form>
|
|
</div>
|
|
<div slot="footer" class="dialog-footer">
|
|
<!-- 取消 -->
|
|
<el-button :disabled="btnLoading" size="small" type="primary" @click="ConfirmReReadingVisible = false;ConfirmReReadingForm = { RequestReReadingRejectReason: null }">
|
|
{{ $t('common:button:cancel') }}
|
|
</el-button>
|
|
<!-- 保存 -->
|
|
<el-button :loading="btnLoading" size="small" type="primary" @click="confirmReReading(rowData, 2)">
|
|
{{ $t('common:button:save') }}
|
|
</el-button>
|
|
</div>
|
|
</el-dialog>
|
|
<el-dialog
|
|
v-if="ReReadingOrBackVisible"
|
|
title="重阅影响任务列表"
|
|
:visible.sync="ReReadingOrBackVisible"
|
|
width="1360px"
|
|
append-to-body
|
|
:close-on-click-modal="false"
|
|
custom-class="base-dialog-wrapper"
|
|
>
|
|
<div class="base-dialog-body">
|
|
<el-table
|
|
v-loading="loading"
|
|
:data="InfluenceTaskList"
|
|
stripe
|
|
height="100"
|
|
style="min-height: 400px;"
|
|
>
|
|
<el-table-column
|
|
prop="TaskCode"
|
|
label="任务编号"
|
|
min-width="100"
|
|
show-overflow-tooltip
|
|
/>
|
|
<el-table-column
|
|
prop="TrialSiteCode"
|
|
label="中心编号"
|
|
min-width="100"
|
|
show-overflow-tooltip
|
|
/>
|
|
<el-table-column
|
|
prop="SubjectCode"
|
|
label="受试者编号"
|
|
min-width="120"
|
|
show-overflow-tooltip
|
|
/>
|
|
<el-table-column
|
|
prop="VisitTaskNum"
|
|
label="访视/阅片期名称"
|
|
min-width="160"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
>
|
|
<template slot-scope="scope">
|
|
{{scope.row.TaskName}}
|
|
</template>
|
|
</el-table-column>
|
|
<el-table-column
|
|
prop="TaskBlindName"
|
|
label="访视盲态名称"
|
|
min-width="140"
|
|
show-overflow-tooltip
|
|
/>
|
|
<el-table-column
|
|
prop="TaskBlindName"
|
|
label="访视盲态名称"
|
|
min-width="140"
|
|
show-overflow-tooltip
|
|
/>
|
|
<el-table-column
|
|
prop="TaskState"
|
|
label="任务状态"
|
|
min-width="100"
|
|
sortable="custom"
|
|
show-overflow-tooltip
|
|
>
|
|
<template slot-scope="scope">
|
|
<el-tag v-if="scope.row.TaskState === 0" type="primary">{{ $fd('TaskState', scope.row.TaskState) }}</el-tag>
|
|
<el-tag v-if="scope.row.TaskState === 1" type="info">{{ $fd('TaskState', scope.row.TaskState) }}</el-tag>
|
|
<el-tag v-if="scope.row.TaskState === 3" type="danger">{{ $fd('TaskState', scope.row.TaskState) }}</el-tag>
|
|
<el-tag v-if="scope.row.TaskState === 4" type="warning">{{ $fd('TaskState', scope.row.TaskState) }}</el-tag>
|
|
</template>
|
|
</el-table-column>
|
|
<el-table-column
|
|
prop="ReadingCategory"
|
|
min-width="100"
|
|
label="任务类型"
|
|
show-overflow-tooltip
|
|
>
|
|
<template slot-scope="scope">
|
|
<el-tag v-if="scope.row.ReadingCategory === 1" type="primary">{{ $fd('ReadingCategory', scope.row.ReadingCategory) }}</el-tag>
|
|
<el-tag v-if="scope.row.ReadingCategory === 2" type="info">{{ $fd('ReadingCategory', scope.row.ReadingCategory) }}</el-tag>
|
|
<el-tag v-if="scope.row.ReadingCategory === 4" type="danger">{{ $fd('ReadingCategory', scope.row.ReadingCategory) }}</el-tag>
|
|
<el-tag v-if="scope.row.ReadingCategory === 5" type="warning">{{ $fd('ReadingCategory', scope.row.ReadingCategory) }}</el-tag>
|
|
</template>
|
|
</el-table-column>
|
|
<el-table-column
|
|
prop="OptType"
|
|
label="生效后任务状态"
|
|
min-width="160"
|
|
show-overflow-tooltip
|
|
>
|
|
<template slot-scope="scope">
|
|
<el-tag v-if="scope.row.OptType === 0" type="primary">{{ $fd('TaskState', scope.row.OptType) }}</el-tag>
|
|
<el-tag v-if="scope.row.OptType === 1" type="info">{{ $fd('TaskState', scope.row.OptType) }}</el-tag>
|
|
<el-tag v-if="scope.row.OptType === 3" type="danger">{{ $fd('TaskState', scope.row.OptType) }}</el-tag>
|
|
<el-tag v-if="scope.row.OptType === 4" type="warning">{{ $fd('TaskState', scope.row.OptType) }}</el-tag>
|
|
</template>
|
|
</el-table-column>
|
|
<el-table-column
|
|
prop="UserName"
|
|
label="阅片人"
|
|
min-width="160"
|
|
show-overflow-tooltip
|
|
>
|
|
<template v-if="scope.row.DoctorUser.UserName" slot-scope="scope">
|
|
{{ scope.row.DoctorUser.UserName }}({{ scope.row.DoctorUser.FullName }})
|
|
</template>
|
|
</el-table-column>
|
|
</el-table>
|
|
</div>
|
|
<div slot="footer" class="dialog-footer">
|
|
<!-- 取消 -->
|
|
<el-button :disabled="btnLoading" size="small" type="primary" @click="ReReadingOrBackVisible = false">
|
|
{{ $t('common:button:cancel') }}
|
|
</el-button>
|
|
<!-- 保存 -->
|
|
<el-button :loading="btnLoading" size="small" type="primary" @click="confirmReReading(rowData, 1)">
|
|
确定
|
|
</el-button>
|
|
</div>
|
|
</el-dialog>
|
|
</template>
|
|
</BaseContainer>
|
|
</template>
|
|
<script>
|
|
import { getTrialSiteSelect } from '@/api/trials'
|
|
import { getReReadingOrBackInfluenceTaskList, applyReReading, confirmReReading, getSPMReReadingTaskList, assignSubjectTaskToDoctor, manualAssignDoctorApplyTask, autoSubjectAssignDoctor, getTaskAllocationRuleList, getSubjectAssignList, assignSubjectDoctor, cancelSubjectAssignDoctor, deleteTaskAllocationRule, configTrialTaskInfo, getDoctorUserSelectList } from '@/api/trials/reading'
|
|
import BaseContainer from '@/components/BaseContainer'
|
|
import Pagination from '@/components/Pagination'
|
|
import { getToken } from '@/utils/auth'
|
|
import { changeURLStatic } from '@/utils/history.js'
|
|
const searchDataDefault = () => {
|
|
return {
|
|
PageIndex: 1,
|
|
PageSize: 20,
|
|
Asc: true,
|
|
SortField: '',
|
|
TrialId: null,
|
|
SiteId: null,
|
|
SubjectId: null,
|
|
SubjectCode: null,
|
|
IsUrgent: null,
|
|
TaskName: null,
|
|
TaskState: null,
|
|
DoctorUserId: null,
|
|
ReadingCategory: null,
|
|
TaskAllocationState: null,
|
|
BeginAllocateDate: null,
|
|
EndAllocateDate: null,
|
|
RootReReadingTaskId: null
|
|
}
|
|
}
|
|
export default {
|
|
name: 'TrialsNotice',
|
|
components: { BaseContainer, Pagination },
|
|
data() {
|
|
return {
|
|
searchData: searchDataDefault(),
|
|
ReReadingOrBackVisible: false,
|
|
InfluenceTaskList: [],
|
|
maxLength: 0,
|
|
list: [],
|
|
siteOptions: [],
|
|
total: 0,
|
|
SubjectAssignListTotal: 0,
|
|
loading: false,
|
|
AllocationConfigVisible: false,
|
|
ConfirmReReadingForm: {
|
|
RequestReReadingRejectReason: null
|
|
},
|
|
rules: {
|
|
RequestReReadingRejectReason: [{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' }]
|
|
},
|
|
ConfirmReReadingVisible: false,
|
|
taskAllocationRuleVisible: false,
|
|
AutoAlloctionVisible: false,
|
|
manualAllocationVisible: false,
|
|
trialId: this.$route.query.trialId,
|
|
currentData: {},
|
|
param: {},
|
|
DoctorUserList: [],
|
|
TaskAllocationRuleList: [],
|
|
btnLoading: false,
|
|
value: true,
|
|
value1: true,
|
|
TrialTaskInfo: {
|
|
TrialId: null,
|
|
TaskAllocateObjEnum: 0,
|
|
FollowVisitAutoAssignDefaultState: 0,
|
|
FollowGlobalVisitAutoAssignDefaultState: 0,
|
|
TaskAllocateDefaultState: 1
|
|
},
|
|
title: '',
|
|
rowData: {},
|
|
timeList: [],
|
|
SubjectAssignList: [],
|
|
SubjectAssignSelectList: [],
|
|
TaskAllocationRuleSelectList: [],
|
|
readVisible: false,
|
|
TaskOptType: null,
|
|
OtherInfo: null,
|
|
ReadingType: null
|
|
}
|
|
},
|
|
mounted() {
|
|
if (this.$route.query.SiteId) {
|
|
this.searchData.SiteId = this.$route.query.SiteId
|
|
this.searchData.SubjectCode = this.$route.query.SubjectCode
|
|
this.searchData.TaskName = this.$route.query.TaskName
|
|
this.searchData.DoctorUserId = this.$route.query.DoctorUserId
|
|
changeURLStatic('SiteId', '')
|
|
changeURLStatic('SubjectCode', '')
|
|
changeURLStatic('TaskName', '')
|
|
changeURLStatic('DoctorUserId', '')
|
|
}
|
|
this.getList()
|
|
this.getSite()
|
|
this.getDoctorUserSelectList()
|
|
},
|
|
methods: {
|
|
openReReadingOrBackList(row) {
|
|
this.loading = true
|
|
this.rowData = {...row}
|
|
getReReadingOrBackInfluenceTaskList(row.OriginalReReadingTaskId, true, row.Id).then(res => {
|
|
this.InfluenceTaskList = res.Result
|
|
this.ReReadingOrBackVisible = true
|
|
this.loading = false
|
|
}).catch(() => {this.loading = false})
|
|
},
|
|
lookReadingResults(row) {
|
|
var token = getToken()
|
|
const routeData = this.$router.resolve({
|
|
path: `/noneDicomReading?subjectId=${row.SubjectId}&trialId=${row.TrialId}&visitTaskId=${row.NewReReadingTaskId}&TokenKey=${token}`
|
|
})
|
|
window.open(routeData.href, '_blank')
|
|
},
|
|
// 申请重阅
|
|
applyReReading(row) {
|
|
this.$confirm('确定要申请重阅?').then(() => {
|
|
this.loading = true
|
|
this.btnLoading = true
|
|
var params = {
|
|
TaskIdList: [
|
|
row.NewReReadingTaskId
|
|
],
|
|
TrialId: this.$route.query.trialId,
|
|
RequestReReadingType: 2,
|
|
RequestReReadingReason: ''
|
|
}
|
|
applyReReading(params).then(() => {
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
this.$message.success('申请重阅成功')
|
|
this.getList()
|
|
}).catch(() => {
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
})
|
|
})
|
|
},
|
|
confirmReReading(row, type, open) {
|
|
if (open) {
|
|
this.rowData = { ...row }
|
|
this.ConfirmReReadingVisible = true
|
|
this.ConfirmReReadingForm = {
|
|
RequestReReadingRejectReason: null
|
|
}
|
|
return
|
|
}
|
|
if (type === 2) {
|
|
this.$refs.reasonForm.validate((valid) => {
|
|
if (!valid) return
|
|
var params = {
|
|
ConfirmReReadingList: [
|
|
{
|
|
Id: row.Id,
|
|
OriginalReReadingTaskId: row.OriginalReReadingTaskId,
|
|
RootReReadingTaskId: row.RootReReadingTaskId,
|
|
NewReReadingTaskId: row.NewReReadingTaskId
|
|
}
|
|
],
|
|
RequestReReadingRejectReason: this.ConfirmReReadingForm.RequestReReadingRejectReason,
|
|
TrialId: this.$route.query.trialId,
|
|
RequestReReadingResultEnum: type
|
|
}
|
|
this.loading = true
|
|
this.btnLoading = true
|
|
confirmReReading(params).then(() => {
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
this.$message.success(`${type === 1 ? '同意' : '拒绝'}申请成功`)
|
|
this.getList()
|
|
this.ConfirmReReadingVisible = false
|
|
}).catch(() => {
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
})
|
|
})
|
|
return
|
|
}
|
|
this.$confirm(`确定${type === 1 ? '同意' : '拒绝'}该重阅申请?`).then(() => {
|
|
var params = {
|
|
ConfirmReReadingList: [
|
|
{
|
|
Id: row.Id,
|
|
OriginalReReadingTaskId: row.OriginalReReadingTaskId,
|
|
RootReReadingTaskId: row.RootReReadingTaskId,
|
|
NewReReadingTaskId: row.NewReReadingTaskId
|
|
}
|
|
],
|
|
TrialId: this.$route.query.trialId,
|
|
RequestReReadingResultEnum: type
|
|
}
|
|
this.loading = true
|
|
this.btnLoading = true
|
|
confirmReReading(params).then(() => {
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
this.$message.success(`${type === 1 ? '同意' : '拒绝'}申请成功`)
|
|
this.ReReadingOrBackVisible = false
|
|
this.getList()
|
|
}).catch(() => {
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
})
|
|
})
|
|
},
|
|
assignSubjectTaskToDoctor(row, type) {
|
|
this.rowData = { ...row }
|
|
this.rowData.TaskOptType = type
|
|
if (type === 1 || type === 2) {
|
|
this.readVisible = true
|
|
} else if (type === 3) {
|
|
this.$confirm('是否确定分配').then(() => {
|
|
this.btnLoading = true
|
|
this.loading = true
|
|
var params = Object.assign({}, this.rowData)
|
|
assignSubjectTaskToDoctor(params).then(() => {
|
|
this.$message.success('保存成功')
|
|
this.btnLoading = false
|
|
this.loading = false
|
|
this.readVisible = false
|
|
this.getList()
|
|
}).catch(() => {
|
|
this.btnLoading = false
|
|
this.loading = false
|
|
})
|
|
})
|
|
} else if (type === 4) {
|
|
this.$confirm('是否确定取消分配').then(() => {
|
|
this.btnLoading = true
|
|
this.loading = true
|
|
var params = Object.assign({}, this.rowData)
|
|
assignSubjectTaskToDoctor(params).then(() => {
|
|
this.$message.success('保存成功')
|
|
this.btnLoading = false
|
|
this.loading = false
|
|
this.readVisible = false
|
|
this.getList()
|
|
}).catch(() => {
|
|
this.btnLoading = false
|
|
this.loading = false
|
|
})
|
|
})
|
|
}
|
|
},
|
|
assignSubjectTaskToDoctorSave() {
|
|
this.$refs.readDataForm.validate(valid => {
|
|
if (!valid) return
|
|
this.btnLoading = true
|
|
this.loading = true
|
|
var params = Object.assign({}, this.rowData)
|
|
assignSubjectTaskToDoctor(params).then(() => {
|
|
this.$message.success('保存成功')
|
|
this.btnLoading = false
|
|
this.loading = false
|
|
this.readVisible = false
|
|
this.getList()
|
|
}).catch(() => {
|
|
this.btnLoading = false
|
|
this.loading = false
|
|
})
|
|
})
|
|
},
|
|
manualAssignDoctorApplyTask(row) {
|
|
console.log(row)
|
|
var params = {
|
|
TrialId: this.trialId
|
|
}
|
|
if (row) {
|
|
params.SubjectDoctorUserList = [
|
|
row
|
|
]
|
|
}
|
|
this.$confirm('确定将当前已分配阅片人应用到任务?').then(() => {
|
|
this.loading = true
|
|
this.btnLoading = true
|
|
manualAssignDoctorApplyTask(params).then(() => {
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
this.$message.success('应用成功')
|
|
this.getList()
|
|
this.openAutoAlloction()
|
|
}).catch(() => {
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
})
|
|
})
|
|
},
|
|
autoSubjectAssignDoctor() {
|
|
this.$confirm('确定执行自动分配?').then(() => {
|
|
this.loading = true
|
|
this.btnLoading = true
|
|
autoSubjectAssignDoctor({ TrialId: this.trialId }).then(() => {
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
this.$message.success('自动分配成功')
|
|
this.getList()
|
|
this.openAutoAlloction()
|
|
}).catch(() => {
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
})
|
|
})
|
|
},
|
|
handleSaveTaskAllocationRuleSelectList() {
|
|
if (this.TaskAllocationRuleSelectList.length === 0) {
|
|
this.$message.error('请选择阅片人')
|
|
return
|
|
}
|
|
var num
|
|
if (this.ReadingType === 2) {
|
|
num = 2
|
|
} else {
|
|
num = 1
|
|
}
|
|
if (this.TaskAllocationRuleSelectList.length !== num) {
|
|
this.$message.error(`当前阅片模式为${this.$fd('ReadingMethod', this.ReadingType)},请选择正确阅片人数量`)
|
|
return
|
|
}
|
|
this.loading = true
|
|
this.btnLoading = true
|
|
var params = {
|
|
DoctorUserIdArmList: this.TaskAllocationRuleSelectList.map((v, i) => { return { DoctorUserId: v.DoctorUserId, ArmEnum: this.ReadingType === 1 ? 1 : i + 1 } }),
|
|
SubjectIdList: this.SubjectAssignSelectList.map(v => v.SubjectId),
|
|
TrialId: this.trialId,
|
|
IsReAssign: true
|
|
}
|
|
assignSubjectDoctor(params).then(() => {
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
this.openAutoAlloction()
|
|
this.TaskAllocationRuleSelectList = []
|
|
this.SubjectAssignSelectList = []
|
|
this.getDoctorUserSelectList()
|
|
this.$message.success('分配成功')
|
|
this.manualAllocationVisible = false
|
|
}).catch(() => {
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
})
|
|
},
|
|
selectable(row) {
|
|
var num
|
|
if (this.ReadingType === 2) {
|
|
num = 2
|
|
} else {
|
|
num = 1
|
|
}
|
|
if (this.TaskAllocationRuleSelectList.length === num && !this.TaskAllocationRuleSelectList.find(v => { return v.UserName === row.UserName })) {
|
|
return false
|
|
} else {
|
|
return true
|
|
}
|
|
},
|
|
cancelSubjectAssignDoctor(row) {
|
|
if (row) {
|
|
this.$confirm('确定要清空该受试者的阅片人吗?').then(() => {
|
|
var params = {
|
|
SubjectIdList: [row.SubjectId],
|
|
TrialId: this.trialId
|
|
}
|
|
this.loading = true
|
|
this.btnLoading = true
|
|
cancelSubjectAssignDoctor(params).then(() => {
|
|
this.$message.success('清空成功')
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
this.openAutoAlloction()
|
|
}).catch(() => {
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
})
|
|
})
|
|
return
|
|
}
|
|
if (this.SubjectAssignSelectList.length === 0) {
|
|
this.$message.error('请勾选要清空阅片人的受试者')
|
|
return
|
|
}
|
|
this.$confirm('确定要清空该受试者的阅片人吗?').then(() => {
|
|
var params = {
|
|
SubjectIdList: this.SubjectAssignSelectList.map(v => v.SubjectId),
|
|
TrialId: this.trialId
|
|
}
|
|
this.loading = true
|
|
this.btnLoading = true
|
|
cancelSubjectAssignDoctor(params).then(() => {
|
|
this.$message.success('清空成功')
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
this.openAutoAlloction()
|
|
}).catch(() => {
|
|
this.loading = false
|
|
this.btnLoading = false
|
|
})
|
|
})
|
|
},
|
|
manualAllocation(row) {
|
|
if (row) {
|
|
this.SubjectAssignSelectList = [row]
|
|
}
|
|
if (this.SubjectAssignSelectList.length === 0) {
|
|
this.$message.error('请勾选要分配的受试者')
|
|
return
|
|
}
|
|
this.manualAllocationVisible = true
|
|
},
|
|
handleTaskAllocationRuleListSelectChange(e) {
|
|
this.TaskAllocationRuleSelectList = e
|
|
},
|
|
handleSubjectAssignListSelectChange(e) {
|
|
this.SubjectAssignSelectList = e
|
|
},
|
|
changeTimeList() {
|
|
if (this.timeList) {
|
|
this.searchData.BeginAllocateDate = this.timeList[0]
|
|
this.searchData.EndAllocateDate = this.timeList[1]
|
|
} else {
|
|
this.searchData.BeginAllocateDate = null
|
|
this.searchData.EndAllocateDate = null
|
|
}
|
|
},
|
|
handleCancel() {
|
|
this.AllocationConfigVisible = false
|
|
},
|
|
handleSave() {
|
|
this.btnLoading = true
|
|
this.loading = true
|
|
var params = Object.assign({}, this.TrialTaskInfo)
|
|
params.TrialId = this.$route.query.trialId
|
|
configTrialTaskInfo(params).then(() => {
|
|
this.btnLoading = false
|
|
this.loading = false
|
|
this.AllocationConfigVisible = false
|
|
this.getList()
|
|
this.$message.success('保存成功')
|
|
}).catch(() => {
|
|
this.btnLoading = false
|
|
this.loading = false
|
|
})
|
|
},
|
|
handleDelete(row) {
|
|
this.$confirm(`确定要删除${row.UserName}的任务分配规则?`, {
|
|
type: 'warning',
|
|
distinguishCancelAndClose: true
|
|
}).then(() => {
|
|
this.loading = true
|
|
deleteTaskAllocationRule(row.Id).then(() => {
|
|
this.loading = false
|
|
this.$message.success('删除成功')
|
|
this.openAllocationConfigVisible()
|
|
}).catch(() => { this.loading = false })
|
|
})
|
|
},
|
|
addOrEdit(row) {
|
|
if (row) {
|
|
this.rowData = { ...row }
|
|
this.title = '编辑'
|
|
} else {
|
|
this.rowData = {}
|
|
this.title = '新增'
|
|
}
|
|
this.taskAllocationRuleVisible = true
|
|
},
|
|
openAllocationConfigVisible() {
|
|
this.loading = true
|
|
getTaskAllocationRuleList({
|
|
TrialId: this.$route.query.trialId
|
|
}).then(res => {
|
|
this.loading = false
|
|
this.TaskAllocationRuleList = res.Result
|
|
this.TrialTaskInfo = Object.assign({}, res.OtherInfo)
|
|
this.AllocationConfigVisible = true
|
|
this.taskAllocationRuleVisible = false
|
|
}).catch(() => { this.loading = false })
|
|
},
|
|
openAutoAlloction() {
|
|
this.loading = true
|
|
getTaskAllocationRuleList({
|
|
TrialId: this.$route.query.trialId
|
|
}).then(async(res) => {
|
|
this.taskSearchData.TrialId = this.$route.query.trialId
|
|
var params = Object.assign({}, this.taskSearchData)
|
|
var SubjectAssignListRes = await getSubjectAssignList(params)
|
|
this.SubjectAssignList = SubjectAssignListRes.Result.CurrentPageData
|
|
this.SubjectAssignListTotal = SubjectAssignListRes.Result.TotalCount
|
|
this.loading = false
|
|
this.TaskAllocationRuleList = res.Result
|
|
this.TrialTaskInfo = Object.assign({}, res.OtherInfo)
|
|
this.AutoAlloctionVisible = true
|
|
}).catch(() => { this.loading = false })
|
|
},
|
|
getDoctorUserSelectList() {
|
|
getDoctorUserSelectList(this.$route.query.trialId).then(res => {
|
|
this.DoctorUserList = res.Result
|
|
if (this.DoctorUserList.length > 0) {
|
|
this.ReadingType = this.DoctorUserList[0].ReadingType
|
|
} else {
|
|
this.$alert('请先去选择项目阅片人')
|
|
}
|
|
})
|
|
},
|
|
getList() {
|
|
this.searchData.TrialId = this.$route.query.trialId
|
|
this.loading = true
|
|
getSPMReReadingTaskList(this.searchData).then(res => {
|
|
this.loading = false
|
|
this.OtherInfo = res.OtherInfo
|
|
this.list = res.Result.CurrentPageData
|
|
this.total = res.Result.TotalCount
|
|
}).catch(() => { this.loading = false })
|
|
},
|
|
handleSearch() {
|
|
this.searchData.PageIndex = 1
|
|
this.getList()
|
|
},
|
|
handleReset() {
|
|
this.searchData = searchDataDefault()
|
|
this.getList()
|
|
},
|
|
getSite() {
|
|
getTrialSiteSelect(this.trialId).then(res => {
|
|
this.siteOptions = res.Result
|
|
})
|
|
},
|
|
// 排序
|
|
handleSortChange(column) {
|
|
if (column.order === 'ascending') {
|
|
this.searchData.Asc = true
|
|
} else {
|
|
this.searchData.Asc = false
|
|
}
|
|
this.searchData.SortField = column.prop
|
|
this.searchData.PageIndex = 1
|
|
this.getList()
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
<style lang="scss" scoped>
|
|
>>>.hidden-row{
|
|
display: none;
|
|
}
|
|
>>>.el-dialog__body {
|
|
padding: 15px 20px;
|
|
}
|
|
|
|
>>>.el-tag--danger.el-tag--dark {
|
|
// background-color: #f56c6c!important;
|
|
border-color: none!important;
|
|
// color: #fff!important;
|
|
}
|
|
>>>#TaskAllocationRuleList thead .el-checkbox__inner{
|
|
display: none;
|
|
}
|
|
>>>.el-descriptions-item__label.has-colon:after{
|
|
display: none;
|
|
}
|
|
</style>
|