|
|
@ -1,3 +1,10 @@ |
|
|
|
<!-- |
|
|
|
* @Author: wally |
|
|
|
* @email: 18603454788@163.com |
|
|
|
* @Date: 2021-02-19 16:04:48 |
|
|
|
* @LastEditors: wally |
|
|
|
* @LastEditTime: 2021-02-19 17:59:27 |
|
|
|
--> |
|
|
|
<template> |
|
|
|
<div class="d-flex flex-column"> |
|
|
|
<search @searchPatientMes="searchPatientMes" /> |
|
|
@ -8,7 +15,7 @@ |
|
|
|
<script> |
|
|
|
import Search from 'components/BiologicalSampleSearch/Search.vue'; |
|
|
|
import SampleTable from 'components/BiologicalSampleSearch/SampleTable.vue'; |
|
|
|
import { selPatientMes } from 'config/api'; |
|
|
|
import { selBiologicalSamples } from 'config/api'; |
|
|
|
import { mapState, mapActions } from 'vuex'; |
|
|
|
|
|
|
|
export default { |
|
|
@ -17,8 +24,11 @@ export default { |
|
|
|
data() { |
|
|
|
return { |
|
|
|
lists: { pageNum: 1, pageSize: 10, total: 1, list: [] }, |
|
|
|
hospitalization: '', |
|
|
|
inpatientId: '', |
|
|
|
collectTime: '', // 采集时间 |
|
|
|
hospitalId: '', // 医院id |
|
|
|
hospitalization: '', // 患者住院号 |
|
|
|
pageNum: 1, // 当前页 |
|
|
|
sampleType: '', // 样本类型 |
|
|
|
}; |
|
|
|
}, |
|
|
|
|
|
|
@ -32,24 +42,31 @@ export default { |
|
|
|
|
|
|
|
searchPatientMes(value) { |
|
|
|
if (value) { |
|
|
|
this.hospitalId = value.hospital; |
|
|
|
this.collectTime = value.acquisitionTime; |
|
|
|
this.hospitalization = value.inpatientNumber; |
|
|
|
this.inpatientId = value.groupValue; |
|
|
|
this.sampleType = value.sampleType; |
|
|
|
} |
|
|
|
this.handleSelPatientMes(); |
|
|
|
}, |
|
|
|
|
|
|
|
async handleSelPatientMes(pageNum = 1) { |
|
|
|
async handleSelPatientMes(current) { |
|
|
|
try { |
|
|
|
const { hospitalization, inpatientId } = this; |
|
|
|
if (current) { |
|
|
|
this.pageNum = current; |
|
|
|
} |
|
|
|
const { collectTime, hospitalId, hospitalization, pageNum, sampleType } = this; |
|
|
|
const params = { |
|
|
|
param: { |
|
|
|
hospitalization, |
|
|
|
inpatientId, |
|
|
|
pageNum, |
|
|
|
pageSize: 10, |
|
|
|
collectTime: collectTime, // 采集时间 |
|
|
|
hospitalId: hospitalId, // 医院id |
|
|
|
hospitalization: hospitalization, // 患者住院号 |
|
|
|
pageNum: pageNum, // 当前页 |
|
|
|
pageSize: 10, // 每页数量 |
|
|
|
sampleType: sampleType, // 样本类型 |
|
|
|
}, |
|
|
|
}; |
|
|
|
const res = await selPatientMes(params); |
|
|
|
const res = await selBiologicalSamples(params); |
|
|
|
const { code, msg, data } = res.data; |
|
|
|
if (code === 200) { |
|
|
|
this.lists = data; |
|
|
|