Browse Source

加载提示,表格展示问题

master
aBin 4 years ago
parent
commit
cde6c010bc
  1. 26
      src/App.vue
  2. 2
      src/common/portrait.styl
  3. 14
      src/components/BiologicalSampleSearch/SampleTable.vue
  4. 3
      src/components/BiologicalSampleSearch/Search.vue
  5. 3
      src/components/CaseTable/CaseKTOne.vue
  6. 10
      src/components/CaseTable/CaseTable.vue
  7. 2
      src/components/Echarts/Analysis.vue
  8. 3
      src/components/Echarts/Categorymap.vue
  9. 1
      src/components/Echarts/Cisualmap.vue
  10. 3
      src/components/Echarts/PatientProgress.vue
  11. 5
      src/components/Echarts/Piemap.vue
  12. 6
      src/components/Echarts/PiemapHos.vue
  13. 9
      src/components/MeetingPreview/MeetingPreview.vue
  14. 26
      src/components/PatientInfo/PatientTable.vue
  15. 5
      src/components/TypeTable/TypeTable.vue
  16. 4
      src/config/api.js
  17. 8
      src/store/modules/home/mutations.js
  18. 5
      src/store/modules/home/state.js
  19. 2392
      src/views/CaseAnalysis/CaseAnalysis.vue
  20. 2395
      src/views/CaseSearch/CaseSearch.vue
  21. 2
      src/views/Index/Index.vue
  22. 2187
      src/views/PatientInfo/PatientInfo.vue
  23. 9
      src/views/PersonalStats/PersonalStats.vue
  24. 76
      src/views/SelectPatient/SelectPatient.vue

26
src/App.vue

