Browse Source

受试者管理

360view
bianyaqi 2 years ago
parent
commit
b24fc7cd26
  1. 1
      src/components/patient-search/index.vue
  2. 10
      src/page-subspecialty/views/modules/scientificManagement/subjectMgt/index.vue
  3. 384
      src/page-subspecialty/views/modules/scientificManagement/subjectMgt/patient-subject/index.vue

1
src/components/patient-search/index.vue

@ -150,7 +150,6 @@ export default {
this.retrieval()
},
viewDetail(val) {
console.log(val)
this.patientId = val
this.detailViewVisible = true
},

10
src/page-subspecialty/views/modules/scientificManagement/subjectMgt/index.vue

@ -2,19 +2,19 @@
<div class="template-container">
<el-tabs v-model="activeName" @tab-click="handleClick">
<el-tab-pane label="样本库" name="first">
<search />
<search v-if="activeName==='first'" />
</el-tab-pane>
<el-tab-pane label="医生管理" name="second">
<doctor />
<doctor v-if="activeName==='second'" />
</el-tab-pane>
<el-tab-pane label="eCRF管理" name="third">
<eCrf />
<eCrf v-if="activeName==='third'" />
</el-tab-pane>
<el-tab-pane label="受试者管理" name="fourth">
<patientSubject />
<patientSubject v-if="activeName==='fourth'" />
</el-tab-pane>
<el-tab-pane label="日志" name="five">
<operateLog />
<operateLog v-if="activeName==='five'" />
</el-tab-pane>
</el-tabs>
</div>

384
src/page-subspecialty/views/modules/scientificManagement/subjectMgt/patient-subject/index.vue

