Browse Source

手机端适配修改

master
aBin 4 years ago
parent
commit
8351a0a8dd
  1. 2
      src/App.vue
  2. 54
      src/components/BiologicalSampleSearch/Search.vue
  3. 59
      src/components/Echarts/Categorymap.vue
  4. 53
      src/components/Echarts/CategorymapHos.vue
  5. 6
      src/components/Echarts/Cisualmap.vue
  6. 2
      src/components/Echarts/PatientProgress.vue
  7. 4
      src/components/Echarts/Piemap.vue
  8. 2
      src/components/Echarts/Treemap.vue
  9. 6
      src/components/PatientInfo/PatientAdd.vue
  10. 6
      src/components/PatientInfo/PatientTable.vue
  11. 2
      src/components/PatientInfo/Search.vue
  12. 8
      src/components/TypeTable/TypeTable.vue
  13. 6
      src/store/modules/home/state.js
  14. 4
      src/views/BiologicalSampleSearch/BiologicalSampleSearch.vue
  15. 4
      src/views/BiologicalSamples/BiologicalSamples.vue
  16. 22
      src/views/CaseAnalysis/CaseAnalysis.vue
  17. 456
      src/views/CaseSearch/CaseSearch.vue
  18. 6
      src/views/Index/Index.vue
  19. 136
      src/views/PatientInfo/PatientInfo.vue
  20. 8
      src/views/ProjectAssistant/General.vue
  21. 6
      src/views/ProjectAssistant/Statistics.vue
  22. 6
      src/views/SelectPatient/SelectPatient.vue

2
src/App.vue

@ -3,7 +3,7 @@
* @email: 18603454788@163.com
* @Date: 2021-04-19 10:23:19
* @LastEditors: aBin
* @LastEditTime: 2021-05-28 16:42:55
* @LastEditTime: 2021-05-31 15:55:52
-->
<template>
<a-config-provider :locale="zh_CN">

54
src/components/BiologicalSampleSearch/Search.vue

@ -3,39 +3,43 @@
* @email: 18603454788@163.com
* @Date: 2021-02-22 09:20:03
* @LastEditors: aBin
* @LastEditTime: 2021-05-28 09:18:00
* @LastEditTime: 2021-05-31 16:01:39
-->
<template>
<!-- search -->
<div>
<div class="d-flex flex-row flex-nowrap">
<a-form :form="form" @submit="handleSubmit" class="d-flex flex-wrap align-center" layout="inline">
<a-form-item>
<a-select placeholder="请选择医院" style="min-width: 200px" v-decorator="['hospital']" allow-clear>
<a-select-option :key="item.id" :value="item.id" v-for="item in hospitals">{{ item.name }}</a-select-option>
</a-select>
</a-form-item>
<a-form-item>
<a-input placeholder="住院号" style="width: 200px" v-decorator="['inpatientNumber']" />
</a-form-item>
<a-form-item>
<a-input placeholder="研究编号" style="width: 200px" v-decorator="['code']" />
</a-form-item>
<a-form-item>
<a-select placeholder="请选择采集时间" style="min-width: 200px" v-decorator="['acquisitionTime']" allow-clear>
<a-select-option :key="t.id" :value="t.id" v-for="t in acquisitionTime">{{ t.title }}</a-select-option>
</a-select>
</a-form-item>
<a-form-item>
<!-- <a-select placeholder="请选择样本类型" style="min-width: 150px" v-decorator="['sampleType']" allow-clear>
<div class="fill-width d-flex">
<a-form-item>
<a-select placeholder="请选择医院" style="min-width: 200px" v-decorator="['hospital']" allow-clear>
<a-select-option :key="item.id" :value="item.id" v-for="item in hospitals">{{ item.name }}</a-select-option>
</a-select>
</a-form-item>
<a-form-item>
<a-input placeholder="住院号" style="width: 200px" v-decorator="['inpatientNumber']" />
</a-form-item>
<a-form-item>
<a-input placeholder="研究编号" style="width: 200px" v-decorator="['code']" />
</a-form-item>
</div>
<div class="fill-width d-flex">
<a-form-item>
<a-select placeholder="请选择采集时间" style="min-width: 200px" v-decorator="['acquisitionTime']" allow-clear>
<a-select-option :key="t.id" :value="t.id" v-for="t in acquisitionTime">{{ t.title }}</a-select-option>
</a-select>
</a-form-item>
<a-form-item>
<!-- <a-select placeholder="请选择样本类型" style="min-width: 150px" v-decorator="['sampleType']" allow-clear>
<a-select-option :key="item.id" :value="item.id" v-for="item in types">{{ item.title }}</a-select-option>
</a-select> -->
<span> 样本类型: </span>
<a-checkbox-group @change="changeType">
<a-checkbox v-for="item in types" :key="item.id" :value="item.id">{{ item.title }}</a-checkbox>
</a-checkbox-group>
</a-form-item>
<a-button class="mr-4" html-type="submit" icon="search" type="primary">搜索</a-button>
<span> 样本类型: </span>
<a-checkbox-group @change="changeType">
<a-checkbox v-for="item in types" :key="item.id" :value="item.id">{{ item.title }}</a-checkbox>
</a-checkbox-group>
</a-form-item>
<a-button class="mr-4" html-type="submit" icon="search" type="primary">搜索</a-button>
</div>
</a-form>
<div class="flex-1"></div>
</div>

59
src/components/Echarts/Categorymap.vue