@ -3,13 +3,13 @@
* @email: 18603454788@163.com
* @Date: 2021-02-22 09:20:03
* @LastEditors: wally
* @LastEditTime: 2021-04-20 10:11:13
* @LastEditTime: 2021-04-26 18:12:14
-->
<template>
<a-config-provider :locale="zh_CN">
<div class="d-flex flex-row flex-nowrap" id="app">
<btn-con />
<!-- <btn-con /> -->
<router-view class="flex-1 bg pa-3"></router-view>
</div>
</a-config-provider>
@ -18,12 +18,12 @@
<script>
import { mapState, mapActions, mapMutations } from 'vuex';
import zh_CN from 'ant-design-vue/lib/locale-provider/zh_CN';
import BtnCon from 'components/BtnCom/BtnCon.vue';
// import BtnCon from 'components/BtnCom/BtnCon.vue';
import { getHId } from 'config/api';
export default {
name: 'App',
components: { BtnCon },
// components: { BtnCon },
data() {
return { zh_CN };
},
@ -36,35 +36,37 @@ export default {
const params = { userId: val.userId };
this.getUserId(params);
this.getHospitalId(val.projectId);
console.log('val.userId:' + val.userId);
}
},
},
async created() {
const userId = '1218763410024566784';
const params = { userId };
await this.getUserId(params);
await this.getToken();
created() {
// const userId = '1218763410024566784';
// const params = { userId };
// await this.getUserId(params);
// await this.getToken();
if (localStorage.getItem('patientId')) {
this.setPatientId(localStorage.getItem('patientId'));
}
if (localStorage.getItem('hospitalization')) {
this.setHospitalization(localStorage.getItem('hospitalization'));
}
if (localStorage.getItem('recordCode')) {
this.setRecordCode(localStorage.getItem('recordCode'));
}
const that = this;
window.plugin = window.TallPlugin.init();
// created created便
// created created
// PT ididididuserId
window.plugin.created(function(props) {
console.log('props: ', props);
that.setPtProps(props);
that.getHospitalId(props.projectId);
});
},
methods: {
...mapActions('home', ['getUserId']),
...mapMutations('home', ['setPtProps', 'setHospitalId', 'setPatientId', 'getToken', 'setHospitalization']),
...mapMutations('home', ['setPtProps', 'setHospitalId', 'setPatientId', 'getToken', 'setHospitalization', 'setRecordCode']),
async getHospitalId(Id) {
try {

2
src/common/portrait.styl

@ -208,7 +208,7 @@
position: fixed;
height: 40px;
font-size: 14px;
right: 12px;
right: 18px;
top: 50px;
}
// flex

14
src/components/BiologicalSampleSearch/SampleTable.vue

@ -37,11 +37,23 @@ const columns = [
key: 'name',
},
{
title: '患者编号',
title: '住院号',
align: 'center',
dataIndex: 'hospitalization',
key: 'hospitalization',
},
{
title: '研究编号',
align: 'center',
dataIndex: 'patientCode',
key: 'patientCode',
},
{
title: '生物样本编号',
align: 'center',
dataIndex: 'code',
key: 'code',
},
{
title: '类型',
align: 'center',

3
src/components/BiologicalSampleSearch/Search.vue

@ -3,7 +3,7 @@
* @email: 18603454788@163.com
* @Date: 2021-02-22 09:20:03
* @LastEditors: wally
* @LastEditTime: 2021-04-14 18:30:24
* @LastEditTime: 2021-04-26 18:12:49
-->
<template>
<!-- search -->
@ -92,7 +92,6 @@ export default {
e.preventDefault();
this.form.validateFields(async (err, values) => {
if (!err) {
console.log('values: ', values);
this.$emit('searchPatientMes', values);
}
});

3
src/components/CaseTable/CaseKTOne.vue

@ -50,7 +50,7 @@
:min="0"
@change="onChange($event, item.code, 'min')"
placeholder="最小值"
style="width: 150px;"
style="width: 150px"
v-model="item.minValue"
/>
<div class="px-2">~</div>
@ -100,7 +100,6 @@ export default {
methods: {
...mapMutations('home', ['setCaseData']),
onChange(e, code, str) {
console.log(e);
let obj = {};
if (str === 'min') {
obj = {

10
src/components/CaseTable/CaseTable.vue

@ -42,11 +42,17 @@ import { mapMutations, mapState } from 'vuex';
import { upPatientMes } from 'config/api';
const columns = [
{
title: '患者编号',
title: '住院号',
align: 'center',
dataIndex: 'hospitalization',
key: 'hospitalization',
},
{
title: '研究编号',
align: 'center',
dataIndex: 'code',
key: 'code',
},
{
title: '医院',
align: 'center',
@ -125,7 +131,6 @@ export default {
this.$emit('setData', current);
},
details(Id, hospitalization) {
console.log(Id, hospitalization);
this.setPatientId(Id);
this.setHospitalization(hospitalization);
this.$router.push('/patientInfo');
@ -135,7 +140,6 @@ export default {
this.recordType = inputStatus;
this.defaultValue = this.statusList[inputStatus];
this.visible = true;
console.log(this.recordType);
},
async handleOk() {
try {

2
src/components/Echarts/Analysis.vue

@ -77,7 +77,6 @@ export default {
let arr = [];
//
// if (this.lists.selGroupNums[i].list.length > 0) {
console.log(this.lists.stringList);
for (let j = 0; j < this.lists.stringList.length; j++) {
let obj = {
name: this.lists.stringList[j],
@ -116,7 +115,6 @@ export default {
};
this.series.push(obj);
}
console.log(this.series);
await this.drawLine();
},
},

3
src/components/Echarts/Categorymap.vue

@ -3,7 +3,7 @@
* @email: 18603454788@163.com
* @Date: 2021-01-29 14:45:02
* @LastEditors: wally
* @LastEditTime: 2021-02-19 15:50:23
* @LastEditTime: 2021-04-26 18:13:05
-->
<template>
<!-- <div>数据统计组件</div> -->
@ -220,7 +220,6 @@ export default {
const res = await HospitalComplete(params);
const { code, msg, data } = res.data;
if (code === 200) {
console.log(data);
for (let i = 0; i < data.length; i++) {
this.forList(data[i]);
}

1
src/components/Echarts/Cisualmap.vue

@ -150,7 +150,6 @@ export default {
this.forOverList(data.overNums[i]);
}
} else {
console.log(msg);
}
} catch (error) {
this.$message.error('获取数据失败');

3
src/components/Echarts/PatientProgress.vue

@ -34,7 +34,6 @@ export default {
this.nameList = [];
this.dataList = [];
this.series = [];
console.log(this.lists);
//
for (let i = 0; i < this.lists.length; i++) {
// Y
@ -87,8 +86,6 @@ export default {
};
this.series.push(obj);
}
console.log(this.stringList);
console.log(this.series);
this.drawLine();
},
},

5
src/components/Echarts/Piemap.vue

@ -59,11 +59,8 @@ export default {
this.dataList.push(obj);
}
} else {
console.log(msg);
}
} catch (error) {
console.log(error);
}
} catch (error) {}
},
},
};

6
src/components/Echarts/PiemapHos.vue

@ -53,7 +53,6 @@ export default {
const res = await selByHosAllYBS(params);
const { code, msg, data } = res.data;
if (code === 200) {
console.log(data, 123);
for (let i = 0; i < data.length; i++) {
var obj = {
value: data[i].nums,
@ -62,11 +61,8 @@ export default {
this.dataList.push(obj);
}
} else {
console.log(msg, 132);
}
} catch (error) {
console.log(error);
}
} catch (error) {}
},
},
};

9
src/components/MeetingPreview/MeetingPreview.vue

@ -1,7 +1,14 @@
<!--
* @Author: wally
* @email: 18603454788@163.com
* @Date: 2021-04-19 10:23:19
* @LastEditors: wally
* @LastEditTime: 2021-04-23 18:52:43
-->
<template>
<div>
<a-button class="mr-3" type="primary">预览</a-button>
<a-modal footer title="会议记录预览" v-model="visible" width="1000px">
<a-modal footer title="会议记录预览" v-model="visible" width="1000px" v-if="visible">
<div class="fill-width">
<a-card :bordered="false">
<a-list class="metting">

26
src/components/PatientInfo/PatientTable.vue

@ -33,15 +33,19 @@
</template>
<template slot="edit" slot-scope="text, record">
<a-button @click="showModal(record.id, record.hospitalization)" class="ml-4" size="small" type="primary">选择</a-button>
<a-button @click="showModal(record.id, record.hospitalization, record.code)" class="ml-4" size="small" type="primary">
选择
</a-button>
</template>
</a-table>
</div>
<a-empty v-else />
<a-modal title="选择患者" width="600px" v-model="visible" @ok="handleOk" @cancel="handleCancel">
是否要录入患者编号为
是否要录入住院号为
<span style="color: green">{{ hospitalization }}</span>
的患者的相关数据
, 研究编号为:
<span style="color: green">{{ recordCode }}</span>
, 的患者的相关数据
</a-modal>
</div>
</template>
@ -103,8 +107,9 @@ export default {
loading: false,
visible: false,
hasPatientId: false,
patientId: '',
hospitalization: '',
patientId: '', // Id
hospitalization: '', //
recordCode: '', //
};
},
@ -120,10 +125,11 @@ export default {
},
methods: {
...mapMutations('home', ['setPatientId', 'setHospitalization']),
showModal(id, hospitalization) {
...mapMutations('home', ['setPatientId', 'setHospitalization', 'setRecordCode']),
showModal(id, hospitalization, recordCode) {
this.patientId = id;
this.hospitalization = hospitalization;
this.recordCode = recordCode;
this.visible = true;
},
handleCancel(e) {
@ -131,16 +137,18 @@ export default {
this.visible1 = false;
},
handleOk() {
this.chooseItem(this.patientId, this.hospitalization);
this.chooseItem(this.patientId, this.hospitalization, this.recordCode);
this.visible1 = true;
},
//
async chooseItem(id, hospitalization) {
async chooseItem(id, hospitalization, recordCode) {
try {
this.setPatientId(id);
this.setHospitalization(hospitalization);
this.setRecordCode(recordCode);
localStorage.setItem('patientId', id);
localStorage.setItem('hospitalization', hospitalization);
localStorage.setItem('recordCode', recordCode);
const params = { param: { patientId: id } };
const res = await generatePatientReport(params);
const { code, msg, data } = res.data;

5
src/components/TypeTable/TypeTable.vue

@ -3,7 +3,7 @@
* @email: 18603454788@163.com
* @Date: 2021-04-20 17:44:23
* @LastEditors: wally
* @LastEditTime: 2021-04-20 21:32:09
* @LastEditTime: 2021-04-26 15:55:24
-->
<template>
<div>
@ -54,7 +54,8 @@ export default {
const data = JSON.parse(this.remark);
this.changeRow(data.param);
this.changeCol(data.param);
console.log(this.list);
console.log('list:', this.list);
console.log('remark:', this.remark);
},
methods: {
/**

4
src/config/api.js

@ -3,7 +3,7 @@
* @email: 18603454788@163.com
* @Date: 2021-01-29 11:16:27
* @LastEditors: wally
* @LastEditTime: 2021-04-01 19:25:20
* @LastEditTime: 2021-04-26 17:59:22
*/
import axios from 'axios';
let { proxyUrl } = require('@/config/setting');
@ -22,7 +22,7 @@ const file = `${tcm}/file`; // 文件相关接口
// 上传文件
export const upload = `${file}/upload`;
// 通过任务Id查询项目Id
// 通过任务Id查询医院Id
export const getHId = params => axios.get(`${hospatil}/byProjectId?projectId=${params}`);
// 查询医院列表

8
src/store/modules/home/mutations.js

@ -53,6 +53,14 @@ const mutations = {
setHospitalization(state, data) {
state.hospitalization = data;
},
/**
* 设置病患住研究编号
* @param {object} state
* @param {string} data
*/
setRecordCode(state, data) {
state.recordCode = data;
},
/**
* 设置预览信息
* @param {object} state

5
src/store/modules/home/state.js

@ -3,7 +3,7 @@
* @email: 18603454788@163.com
* @Date: 2021-02-22 09:20:03
* @LastEditors: wally
* @LastEditTime: 2021-04-02 08:31:38
* @LastEditTime: 2021-04-26 17:28:17
*/
const state = {
anyringToken: '',
@ -11,8 +11,9 @@ const state = {
controlGroups: [], // 对照组
patientId: '', // 病患id
hospitalization: '', // 病患住院号
recordCode: '', // 患者研究编号
previewInfo: { host: '', place: '', startTime: '', endTime: '', participants: '', meetingMinutes: '', discussionContent: '' }, // 预览信息
ptProps: null, // 接受PT传过来的 pluginId,projectId,roleId,taskId,userId
ptProps: { userId: '' }, // 接受PT传过来的 pluginId,projectId,roleId,taskId,userId
hospitalId: '', // 医院Id
caseData: null, // 病例 搜索/分析 下的认知量表所做的每道题,每次改变重新存一次
};

2392
src/views/CaseAnalysis/CaseAnalysis.vue

File diff suppressed because it is too large

2395
src/views/CaseSearch/CaseSearch.vue

File diff suppressed because it is too large

2
src/views/Index/Index.vue

@ -3,7 +3,7 @@
* @email: 18603454788@163.com
* @Date: 2021-02-22 09:20:03
* @LastEditors: wally
* @LastEditTime: 2021-04-02 08:50:23
* @LastEditTime: 2021-04-21 19:27:05
-->
<template>
<div class="flex-wrap">

2187
src/views/PatientInfo/PatientInfo.vue

File diff suppressed because it is too large

9
src/views/PersonalStats/PersonalStats.vue

@ -1,7 +1,14 @@
<!--
* @Author: wally
* @email: 18603454788@163.com
* @Date: 2021-04-19 10:23:19
* @LastEditors: wally
* @LastEditTime: 2021-04-21 19:27:51
-->
<template>
<div class="flex-wrap">
<div class="fill-width mb-3">
<a-card style="width: 100%; min-height: 500px; height: auto" title="临近任务">
<a-card style="width: 100%; max-height: 500px; height: auto" title="临近任务">
<adjacentTasks :obj-list="objList" @getTableData="getTableData" />
</a-card>
</div>

76
src/views/SelectPatient/SelectPatient.vue

@ -1,20 +1,21 @@
<template>
<div class="d-flex flex-column">
<div class="d-flex flex-column main">
<div v-if="!patientId">
<search @searchPatientMes="searchPatientMes" />
<patient-table :lists="lists" @handleSelPatientMes="handleSelPatientMes" class="mt-3" />
</div>
<div v-else style="position: relative">
<a-tabs default-active-key="OTHER">
<a-tab-pane v-for="item in codeTypeList" :key="item.code" :tab="item.name">
<div v-if="item.code === 'SWYB'">
<biological-samples />
<a-button v-if="isShow === true" type="primary" class="full-screen" @click="changeShow">取消全屏</a-button>
<a-tabs default-active-key="OTHER" @tabClick="changeShow">
<a-tab-pane v-for="item in codeTypeList" :key="item.code" :tab="item.name" :class="isShow ? 'fixed-pane' : ''">
<div v-if="item.code === 'SWYB'" class="flex-1">
<biological-samples style="width: 100%" />
</div>
<div v-else-if="item.code === 'RZLB'">
<iframe style="width: 100%; heigt: 100%" height="100%" :src="rzlbSrc"></iframe>
<div v-else-if="item.code === 'RZLB'" class="flex-1">
<iframe style="width: 100%; border: none !important" :style="{ height: height }" :src="rzlbSrc"></iframe>
</div>
<div v-else-if="item.code !== 'SWYB' && item.code !== 'RZLB'">
<patient-info :code="item.code" />
<div v-else-if="item.code !== 'SWYB' && item.code !== 'RZLB'" class="flex-1">
<patient-info :code="item.code" style="width: 100%" />
</div>
</a-tab-pane>
</a-tabs>
@ -42,6 +43,7 @@ export default {
lists: { pageNum: 1, pageSize: 10, total: 1, list: [] },
hospitalization: '',
inpatientId: '',
height: '',
codeTypeList: [
{
code: 'OTHER',
@ -59,21 +61,27 @@ export default {
code: 'QXJC',
name: '器械检查',
},
{
code: 'SWYB',
name: '生物样本',
},
{
code: 'RZLB',
name: '认知量表',
},
{
code: 'SWYB',
name: '生物样本',
},
],
rzlbSrc: `http://sxzxyzzlm.tall.wiki/ht-common?code=KT&userId=1218763410024566784`,
isShow: true,
rzlbSrc: '',
};
},
computed: mapState('home', ['patientId', 'ptProps', 'user']),
mounted() {
this.height = document.getElementsByClassName('main')[0].offsetHeight + 'px';
this.rzlbSrc = `http://sxzxyzzlm.tall.wiki/ht-common?code=KT&userId=${this.ptProps.userId}`;
},
created() {
this.handleSelPatientMes();
this.getControlGroups();
@ -82,7 +90,7 @@ export default {
methods: {
...mapActions('home', ['getControlGroups']),
...mapMutations('home', ['setPatientId']),
...mapMutations('home', ['setPatientId', 'setHospitalization', 'setRecordCode']),
searchPatientMes(value) {
if (value) {
this.hospitalization = value.inpatientNumber;
@ -121,6 +129,22 @@ export default {
*/
choosePatient() {
this.setPatientId('');
this.setHospitalization('');
this.setRecordCode('');
if (localStorage.getItem('patientId')) {
localStorage.removeItem('patientId');
}
if (localStorage.getItem('hospitalization')) {
localStorage.removeItem('hospitalization');
}
if (localStorage.getItem('recordCode')) {
localStorage.removeItem('recordCode');
}
},
changeShow() {
this.isShow = !this.isShow;
console.log(this.isShow);
},
},
};
@ -129,7 +153,27 @@ export default {
<style lang="stylus" scoped>
.choose-btn {
position: fixed;
top: 12px;
top: 74px;
right: 12px;
}
.fixed-pane {
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
background-color: #eee;
z-index: 100;
max-height: 100%;
overflow-y: auto;
scroll-y: auto;
}
.full-screen {
position: fixed;
z-index: 101;
right: 18px;
top: 4px;
}
</style>

Loading…
Cancel
Save