@ -1,172 +1,174 @@
<template>
<div class="subject-management">
<div class="subject-left">
<el-scrollbar style="height: 100%">
<div class="photo-groups">
<span>受试者分组</span>
<i class="el-icon-circle-plus" @click="addGroupClick" />
</div>
<div
v-for="(item, index) in groupList"
:key="item.id"
class="group-list"
:class="currentIndex == index ? 'group-list-active' : ''"
@click="grouplistClick(item.id, index)"
>
<span>{{ item.name }}</span>
<span v-if="item.name == '全部'" style="margin-right:20px;">{{ groupListAll.total }}</span>
<span v-else-if="item.name == '未分组'" style="margin-right:20px;">{{ groupListAll.noInGroup }}</span>
<div v-else class="dropdown-right">
<span class="number">{{ item.groupTotal }}</span>
<el-dropdown trigger="click" @command="handleDropdownCommand(item.id, $event)">
<i class="el-icon-more" />
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="1">修改</el-dropdown-item>
<el-dropdown-item command="2">删除</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
<div class="subject">
<div v-if="!detailViewVisible" class="subject-management">
<div class="subject-left">
<el-scrollbar style="height: 100%">
<div class="photo-groups">
<span>受试者分组</span>
<i class="el-icon-circle-plus" @click="addGroupClick" />
</div>
</div>
</el-scrollbar>
</div>
<div class="subject-right">
<div class="input-search">
<el-input
v-model="inputSearchValue"
placeholder="姓名"
class="input-with-select"
clearable
@clear="getDataList()"
@change="getDataList()"
>
<el-button slot="append" icon="el-icon-search" @click="getDataList()" />
</el-input>
<div
v-for="(item, index) in groupList"
:key="item.id"
class="group-list"
:class="currentIndex == index ? 'group-list-active' : ''"
@click="grouplistClick(item.id, index)"
>
<span>{{ item.name }}</span>
<span v-if="item.name == '全部'" style="margin-right:20px;">{{ groupListAll.total }}</span>
<span v-else-if="item.name == '未分组'" style="margin-right:20px;">{{ groupListAll.noInGroup }}</span>
<div v-else class="dropdown-right">
<span class="number">{{ item.groupTotal }}</span>
<el-dropdown trigger="click" @command="handleDropdownCommand(item.id, $event)">
<i class="el-icon-more" />
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="1">修改</el-dropdown-item>
<el-dropdown-item command="2">删除</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</div>
</div>
</el-scrollbar>
</div>
<div class="subject-right">
<div class="input-search">
<el-input
v-model="inputSearchValue"
placeholder="姓名"
class="input-with-select"
clearable
@clear="getDataListInitial()"
@change="getDataListInitial()"
>
<el-button slot="append" icon="el-icon-search" @click="getDataListInitial()" />
</el-input>
</div>
<div class="people-list">
<!-- <div class="title">人员列表</div> -->
<el-table
ref="multipleTable"
v-loading="tabelLoading"
:data="dataList"
tooltip-effect="dark"
style="width: 100%"
@selection-change="handleSelectionChange"
>
<el-table-column type="selection" width="55" />
<el-table-column type="index" width="55" label="序号" header-align="center" align="center" />
<el-table-column prop="patientName" label="姓名" header-align="center" align="center" />
<el-table-column prop="age" label="年龄" header-align="center" align="center" />
<el-table-column prop="patientSex" label="性别" header-align="center" align="center" />
<el-table-column prop="suggest" label="纳排建议" header-align="center" align="center">
<template slot-scope="scope">
<span
v-if="scope.row.suggest"
:class="scope.row.suggest == '1' ? 'suggest-circle suggest-circle-green' : 'suggest-circle suggest-circle-red'"
/>
<span>{{ scope.row.suggest==1 ? '符合': (scope.row.suggest==0 ? '不符合' : '无') }}</span>
</template>
</el-table-column>
<el-table-column label="分组信息" header-align="center" align="center">
<template slot-scope="scope">
<div v-show="scope.row.groupList && scope.row.groupList.length > 0">
<span v-for="item in scope.row.groupList" :key="item.id">{{ item.name }}</span>
</div>
</template>
</el-table-column>
<el-table-column prop="operation" label="操作" width="200">
<template slot-scope="scope">
<span
style="color: #1890ff; padding-right: 8px"
class="operation-details"
@click="showDetail(scope.row)"
>详情</span>
<span
style="color: #ff4d4f"
class="operation-delete"
@click="deleteSubjectClick(scope.row.id)"
>移出课题</span>
<span
v-show="groupId!==0 && groupId!=='' ? true:false"
style="color: #ff4d4f;padding-left:10px;"
class="operation-delete"
@click="deleteGroupClick(scope.row)"
>移出分组</span>
</template>
</el-table-column>
</el-table>
<!-- 分页 -->
<el-pagination
:current-page="page"
:page-sizes="[10, 20, 50, 100]"
:page-size="limit"
:total="total"
layout="total, sizes, prev, pager, next, jumper"
@size-change="pageSizeChangeHandle"
@current-change="pageCurrentChangeHandle"
/>
<div class="people-list">
<!-- <div class="title">人员列表</div> -->
<el-table
ref="multipleTable"
v-loading="tabelLoading"
:data="dataList"
tooltip-effect="dark"
style="width: 100%"
@selection-change="handleSelectionChange"
>
<el-table-column type="selection" width="55" />
<el-table-column type="index" width="55" label="序号" header-align="center" align="center" />
<el-table-column prop="patientName" label="姓名" header-align="center" align="center" />
<el-table-column prop="age" label="年龄" header-align="center" align="center" />
<el-table-column prop="patientSex" label="性别" header-align="center" align="center" />
<el-table-column prop="suggest" label="纳排建议" header-align="center" align="center">
<template slot-scope="scope">
<span
v-if="scope.row.suggest"
:class="scope.row.suggest == '1' ? 'suggest-circle suggest-circle-green' : 'suggest-circle suggest-circle-red'"
/>
<span>{{ scope.row.suggest==1 ? '符合': (scope.row.suggest==0 ? '不符合' : '无') }}</span>
</template>
</el-table-column>
<el-table-column label="分组信息" header-align="center" align="center">
<template slot-scope="scope">
<div v-show="scope.row.groupList && scope.row.groupList.length > 0">
<span v-for="item in scope.row.groupList" :key="item.id">{{ item.name }}</span>
</div>
</template>
</el-table-column>
<el-table-column prop="operation" label="操作" width="200">
<template slot-scope="scope">
<span
style="color: #1890ff; padding-right: 8px"
class="operation-details"
@click="showDetail(scope.row)"
>详情</span>
<span
style="color: #ff4d4f"
class="operation-delete"
@click="deleteSubjectClick(scope.row.id)"
>移出课题</span>
<span
v-show="groupId!==0 && groupId!=='' ? true:false"
style="color: #ff4d4f;padding-left:10px;"
class="operation-delete"
@click="deleteGroupClick(scope.row)"
>移出分组</span>
</template>
</el-table-column>
</el-table>
<!-- 分页 -->
<el-pagination
:current-page="page"
:page-sizes="[10, 20, 50, 100]"
:page-size="limit"
:total="total"
layout="total, sizes, prev, pager, next, jumper"
@size-change="pageSizeChangeHandle"
@current-change="pageCurrentChangeHandle"
/>
<!-- 底部全选反选 -->
<checked-footer
ref="checkfooter"
table-ref="multipleTable"
:current-table-list="currentTableList"
:data-list="dataList"
>
<div class="batch_button">
<!-- <el-button
size="small"
:disabled="(groupId==0 || groupId=='') && currentTableList.length > 0 ? false:true"
@click="batchDeleteSubjectClick"
>批量移出课题</el-button>
<el-button
size="small"
:disabled="groupId!==0 && groupId!==''&& currentTableList.length > 0 ? false:true"
@click="batchDeleteGroupClick"
>批量移出分组</el-button>
<el-button size="small" @click="btnExportClick">{{ currentTableList.length > 0 ?"导出":"全部导出" }}</el-button>
<el-dropdown @command="handleGroupCommand($event)">
<el-button type="primary" size="small" :disabled="currentTableList.length > 0 ? false :true">分组
</el-button>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item
v-for="item in groupList"
:key="item.id"
:command="item.id"
:disabled="item.name=='全部' || item.name=='未分组'"
>{{ item.name }}
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown> -->
<!-- 底部全选反选 -->
<checked-footer
ref="checkfooter"
table-ref="multipleTable"
:current-table-list="currentTableList"
:data-list="dataList"
>
<div class="batch_button">
<!-- <el-button
size="small"
:disabled="(groupId==0 || groupId=='') && currentTableList.length > 0 ? false:true"
@click="batchDeleteSubjectClick"
>批量移出课题</el-button>
<el-button
size="small"
:disabled="groupId!==0 && groupId!==''&& currentTableList.length > 0 ? false:true"
@click="batchDeleteGroupClick"
>批量移出分组</el-button>
<el-button size="small" @click="btnExportClick">{{ currentTableList.length > 0 ?"导出":"全部导出" }}</el-button>
<el-dropdown @command="handleGroupCommand($event)">
<el-button type="primary" size="small" :disabled="currentTableList.length > 0 ? false :true">分组
</el-button>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item
v-for="item in groupList"
:key="item.id"
:command="item.id"
:disabled="item.name=='全部' || item.name=='未分组'"
>{{ item.name }}
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown> -->
<!-- 批量 -->
<el-dropdown @command="handleCommandChecked">
<el-button split-button size="small" type="primary" :disabled="currentTableList.length === 0">
<span class="el-dropdown-link">
批量操作
</span>
</el-button>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="export">导出</el-dropdown-item>
<el-dropdown-item command="remove">移除</el-dropdown-item>
<el-dropdown-item command="group">分组</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
<!-- 全部 -->
<el-dropdown @command="handleCommandAll">
<el-button split-button size="small" type="primary">
<span class="el-dropdown-link">
全部操作
</span>
</el-button>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="export">导出</el-dropdown-item>
<el-dropdown-item command="remove">移除</el-dropdown-item>
<el-dropdown-item command="group">分组</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</div>
</checked-footer>
<!-- 批量 -->
<el-dropdown @command="handleCommandChecked">
<el-button split-button size="small" type="primary" :disabled="currentTableList.length === 0">
<span class="el-dropdown-link">
批量操作
</span>
</el-button>
<el-dropdown-menu slot="dropdown">
<!-- <el-dropdown-item command="export">导出</el-dropdown-item>-->
<el-dropdown-item command="remove">移除</el-dropdown-item>
<el-dropdown-item command="group">分组</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
<!-- 全部 -->
<el-dropdown @command="handleCommandAll">
<el-button split-button size="small" type="primary">
<span class="el-dropdown-link">
全部操作
</span>
</el-button>
<el-dropdown-menu slot="dropdown">
<!-- <el-dropdown-item command="export">导出</el-dropdown-item>-->
<el-dropdown-item command="remove">移除</el-dropdown-item>
<el-dropdown-item command="group">分组</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</div>
</checked-footer>
</div>
</div>
</div>
@ -192,25 +194,6 @@
</span>
</el-dialog>
<!-- 详情页 -->
<el-dialog
class="dialog-360"
:visible.sync="dialogVisible"
:title="'患者360'"
:close-on-click-modal="false"
:close-on-press-escape="false"
:fullscreen="true"
append-to-body
>
<patient-view
v-if="dialogVisible"
ref="detailView"
:patient-id-number="patient.patientIdNumber"
:project-id="patient.projectId"
:is-subject="true"
/>
</el-dialog>
<!-- 添加分组弹框 -->
<el-dialog title="添加分组" :visible.sync="dialogFormVisible" @close="CloseDialog">
<el-form ref="addGroupRuleForm" :model="formGroup" :rules="addGroupRules" @submit.native.prevent>
@ -249,9 +232,12 @@
<el-button type="primary" @click="exportOK()"> </el-button>
</span>
</el-dialog>
<!-- 详情页 -->
<detail-view v-if="detailViewVisible" ref="viewRef" :only-read="onlyRead" :is-search="'1'" :patient-id="patientId" @detailViewVisible="detailViewVisible=false" />
</div>
</template>
<script>
import detailView from '@/components/360View/index' // 360
import checked from '@/mixins/checked'
import patientView from '@/components/patient-view'
import checkedFooter from '@/components/checked-footer'
@ -262,7 +248,7 @@ import { formatDate } from '@/utils/index.js'
import eventBus from '@/page-subspecialty/utils/eventBus'
export default {
components: { patientView, checkedFooter, kpiSelect, deviceSelect },
components: { patientView, checkedFooter, kpiSelect, deviceSelect, detailView },
mixins: [checked],
data() {
return {
@ -313,8 +299,10 @@ export default {
patient: {
patientIdNumber: '',
projectId: ''
}
},
detailViewVisible: false,
patientId: '',
onlyRead: true
}
},
computed: {
@ -327,38 +315,37 @@ export default {
},
created() {
this.formGroup.projectId = this.$route.query.projectId
this.getDataList()
this.projectId = this.$route.query.projectId
this.getDataListInitial()
this.getGroupList()
},
mounted() {
eventBus.$off('getSubjectSuccess')
eventBus.$on('getSubjectSuccess', () => {
this.getGroupList()
this.getDataList()
this.getDataListInitial()
})
},
methods: {
refresh() {
this.getGroupList()
this.grouplistClick(this.groupId, this.currentIndex)
},
//
showDetail(row) {
// console.log(row)
this.dialogVisible = true
this.patient.patientIdNumber = row.patientIdNumber
this.patient.projectId = this.projectId
this.patientId = row.patientId
console.log(this.patientId)
this.detailViewVisible = true
},
//
grouplistClick(id, index) {
this.groupId = id
this.currentIndex = index
this.page = 1
this.getDataList()
this.getDataListInitial()
},
//
getDataList() {
getDataListInitial() {
this.tabelLoading = true
this.$http.get('/project/patient/page', {
params: {
@ -443,6 +430,7 @@ export default {
}).then(({ data: res }) => {
this.groupList = [{ name: '全部', id: '' }, { name: '未分组', id: 0 }, ...res.data.list]
this.groupListAll = res.data
console.log(this.groupList)
})
},
//
@ -505,6 +493,7 @@ export default {
//
handleGroup(type) {
this.dialogVisible_group = true
console.log(type)
this.dialogGroup.type = type
},
handleGroup_OK() {
@ -610,13 +599,13 @@ export default {
// ,
pageCurrentChangeHandle(val) {
this.page = val
this.getDataList()
this.getDataListInitial()
},
// ,
pageSizeChangeHandle(val) {
this.page = 1
this.limit = val
this.getDataList()
this.getDataListInitial()
},
//
async handleGroupCommand(e) {
@ -753,6 +742,9 @@ export default {
font-size: 12px;
}
}
.subject{
height: 100%;
}
.subject-management .detail-view {
.el-dialog {
background: #000;

Loading…
Cancel
Save