项目添加课题组相关
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
15adb3611a
commit
15e8a8edc2
|
@ -356,4 +356,12 @@ export function getGAUserList() {
|
|||
method: 'get'
|
||||
})
|
||||
}
|
||||
// 修改检查课题组
|
||||
export function modifySCPStudyHospitalGroup(data) {
|
||||
return request({
|
||||
url: `/Patient/modifySCPStudyHospitalGroup`,
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
|
|
|
@ -1,44 +1,23 @@
|
|||
<template>
|
||||
<el-dialog
|
||||
:visible.sync="visible"
|
||||
:close-on-click-modal="false"
|
||||
:fullscreen="true"
|
||||
custom-class="upload-dialog"
|
||||
:before-close="beforeCloseStudyDig"
|
||||
>
|
||||
<span slot="title"
|
||||
>{{ $t('trials:inspection:message:viewStudy') }}({{
|
||||
<el-dialog :visible.sync="visible" :close-on-click-modal="false" :fullscreen="true" custom-class="upload-dialog"
|
||||
:before-close="beforeCloseStudyDig">
|
||||
<span slot="title">{{ $t('trials:inspection:message:viewStudy') }}({{
|
||||
$t('trials:uploadDicomList:table:patientInfo')
|
||||
}}:{{ Patient.PatientIdStr }},{{ Patient.PatientName }})</span
|
||||
>
|
||||
}}:{{ Patient.PatientIdStr }},{{ Patient.PatientName }})</span>
|
||||
<div class="search">
|
||||
<el-form :inline="true" class="base-search-form">
|
||||
<!-- 检查类型 -->
|
||||
<el-form-item :label="$t('trials:audit:table:modality')">
|
||||
<el-select
|
||||
v-model="searchData.Modalities"
|
||||
clearable
|
||||
style="width: 140px"
|
||||
>
|
||||
<el-option
|
||||
v-for="item of $d.modalType"
|
||||
:key="item.id"
|
||||
:label="item.label"
|
||||
:value="item.label"
|
||||
>
|
||||
<el-select v-model="searchData.Modalities" clearable style="width: 140px">
|
||||
<el-option v-for="item of $d.modalType" :key="item.id" :label="item.label" :value="item.label">
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- 检查日期 -->
|
||||
<el-form-item :label="$t('trials:uploadedDicoms:table:studyDate')">
|
||||
<el-date-picker
|
||||
v-model="dateValue"
|
||||
type="datetimerange"
|
||||
range-separator="-"
|
||||
<el-date-picker v-model="dateValue" type="datetimerange" range-separator="-"
|
||||
:start-placeholder="$t('trials:uploadClinicalData:table:beginDate')"
|
||||
:end-placeholder="$t('trials:uploadClinicalData:table:endDate')"
|
||||
:default-time="['00:00:00', '23:59:59']"
|
||||
>
|
||||
:end-placeholder="$t('trials:uploadClinicalData:table:endDate')" :default-time="['00:00:00', '23:59:59']">
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
|
@ -47,143 +26,111 @@
|
|||
{{ $t('common:button:search') }}
|
||||
</el-button>
|
||||
<!-- 重置 -->
|
||||
<el-button
|
||||
type="primary"
|
||||
icon="el-icon-refresh-left"
|
||||
@click="handleReset"
|
||||
>
|
||||
<el-button type="primary" icon="el-icon-refresh-left" @click="handleReset">
|
||||
{{ $t('common:button:reset') }}
|
||||
</el-button>
|
||||
<!-- 选择课题组 -->
|
||||
<el-button type="primary" :disabled="multipleSelection.length <= 0" @click="openGroup">
|
||||
{{ $t('trials:inspection:button:checkGroupId') }}
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
<!--检查列表-->
|
||||
<el-table
|
||||
ref="viewStudyList"
|
||||
v-loading="loading"
|
||||
v-adaptive="{ bottomOffset: 60 }"
|
||||
:data="list"
|
||||
stripe
|
||||
height="100"
|
||||
@sort-change="handleSortByColumn"
|
||||
:default-sort="{ prop: 'StudyTime', order: 'descending' }"
|
||||
>
|
||||
<el-table-column type="index" width="40" />
|
||||
<el-table ref="viewStudyList" v-loading="loading" v-adaptive="{ bottomOffset: 60 }" :data="list" stripe height="100"
|
||||
@sort-change="handleSortByColumn" :default-sort="{ prop: 'StudyTime', order: 'descending' }"
|
||||
@selection-change="handleSelectionChange">
|
||||
<!-- <el-table-column type="index" width="40" /> -->
|
||||
<el-table-column type="selection" width="55" />
|
||||
<!--检查申请号-->
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="AccessionNumber"
|
||||
:label="$t('trials:inspection:table:AccessionNumber')"
|
||||
show-overflow-tooltip
|
||||
min-width="120"
|
||||
sortable="custom"
|
||||
></el-table-column>
|
||||
<el-table-column align="center" prop="AccessionNumber" :label="$t('trials:inspection:table:AccessionNumber')"
|
||||
show-overflow-tooltip min-width="120" sortable="custom"></el-table-column>
|
||||
<!--检查描述-->
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="Description"
|
||||
:label="$t('trials:inspection:table:studyDescription')"
|
||||
show-overflow-tooltip
|
||||
min-width="120"
|
||||
sortable="custom"
|
||||
></el-table-column>
|
||||
<el-table-column align="center" prop="Description" :label="$t('trials:inspection:table:studyDescription')"
|
||||
show-overflow-tooltip min-width="120" sortable="custom"></el-table-column>
|
||||
<!--检查类型-->
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="Modalities"
|
||||
:label="$t('trials:audit:table:modality')"
|
||||
show-overflow-tooltip
|
||||
min-width="120"
|
||||
sortable="custom"
|
||||
></el-table-column>
|
||||
<el-table-column align="center" prop="Modalities" :label="$t('trials:audit:table:modality')" show-overflow-tooltip
|
||||
min-width="120" sortable="custom"></el-table-column>
|
||||
<!--Called AE-->
|
||||
<el-table-column
|
||||
prop="CalledAE"
|
||||
:label="$t('trials:inspection:table:CalledAE')"
|
||||
show-overflow-tooltip
|
||||
min-width="120"
|
||||
>
|
||||
<el-table-column prop="CalledAE" :label="$t('trials:inspection:table:CalledAE')" show-overflow-tooltip
|
||||
min-width="120">
|
||||
</el-table-column>
|
||||
<!--Calling AE-->
|
||||
<el-table-column
|
||||
prop="CallingAE"
|
||||
:label="$t('trials:inspection:table:CallingAE')"
|
||||
show-overflow-tooltip
|
||||
min-width="120"
|
||||
>
|
||||
<el-table-column prop="CallingAE" :label="$t('trials:inspection:table:CallingAE')" show-overflow-tooltip
|
||||
min-width="120">
|
||||
</el-table-column>
|
||||
<!--课题组-->
|
||||
<el-table-column prop="ViewHospitalGroupList" :label="$t('trials:inspection:table:ViewHospitalGroupList')"
|
||||
show-overflow-tooltip min-width="100">
|
||||
<template slot-scope="scope">
|
||||
<span>{{
|
||||
scope.row.ViewHospitalGroupList && scope.row.ViewHospitalGroupList.length > 0 ?
|
||||
scope.row.ViewHospitalGroupList.map(item => item.Name).join(', ') : ''}}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!--序列数量-->
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="SeriesCount"
|
||||
:label="$t('trials:audit:table:seriesCount')"
|
||||
show-overflow-tooltip
|
||||
min-width="100"
|
||||
sortable="custom"
|
||||
></el-table-column>
|
||||
<el-table-column align="center" prop="SeriesCount" :label="$t('trials:audit:table:seriesCount')"
|
||||
show-overflow-tooltip min-width="100" sortable="custom"></el-table-column>
|
||||
<!--图像数量-->
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="InstanceCount"
|
||||
:label="$t('trials:audit:table:instanceCount')"
|
||||
show-overflow-tooltip
|
||||
min-width="100"
|
||||
sortable="custom"
|
||||
></el-table-column>
|
||||
<el-table-column align="center" prop="InstanceCount" :label="$t('trials:audit:table:instanceCount')"
|
||||
show-overflow-tooltip min-width="100" sortable="custom"></el-table-column>
|
||||
<!--检查日期-->
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="StudyTime"
|
||||
:label="$t('trials:audit:table:studyDate')"
|
||||
show-overflow-tooltip
|
||||
min-width="180"
|
||||
sortable="custom"
|
||||
></el-table-column>
|
||||
<el-table-column align="center" prop="StudyTime" :label="$t('trials:audit:table:studyDate')" show-overflow-tooltip
|
||||
min-width="180" sortable="custom"></el-table-column>
|
||||
<!--操作-->
|
||||
<el-table-column :label="$t('common:action:action')" min-width="150">
|
||||
<template slot-scope="scope">
|
||||
<!-- 影像 -->
|
||||
<el-button
|
||||
circle
|
||||
icon="el-icon-view"
|
||||
:title="$t('trials:inspection:button:image')"
|
||||
@click.stop="image(scope.row)"
|
||||
/>
|
||||
<el-button circle icon="el-icon-view" :title="$t('trials:inspection:button:image')"
|
||||
@click.stop="image(scope.row)" />
|
||||
<!--删除-->
|
||||
<el-button
|
||||
circle
|
||||
v-hasPermi="['trials:trialsInspection:delStudy']"
|
||||
icon="el-icon-delete"
|
||||
:title="$t('trials:inspection:button:delete')"
|
||||
@click.stop="deletePatientStudy(scope.row)"
|
||||
/>
|
||||
<el-button circle v-hasPermi="['trials:trialsInspection:delStudy']" icon="el-icon-delete"
|
||||
:title="$t('trials:inspection:button:delete')" @click.stop="deletePatientStudy(scope.row)" />
|
||||
<!-- 诊断报告 -->
|
||||
<el-button
|
||||
circle
|
||||
icon="el-icon-document"
|
||||
@click.stop="report(scope.row)"
|
||||
:title="$t('trials:inspection:button:diagnosticReport')"
|
||||
disabled
|
||||
/>
|
||||
<el-button circle icon="el-icon-document" @click.stop="report(scope.row)"
|
||||
:title="$t('trials:inspection:button:diagnosticReport')" disabled />
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
<!-- 分页组件 -->
|
||||
<pagination
|
||||
class="page"
|
||||
:total="total"
|
||||
:page.sync="searchData.PageIndex"
|
||||
:limit.sync="searchData.PageSize"
|
||||
@pagination="getList"
|
||||
/>
|
||||
<pagination class="page" :total="total" :page.sync="searchData.PageIndex" :limit.sync="searchData.PageSize"
|
||||
@pagination="getList" />
|
||||
<base-model v-if="group_model.visible" :config="group_model">
|
||||
<template slot="dialog-body">
|
||||
<el-form ref="anonymizationFrom" :model="form" :rules="rules" label-width="100px" size="small">
|
||||
<el-form-item :label="$t('trials:externalStaff:table:lastName')" prop="LastName" v-show="false">
|
||||
<el-input clearable />
|
||||
</el-form-item>
|
||||
<!-- 用户类型 -->
|
||||
<el-form-item :label="$t('trials:externalStaff:table:hospitalGroupIdList')" prop="hospitalGroupIdList">
|
||||
<el-select v-model="form.hospitalGroupIdList" style="width: 100%" multiple clearable>
|
||||
<el-option v-for="item of hospitalGroupList" :key="item.Id" :label="item.Name" :value="item.Id">
|
||||
<!-- <span>{{ item.UserType }}</span> -->
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</template>
|
||||
<template slot="dialog-footer">
|
||||
<!-- 取消 -->
|
||||
<el-button size="small" type="primary" :disabled="btnLoading" @click="handleCancelGroup">
|
||||
{{ $t("common:button:cancel") }}
|
||||
</el-button>
|
||||
<!-- 保存 -->
|
||||
<el-button size="small" type="primary" :loading="btnLoading" @click="handleSaveGroup">
|
||||
{{ $t("common:button:save") }}
|
||||
</el-button>
|
||||
</template>
|
||||
</base-model>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination'
|
||||
import { getPatientStudyList, deletePatientStudy } from '@/api/inspection.js'
|
||||
import { modifySCPStudyHospitalGroup, getHospitalGroupList } from '@/api/admin.js'
|
||||
import { getToken } from '@/utils/auth'
|
||||
|
||||
import BaseModel from '@/components/BaseModel'
|
||||
const defaultSearchData = () => {
|
||||
return {
|
||||
Modalities: null,
|
||||
|
@ -198,7 +145,7 @@ const defaultSearchData = () => {
|
|||
}
|
||||
export default {
|
||||
name: 'viewStudyList',
|
||||
components: { Pagination },
|
||||
components: { Pagination, BaseModel },
|
||||
props: {
|
||||
visible: {
|
||||
required: true,
|
||||
|
@ -220,12 +167,69 @@ export default {
|
|||
loading: false,
|
||||
list: [],
|
||||
total: 0,
|
||||
multipleSelection: [],
|
||||
group_model: {
|
||||
visible: false,
|
||||
title: this.$t('trials:inspection:dialogTitle:add'),
|
||||
width: '400px',
|
||||
appendToBody: true
|
||||
},
|
||||
form: {
|
||||
HospitalGroupIdList: [],
|
||||
},
|
||||
rules: {},
|
||||
btnLoading: false,
|
||||
hospitalGroupList: []
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
async getHospitalGroupList() {
|
||||
try {
|
||||
let res = await getHospitalGroupList({})
|
||||
if (res.IsSuccess) {
|
||||
this.hospitalGroupList = res.Result
|
||||
}
|
||||
} catch (err) {
|
||||
console.log(err)
|
||||
}
|
||||
},
|
||||
openGroup() {
|
||||
this.form.hospitalGroupIdList = []
|
||||
this.getHospitalGroupList()
|
||||
this.group_model.visible = true
|
||||
},
|
||||
handleCancelGroup() {
|
||||
this.form.hospitalGroupIdList = []
|
||||
this.group_model.visible = false
|
||||
},
|
||||
async handleSaveGroup() {
|
||||
try {
|
||||
if (this.multipleSelection.length <= 0) return false
|
||||
let ScPstudyIdList = this.multipleSelection.map(item => item.SCPStudyId)
|
||||
let data = {
|
||||
ScPstudyIdList,
|
||||
AddOrDelete: 1,
|
||||
HospitalGroupIdList: this.form.HospitalGroupIdList
|
||||
}
|
||||
this.btnLoading = true
|
||||
let res = await modifySCPStudyHospitalGroup(data)
|
||||
this.btnLoading = false
|
||||
if (res.IsSuccess) {
|
||||
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
||||
this.handleCancelGroup()
|
||||
this.getList()
|
||||
}
|
||||
} catch (err) {
|
||||
console.log(err)
|
||||
this.btnLoading = false
|
||||
}
|
||||
},
|
||||
handleSelectionChange(val) {
|
||||
this.multipleSelection = val;
|
||||
},
|
||||
// 删除检查
|
||||
async deletePatientStudy(item) {
|
||||
try {
|
||||
|
@ -315,7 +319,7 @@ export default {
|
|||
this.$setOpenWindow(newWindow)
|
||||
},
|
||||
// 查看报告
|
||||
report() {},
|
||||
report() { },
|
||||
// 表格排序
|
||||
handleSortByColumn(sort) {
|
||||
this.searchData.SortField = sort.prop
|
||||
|
@ -327,5 +331,4 @@ export default {
|
|||
},
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
</style>
|
||||
<style lang="scss" scoped></style>
|
|
@ -30,8 +30,10 @@
|
|||
</el-form-item>
|
||||
<!-- 最新接收时间 -->
|
||||
<el-form-item :label="$t('trials:inspection:table:latestReceiveTime')">
|
||||
<el-date-picker v-model="dateValue" type="datetimerange" range-separator="-" :start-placeholder="$t('trials:uploadClinicalData:table:beginDate')"
|
||||
:end-placeholder="$t('trials:uploadClinicalData:table:endDate')" :default-time="['00:00:00', '23:59:59']" clearable>
|
||||
<el-date-picker v-model="dateValue" type="datetimerange" range-separator="-"
|
||||
:start-placeholder="$t('trials:uploadClinicalData:table:beginDate')"
|
||||
:end-placeholder="$t('trials:uploadClinicalData:table:endDate')" :default-time="['00:00:00', '23:59:59']"
|
||||
clearable>
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
|
@ -116,6 +118,15 @@
|
|||
<!-- <span v-else>{{ scope.row.VisitName }}</span> -->
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!--课题组-->
|
||||
<el-table-column prop="StudyHospitalGroupList" :label="$t('trials:trials-myinfo:form:StudyHospitalGroupList')"
|
||||
show-overflow-tooltip min-width="100">
|
||||
<template slot-scope="scope">
|
||||
<span>{{
|
||||
scope.row.StudyHospitalGroupList && scope.row.StudyHospitalGroupList.length > 0 ?
|
||||
scope.row.StudyHospitalGroupList.map(item => item.Name).join(', '):'' }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- 检查数 -->
|
||||
<el-table-column prop="StudyCount" :label="$t('trials:studyList:table:count')" show-overflow-tooltip
|
||||
min-width="100" sortable="custom">
|
||||
|
|
|
@ -1,66 +1,28 @@
|
|||
<!-- eslint-disable -->
|
||||
<template>
|
||||
<el-form
|
||||
ref="trialForm"
|
||||
v-loading="loading"
|
||||
label-width="250px"
|
||||
:rules="trialFormRules"
|
||||
class="demo-ruleForm trial-Form"
|
||||
:model="trialForm"
|
||||
label-position="right"
|
||||
:inline="true"
|
||||
>
|
||||
<el-form ref="trialForm" v-loading="loading" label-width="250px" :rules="trialFormRules"
|
||||
class="demo-ruleForm trial-Form" :model="trialForm" label-position="right" :inline="true">
|
||||
<el-row>
|
||||
<!-- 项目码 -->
|
||||
<el-form-item
|
||||
:label="$t('trials:trials-list:table:trialId')"
|
||||
prop="TrialCode"
|
||||
v-if="trialForm.Id !== ''"
|
||||
>
|
||||
<el-form-item :label="$t('trials:trials-list:table:trialId')" prop="TrialCode" v-if="trialForm.Id !== ''">
|
||||
<el-input v-model="trialForm.TrialCode" disabled />
|
||||
<!-- <el-input v-model="trialForm.TrialCode" /> -->
|
||||
</el-form-item>
|
||||
<!-- 项目类型 -->
|
||||
<el-form-item
|
||||
:label="$t('trials:trials-list:form:trialType')"
|
||||
prop="TrialType"
|
||||
>
|
||||
<el-radio-group
|
||||
v-model="trialForm.TrialType"
|
||||
:disabled="trialForm.Id !== ''"
|
||||
>
|
||||
<el-radio
|
||||
v-for="item of $d.TrialType"
|
||||
:key="item.id"
|
||||
:label="item.value"
|
||||
>{{ item.label }}</el-radio
|
||||
>
|
||||
<el-form-item :label="$t('trials:trials-list:form:trialType')" prop="TrialType">
|
||||
<el-radio-group v-model="trialForm.TrialType" :disabled="trialForm.Id !== ''">
|
||||
<el-radio v-for="item of $d.TrialType" :key="item.id" :label="item.value">{{ item.label }}</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<!-- 研究方案号 -->
|
||||
<el-form-item
|
||||
:label="$t('trials:trials-list:form:researchNumber')"
|
||||
prop="ResearchProgramNo"
|
||||
>
|
||||
<el-input
|
||||
v-model="trialForm.ResearchProgramNo"
|
||||
clearable
|
||||
:disabled="TrialStatusStr === 'Ongoing'"
|
||||
/>
|
||||
<el-form-item :label="$t('trials:trials-list:form:researchNumber')" prop="ResearchProgramNo">
|
||||
<el-input v-model="trialForm.ResearchProgramNo" clearable :disabled="TrialStatusStr === 'Ongoing'" />
|
||||
</el-form-item>
|
||||
<!-- 研究名称 -->
|
||||
<el-form-item
|
||||
:label="$t('trials:trials-list:table:researchName')"
|
||||
prop="ExperimentName"
|
||||
>
|
||||
<el-input
|
||||
v-model="trialForm.ExperimentName"
|
||||
type="textarea"
|
||||
:autosize="{ minRows: 1, maxRows: 4 }"
|
||||
clearable
|
||||
/>
|
||||
<el-form-item :label="$t('trials:trials-list:table:researchName')" prop="ExperimentName">
|
||||
<el-input v-model="trialForm.ExperimentName" type="textarea" :autosize="{ minRows: 1, maxRows: 4 }" clearable />
|
||||
</el-form-item>
|
||||
</el-row>
|
||||
<el-row>
|
||||
|
@ -69,34 +31,19 @@
|
|||
<el-input v-model="trialForm.MedicineName" clearable />
|
||||
</el-form-item>
|
||||
<!-- 申办方 -->
|
||||
<el-form-item
|
||||
:label="$t('trials:trials-list:form:sponsor')"
|
||||
prop="Sponsor"
|
||||
>
|
||||
<el-form-item :label="$t('trials:trials-list:form:sponsor')" prop="Sponsor">
|
||||
<el-input v-model="trialForm.Sponsor" maxlength="200" clearable />
|
||||
</el-form-item>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<!-- 研究者 -->
|
||||
<el-form-item
|
||||
:label="$t('trials:trials-list:form:investigator')"
|
||||
prop="HeadPI"
|
||||
>
|
||||
<el-form-item :label="$t('trials:trials-list:form:investigator')" prop="HeadPI">
|
||||
<el-input v-model="trialForm.HeadPI" clearable />
|
||||
</el-form-item>
|
||||
<!-- 临床分期 -->
|
||||
<el-form-item :label="$t('trials:trials-list:form:phase')" prop="PhaseId">
|
||||
<el-select
|
||||
v-model="trialForm.PhaseId"
|
||||
@change="handlePhaseChange"
|
||||
clearable
|
||||
>
|
||||
<el-option
|
||||
v-for="item of $d.Trial_Phase"
|
||||
:key="item.id"
|
||||
:label="item.label"
|
||||
:value="item.id"
|
||||
/>
|
||||
<el-select v-model="trialForm.PhaseId" @change="handlePhaseChange" clearable>
|
||||
<el-option v-for="item of $d.Trial_Phase" :key="item.id" :label="item.label" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-row>
|
||||
|
@ -106,37 +53,30 @@
|
|||
<el-input v-model="trialForm.Indication" clearable />
|
||||
</el-form-item>
|
||||
<!-- 阅片标准 -->
|
||||
<el-form-item
|
||||
:label="$t('trials:trials-list:form:criterion')"
|
||||
prop="CriterionTypeList"
|
||||
>
|
||||
<el-select
|
||||
v-model="trialForm.CriterionTypeList"
|
||||
multiple
|
||||
clearable
|
||||
:disabled="TrialStatusStr === 'Ongoing'"
|
||||
>
|
||||
<el-option
|
||||
v-for="item of CriterionTypeList"
|
||||
:key="item.Id"
|
||||
:label="item.CriterionName"
|
||||
:value="item.CriterionType"
|
||||
:title="item.Description"
|
||||
/>
|
||||
<el-form-item :label="$t('trials:trials-list:form:criterion')" prop="CriterionTypeList">
|
||||
<el-select v-model="trialForm.CriterionTypeList" multiple clearable :disabled="TrialStatusStr === 'Ongoing'">
|
||||
<el-option v-for="item of CriterionTypeList" :key="item.Id" :label="item.CriterionName"
|
||||
:value="item.CriterionType" :title="item.Description" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<!-- 课题组 -->
|
||||
<el-form-item :label="$t('trials:trials-list:form:HospitalGroupId')" prop="HospitalGroupId">
|
||||
<el-select v-model="trialForm.HospitalGroupId" clearable :disabled="TrialStatusStr === 'Ongoing'">
|
||||
<el-option v-for="item of hospitalGroupList" :key="item.Id" :label="item.Name" :value="item.Id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- CRO -->
|
||||
<el-form-item :label="$t('trials:trials-list:form:cro')" prop="Cro">
|
||||
<el-input v-model="trialForm.CRO" maxlength="200" clearable />
|
||||
</el-form-item>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<!-- 联系人 -->
|
||||
<el-form-item :label="$t('trials:researchForm:form:contactor')">
|
||||
<el-input v-model="trialForm.ContactUser" clearable />
|
||||
</el-form-item>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<!-- 电话 -->
|
||||
<el-form-item :label="$t('trials:trials-myinfo:form:phone')">
|
||||
<el-input v-model="trialForm.ContactPhone" type="number" clearable />
|
||||
|
@ -144,32 +84,15 @@
|
|||
</el-row>
|
||||
<el-row>
|
||||
<!-- 项目周期 -->
|
||||
<el-form-item
|
||||
:label="$t('trials:trials-list:form:projectCycle')"
|
||||
prop="AuthorizationDuration"
|
||||
>
|
||||
<el-form-item :label="$t('trials:trials-list:form:projectCycle')" prop="AuthorizationDuration">
|
||||
<div style="position: relative">
|
||||
<el-input
|
||||
v-model.number="trialForm.AuthorizationDuration"
|
||||
type="number"
|
||||
clearable
|
||||
:max="200"
|
||||
:min="1"
|
||||
/>
|
||||
<el-input v-model.number="trialForm.AuthorizationDuration" type="number" clearable :max="200" :min="1" />
|
||||
</div>
|
||||
</el-form-item>
|
||||
<!-- 到期日 -->
|
||||
<el-form-item
|
||||
:label="$t('trials:trials-list:table:dateAuthorized')"
|
||||
prop="visitNumberAuthorized"
|
||||
>
|
||||
<el-date-picker
|
||||
v-model="trialForm.AuthorizationDate"
|
||||
value-format="yyyy-MM-dd"
|
||||
type="date"
|
||||
placeholder=""
|
||||
disabled
|
||||
>
|
||||
<el-form-item :label="$t('trials:trials-list:table:dateAuthorized')" prop="visitNumberAuthorized">
|
||||
<el-date-picker v-model="trialForm.AuthorizationDate" value-format="yyyy-MM-dd" type="date" placeholder=""
|
||||
disabled>
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
</el-row>
|
||||
|
@ -193,6 +116,9 @@ import {
|
|||
addOrUpdateTrialHir,
|
||||
getSystemConfirmedCreiterionList,
|
||||
} from "@/api/trials";
|
||||
import {
|
||||
getHospitalGroupList
|
||||
} from '@/api/admin.js'
|
||||
import { getBasicDataSelects } from "@/api/dictionary/dictionary";
|
||||
export default {
|
||||
name: "TrialForm",
|
||||
|
@ -222,9 +148,18 @@ export default {
|
|||
ContactPhone: "",
|
||||
AuthorizationDuration: null,
|
||||
AuthorizationDate: null,
|
||||
HospitalGroupId: null
|
||||
},
|
||||
indicationGrouping: null,
|
||||
trialFormRules: {
|
||||
// 项目码
|
||||
HospitalGroupId: [
|
||||
{
|
||||
required: true,
|
||||
message: this.$t("common:ruleMessage:specify"),
|
||||
trigger: "blur",
|
||||
},
|
||||
],
|
||||
// 项目码
|
||||
TrialCode: [
|
||||
{
|
||||
|
@ -350,6 +285,7 @@ export default {
|
|||
dictionaryList: {},
|
||||
CriterionTypeList: [], // 阅片标准列表
|
||||
TrialStatusStr: null, // 项目状态
|
||||
hospitalGroupList: []
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
|
@ -360,6 +296,16 @@ export default {
|
|||
this.initPage();
|
||||
},
|
||||
methods: {
|
||||
async getHospitalGroupList() {
|
||||
try {
|
||||
let res = await getHospitalGroupList({})
|
||||
if (res.IsSuccess) {
|
||||
this.hospitalGroupList = res.Result
|
||||
}
|
||||
} catch (err) {
|
||||
console.log(err)
|
||||
}
|
||||
},
|
||||
// 获取阅片标准
|
||||
async getSystemConfirmedCreiterionList() {
|
||||
try {
|
||||
|
@ -519,6 +465,7 @@ export default {
|
|||
.trial-Form .el-textarea {
|
||||
width: 340px;
|
||||
}
|
||||
|
||||
.trial-Form .el-col .el-input {
|
||||
width: 165px;
|
||||
margin-right: 10px;
|
||||
|
|
|
@ -90,9 +90,10 @@
|
|||
<el-table-column prop="ResearchProgramNo" :label="$t('trials:trials-list:table:researchNumber')"
|
||||
show-overflow-tooltip min-width="120" sortable="custom" />
|
||||
|
||||
<el-table-column prop="ExperimentName" :label="$t('trials:trials-list:table:experimentName')"
|
||||
<el-table-column prop="HospitalGroupName" :label="$t('trials:trials-list:table:HospitalGroupName')"
|
||||
show-overflow-tooltip min-width="120" sortable="custom" />
|
||||
<el-table-column prop="ResearchProgramNo" :label="$t('trials:trials-list:table:researchNumber')"
|
||||
show-overflow-tooltip min-width="120" sortable="custom" />
|
||||
|
||||
<el-table-column prop="Sponsor" :label="$t('trials:trials-list:table:sponsor')" min-width="90"
|
||||
show-overflow-tooltip sortable="custom" />
|
||||
<el-table-column prop="TrialStatusStr" :label="$t('trials:trials-list:table:status')" show-overflow-tooltip
|
||||
|
|
|
@ -14,12 +14,12 @@
|
|||
<!-- 用户类型 -->
|
||||
<el-form-item :label="$t('trials:staff:table:userType')">
|
||||
<el-select v-model="listQuery.UserTypeId" clearable class="mr">
|
||||
<el-option
|
||||
v-for="item of userTypeOptions"
|
||||
:key="item.Id"
|
||||
:label="item.UserType"
|
||||
:value="item.Id"
|
||||
>
|
||||
<el-option v-for="item of userTypeOptions" v-show="item.UserTypeEnum !== 8 &&
|
||||
item.UserTypeEnum !== 31 &&
|
||||
item.UserTypeEnum !== 26 &&
|
||||
item.UserTypeEnum !== 27
|
||||
" :key="item.Id" :label="item.UserTypeShortName" :value="item.Id">
|
||||
<span>{{ item.UserType }}</span>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
@ -27,172 +27,143 @@
|
|||
<el-form-item :label="$t('trials:staff:table:organization')">
|
||||
<el-input v-model="listQuery.OrganizationName" class="mr" clearable />
|
||||
</el-form-item>
|
||||
<!-- 邮箱 -->
|
||||
<el-form-item :label="$t('trials:staff:table:email')">
|
||||
<el-input v-model="listQuery.Email" class="mr" clearable />
|
||||
</el-form-item>
|
||||
<!-- 状态 -->
|
||||
<el-form-item :label="$t('trials:staff:table:status')">
|
||||
<el-select v-model="listQuery.IsDeleted" clearable class="mr">
|
||||
<el-option
|
||||
v-for="item of $d.IsUserExitTrial"
|
||||
:key="`IsDeleted${item.label}`"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
<el-option v-for="item of $d.IsUserExitTrial" :label="item.label" :value="item.value" :key="item.id" />
|
||||
<!-- <el-option label="加入" :value="false" />-->
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<!-- 查询 -->
|
||||
<el-button type="primary" icon="el-icon-search" @click="handleSearch">
|
||||
{{ $t("common:button:search") }}
|
||||
{{ $t('common:button:search') }}
|
||||
</el-button>
|
||||
<!-- 重置 -->
|
||||
<el-button
|
||||
type="primary"
|
||||
icon="el-icon-refresh-left"
|
||||
@click="handleReset"
|
||||
>
|
||||
{{ $t("common:button:reset") }}
|
||||
<el-button type="primary" icon="el-icon-refresh-left" @click="handleReset">
|
||||
{{ $t('common:button:reset') }}
|
||||
</el-button>
|
||||
<!-- 添加用户 -->
|
||||
<el-button
|
||||
v-hasPermi="[
|
||||
<el-button v-hasPermi="[
|
||||
'trials:trials-panel:setting:personnel-manage:add-internal-staff',
|
||||
]"
|
||||
type="primary"
|
||||
style="margin-left: 10px"
|
||||
icon="el-icon-plus"
|
||||
@click="handleAdd('Add')"
|
||||
>
|
||||
{{ $t("trials:staff:button:addStaff") }}
|
||||
]" type="primary" style="margin-left: 10px" icon="el-icon-plus" @click="handleAdd('Add')">
|
||||
{{ $t('trials:staff:button:addStaff') }}
|
||||
</el-button>
|
||||
<!-- 添加新用户 -->
|
||||
<!-- <el-button
|
||||
v-hasPermi="['trials:trials-panel:setting:personnel-manage:add-external-staff']"
|
||||
type="primary"
|
||||
icon="el-icon-plus"
|
||||
@click="handleAdd('External')"
|
||||
>
|
||||
{{ $t('trials:staff:button:addExternalStaff') }}
|
||||
</el-button> -->
|
||||
<!-- 导出 -->
|
||||
<!-- <el-button
|
||||
type="primary"
|
||||
icon="el-icon-download"
|
||||
:disabled="list.length === 0"
|
||||
@click="handleExport"
|
||||
>
|
||||
{{ $t("common:button:export") }}
|
||||
<!-- <el-button type="primary" icon="el-icon-download" :disabled="list.length === 0" @click="handleExport">
|
||||
{{ $t('common:button:export') }}
|
||||
</el-button> -->
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
|
||||
<!-- 项目参与人员列表 -->
|
||||
<el-table
|
||||
ref="settingList"
|
||||
v-adaptive="{ bottomOffset: 60 }"
|
||||
v-loading="listLoading"
|
||||
:data="list"
|
||||
stripe
|
||||
@sort-change="handleSortByColumn"
|
||||
>
|
||||
<el-table-column type="index" width="50" />
|
||||
<el-table ref="settingList" v-loading="listLoading" :data="list" v-adaptive="{ bottomOffset: 60 }" stripe
|
||||
@sort-change="handleSortByColumn">
|
||||
<el-table-column type="index" width="60">
|
||||
<template slot-scope="scope">
|
||||
<span style="
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-end;
|
||||
">
|
||||
<el-tooltip class="item" effect="dark" :content="$t('trials:staff:tip:userDisabled')" placement="top"
|
||||
style="margin-right: 3px" v-if="!scope.row.Status">
|
||||
<i v-if="!scope.row.Status" class="el-icon-warning icon-i"></i>
|
||||
</el-tooltip>
|
||||
<span>{{ scope.$index + 1 }}</span>
|
||||
</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- 姓名 -->
|
||||
<el-table-column
|
||||
prop="UserRealName"
|
||||
:label="$t('trials:staff:table:name')"
|
||||
show-overflow-tooltip
|
||||
sortable
|
||||
min-width="40"
|
||||
/>
|
||||
<el-table-column prop="FullName" :label="$t('trials:staff:table:name')" show-overflow-tooltip sortable
|
||||
min-width="40" />
|
||||
<!-- 用户名 -->
|
||||
<el-table-column
|
||||
prop="UserName"
|
||||
:label="$t('trials:staff:table:uid')"
|
||||
show-overflow-tooltip
|
||||
sortable
|
||||
min-width="50"
|
||||
/>
|
||||
<el-table-column prop="UserName" :label="$t('trials:staff:table:uid')" show-overflow-tooltip sortable
|
||||
min-width="50" />
|
||||
<!-- 用户类型 -->
|
||||
<el-table-column
|
||||
prop="UserType"
|
||||
:label="$t('trials:staff:table:userType')"
|
||||
show-overflow-tooltip
|
||||
sortable
|
||||
width="140"
|
||||
/>
|
||||
<el-table-column prop="UserType" :label="$t('trials:staff:table:userType')" show-overflow-tooltip sortable
|
||||
width="160">
|
||||
<template slot-scope="scope">
|
||||
<el-button v-if="
|
||||
Array.isArray(scope.row.TrialUserRoleList) &&
|
||||
scope.row.TrialUserRoleList.length > 0 &&
|
||||
hasPermi(['trials:trials-panel:setting:personnel-manage:status'])
|
||||
" type="text" @click.stop="openRoleList(scope.row)">
|
||||
<el-tooltip class="item" effect="dark" :content="$t('trials:staff:tip:userTypeDisabled')" placement="top"
|
||||
style="margin-right: 2px" v-if="
|
||||
scope.row.TrialUserRoleList.some(
|
||||
(item) => item.IsDeleted || item.IsUserRoleDisabled
|
||||
)
|
||||
">
|
||||
<i class="el-icon-warning icon-i"></i>
|
||||
</el-tooltip>
|
||||
<span>{{
|
||||
scope.row.TrialUserRoleList.map(
|
||||
(item) => item.UserTypeShortName
|
||||
).join(', ')
|
||||
}}</span>
|
||||
</el-button>
|
||||
<div v-else-if="
|
||||
Array.isArray(scope.row.TrialUserRoleList) &&
|
||||
scope.row.TrialUserRoleList.length > 0
|
||||
">
|
||||
<el-tooltip class="item" effect="dark" :content="$t('trials:staff:tip:userTypeDisabled')" placement="top"
|
||||
style="margin-right: 2px" v-if="
|
||||
scope.row.TrialUserRoleList.some(
|
||||
(item) => item.IsDeleted || item.IsUserRoleDisabled
|
||||
)
|
||||
">
|
||||
<i class="el-icon-warning icon-i"></i>
|
||||
</el-tooltip>
|
||||
<span>{{
|
||||
scope.row.TrialUserRoleList.map(
|
||||
(item) => item.UserTypeShortName
|
||||
).join(', ')
|
||||
}}</span>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- 联系电话 -->
|
||||
<el-table-column
|
||||
prop="Phone"
|
||||
:label="$t('trials:staff:table:phone')"
|
||||
show-overflow-tooltip
|
||||
sortable
|
||||
min-width="40"
|
||||
/>
|
||||
<el-table-column prop="Phone" :label="$t('trials:staff:table:phone')" show-overflow-tooltip sortable
|
||||
min-width="40" />
|
||||
<!-- 邮箱 -->
|
||||
<el-table-column
|
||||
prop="EMail"
|
||||
:label="$t('trials:staff:table:email')"
|
||||
show-overflow-tooltip
|
||||
sortable
|
||||
min-width="40"
|
||||
/>
|
||||
<el-table-column prop="EMail" :label="$t('trials:staff:table:email')" show-overflow-tooltip sortable
|
||||
min-width="40" />
|
||||
<!-- 单位 -->
|
||||
<el-table-column
|
||||
prop="OrganizationName"
|
||||
:label="$t('trials:staff:table:organization')"
|
||||
sortable
|
||||
show-overflow-tooltip
|
||||
min-width="50"
|
||||
/>
|
||||
<el-table-column prop="OrganizationName" :label="$t('trials:staff:table:organization')" sortable
|
||||
show-overflow-tooltip min-width="50" />
|
||||
<!-- 状态 -->
|
||||
<el-table-column
|
||||
prop="IsDeleted"
|
||||
:label="$t('trials:staff:table:status')"
|
||||
show-overflow-tooltip
|
||||
sortable
|
||||
min-width="40"
|
||||
>
|
||||
<el-table-column prop="IsDeleted" :label="$t('trials:staff:table:status')" show-overflow-tooltip sortable
|
||||
min-width="40">
|
||||
<template slot-scope="scope">
|
||||
<el-tag v-if="scope.row.IsDeleted" type="danger">{{
|
||||
$fd("IsUserExitTrial", scope.row.IsDeleted)
|
||||
$fd('IsUserExitTrial', scope.row.IsDeleted)
|
||||
}}</el-tag>
|
||||
<el-tag v-else>{{
|
||||
$fd("IsUserExitTrial", scope.row.IsDeleted)
|
||||
$fd('IsUserExitTrial', scope.row.IsDeleted)
|
||||
}}</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- 加入日期 -->
|
||||
<el-table-column
|
||||
prop="JoinTime"
|
||||
:label="$t('trials:staff:table:joinTime')"
|
||||
show-overflow-tooltip
|
||||
sortable
|
||||
width="160"
|
||||
>
|
||||
<el-table-column prop="JoinTime" :label="$t('trials:staff:table:joinTime')" show-overflow-tooltip sortable
|
||||
width="160">
|
||||
<template slot-scope="scope">
|
||||
{{
|
||||
scope.row.JoinTime
|
||||
? moment(scope.row.JoinTime).format("YYYY-MM-DD")
|
||||
: ""
|
||||
? moment(scope.row.JoinTime).format('YYYY-MM-DD')
|
||||
: ''
|
||||
}}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- 退出日期 -->
|
||||
<el-table-column
|
||||
prop="RemoveTime"
|
||||
:label="$t('trials:staff:table:exitTime')"
|
||||
show-overflow-tooltip
|
||||
sortable
|
||||
width="160"
|
||||
>
|
||||
<el-table-column prop="RemoveTime" :label="$t('trials:staff:table:exitTime')" show-overflow-tooltip sortable
|
||||
width="160">
|
||||
<template slot-scope="scope">
|
||||
{{
|
||||
scope.row.RemoveTime
|
||||
? moment(scope.row.RemoveTime).format("YYYY-MM-DD")
|
||||
: ""
|
||||
? moment(scope.row.RemoveTime).format('YYYY-MM-DD')
|
||||
: ''
|
||||
}}
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
@ -213,126 +184,133 @@
|
|||
min-width="60"
|
||||
/> -->
|
||||
|
||||
<el-table-column
|
||||
v-if="hasPermi(['trials:trials-panel:setting:personnel-manage:status'])"
|
||||
:label="$t('common:action:action')"
|
||||
width="150"
|
||||
>
|
||||
<el-table-column v-if="hasPermi(['trials:trials-panel:setting:personnel-manage:status'])"
|
||||
:label="$t('common:action:action')" width="150">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
v-hasPermi="['trials:trials-panel:setting:personnel-manage:status']"
|
||||
circle
|
||||
:title="$t('trials:staff:action:status')"
|
||||
icon="el-icon-edit-outline"
|
||||
:disabled="scope.row.UserTypeEnum * 1 === 3"
|
||||
@click="handleStatus(scope.row)"
|
||||
/>
|
||||
<el-button v-hasPermi="['trials:trials-panel:setting:personnel-manage:status']" circle
|
||||
:title="$t('trials:staff:action:status')" icon="el-icon-edit-outline" :disabled="!!scope.row.TrialUserRoleList.find(
|
||||
(item) => item.UserTypeEnum === 1
|
||||
)
|
||||
" @click="handleStatus(scope.row)" />
|
||||
<!---v-if="!scope.row.UserName"-->
|
||||
<el-button v-if="!scope.row.UserName" circle :title="$t('trials:staff:action:email')" icon="el-icon-message"
|
||||
@click="handleSendEmail(scope.row)" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
<!-- 分页组件 -->
|
||||
<div class="pagination" style="text-align: right">
|
||||
<pagination
|
||||
:total="total"
|
||||
:page.sync="listQuery.PageIndex"
|
||||
:limit.sync="listQuery.PageSize"
|
||||
@pagination="getList"
|
||||
/>
|
||||
<pagination :total="total" :page.sync="listQuery.PageIndex" :limit.sync="listQuery.PageSize"
|
||||
@pagination="getList" />
|
||||
</div>
|
||||
|
||||
<!-- 分配参与人员模态框 -->
|
||||
<base-model v-if="staff_model.visible" :config="staff_model">
|
||||
<template slot="dialog-body">
|
||||
<StaffForm
|
||||
v-if="isAdd == 'Add'"
|
||||
:userTypeOptions="userTypeOptions"
|
||||
@closeDialog="closeDialog"
|
||||
/>
|
||||
<StaffExternalForm
|
||||
v-else
|
||||
@closeDialog="closeDialog"
|
||||
@getList="getList"
|
||||
/>
|
||||
<StaffForm v-if="isAdd == 'Add'" @closeDialog="closeDialog" />
|
||||
<StaffExternalForm v-else @closeDialog="closeDialog" @getList="getList" />
|
||||
</template>
|
||||
</base-model>
|
||||
|
||||
<!-- 修改参与者人员状态 -->
|
||||
<base-model v-if="status_model.visible" :config="status_model">
|
||||
<template slot="dialog-body">
|
||||
<el-form
|
||||
ref="statusForm"
|
||||
:model="statusForm"
|
||||
label-width="110px"
|
||||
size="small"
|
||||
:rules="statusRules"
|
||||
>
|
||||
<el-form ref="statusForm" :model="statusForm" label-width="110px" size="small" :rules="statusRules">
|
||||
<!-- Status -->
|
||||
<el-form-item
|
||||
:label="$t('trials:staff:table:status')"
|
||||
prop="isDeleted"
|
||||
>
|
||||
<el-radio-group
|
||||
v-model="statusForm.isDeleted"
|
||||
@change="handleIsDeletedChanged"
|
||||
>
|
||||
<el-radio
|
||||
v-for="item of $d.IsUserExitTrial"
|
||||
:key="`statusForm.isDeleted${item.value}`"
|
||||
:label="item.value"
|
||||
>{{ item.label }}</el-radio
|
||||
>
|
||||
<el-form-item :label="$t('trials:staff:table:status')" prop="isDeleted">
|
||||
<el-radio-group v-model="statusForm.isDeleted" @change="handleIsDeletedChanged">
|
||||
<el-radio v-for="item of $d.IsUserExitTrial" :label="item.value" :key="item.id">{{ item.label
|
||||
}}</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
<!-- 退出日期 -->
|
||||
<el-form-item
|
||||
v-if="statusForm.isDeleted"
|
||||
:label="$t('trials:staff:table:exitTime')"
|
||||
prop="removeTime"
|
||||
>
|
||||
<el-date-picker
|
||||
v-model="statusForm.removeTime"
|
||||
type="date"
|
||||
:picker-options="pickerOption"
|
||||
value-format="yyyy-MM-dd"
|
||||
format="yyyy-MM-dd"
|
||||
/>
|
||||
<el-form-item v-if="statusForm.isDeleted" :label="$t('trials:staff:table:exitTime')" prop="removeTime">
|
||||
<el-date-picker v-model="statusForm.removeTime" type="date" :picker-options="pickerOption"
|
||||
value-format="yyyy-MM-dd" format="yyyy-MM-dd" />
|
||||
</el-form-item>
|
||||
<!-- 加入日期 -->
|
||||
<el-form-item
|
||||
v-else
|
||||
:label="$t('trials:staff:table:joinTime')"
|
||||
prop="joinTime"
|
||||
>
|
||||
<el-date-picker
|
||||
v-model="statusForm.joinTime"
|
||||
type="date"
|
||||
:picker-options="pickerOption"
|
||||
value-format="yyyy-MM-dd"
|
||||
format="yyyy-MM-dd"
|
||||
/>
|
||||
<el-form-item v-else :label="$t('trials:staff:table:joinTime')" prop="joinTime">
|
||||
<el-date-picker v-model="statusForm.joinTime" type="date" :picker-options="pickerOption"
|
||||
value-format="yyyy-MM-dd" format="yyyy-MM-dd" />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</template>
|
||||
<template slot="dialog-footer">
|
||||
<el-button
|
||||
:disabled="btnLoading"
|
||||
size="small"
|
||||
type="primary"
|
||||
@click="status_model.visible = false"
|
||||
>
|
||||
{{ $t("common:button:cancel") }}
|
||||
<el-button :disabled="btnLoading" size="small" type="primary" @click="status_model.visible = false">
|
||||
{{ $t('common:button:cancel') }}
|
||||
</el-button>
|
||||
<el-button
|
||||
size="small"
|
||||
type="primary"
|
||||
:loading="btnLoading"
|
||||
@click="saveStatus"
|
||||
>
|
||||
{{ $t("common:button:save") }}
|
||||
<el-button size="small" type="primary" :loading="btnLoading" @click="saveStatus">
|
||||
{{ $t('common:button:save') }}
|
||||
</el-button>
|
||||
</template>
|
||||
</base-model>
|
||||
<!-- 修改参与者人员角色 -->
|
||||
<base-model v-if="role_model.visible" :config="role_model">
|
||||
<template slot="dialog-body">
|
||||
<el-table :data="roleList" style="width: 100%" max-height="300px">
|
||||
<el-table-column type="index" width="60">
|
||||
<template slot-scope="scope">
|
||||
<span style="
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-end;
|
||||
">
|
||||
<el-tooltip class="item" effect="dark" :content="$t('trials:staff:tip:userTypeSysDisabled')"
|
||||
placement="top" style="margin-right: 3px" v-if="scope.row.IsUserRoleDisabled">
|
||||
<i v-if="scope.row.IsUserRoleDisabled" class="el-icon-warning icon-i"></i>
|
||||
</el-tooltip>
|
||||
<span>{{ scope.$index + 1 }}</span>
|
||||
</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="UserTypeShortName" :label="$t(
|
||||
'trials:trials-panel:setting:personnel-manage:table:UserTypeShortName'
|
||||
)
|
||||
" />
|
||||
<el-table-column prop="IsDeleted" :label="$t(
|
||||
'trials:trials-panel:setting:personnel-manage:table:IsUserRoleDisabled'
|
||||
)
|
||||
">
|
||||
<template slot-scope="scope">
|
||||
<span> {{ $fd('IsDisable', scope.row.IsDeleted) }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="IsDeleted" :label="$t(
|
||||
'trials:trials-panel:setting:personnel-manage:table:enableTime'
|
||||
)
|
||||
" min-width="120px">
|
||||
<template slot-scope="scope">
|
||||
<span>
|
||||
{{ scope.row.CreateTime }}
|
||||
</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="IsDeleted" :label="$t(
|
||||
'trials:trials-panel:setting:personnel-manage:table:forbiddenTime'
|
||||
)
|
||||
" min-width="120px">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.IsDeleted">
|
||||
{{ scope.row.UpdateTime }}
|
||||
</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column :label="$t('common:action:action')" min-width="120px">
|
||||
<template slot-scope="scope">
|
||||
<el-button size="mini" type="text" :disabled="scope.row.IsDeleted || scope.row.UserTypeEnum === 1"
|
||||
@click.stop="changeRoleStatus(scope.row, true)">
|
||||
{{ $fd('IsDisable', true) }}
|
||||
</el-button>
|
||||
<el-button size="mini" type="text" :disabled="!scope.row.IsDeleted || scope.row.UserTypeEnum === 1"
|
||||
@click.stop="changeRoleStatus(scope.row, false)">
|
||||
{{ $fd('IsDisable', false) }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</template>
|
||||
</base-model>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
|
@ -341,27 +319,27 @@ import {
|
|||
getTrialUserTypeList,
|
||||
updateTrialUser,
|
||||
trialUserListExport,
|
||||
} from "@/api/trials";
|
||||
import { getUserTypeListByUserType } from "@/api/admin";
|
||||
import Pagination from "@/components/Pagination";
|
||||
import StaffForm from "./staffForm";
|
||||
import StaffExternalForm from "./staffExternalForm";
|
||||
import BaseModel from "@/components/BaseModel";
|
||||
import moment from "moment";
|
||||
updateTrialUserRole,
|
||||
trialUserSendJoinEmail,
|
||||
} from '@/api/trials'
|
||||
import Pagination from '@/components/Pagination'
|
||||
import StaffForm from './staffForm'
|
||||
import StaffExternalForm from './staffExternalForm'
|
||||
import BaseModel from '@/components/BaseModel'
|
||||
import moment from 'moment'
|
||||
const getListQueryDefault = () => {
|
||||
return {
|
||||
UserRealName: "",
|
||||
UserName: "",
|
||||
UserTypeId: "",
|
||||
OrganizationName: "",
|
||||
Email: "",
|
||||
UserRealName: '',
|
||||
UserName: '',
|
||||
UserTypeId: '',
|
||||
OrganizationName: '',
|
||||
IsDeleted: null,
|
||||
PageIndex: 1,
|
||||
PageSize: 20,
|
||||
};
|
||||
};
|
||||
}
|
||||
}
|
||||
export default {
|
||||
name: "Staff",
|
||||
name: 'Staff',
|
||||
components: { Pagination, StaffForm, BaseModel, StaffExternalForm },
|
||||
data() {
|
||||
return {
|
||||
|
@ -371,162 +349,221 @@ export default {
|
|||
total: 0,
|
||||
staff_model: {
|
||||
visible: false,
|
||||
title: this.$t("trials:staff:dialogTitle:add"),
|
||||
width: "1200px",
|
||||
title: this.$t('trials:staff:dialogTitle:add'),
|
||||
width: '1200px',
|
||||
},
|
||||
status_model: {
|
||||
visible: false,
|
||||
title: this.$t("trials:staff:dialogTitle:status"),
|
||||
width: "500px",
|
||||
title: this.$t('trials:staff:dialogTitle:status'),
|
||||
width: '500px',
|
||||
},
|
||||
userTypeOptions: [],
|
||||
isAdd: "Add",
|
||||
isAdd: 'Add',
|
||||
staffStatus: null,
|
||||
btnLoading: false,
|
||||
currentRow: {},
|
||||
trialId: "",
|
||||
trialId: '',
|
||||
moment,
|
||||
statusForm: { isDeleted: false, removeTime: "", joinTime: "" },
|
||||
statusForm: { isDeleted: false, removeTime: '', joinTime: '' },
|
||||
statusRules: {
|
||||
removeTime: [
|
||||
{
|
||||
required: true,
|
||||
message: this.$t("common:ruleMessage:select"),
|
||||
trigger: ["blur"],
|
||||
message: this.$t('common:ruleMessage:select'),
|
||||
trigger: ['blur'],
|
||||
},
|
||||
],
|
||||
joinTime: [
|
||||
{
|
||||
required: true,
|
||||
message: this.$t("common:ruleMessage:select"),
|
||||
trigger: ["blur"],
|
||||
message: this.$t('common:ruleMessage:select'),
|
||||
trigger: ['blur'],
|
||||
},
|
||||
],
|
||||
},
|
||||
pickerOption: {
|
||||
disabledDate: (time) => {
|
||||
return time.getTime() > Date.now();
|
||||
return time.getTime() > Date.now()
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
roleList: [],
|
||||
role_model: {
|
||||
visible: false,
|
||||
title: this.$t('trials:staff:dialogTitle:role'),
|
||||
width: '800px',
|
||||
},
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.trialId = this.$route.query.trialId;
|
||||
this.getUserType();
|
||||
this.getList();
|
||||
this.trialId = this.$route.query.trialId
|
||||
this.getUserType()
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
// 发送邮件
|
||||
async handleSendEmail(row) {
|
||||
try {
|
||||
let confirm = await this.$confirm(
|
||||
this.$t('trials:staff:confirm:sendEmail')
|
||||
)
|
||||
if (!confirm) return false
|
||||
let data = {
|
||||
TrialId: this.$route.query.trialId,
|
||||
IdentityUserId: row.IdentityUserId,
|
||||
BaseUrl: `${location.protocol}//${location.host}/login`,
|
||||
RouteUrl: `${location.protocol}//${location.host}/email-recompose`,
|
||||
}
|
||||
this.listLoading = true
|
||||
let res = await trialUserSendJoinEmail(data)
|
||||
this.listLoading = false
|
||||
if (res.IsSuccess) {
|
||||
this.$message.success(
|
||||
this.$t('trials:staff:message:sendEmailSuccess')
|
||||
)
|
||||
this.getList()
|
||||
}
|
||||
} catch (err) {
|
||||
this.listLoading = false
|
||||
console.log(err)
|
||||
}
|
||||
},
|
||||
// 修改角色状态
|
||||
async changeRoleStatus(row, status) {
|
||||
try {
|
||||
let message = this.$t('trials:staff:comfirm:changeRoleStatus').replace(
|
||||
'xxx',
|
||||
this.$fd('IsDisable', status)
|
||||
)
|
||||
let comfirm = await this.$confirm(message)
|
||||
if (!comfirm) return false
|
||||
let data = {
|
||||
IdList: [row.Id],
|
||||
IsDeleted: status,
|
||||
}
|
||||
let res = await updateTrialUserRole(data)
|
||||
if (res.IsSuccess) {
|
||||
row.IsDeleted = status
|
||||
this.$message.success(
|
||||
this.$t('trials:trials-myinfo:message:updateSuccessfully')
|
||||
)
|
||||
this.getList()
|
||||
}
|
||||
} catch (err) {
|
||||
console.log(err)
|
||||
}
|
||||
},
|
||||
openRoleList(row) {
|
||||
this.roleList = row.TrialUserRoleList
|
||||
this.role_model.visible = true
|
||||
},
|
||||
// 分页获取项目参与人员列表
|
||||
getList() {
|
||||
this.listLoading = true;
|
||||
this.listQuery.TrialId = this.trialId;
|
||||
this.listLoading = true
|
||||
this.listQuery.TrialId = this.trialId
|
||||
getMaintenanceList(this.listQuery)
|
||||
.then((res) => {
|
||||
this.listLoading = false;
|
||||
this.list = res.Result.CurrentPageData;
|
||||
this.total = res.Result.TotalCount;
|
||||
this.listLoading = false
|
||||
this.list = res.Result.CurrentPageData
|
||||
this.total = res.Result.TotalCount
|
||||
})
|
||||
.catch(() => {
|
||||
this.listLoading = false;
|
||||
});
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
// 新增项目参与者
|
||||
handleAdd(type) {
|
||||
if (type === "Add") {
|
||||
this.staff_model.title = this.$t("trials:staff:button:addStaff");
|
||||
if (type === 'Add') {
|
||||
this.staff_model.title = this.$t('trials:staff:button:addInternalStaff')
|
||||
} else {
|
||||
this.staff_model.title = this.$t(
|
||||
"trials:staff:button:addExternalStaff"
|
||||
);
|
||||
this.staff_model.title = this.$t('trials:staff:button:addExternalStaff')
|
||||
}
|
||||
this.staff_model.visible = true;
|
||||
this.isAdd = type;
|
||||
this.staff_model.visible = true
|
||||
this.isAdd = type
|
||||
},
|
||||
handleStatus(row) {
|
||||
const { IsDeleted, RemoveTime, JoinTime } = { ...row };
|
||||
this.currentRow = { ...row };
|
||||
this.statusForm.isDeleted = IsDeleted;
|
||||
this.statusForm.removeTime = RemoveTime;
|
||||
this.statusForm.joinTime = JoinTime;
|
||||
this.status_model.visible = true;
|
||||
const { IsDeleted, RemoveTime, JoinTime } = { ...row }
|
||||
this.currentRow = { ...row }
|
||||
this.statusForm.isDeleted = IsDeleted
|
||||
this.statusForm.removeTime = RemoveTime
|
||||
this.statusForm.joinTime = JoinTime
|
||||
this.status_model.visible = true
|
||||
},
|
||||
// 修改参与者状态
|
||||
saveStatus() {
|
||||
this.$refs.statusForm.validate((valid) => {
|
||||
if (!valid) return;
|
||||
this.btnLoading = true;
|
||||
if (!valid) return
|
||||
this.btnLoading = true
|
||||
const param = {
|
||||
id: this.currentRow.Id,
|
||||
trialId: this.trialId,
|
||||
isDeleted: this.statusForm.isDeleted,
|
||||
removeTime: this.statusForm.removeTime,
|
||||
joinTime: this.statusForm.joinTime,
|
||||
};
|
||||
}
|
||||
updateTrialUser(param)
|
||||
.then((res) => {
|
||||
this.btnLoading = false;
|
||||
this.btnLoading = false
|
||||
if (res.IsSuccess) {
|
||||
this.status_model.visible = false;
|
||||
this.getList();
|
||||
this.$message.success(
|
||||
this.$t("common:message:savedSuccessfully")
|
||||
);
|
||||
this.status_model.visible = false
|
||||
this.getList()
|
||||
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
||||
}
|
||||
})
|
||||
.catch(() => {
|
||||
this.btnLoading = false;
|
||||
});
|
||||
});
|
||||
this.btnLoading = false
|
||||
})
|
||||
})
|
||||
},
|
||||
handleIsDeletedChanged(val) {
|
||||
if (val) {
|
||||
this.statusForm.joinTime = "";
|
||||
// this.statusForm.joinTime = ''
|
||||
} else {
|
||||
this.statusForm.removeTime = "";
|
||||
this.statusForm.removeTime = ''
|
||||
}
|
||||
},
|
||||
// 查询
|
||||
handleSearch() {
|
||||
this.listQuery.PageIndex = 1;
|
||||
this.getList();
|
||||
this.listQuery.PageIndex = 1
|
||||
this.getList()
|
||||
},
|
||||
// 重置
|
||||
handleReset() {
|
||||
this.listQuery = getListQueryDefault();
|
||||
this.getList();
|
||||
this.listQuery = getListQueryDefault()
|
||||
this.getList()
|
||||
},
|
||||
// 排序
|
||||
handleSortByColumn(column) {
|
||||
if (column.order === "ascending") {
|
||||
this.listQuery.Asc = true;
|
||||
if (column.order === 'ascending') {
|
||||
this.listQuery.Asc = true
|
||||
} else {
|
||||
this.listQuery.Asc = false;
|
||||
this.listQuery.Asc = false
|
||||
}
|
||||
this.listQuery.SortField = column.prop;
|
||||
this.listQuery.PageIndex = 1;
|
||||
this.getList();
|
||||
this.listQuery.SortField = column.prop
|
||||
this.listQuery.PageIndex = 1
|
||||
this.getList()
|
||||
},
|
||||
// 关闭模态框并更新列表
|
||||
closeDialog() {
|
||||
this.staff_model.visible = false;
|
||||
this.$message.success(this.$t("common:message:savedSuccessfully"));
|
||||
this.getList();
|
||||
this.staff_model.visible = false
|
||||
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
||||
this.getList()
|
||||
},
|
||||
// 导出
|
||||
handleExport() {
|
||||
this.listLoading = true;
|
||||
this.listQuery.TrialId = this.trialId;
|
||||
this.listLoading = true
|
||||
this.listQuery.TrialId = this.trialId
|
||||
trialUserListExport({ ...this.listQuery })
|
||||
.then((data) => {
|
||||
this.listLoading = false;
|
||||
this.listLoading = false
|
||||
})
|
||||
.catch(() => {
|
||||
this.listLoading = false;
|
||||
});
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
// 获取用户类型下拉数据
|
||||
getUserType() {
|
||||
getUserTypeListByUserType(0).then((res) => {
|
||||
getTrialUserTypeList().then((res) => {
|
||||
let arr = [];
|
||||
if (this.hasPermi(["role:admin"])) {
|
||||
arr = [1];
|
||||
|
@ -542,31 +579,40 @@ export default {
|
|||
return item;
|
||||
}
|
||||
}).filter((item) => item);
|
||||
});
|
||||
})
|
||||
},
|
||||
},
|
||||
};
|
||||
}
|
||||
</script>
|
||||
<style lang="scss">
|
||||
.participant-list {
|
||||
.filter-box {
|
||||
display: flex;
|
||||
padding: 5px;
|
||||
|
||||
.base-search-form {
|
||||
.el-form-item {
|
||||
margin-bottom: 0px;
|
||||
}
|
||||
}
|
||||
|
||||
.mr {
|
||||
margin-right: 5px;
|
||||
width: 120px;
|
||||
}
|
||||
}
|
||||
|
||||
.el-dialog__header {
|
||||
padding: 10px;
|
||||
}
|
||||
|
||||
.el-dialog__body {
|
||||
padding: 10px;
|
||||
}
|
||||
}
|
||||
|
||||
.icon-i {
|
||||
color: #e6a23c;
|
||||
cursor: pointer;
|
||||
}
|
||||
</style>
|
||||
|
|
|
@ -297,6 +297,7 @@ export default {
|
|||
if (selectedUserType.length > 0) {
|
||||
this.form.UserTypeEnum = selectedUserType[0].UserTypeEnum;
|
||||
}
|
||||
this.form.TrialId = this.$route.query.trialId
|
||||
addUser(this.form, true)
|
||||
.then((res) => {
|
||||
this.btnLoading = false;
|
||||
|
|
Loading…
Reference in New Issue