@ -2,8 +2,8 @@
* @Author: wally
* @email: 18603454788@163.com
* @Date: 2021-01-29 14:45:02
* @LastEditors: wally
* @LastEditTime: 2021-05-20 18:48:35
* @LastEditors: aBin
* @LastEditTime: 2021-05-31 15:40:11
-->
<template>
<!-- <div>数据统计组件</div> -->
@ -29,10 +29,12 @@ export default {
cList: [], //
dList: [], //
eList: [], //
widthNum: 0,
};
},
mounted() {
this.init(this.drawLine);
this.widthNum = document.getElementsByClassName('chart-box')[0].offsetWidth;
const that = this;
window.onresize = () => {
return (() => {
@ -58,12 +60,53 @@ export default {
legend: { data: ['新建', '数据收集按时完成', '数据收集中', '废弃', '数据收集超时'] },
xAxis: [
{
axisLabel: {
//
formatter: function(params) {
var newParamsName = ''; //
var paramsNameNumber = params.length; //
var wNum = document.getElementsByClassName('chart-box')[0].offsetWidth;
var provideNumber = wNum > 550 ? 20 : 4; //
var rowNumber = Math.ceil(paramsNameNumber / provideNumber); //
/**
* 判断标签的个数是否大于规定的个数 如果大于则进行换行处理 如果不大于即等于或小于就返回原标签
*/
// rowNumber>1
if (paramsNameNumber > provideNumber) {
/** 循环每一行,p表示行 */
for (var p = 0; p < rowNumber; p++) {
var tempStr = ''; //
var start = p * provideNumber; //
var end = start + provideNumber; //
//
if (p === rowNumber - 1) {
//
tempStr = params.substring(start, paramsNameNumber);
} else {
//
tempStr = params.substring(start, end) + '\n';
}
newParamsName += tempStr; //
}
} else {
//
newParamsName = params;
}
return newParamsName;
},
},
type: 'category',
axisTick: { show: false },
data: this.xDataList,
},
],
yAxis: [{ type: 'value' }],
grid: {
x: this.widthNum > 550 ? 60 : 40,
y: 60,
x2: this.widthNum > 550 ? 40 : 20,
y2: this.widthNum > 550 ? 60 : 90,
},
series: [
{
name: '新建',
@ -72,7 +115,7 @@ export default {
// label: labelOption,
emphasis: { focus: 'series' },
data: this.aList,
barWidth: 20,
barWidth: this.widthNum > 550 ? 20 : 10,
itemStyle: {
normal: {
label: {
@ -103,7 +146,7 @@ export default {
// label: labelOption,
emphasis: { focus: 'series' },
data: this.bList,
barWidth: 20,
barWidth: this.widthNum > 550 ? 20 : 10,
itemStyle: {
normal: {
label: {
@ -134,7 +177,7 @@ export default {
// label: labelOption,
emphasis: { focus: 'series' },
data: this.cList,
barWidth: 20,
barWidth: this.widthNum > 550 ? 20 : 10,
itemStyle: {
normal: {
label: {
@ -165,7 +208,7 @@ export default {
// label: labelOption,
emphasis: { focus: 'series' },
data: this.dList,
barWidth: 20,
barWidth: this.widthNum > 550 ? 20 : 10,
itemStyle: {
normal: {
label: {
@ -196,7 +239,7 @@ export default {
// label: labelOption,
emphasis: { focus: 'series' },
data: this.eList,
barWidth: 20,
barWidth: this.widthNum > 550 ? 20 : 10,
itemStyle: {
normal: {
label: {
@ -253,4 +296,4 @@ export default {
};
</script>
<style lang="stylus" scoped ></style>
<style lang="stylus" scoped></style>

53
src/components/Echarts/CategorymapHos.vue

@ -22,11 +22,13 @@ export default {
cList: [], //
dList: [], //
eList: [], //
widthNum: 0,
};
},
computed: mapState('home', ['hospitalId']),
mounted() {
this.init(this.drawLine);
this.widthNum = document.getElementsByClassName('chart-box')[0].offsetWidth;
const that = this;
window.onresize = () => {
return (() => {
@ -45,12 +47,53 @@ export default {
legend: { data: ['新建', '数据收集按时完成', '数据收集中', '废弃', '数据收集超时'] },
xAxis: [
{
axisLabel: {
//
formatter: function(params) {
var newParamsName = ''; //
var paramsNameNumber = params.length; //
var wNum = document.getElementsByClassName('chart-box')[0].offsetWidth;
var provideNumber = wNum > 550 ? 20 : 4; //
var rowNumber = Math.ceil(paramsNameNumber / provideNumber); //
/**
* 判断标签的个数是否大于规定的个数 如果大于则进行换行处理 如果不大于即等于或小于就返回原标签
*/
// rowNumber>1
if (paramsNameNumber > provideNumber) {
/** 循环每一行,p表示行 */
for (var p = 0; p < rowNumber; p++) {
var tempStr = ''; //
var start = p * provideNumber; //
var end = start + provideNumber; //
//
if (p === rowNumber - 1) {
//
tempStr = params.substring(start, paramsNameNumber);
} else {
//
tempStr = params.substring(start, end) + '\n';
}
newParamsName += tempStr; //
}
} else {
//
newParamsName = params;
}
return newParamsName;
},
},
type: 'category',
axisTick: { show: false },
data: this.xDataList,
},
],
yAxis: [{ type: 'value' }],
grid: {
x: this.widthNum > 550 ? 60 : 40,
y: 60,
x2: this.widthNum > 550 ? 40 : 20,
y2: this.widthNum > 550 ? 60 : 90,
},
series: [
{
name: '新建',
@ -59,7 +102,7 @@ export default {
// label: labelOption,
emphasis: { focus: 'series' },
data: this.aList,
barWidth: 20,
barWidth: this.widthNum > 550 ? 20 : 10,
itemStyle: {
normal: {
label: {
@ -90,7 +133,7 @@ export default {
// label: labelOption,
emphasis: { focus: 'series' },
data: this.bList,
barWidth: 20,
barWidth: this.widthNum > 550 ? 20 : 10,
itemStyle: {
normal: {
label: {
@ -121,7 +164,7 @@ export default {
// label: labelOption,
emphasis: { focus: 'series' },
data: this.cList,
barWidth: 20,
barWidth: this.widthNum > 550 ? 20 : 10,
itemStyle: {
normal: {
label: {
@ -152,7 +195,7 @@ export default {
// label: labelOption,
emphasis: { focus: 'series' },
data: this.dList,
barWidth: 20,
barWidth: this.widthNum > 550 ? 20 : 10,
itemStyle: {
normal: {
label: {
@ -183,7 +226,7 @@ export default {
// label: labelOption,
emphasis: { focus: 'series' },
data: this.eList,
barWidth: 20,
barWidth: this.widthNum > 550 ? 20 : 10,
itemStyle: {
normal: {
label: {

6
src/components/Echarts/Cisualmap.vue

@ -26,12 +26,12 @@ export default {
};
},
computed: {
...mapState('home', ['ptProps', 'hospitalId']),
...mapState('home', ['ptProps', 'hospitalId', 'user']),
option1() {
return {
title: {
left: 'center',
text: '新建病例',
text: '进行中病例',
},
tooltip: {
trigger: 'item',
@ -137,7 +137,7 @@ export default {
const params = {
param: {
hospitalId: this.hospitalId ? this.hospitalId : '',
userId: this.ptProps && this.ptProps.userId ? this.ptProps.userId : '',
userId: this.user && this.user.id ? this.user.id : '',
},
};
const res = await countCase(params);

2
src/components/Echarts/PatientProgress.vue

@ -32,7 +32,7 @@ export default {
},
watch: {
lists() {
console.log(this.lists);
// console.log(this.lists);
this.nameList = [];
this.dataList = [];
this.series = [];

4
src/components/Echarts/Piemap.vue

@ -2,8 +2,8 @@
* @Author: wally
* @email: 18603454788@163.com
* @Date: 2021-04-19 10:23:19
* @LastEditors: wally
* @LastEditTime: 2021-05-12 11:49:10
* @LastEditors: aBin
* @LastEditTime: 2021-05-31 15:09:50
-->
<template>
<!-- <div>数据统计组件</div> -->

2
src/components/Echarts/Treemap.vue

@ -84,7 +84,7 @@ export default {
const params = {
param: {
hospitalId: this.hospitalId ? this.hospitalId : '',
userId: this.ptProps && this.ptProps.userId ? this.ptProps.userId : '',
userId: this.user && this.user.id ? this.user.id : '',
},
};
const res = await complete(params);

6
src/components/PatientInfo/PatientAdd.vue

@ -2,8 +2,8 @@
* @Author: wally
* @email: 18603454788@163.com
* @Date: 2021-02-22 09:20:03
* @LastEditors: wally
* @LastEditTime: 2021-05-06 16:47:25
* @LastEditors: aBin
* @LastEditTime: 2021-05-31 09:46:52
-->
<template>
<div class="d-flex flex-wrap pb-3">
@ -96,7 +96,7 @@ export default {
throw msg;
}
} catch (error) {
console.log('error: ', error);
// console.log('error: ', error);
this.$message.error(error || '添加失败');
}
}

6
src/components/PatientInfo/PatientTable.vue

@ -295,9 +295,9 @@ export default {
};
const res = await checkPatientComplete(params);
const { code, msg, data } = res.data;
console.log(data);
// console.log(data);
if (code === 200) {
console.log(data);
// console.log(data);
localStorage.setItem('reportId', data.id);
}
if (localStorage.getItem('patientId') && localStorage.getItem('hospitalization')) {
@ -305,7 +305,7 @@ export default {
this.setShowTable(1);
}
} catch (error) {
console.log(error);
// console.log(error);
}
},
//

2
src/components/PatientInfo/Search.vue

@ -62,7 +62,7 @@ export default {
e.preventDefault();
this.form.validateFields(async (err, values) => {
if (!err) {
console.log('values: ', values);
// console.log('values: ', values);
this.$emit('searchPatientMes', values);
}
});

8
src/components/TypeTable/TypeTable.vue

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

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

@ -2,8 +2,8 @@
* @Author: wally
* @email: 18603454788@163.com
* @Date: 2021-04-19 10:23:19
* @LastEditors: wally
* @LastEditTime: 2021-05-26 10:07:28
* @LastEditors: aBin
* @LastEditTime: 2021-05-31 15:43:25
*/
const state = {
anyringToken: '',
@ -13,7 +13,7 @@ const state = {
hospitalization: '', // 病患住院号
recordCode: '', // 病例研究编号
previewInfo: { host: '', place: '', startTime: '', endTime: '', participants: '', meetingMinutes: '', discussionContent: '' }, // 预览信息
ptProps: { userId: '1' }, // 接受PT传过来的 pluginId,projectId,roleId,taskId,userId
ptProps: { userId: '' }, // 接受PT传过来的 pluginId,projectId,roleId,taskId,userId
hospitalId: '', // 医院Id
caseData: null, // 病例 搜索/分析 下的认知量表所做的每道题,每次改变重新存一次
showTable: 0,

4
src/views/BiologicalSampleSearch/BiologicalSampleSearch.vue

@ -2,8 +2,8 @@
* @Author: wally
* @email: 18603454788@163.com
* @Date: 2021-02-19 16:04:48
* @LastEditors: wally
* @LastEditTime: 2021-05-20 10:33:12
* @LastEditors: aBin
* @LastEditTime: 2021-05-31 16:02:07
-->
<template>
<div class="d-flex flex-column">

4
src/views/BiologicalSamples/BiologicalSamples.vue

@ -109,7 +109,7 @@ export default {
},
methods: {
chanegType(e) {
console.log(e);
// console.log(e);
this.sampleType = e;
},
//
@ -117,7 +117,7 @@ export default {
e.preventDefault();
this.form.validateFieldsAndScroll(async (err, values) => {
if (!err) {
console.log(values);
// console.log(values);
if (this.sampleType && this.sampleType.length === 0) {
this.$message.error('请填写完整信息');
return;

22
src/views/CaseAnalysis/CaseAnalysis.vue

@ -1795,7 +1795,7 @@ export default {
};
contentList.push(obj);
this.contentList = [...contentList];
console.log(this.contentList);
// console.log(this.contentList);
},
//
ergodicList(id) {
@ -1823,13 +1823,13 @@ export default {
};
this.contentList.push(obj);
}
console.log(this.contentList);
// console.log(this.contentList);
},
//
inputChange1(id, e, value, recordId, list, str) {
let listArr = this.getList(list);
console.log(listArr);
console.log(id);
// console.log(listArr);
// console.log(id);
let numkg = 0;
for (let i = 0; i < this.contentList.length; i++) {
if (this.contentList[i].testQuestionsId === id) {
@ -1864,7 +1864,7 @@ export default {
};
this.contentList.push(obj);
}
console.log(this.contentList);
// console.log(this.contentList);
},
//
explainChange(id, e, recordId) {
@ -1885,7 +1885,7 @@ export default {
},
//
fileChange(info, id, recordId) {
console.log(info);
// console.log(info);
this.spinning = true;
if (info.file.status === 'done') {
this.fileList = info.fileList;
@ -1903,8 +1903,8 @@ export default {
this.contentList.push(obj);
}
this.spinning = false;
console.log(this.contentList);
console.log(this.fileList);
// console.log(this.contentList);
// console.log(this.fileList);
} else if (info.file.status === 'removed') {
this.fileList = info.fileList;
for (let i = 0; i < this.contentList.length; i++) {
@ -1941,7 +1941,7 @@ export default {
* 选择组别
*/
changeList(value) {
console.log(`Selected: ${value}`);
// console.log(`Selected: ${value}`);
this.inpatientList = [];
for (let i = 0; i < value.length; i++) {
this.inpatientList.push(parseInt(value[i]));
@ -1998,7 +1998,7 @@ export default {
this.list = [...list];
this.spinning = false;
} else {
console.log(msg);
// console.log(msg);
this.spinning = false;
}
}
@ -2137,7 +2137,7 @@ export default {
this.caseList = data;
}
} catch (error) {
console.log(error);
// console.log(error);
}
},
},

456
src/views/CaseSearch/CaseSearch.vue

@ -148,8 +148,8 @@
>
<a-form-item
:label="h.question"
:label-col="formItemLayout.labelCol"
:wrapper-col="formItemLayout.wrapperCol"
:label-col="widthNum > 575 ? formItemLayout.labelCol : {}"
:wrapper-col="widthNum > 575 ? formItemLayout.wrapperCol : {}"
class="d-flex align-center mb-3"
>
<a-input
@ -340,7 +340,7 @@
placeholder="日期时间选择"
:input-read-only="true"
@change="onChange($event, h.type, h.id, h.recordId)"
show-time
:show-time="{ format: 'HH:mm' }"
/>
</div>
<div v-for="(dom, domIndex) in h.domList" :key="domIndex">
@ -404,222 +404,208 @@
></a-textarea>
<div v-else-if="j.afterOperation === 3" :key="i" v-for="(h, i) in j.questionVos" style="position: relative">
<a-form-item
:label-col="formItemLayout1.labelCol"
:wrapper-col="formItemLayout1.wrapperCol"
:label="h.question"
:label-col="widthNum > 575 ? formItemLayout.labelCol : {}"
:wrapper-col="widthNum > 575 ? formItemLayout.wrapperCol : {}"
class="d-flex align-center mb-3"
>
<a-form-item
:label="h.question"
:label-col="formItemLayout.labelCol"
:wrapper-col="formItemLayout.wrapperCol"
class="d-flex align-center mb-3"
<a-input
:max-length="500"
@change="onChange($event, h.type, h.id, h.recordId)"
style="width: 100%"
v-if="h.type === 1"
v-model="h.answer"
/>
<a-textarea
@change="onChange($event, h.type, h.id)"
style="height: 150px; width: 100%"
v-else-if="h.type === 2"
v-model="h.answer"
/>
<a-select
@change="onChange($event, h.type, h.id, h.recordId)"
style="width: 120px"
v-else-if="h.type === 5"
v-model="h.answer"
>
<a-input
:max-length="500"
@change="onChange($event, h.type, h.id, h.recordId)"
style="width: 100%"
v-if="h.type === 1"
v-model="h.answer"
/>
<a-textarea
@change="onChange($event, h.type, h.id)"
style="height: 150px; width: 100%"
v-else-if="h.type === 2"
v-model="h.answer"
/>
<a-select-option :key="c" :value="b.showValue" v-for="(b, c) in h.optionVos">{{ b.showValue }}</a-select-option>
</a-select>
<a-date-picker
:default-value="h.answer ? $moment(h.answer, dateFormat) : ''"
@change="onChange($event, h.type, h.id, h.recordId)"
placeholder="日期选择"
:input-read-only="true"
show-time
style="width: 100%"
v-else-if="h.type === 6"
/>
<a-upload
:action="action"
:default-file-list="fileList"
:headers="headers"
@change="fileChange($event, h.id)"
list-type="picture"
:before-upload="beforeUpload1"
name="files"
v-else-if="h.type === 7"
>
<a-button
v-show="
!contentList.find(item => {
return item.testQuestionsId === h.id;
})
"
>
<a-icon type="upload" />点击上传
</a-button>
</a-upload>
<div v-else-if="h.type === 10">
<a-select
:default-value="getAnswer(h.answer)"
@change="onChange($event, h.type, h.id, h.recordId)"
style="width: 120px"
v-else-if="h.type === 5"
v-model="h.answer"
style="width: 100%"
>
<a-select-option :key="c" :value="b.showValue" v-for="(b, c) in h.optionVos">{{
b.showValue
}}</a-select-option>
</a-select>
<a-date-picker
:default-value="h.answer ? $moment(h.answer, dateFormat) : ''"
@change="onChange($event, h.type, h.id, h.recordId)"
placeholder="日期选择"
:input-read-only="true"
show-time
style="width: 100%"
v-else-if="h.type === 6"
/>
<a-upload
:action="action"
:default-file-list="fileList"
:headers="headers"
@change="fileChange($event, h.id)"
list-type="picture"
:before-upload="beforeUpload1"
name="files"
v-else-if="h.type === 7"
>
<a-button
v-show="
!contentList.find(item => {
return item.testQuestionsId === h.id;
})
<div :key="c" v-for="(b, c) in h.optionVos">
<div
v-if="
(contentList.find(item => {
return item.testQuestionsId === h.id && item.contents === `${b.showValue}`;
}) &&
b.afterOperation === 1) ||
(b.afterOperation === 1 &&
!contentList.find(item => {
return item.testQuestionsId === h.id;
}))
"
>
<a-icon type="upload" />点击上传
</a-button>
</a-upload>
<div v-else-if="h.type === 10">
<a-select
:default-value="getAnswer(h.answer)"
@change="onChange($event, h.type, h.id, h.recordId)"
style="width: 100%"
>
<a-select-option :key="c" :value="b.showValue" v-for="(b, c) in h.optionVos">{{
b.showValue
}}</a-select-option>
</a-select>
<div :key="c" v-for="(b, c) in h.optionVos">
<div
v-if="
(contentList.find(item => {
return item.testQuestionsId === h.id && item.contents === `${b.showValue}`;
}) &&
b.afterOperation === 1) ||
(b.afterOperation === 1 &&
!contentList.find(item => {
return item.testQuestionsId === h.id;
}))
"
>
<a-form-item class="d-flex align-center mb-3">
<a-input
:max-length="500"
@change="inputChange(h.id, $event, b.showValue)"
style="width: 100%"
v-model="b.otherInformation"
></a-input>
</a-form-item>
</div>
</div>
</div>
<div v-else-if="h.type === 4">
<a-checkbox-group
:default-value="getList(h.optionVos)"
@change="onChange($event, h.type, h.id, h.recordId)"
class="d-flex flex-row flex-wrap"
style="width: 100%"
>
<a-row class="flex-1 flex-wrap">
<div style="width: 100%" :key="indexNum" :span="24" v-for="(ques, indexNum) in h.optionVos">
<a-col>
<a-checkbox :value="ques.submitValue">{{ ques.showValue }}</a-checkbox>
</a-col>
<a-col>
<div
v-if="
(contentList.find(item => {
return item.testQuestionsId === h.id && item.contents === `${ques.showValue}`;
}) &&
ques.afterOperation > 0) ||
(ques.afterOperation > 0 && ques.choose === 1)
"
>
<!-- <div v-if="ques.afterOperation > 0"> -->
<a-input
:max-length="500"
@change="inputChange1(h.id, $event, ques.showValue, h.recordId, h.optionVos, ques.id)"
style="width: 100%"
v-model="ques.otherInformation"
v-if="ques.afterOperation === 1"
/>
<a-textarea
@change="inputChange1(h.id, $event, ques.showValue, h.recordId, h.optionVos, ques.id)"
style="width: 100%; height: 150px"
:max-length="500"
v-else-if="ques.afterOperation === 2"
/>
<div v-else-if="ques.afterOperation === 3">当前程序已无法嵌套</div>
</div>
</a-col>
</div>
</a-row>
</a-checkbox-group>
</div>
<!-- 当类型为12时为单选+关联 -->
<div v-else-if="h.type === 3">
<a-radio-group
@change="onChange($event, h.type, h.id, h.recordId)"
class="d-flex flex-row flex-wrap"
v-model="h.answer"
>
<a-radio :key="g" :style="radioStyle" :value="f.showValue" v-for="(f, g) in h.optionVos">{{
f.showValue
}}</a-radio>
</a-radio-group>
<div :key="n" v-for="(m, n) in h.optionVos">
<div
v-if="
contentList.find(item => {
return item.testQuestionsId === h.id && item.contents === `${m.showValue}`;
}) && m.afterOperation > 0
"
>
<a-form-item class="d-flex align-center mb-3">
<a-input
:max-length="500"
@change="inputChange(h.id, $event, m.showValue)"
style="width: 200px"
v-if="m.afterOperation === 1"
@change="inputChange(h.id, $event, b.showValue)"
style="width: 100%"
v-model="b.otherInformation"
></a-input>
<a-textarea
:max-length="500"
style="width: 100%; height: 150px"
@change="inputChange(h.id, $event, m.showValue)"
v-else-if="m.afterOperation === 2"
></a-textarea>
<div v-else-if="m.afterOperation === 3" :key="q" v-for="(p, q) in m.questionVos">
<a-form-item
:label="p.question"
:label-col="formItemLayout.labelCol"
:wrapper-col="formItemLayout.wrapperCol"
class="d-flex align-center mb-3"
</a-form-item>
</div>
</div>
</div>
<div v-else-if="h.type === 4">
<a-checkbox-group
:default-value="getList(h.optionVos)"
@change="onChange($event, h.type, h.id, h.recordId)"
class="d-flex flex-row flex-wrap"
style="width: 100%"
>
<a-row class="flex-1 flex-wrap">
<div style="width: 100%" :key="indexNum" :span="24" v-for="(ques, indexNum) in h.optionVos">
<a-col>
<a-checkbox :value="ques.submitValue">{{ ques.showValue }}</a-checkbox>
</a-col>
<a-col>
<div
v-if="
(contentList.find(item => {
return item.testQuestionsId === h.id && item.contents === `${ques.showValue}`;
}) &&
ques.afterOperation > 0) ||
(ques.afterOperation > 0 && ques.choose === 1)
"
>
<div>当前程序已无法嵌套</div>
</a-form-item>
</div>
<!-- <div v-if="ques.afterOperation > 0"> -->
<a-input
:max-length="500"
@change="inputChange1(h.id, $event, ques.showValue, h.recordId, h.optionVos, ques.id)"
style="width: 100%"
v-model="ques.otherInformation"
v-if="ques.afterOperation === 1"
/>
<a-textarea
@change="inputChange1(h.id, $event, ques.showValue, h.recordId, h.optionVos, ques.id)"
style="width: 100%; height: 150px"
:max-length="500"
v-else-if="ques.afterOperation === 2"
/>
<div v-else-if="ques.afterOperation === 3">当前程序已无法嵌套</div>
</div>
</a-col>
</div>
</a-row>
</a-checkbox-group>
</div>
<!-- 当类型为12时为单选+关联 -->
<div v-else-if="h.type === 3">
<a-radio-group
@change="onChange($event, h.type, h.id, h.recordId)"
class="d-flex flex-row flex-wrap"
v-model="h.answer"
>
<a-radio :key="g" :style="radioStyle" :value="f.showValue" v-for="(f, g) in h.optionVos">{{
f.showValue
}}</a-radio>
</a-radio-group>
<div :key="n" v-for="(m, n) in h.optionVos">
<div
v-if="
contentList.find(item => {
return item.testQuestionsId === h.id && item.contents === `${m.showValue}`;
}) && m.afterOperation > 0
"
>
<a-input
:max-length="500"
@change="inputChange(h.id, $event, m.showValue)"
style="width: 200px"
v-if="m.afterOperation === 1"
></a-input>
<a-textarea
:max-length="500"
style="width: 100%; height: 150px"
@change="inputChange(h.id, $event, m.showValue)"
v-else-if="m.afterOperation === 2"
></a-textarea>
<div v-else-if="m.afterOperation === 3" :key="q" v-for="(p, q) in m.questionVos">
<a-form-item
:label="p.question"
:label-col="formItemLayout.labelCol"
:wrapper-col="formItemLayout.wrapperCol"
class="d-flex align-center mb-3"
>
<div>当前程序已无法嵌套</div>
</a-form-item>
</div>
</div>
</div>
<div v-else-if="h.type === 13">
<a-input-number
@change="onChange($event, h.type, h.id, h.recordId)"
style="width: 200px%"
v-model="h.answer"
/>
</div>
<div v-else-if="h.type === 15">
<a-time-picker placeholder="时间选择" @change="onChange($event, h.type, h.id, h.recordId)" />
</div>
<div v-else-if="h.type === 16">
<a-date-picker
placeholder="日期时间选择"
:input-read-only="true"
@change="onChange($event, h.type, h.id, h.recordId)"
show-time
/>
</div>
<div v-for="(dom, domIndex) in h.domList" :key="domIndex">
<a-input v-if="h.type === 1" v-model="h.domList[domIndex]"></a-input>
<a-textarea v-else-if="h.type === 2" v-model="h.domList[domIndex]"></a-textarea>
</div>
<div v-if="h.remark && JSON.parse(h.remark).type === 'desc'">
说明
<a-textarea @change="explainChange(h.id, $event)" v-model="h.explains" />
</div>
<p class="units-position" style="margin-left: 10px">
<span v-if="h.units">{{ h.units }}</span>
<span v-if="typeof h.referenceLower === 'number'">
({{ h.referenceLower + '-' }}{{ h.referenceUpper }})
</span>
</p>
</a-form-item>
</div>
<div v-else-if="h.type === 13">
<a-input-number @change="onChange($event, h.type, h.id, h.recordId)" style="width: 200px%" v-model="h.answer" />
</div>
<div v-else-if="h.type === 15">
<a-time-picker placeholder="时间选择" @change="onChange($event, h.type, h.id, h.recordId)" />
</div>
<div v-else-if="h.type === 16">
<a-date-picker
placeholder="日期时间选择"
:input-read-only="true"
@change="onChange($event, h.type, h.id, h.recordId)"
:show-time="{ format: 'HH:mm' }"
/>
</div>
<div v-for="(dom, domIndex) in h.domList" :key="domIndex">
<a-input v-if="h.type === 1" v-model="h.domList[domIndex]"></a-input>
<a-textarea v-else-if="h.type === 2" v-model="h.domList[domIndex]"></a-textarea>
</div>
<div v-if="h.remark && JSON.parse(h.remark).type === 'desc'">
说明
<a-textarea @change="explainChange(h.id, $event)" v-model="h.explains" />
</div>
<p class="units-position" style="margin-left: 10px">
<span v-if="h.units">{{ h.units }}</span>
<span v-if="typeof h.referenceLower === 'number'"> ({{ h.referenceLower + '-' }}{{ h.referenceUpper }}) </span>
</p>
</a-form-item>
<a-button
v-if="h.remark && JSON.parse(h.remark).type === 'add'"
@ -643,7 +629,7 @@
placeholder="日期时间选择"
:input-read-only="true"
@change="onChange($event, a.type, a.id, a.recordId)"
show-time
:show-time="{ format: 'HH:mm' }"
/>
</div>
<div v-for="(dom, domIndex) in a.domList" :key="domIndex">
@ -816,8 +802,8 @@
>
<a-form-item
:label="h.question"
:label-col="formItemLayout.labelCol"
:wrapper-col="formItemLayout.wrapperCol"
:label-col="widthNum > 575 ? formItemLayout.labelCol : {}"
:wrapper-col="widthNum > 575 ? formItemLayout.wrapperCol : {}"
class="d-flex align-center mb-3"
>
<a-input
@ -1008,7 +994,7 @@
placeholder="日期时间选择"
@change="onChange($event, h.type, h.id, h.recordId)"
:input-read-only="true"
show-time
:show-time="{ format: 'HH:mm' }"
/>
</div>
<div v-for="(dom, domIndex) in h.domList" :key="domIndex">
@ -1078,8 +1064,8 @@
<div v-else-if="j.afterOperation === 3" :key="i" v-for="(h, i) in j.questionVos" style="position: relative">
<a-form-item
:label="h.question"
:label-col="formItemLayout.labelCol"
:wrapper-col="formItemLayout.wrapperCol"
:label-col="widthNum > 575 ? formItemLayout.labelCol : {}"
:wrapper-col="widthNum > 575 ? formItemLayout.wrapperCol : {}"
class="d-flex align-center mb-3"
>
<a-input
@ -1270,7 +1256,7 @@
placeholder="日期时间选择"
:input-read-only="true"
@change="onChange($event, h.type, h.id, h.recordId)"
show-time
:show-time="{ format: 'HH:mm' }"
/>
</div>
<div v-for="(dom, domIndex) in h.domList" :key="domIndex">
@ -1364,11 +1350,11 @@ import TypeTable from 'components/TypeTable/TypeTable.vue';
const formItemLayout = {
labelCol: { span: 6 },
wrapperCol: { span: 9 },
wrapperCol: { span: 12 },
};
const formItemLayout1 = {
labelCol: { span: 0 },
wrapperCol: { span: 24 },
wrapperCol: { span: 18 },
};
const tailItemLayout = { wrapperCol: { span: 18, offset: 4 } };
export default {
@ -1438,6 +1424,7 @@ export default {
caseList: [],
caseAnswer: [], //
spinning: false,
widthNum: 0,
};
},
computed: {
@ -1499,6 +1486,11 @@ export default {
}
},
},
mounted() {
this.widthNum = document.getElementsByClassName('main')[0].offsetWidth;
},
created() {
this.getControlGroups();
this.handleSearchCriteriaList();
@ -1773,7 +1765,7 @@ export default {
};
contentList.push(obj);
this.contentList = [...contentList];
console.log(this.contentList);
// console.log(this.contentList);
},
//
ergodicList(id) {
@ -1801,13 +1793,13 @@ export default {
};
this.contentList.push(obj);
}
console.log(this.contentList);
// console.log(this.contentList);
},
//
inputChange1(id, e, value, recordId, list, str) {
let listArr = this.getList(list);
console.log(listArr);
console.log(id);
// console.log(listArr);
// console.log(id);
let numkg = 0;
for (let i = 0; i < this.contentList.length; i++) {
if (this.contentList[i].testQuestionsId === id) {
@ -1842,7 +1834,7 @@ export default {
};
this.contentList.push(obj);
}
console.log(this.contentList);
// console.log(this.contentList);
},
//
explainChange(id, e, recordId) {
@ -1864,7 +1856,7 @@ export default {
//
fileChange(info, id, recordId) {
this.spinning = true;
console.log(info);
// console.log(info);
if (info.file.status === 'done') {
this.fileList = info.fileList;
for (let i = 0; i < this.contentList.length; i++) {
@ -1881,8 +1873,8 @@ export default {
this.contentList.push(obj);
}
this.spinning = false;
console.log(this.contentList);
console.log(this.fileList);
// console.log(this.contentList);
// console.log(this.fileList);
} else if (info.file.status === 'removed') {
this.fileList = info.fileList;
for (let i = 0; i < this.contentList.length; i++) {
@ -1944,7 +1936,7 @@ export default {
this.list = [...list];
this.spinning = false;
} else {
console.log(msg);
// console.log(msg);
this.spinning = false;
}
}
@ -2067,7 +2059,7 @@ export default {
const { code, msg, data } = res.data;
if (code === 200) {
this.lists = data;
console.log(this.lists);
// console.log(this.lists);
this.spinning = false;
} else {
this.$message.error('搜索失败');
@ -2088,7 +2080,7 @@ export default {
this.caseList = data;
}
} catch (error) {
console.log(error);
// console.log(error);
}
},
},
@ -2114,4 +2106,28 @@ export default {
right: -10px;
transform: translate3d(100%, -100%, 0);
}
@media (max-width: 575px) {
/deep/.ant-form-item-label .ant-form-item-control-wrapper {
display: block;
width: 50%;
}
.add-btn {
position: absolute;
right: 0;
top: -3px;
}
/deep/span.ant-radio + * {
padding-right: 12px;
padding-left: 4px;
}
.choose-btn {
position: fixed;
top: 58px;
right: 6px;
}
}
</style>

6
src/views/Index/Index.vue

@ -52,4 +52,8 @@ export default {
};
</script>
<style lang="stylus" scoped></style>
<style lang="stylus" scoped>
/deep/ .ant-card-body {
padding: 24px 4px !important;
}
</style>

136
src/views/PatientInfo/PatientInfo.vue

@ -1,5 +1,5 @@
<template>
<div class="flex-column">
<div class="flex-column main">
<div :style="{ width: width }">
<a-tabs @change="callback" tab-position="top">
<a-tab-pane :key="item" :tab="typeof item === 'number' ? item + '天' : item" v-for="item in tabList" width="100" />
@ -28,6 +28,7 @@
<a-date-picker
:default-value="a.answer ? $moment(a.answer, dateFormat) : ''"
@change="onChange($event, a.type, a.id)"
format="YYYY-MM-DD HH:mm"
placeholder="日期选择"
style="width: 100%"
:input-read-only="true"
@ -86,7 +87,7 @@
style="width: 100%"
>
<a-row class="flex-1 flex-wrap">
<div style="width: 60%" :key="indexNum" :span="24" v-for="(ques, indexNum) in a.optionVos">
<div class="fill-width" :key="indexNum" :span="24" v-for="(ques, indexNum) in a.optionVos">
<a-col>
<a-checkbox :value="ques.submitValue">{{ ques.showValue }}</a-checkbox>
</a-col>
@ -97,7 +98,11 @@
return item.testQuestionsId === a.id && item.contents === `${ques.showValue}`;
}) &&
ques.afterOperation > 0) ||
(ques.afterOperation > 0 && ques.choose === 1)
(ques.afterOperation > 0 &&
ques.choose === 1 &&
!contentList.find(item => {
return item.testQuestionsId === a.id;
}))
"
>
<!-- <div v-if="ques.afterOperation > 0"> -->
@ -122,8 +127,8 @@
>
<a-form-item
:label="h.question"
:label-col="formItemLayout.labelCol"
:wrapper-col="formItemLayout.wrapperCol"
:label-col="widthNum > 575 ? formItemLayout.labelCol : {}"
:wrapper-col="widthNum > 575 ? formItemLayout1.wrapperCol : {}"
class="d-flex align-center mb-3"
>
<a-input
@ -150,6 +155,7 @@
</a-select>
<a-date-picker
:default-value="h.answer ? $moment(h.answer, dateFormat) : ''"
format="YYYY-MM-DD HH:mm"
@change="onChange($event, h.type, h.id, h.recordId)"
placeholder="日期选择"
show-time
@ -238,13 +244,13 @@
<!-- <div v-if="quesA.afterOperation > 0"> -->
<a-input
:max-length="500"
@change="inputChange1(h.id, $event, quesA.showValue, h.recordId, h.optionVos, quesA.id)"
@change="inputChange1(h.id, $event, quesA.showValue, h.optionVos, quesA.id)"
style="width: 100%"
v-model="quesA.otherInformation"
v-if="quesA.afterOperation === 1"
/>
<a-textarea
@change="inputChange1(h.id, $event, quesA.showValue, h.recordId, h.optionVos, quesA.id)"
@change="inputChange1(h.id, $event, quesA.showValue, h.optionVos, quesA.id)"
style="width: 100%; height: 150px"
:max-length="500"
v-else-if="quesA.afterOperation === 2"
@ -316,10 +322,11 @@
<div v-else-if="h.type === 16">
<a-date-picker
:default-value="h.answer ? $moment(h.answer, dateFormat) : ''"
format="YYYY-MM-DD HH:mm"
placeholder="日期时间选择"
:input-read-only="true"
@change="onChange($event, h.type, h.id, h.recordId)"
show-time
:show-time="{ format: 'HH:mm' }"
/>
</div>
<div v-for="(dom, domIndex) in h.domList" :key="domIndex">
@ -393,7 +400,12 @@
@change="inputChange(a.id, $event, j.showValue)"
></a-textarea>
<div v-else-if="j.afterOperation === 3" :key="i" v-for="(h, i) in j.questionVos" style="position: relative">
<a-form-item :label="h.question" class="d-flex align-center mb-3">
<a-form-item
:label="h.question"
class="d-flex align-center mb-3"
:label-col="widthNum > 575 ? formItemLayout.labelCol : {}"
:wrapper-col="widthNum > 575 ? formItemLayout1.wrapperCol : {}"
>
<a-input
:max-length="500"
@change="onChange($event, h.type, h.id, h.recordId)"
@ -417,6 +429,7 @@
</a-select>
<a-date-picker
:default-value="h.answer ? $moment(h.answer, dateFormat) : ''"
format="YYYY-MM-DD HH:mm"
@change="onChange($event, h.type, h.id, h.recordId)"
placeholder="日期选择"
:input-read-only="true"
@ -501,13 +514,13 @@
<!-- <div v-if="ques.afterOperation > 0"> -->
<a-input
:max-length="500"
@change="inputChange1(h.id, $event, ques.showValue, h.recordId, h.optionVos, ques.id)"
@change="inputChange1(h.id, $event, ques.showValue, h.optionVos, ques.id)"
style="width: 100%"
v-model="ques.otherInformation"
v-if="ques.afterOperation === 1"
/>
<a-textarea
@change="inputChange1(h.id, $event, ques.showValue, h.recordId, h.optionVos, ques.id)"
@change="inputChange1(h.id, $event, ques.showValue, h.optionVos, ques.id)"
style="width: 100%; height: 150px"
:max-length="500"
v-else-if="ques.afterOperation === 2"
@ -576,10 +589,11 @@
<div v-else-if="h.type === 16">
<a-date-picker
:default-value="h.answer ? $moment(h.answer, dateFormat) : ''"
format="YYYY-MM-DD HH:mm"
placeholder="日期时间选择"
:input-read-only="true"
@change="onChange($event, h.type, h.id, h.recordId)"
show-time
:show-time="{ format: 'HH:mm' }"
/>
</div>
<div v-for="(dom, domIndex) in h.domList" :key="domIndex">
@ -615,10 +629,11 @@
<div v-else-if="a.type === 16">
<a-date-picker
:default-value="a.answer ? $moment(a.answer, dateFormat) : ''"
format="YYYY-MM-DD HH:mm"
placeholder="日期时间选择"
:input-read-only="true"
@change="onChange($event, a.type, a.id)"
show-time
:show-time="{ format: 'HH:mm' }"
/>
</div>
<div v-for="(dom, domIndex) in a.domList" :key="domIndex">
@ -691,6 +706,7 @@
<a-date-picker
:default-value="e.answer ? $moment(e.answer, dateFormat) : ''"
@change="onChange($event, e.type, e.id, e.recordId)"
format="YYYY-MM-DD HH:mm"
placeholder="日期选择"
:input-read-only="true"
show-time
@ -766,18 +782,22 @@
return item.testQuestionsId === e.id && item.contents === `${ques.showValue}`;
}) &&
ques.afterOperation > 0) ||
(ques.afterOperation > 0 && ques.choose === 1)
(ques.afterOperation > 0 &&
ques.choose === 1 &&
!contentList.find(item => {
return item.testQuestionsId === e.id;
}))
"
>
<a-input
:max-length="500"
@change="inputChange1(e.id, $event, ques.showValue, e.recordId, e.optionVos, ques.id)"
@change="inputChange1(e.id, $event, ques.showValue, e.optionVos, ques.id)"
style="width: 100%"
v-model="ques.otherInformation"
v-if="ques.afterOperation === 1"
/>
<a-textarea
@change="inputChange1(e.id, $event, ques.showValue, e.recordId, e.optionVos, ques.id)"
@change="inputChange1(e.id, $event, ques.showValue, e.optionVos, ques.id)"
style="width: 100%; height: 150px"
:max-length="500"
v-else-if="ques.afterOperation === 2"
@ -790,13 +810,13 @@
>
<a-form-item
:label="h.question"
:label-col="formItemLayout.labelCol"
:wrapper-col="formItemLayout.wrapperCol"
:label-col="widthNum > 575 ? formItemLayout.labelCol : {}"
:wrapper-col="widthNum > 575 ? formItemLayout.wrapperCol : {}"
class="d-flex align-center mb-3"
>
<a-input
:max-length="500"
@change="onChange($event, h.type, h.id, h.h.recordId)"
@change="onChange($event, h.type, h.id, h.recordId)"
v-if="h.type === 1"
v-model="h.answer"
/>
@ -819,6 +839,7 @@
<a-date-picker
:default-value="h.answer ? $moment(h.answer, dateFormat) : ''"
@change="onChange($event, h.type, h.id, h.recordId)"
format="YYYY-MM-DD HH:mm"
placeholder="日期选择"
:input-read-only="true"
show-time
@ -911,13 +932,13 @@
<!-- <div v-if="quesA.afterOperation > 0"> -->
<a-input
:max-length="500"
@change="inputChange1(h.id, $event, quesA.showValue, h.recordId, h.optionVos, quesA.id)"
@change="inputChange1(h.id, $event, quesA.showValue, h.optionVos, quesA.id)"
style="width: 100%"
v-model="quesA.otherInformation"
v-if="quesA.afterOperation === 1"
/>
<a-textarea
@change="inputChange1(h.id, $event, quesA.showValue, h.recordId, h.optionVos, quesA.id)"
@change="inputChange1(h.id, $event, quesA.showValue, h.optionVos, quesA.id)"
style="width: 100%; height: 150px"
:max-length="500"
v-else-if="quesA.afterOperation === 2"
@ -989,10 +1010,11 @@
<div v-else-if="h.type === 16">
<a-date-picker
:default-value="h.answer ? $moment(h.answer, dateFormat) : ''"
format="YYYY-MM-DD HH:mm"
placeholder="日期时间选择"
@change="onChange($event, h.type, h.id, h.recordId)"
:input-read-only="true"
show-time
:show-time="{ format: 'HH:mm' }"
/>
</div>
<div v-for="(dom, domIndex) in h.domList" :key="domIndex">
@ -1067,13 +1089,13 @@
<div v-else-if="j.afterOperation === 3" :key="i" v-for="(h, i) in j.questionVos" style="position: relative">
<a-form-item
:label="h.question"
:label-col="formItemLayout.labelCol"
:wrapper-col="formItemLayout.wrapperCol"
:label-col="widthNum > 575 ? formItemLayout.labelCol : {}"
:wrapper-col="widthNum > 575 ? formItemLayout.wrapperCol : {}"
class="d-flex align-center mb-3"
>
<a-input
:max-length="500"
@change="onChange($event, h.type, h.id, h.h.recordId)"
@change="onChange($event, h.type, h.id, h.recordId)"
v-if="h.type === 1"
v-model="h.answer"
/>
@ -1096,6 +1118,7 @@
<a-date-picker
:default-value="h.answer ? $moment(h.answer, dateFormat) : ''"
@change="onChange($event, h.type, h.id, h.recordId)"
format="YYYY-MM-DD HH:mm"
placeholder="日期选择"
:input-read-only="true"
show-time
@ -1183,13 +1206,13 @@
<!-- <div v-if="ques.afterOperation > 0"> -->
<a-input
:max-length="500"
@change="inputChange1(h.id, $event, ques.showValue, h.recordId, h.optionVos, ques.id)"
@change="inputChange1(h.id, $event, ques.showValue, h.optionVos, ques.id)"
style="width: 100%"
v-model="ques.otherInformation"
v-if="ques.afterOperation === 1"
/>
<a-textarea
@change="inputChange1(h.id, $event, ques.showValue, h.recordId, h.optionVos, ques.id)"
@change="inputChange1(h.id, $event, ques.showValue, h.optionVos, ques.id)"
style="width: 100%; height: 150px"
:max-length="500"
v-else-if="ques.afterOperation === 2"
@ -1261,10 +1284,11 @@
<div v-else-if="h.type === 16">
<a-date-picker
:default-value="h.answer ? $moment(h.answer, dateFormat) : ''"
format="YYYY-MM-DD HH:mm"
placeholder="日期时间选择"
:input-read-only="true"
@change="onChange($event, h.type, h.id, h.recordId)"
show-time
:show-time="{ format: 'HH:mm' }"
/>
</div>
<div v-for="(dom, domIndex) in h.domList" :key="domIndex">
@ -1306,10 +1330,11 @@
<div v-else-if="e.type === 16">
<a-date-picker
:default-value="e.answer ? $moment(e.answer, dateFormat) : ''"
format="YYYY-MM-DD HH:mm"
placeholder="日期时间选择"
:input-read-only="true"
@change="onChange($event, e.type, e.id, e.recordId)"
show-time
:show-time="{ format: 'HH:mm' }"
/>
</div>
<div v-for="(dom, domIndex) in e.domList" :key="domIndex">
@ -1401,7 +1426,7 @@ const formItemLayout = {
};
const formItemLayout1 = {
labelCol: { span: 0 },
wrapperCol: { span: 24 },
wrapperCol: { span: 18 },
};
const tailItemLayout = { wrapperCol: { span: 18, offset: 4 } };
export default {
@ -1468,7 +1493,7 @@ export default {
action: upload, //
fileList: [], //
files: '', // Id
dateFormat: 'YYYY-MM-DD HH:mm:ss',
dateFormat: 'YYYY-MM-DD HH:mm',
dateChoose: new Date(),
subDateTime: '',
getCode: '',
@ -1481,6 +1506,7 @@ export default {
lists: {},
height: '',
width: '',
widthNum: 0,
queryPath: '',
coordinate: {
client: {},
@ -1505,15 +1531,15 @@ export default {
}
},
activeKey(val) {
window,scrollTo(0,0)
}
window, scrollTo(0, 0);
},
},
mounted() {
this.height = document.getElementsByClassName('main')[0].offsetHeight + 'px';
this.width = document.getElementsByClassName('main')[0].offsetWidth - 6 + 'px';
console.log(this.width);
this.rzlbSrc = `https://sxzxyzzlm.tall.wiki/ht-common/home/reportHistory?code=LSBGD&userId=${this.ptProps.userId}`;
this.rzlbcpSrc = `https://sxzxyzzlm.tall.wiki/ht-common?code=KT&userId=${this.ptProps.userId}`;
this.widthNum = document.getElementsByClassName('main')[0].offsetWidth;
this.rzlbSrc = `https://sxzxyzzlm.tall.wiki/ht-common/home/reportHistory?code=LSBGD&userId=${this.user.id}`;
this.rzlbcpSrc = `https://sxzxyzzlm.tall.wiki/ht-common?code=KT&userId=${this.user.id}`;
window.addEventListener('scroll', this.handleScroll);
},
@ -1615,7 +1641,7 @@ export default {
status: 'done',
name: `${0}`,
};
console.log([{ ...obj }, ...arr]);
// console.log([{ ...obj }, ...arr]);
return [{ ...obj }, ...arr];
} else {
return [...arr];
@ -1656,7 +1682,7 @@ export default {
}
quesObj.domList.push('');
this.list = [...list];
console.log(this.list);
// console.log(this.list);
},
addDomB(type, index, indexB, id, quesIndex, quesId) {
const { list } = this;
@ -1720,20 +1746,20 @@ export default {
}
}
} else {
console.log(msg);
// console.log(msg);
}
} catch (error) {
console.log(error);
// console.log(error);
}
this.spinning = false;
},
onChange(e, type, id) {
console.log(e);
// console.log(e);
//
if (this.contentList.find(item => item.testQuestionsId === id)) {
if (type === 1) {
//
console.log(e);
// console.log(e);
this.forFn(id, e.target.value);
} else if (type === 2) {
//
@ -1875,13 +1901,13 @@ export default {
this.failFn(id, this.$moment(e._d).format('YYYY-MM-DD HH:mm:ss'));
}
}
console.log(this.contentList);
// console.log(this.contentList);
},
// +
getRadioAnswer(options) {
for (let i = 0; i < options.length; i++) {
if (options[i].choose - 0 === 1) {
console.log(options[i].submitValue);
// console.log(options[i].submitValue);
return options[i].submitValue;
}
}
@ -1919,7 +1945,7 @@ export default {
};
contentList.push(obj);
this.contentList = [...contentList];
console.log(this.contentList);
// console.log(this.contentList);
},
//
ergodicList(id) {
@ -1947,13 +1973,13 @@ export default {
};
this.contentList.push(obj);
}
console.log(this.contentList);
// console.log(this.contentList);
},
//
inputChange1(id, e, value, list, str) {
let listArr = this.getList(list);
console.log(listArr);
console.log(id);
// console.log(listArr);
// console.log(id);
let numkg = 0;
for (let i = 0; i < this.contentList.length; i++) {
if (this.contentList[i].testQuestionsId === id) {
@ -1988,7 +2014,7 @@ export default {
};
this.contentList.push(obj);
}
console.log(this.contentList);
// console.log(this.contentList);
},
//
explainChange(id, e) {
@ -2017,7 +2043,7 @@ export default {
// this.contentList.splice(i, 1);
// }
// }
console.log(info.fileList);
// console.log(info.fileList);
if (info.fileList.length > 0) {
let obj = {
testQuestionsId: id,
@ -2036,14 +2062,14 @@ export default {
}
this.spinning = false;
}
console.log(this.contentList);
// console.log(this.contentList);
},
//
async handleChange(info, title, indexA, indexB) {
this.spinning = true;
if (info.file.status === 'done') {
const { list } = this;
console.log(list, indexA);
// console.log(list, indexA);
const objList = list[indexA].subReportCodes[indexB];
const params = {
param: {
@ -2089,7 +2115,7 @@ export default {
list[indexA].subReportCodes[indexB] = { ...objList };
this.list = [...list];
} else {
console.log(msg);
// console.log(msg);
this.spinning = false;
}
} else if (info.file.status === 'removed') {
@ -2290,7 +2316,7 @@ export default {
const res = await queryByPatient(params);
const { code, msg, data } = res.data;
if (code === 200) {
console.log(data);
// console.log(data);
this.lists = data;
} else {
this.$message.error(msg);
@ -2332,7 +2358,7 @@ export default {
}
@media (max-width: 575px) {
/deep/.ant-form-item-label, .ant-form-item-control-wrapper {
/deep/.ant-form-item-label .ant-form-item-control-wrapper {
display: block;
width: 50%;
}

8
src/views/ProjectAssistant/General.vue

@ -2,7 +2,7 @@
<div class="flex-1 flex-wrap">
<div style="width: 100%">
<a-form :form="form" class="d-flex flex-wrap align-center" layout="inline">
<div class="fill-width">
<div class="fill-width d-flex">
<a-form-item>
<a-select placeholder="请选择医院" style="width: 180px" @change="changeHospitalId" allow-clear>
<a-select-option :key="item.id" :value="item.id" v-for="item in hospitals">{{ item.name }}</a-select-option>
@ -174,7 +174,7 @@ export default {
...mapActions('home', ['getDoctor', 'getControlGroups']),
//
changeHospitalId(e) {
console.log(typeof e);
// console.log(typeof e);
if (typeof e === 'string') {
this.HospitalId = e;
} else {
@ -188,7 +188,7 @@ export default {
const { code, msg, data } = res.data;
if (code === 200) {
this.hospitals = data;
console.log(data);
// console.log(data);
} else {
this.$message.error('查询医院列表失败');
}
@ -220,7 +220,7 @@ export default {
};
const res = await selPatientMes(params);
const { code, msg, data } = res.data;
console.log('获取列表');
// console.log('');
if (code === 200) {
let { lists } = this;
lists = { ...data };

6
src/views/ProjectAssistant/Statistics.vue

@ -83,15 +83,15 @@ export default {
},
};
const res = await getHospitalTask(params);
console.log(res);
// console.log(res);
const { code, msg, data } = res.data;
if (code === 200) {
this.objList = { ...data };
console.log(data);
// console.log(data);
this.loading = false;
}
} catch (error) {
console.log(error);
// console.log(error);
}
},
getTableData(pagination) {

6
src/views/SelectPatient/SelectPatient.vue

@ -76,7 +76,7 @@ export default {
mounted() {
this.height = document.getElementsByClassName('main')[0].offsetHeight + 'px';
this.rzlbSrc = `https://sxzxyzzlm.tall.wiki/ht-common?code=KT&userId=${this.ptProps.userId}`;
this.rzlbSrc = `https://sxzxyzzlm.tall.wiki/ht-common?code=KT&userId=${this.user.id}`;
},
created() {
@ -114,7 +114,7 @@ export default {
};
const res = await selPatientMes(params);
const { code, msg, data } = res.data;
console.log('获取列表');
// console.log('');
if (code === 200) {
this.lists = data;
} else {
@ -148,7 +148,7 @@ export default {
changeShow() {
this.isShow = !this.isShow;
console.log(this.isShow);
// console.log(this.isShow);
},
},
};

Loading…
Cancel
Save