Browse Source

peter

360view
newPeter7 2 years ago
parent
commit
bd9b31d1ce
  1. 211
      src/components/360View/commonForm/optometryForm.vue
  2. 2
      src/components/360View/commonForm/threeVision.vue

211
src/components/360View/commonForm/optometryForm.vue

@ -13,12 +13,11 @@
验光报告单
</p>
<div style="display: flex;justify-content: space-around">
<span>登记号<el-input v-model="dataForm.patientId" style="width: 80px" size="small" clearable placeholder="" /></span>
<span>姓名<el-input v-model="dataForm.patientName" style="width: 80px" size="small" clearable placeholder="" /></span>
<span>性别<el-input v-model="dataForm.patientSex" style="width: 60px" size="small" clearable placeholder="" /></span>
<span>年龄<el-input v-model="dataForm.patientAge" style="width: 60px" size="small" clearable placeholder="" /></span>
<span>屈光发育档案<el-input v-model="dataForm.file" style="width: 60px" size="small" clearable placeholder="" /></span>
<span>档案号<el-input v-model="dataForm.fileNUm" style="width: 80px" size="small" clearable placeholder="" /></span>
<span>登记号<el-input v-model="dataForm.patientId" style="width: 80px" clearable placeholder="" /></span>
<span>姓名<el-input v-model="dataForm.patientName" style="width: 80px" clearable placeholder="" /></span>
<span>性别<el-input v-model="dataForm.patientSex" style="width: 60px" clearable placeholder="" /></span>
<span>年龄<el-input v-model="dataForm.patientAge" style="width: 60px" clearable placeholder="" /></span>
<span>屈光发育档案<el-input v-model="dataForm.file" style="width: 60px" clearable placeholder="" /></span>
</div>
<div class="operation-record-table">
<el-table :data="tableData" :span-method="objectSpanMethod" border style="width: 100%; margin-top: 5px">
@ -29,11 +28,6 @@
瞳孔
</div>
</div>
<div v-else-if="scope.row.name == 2">
<div class="width-180 center">
检查方法
</div>
</div>
<div v-else-if="scope.row.name == 3">
<div class="width-180 center">
右眼
@ -49,11 +43,11 @@
右眼
</div>
</div>
<div v-else-if="scope.row.name == 6">
<div class="width-180 center">
左眼
</div>
</div>
<!-- <div v-else-if="scope.row.name == 6">-->
<!-- <div class="width-180 center">-->
<!-- 左眼-->
<!-- </div>-->
<!-- </div>-->
<div v-else-if="scope.row.name == 7" style="display: flex;justify-content: space-between">
<div class="width-180" style="text-align: left">
<span style="display: inline-block;margin-top: 16px">视光师:</span>
@ -75,6 +69,12 @@
<div v-else-if="scope.row.name == '最终处方'">
<div class="width-180 center" @click="copyData">
<el-button type="text" plain style="font-size: 14px">最终处方</el-button>
<div style="display: flex;flex-wrap: wrap">
<div v-for="(item,index) in scope.row.value" :key="index" class="check" @click="item.isSelect = !item.isSelect" style="margin-left: 8px">
<input type="checkbox" :checked="item.isSelect">
<div>{{ item.name }}</div>
</div>
</div>
</div>
</div>
<p v-else>{{ scope.row.name }}</p>
@ -96,24 +96,6 @@
</div>
</div>
</div>
<div v-if="scope.row.name == '2'">
<div class="width-180">
<div style="display: flex;flex-wrap: wrap">
<el-select v-model="scope.row.value" multiple placeholder="请选择">
<el-option
v-for="item in scope.row.examine"
:key="item.id"
:label="item.name"
:value="item.name"
/>
</el-select>
<!-- <div v-for="(item,index) in scope.row.examine" :key="index" class="check" @click="item.isSelect = !item.isSelect">-->
<!-- <input type="checkbox" :checked="item.isSelect">-->
<!-- <div>{{ item.name }}</div>-->
<!-- </div>-->
</div>
</div>
</div>
<div v-if="scope.row.name == '3'">
<div class="width-100 center">
<el-input v-model="scope.row.a" placeholder="" />
@ -129,28 +111,14 @@
<el-input v-model="scope.row.a" placeholder="" />
</div>
</div>
<div v-if="scope.row.name == '6'">
<div class="width-100 center">
<el-input v-model="scope.row.a" placeholder="" />
</div>
</div>
<div v-if="scope.row.name == '基本信息'">
<div class="width-100 center">
裸眼视力
</div>
</div>
<div v-if="scope.row.name == '最终处方'">
<div class="width-100">
<div style="display: flex;flex-wrap: wrap">
<div v-for="(item,index) in scope.row.value" :key="index" class="check" @click="item.isSelect = !item.isSelect">
<input type="checkbox" :checked="item.isSelect">
<div>{{ item.name }}</div>
</div>
</div>
<!-- <el-checkbox-group v-model="scope.row.value">-->
<!-- <el-checkbox label="远用" />-->
<!-- <el-checkbox label="近用" />-->
<!-- </el-checkbox-group>-->
<div class="width-100 center" style="text-align: center">
左眼
</div>
</div>
<div v-if="scope.row.name == '配镜建议'">
@ -162,14 +130,14 @@
</div>
</div>
<p style="margin-left: 16px">
<el-input v-model="scope.row.value" placeholder="" style="width: 180px">
<el-input v-model="scope.row.value" placeholder="" style="width: 280px">
<template slot="prepend">其他:</template>
</el-input>
</p>
</div>
</div>
<div v-if="scope.row.name == '备注'">
<div class="width-180">
<div>
<el-input v-model="scope.row.value" placeholder="" />
</div>
</div>
@ -187,6 +155,11 @@
球镜(DS)
</div>
</div>
<div v-if="scope.row.name == '1'">
<div class="width-180 center">
检查方法
</div>
</div>
<div v-if="scope.row.name == '3'">
<div class="width-100 center">
<el-input v-model="scope.row.b" placeholder="" />
@ -202,22 +175,11 @@
<el-input v-model="scope.row.b" placeholder="" />
</div>
</div>
<div v-if="scope.row.name == '6'">
<div v-if="scope.row.name == '最终处方'">
<div class="width-100 center">
<el-input v-model="scope.row.b" placeholder="" />
<el-input v-model="scope.row.a" placeholder="" />
</div>
</div>
<!-- <div v-if="scope.row.name == '最终处方'">-->
<!-- <div class="width-100 center">-->
<!-- 恢复点<el-input v-model="scope.row.value" placeholder="" />-->
<!-- </div>-->
<!-- </div>-->
<!-- <div v-if="scope.row.name == '立体视(stereo)'">-->
<!-- <div class="width-100 center">-->
<!-- TNO()<el-input v-model="scope.row.value" placeholder="" />-->
<!-- </div>-->
<!-- </div>-->
</template>
</el-table-column>
<el-table-column label="" width="" :resizable="false">
@ -232,6 +194,20 @@
柱镜(DC)
</div>
</div>
<div v-if="scope.row.name == '1'">
<div>
<div style="display: flex;flex-wrap: wrap">
<el-select v-model="scope.row.examValue" multiple placeholder="请选择">
<el-option
v-for="item in scope.row.examine"
:key="item.id"
:label="item.name"
:value="item.name"
/>
</el-select>
</div>
</div>
</div>
<div v-if="scope.row.name == '3'">
<div class="width-100 center">
<el-input v-model="scope.row.c" placeholder="" />
@ -247,9 +223,9 @@
<el-input v-model="scope.row.c" placeholder="" />
</div>
</div>
<div v-if="scope.row.name == '6'">
<div v-if="scope.row.name == '最终处方'">
<div class="width-100 center">
<el-input v-model="scope.row.c" placeholder="" />
<el-input v-model="scope.row.b" placeholder="" />
</div>
</div>
</template>
@ -281,9 +257,9 @@
<el-input v-model="scope.row.d" placeholder="" />
</div>
</div>
<div v-if="scope.row.name == '6'">
<div v-if="scope.row.name == '最终处方'">
<div class="width-100 center">
<el-input v-model="scope.row.d" placeholder="" />
<el-input v-model="scope.row.c" placeholder="" />
</div>
</div>
</template>
@ -315,9 +291,9 @@
<el-input v-model="scope.row.e" placeholder="" />
</div>
</div>
<div v-if="scope.row.name == '6'">
<div v-if="scope.row.name == '最终处方'">
<div class="width-100 center">
<el-input v-model="scope.row.e" placeholder="" />
<el-input v-model="scope.row.d" placeholder="" />
</div>
</div>
</template>
@ -344,9 +320,9 @@
<el-input v-model="scope.row.f" placeholder="" />
</div>
</div>
<div v-if="scope.row.name == '6'">
<div v-if="scope.row.name == '最终处方'">
<div class="width-80 center">
<el-input v-model="scope.row.f" placeholder="" />
<el-input v-model="scope.row.e" placeholder="" />
</div>
</div>
</template>
@ -373,9 +349,9 @@
<el-input v-model="scope.row.g" placeholder="" />
</div>
</div>
<div v-if="scope.row.name == '6'">
<div v-if="scope.row.name == '最终处方'">
<div class="width-80 center">
<el-input v-model="scope.row.g" placeholder="" />
<el-input v-model="scope.row.f" placeholder="" />
</div>
</div>
</template>
@ -387,6 +363,11 @@
棱镜
</div>
</div>
<div v-if="scope.row.name == '最终处方'">
<div class="width-80 center">
<el-input v-model="scope.row.g" placeholder="" />
</div>
</div>
</template>
</el-table-column>
</el-table>
@ -428,8 +409,7 @@ export default {
patientName: '',
patientSex: '',
patientAge: '',
file: '',
fileNUm: ''
file: ''
},
originTableData: [],
tableData: [
@ -441,6 +421,7 @@ export default {
}, {
name: '1',
value: '',
examValue: '',
pupil: [
{
name: '正常瞳孔',
@ -464,10 +445,6 @@ export default {
isSelect: false
}
],
type: ''
}, {
name: '2',
value: '',
examine: [
{
name: '检影',
@ -514,9 +491,6 @@ export default {
isSelect: false
}
],
type: ''
}, {
name: '5',
type: '',
a: '',
b: '',
@ -526,7 +500,7 @@ export default {
f: '',
g: ''
}, {
name: '6',
name: '5',
type: '',
a: '',
b: '',
@ -535,7 +509,7 @@ export default {
e: '',
f: '',
g: ''
}, {
},{
name: '配镜建议',
suggest: [
{
@ -574,9 +548,9 @@ export default {
this.ws.close()
},
mounted() {
this.originTableData = JSON.parse(JSON.stringify(this.tableData))
this.setSign()
this.initWebSoket()
this.originTableData = JSON.parse(JSON.stringify(this.tableData))
this.getPatientData()
},
methods: {
@ -604,10 +578,9 @@ export default {
patientName: '',
patientSex: '',
patientAge: '',
file: '',
fileNUm: ''
file: ''
}
this.tableData = this.originTableData
this.tableData = Object.assign([], this.originTableData)
this.setSign()
this.getPatientData()
},
@ -615,7 +588,7 @@ export default {
const ods = this.tableData.filter(item => item.name === '3')
const oss = this.tableData.filter(item => item.name === '4')
this.tableData.forEach(item => {
if (item.name === '5') {
if (item.name === '最终处方') {
item.a = ods[0].a
item.b = ods[0].b
item.c = ods[0].c
@ -624,7 +597,7 @@ export default {
item.f = ods[0].f
item.g = ods[0].g
}
if (item.name === '6') {
if (item.name === '5') {
item.a = oss[0].a
item.b = oss[0].b
item.c = oss[0].c
@ -673,7 +646,7 @@ export default {
that.lockReconnect = false
}, 5000)
},
reset() { //
resetHeart() { //
const that = this
//
clearTimeout(that.timeoutObj)
@ -719,8 +692,9 @@ export default {
}
this.ws.onmessage = function(msg) {
const message = JSON.parse(msg.data)
// const data = JSON.parse(msg.data)
// const message = JSON.parse(data.msgTxt)
console.log(message)
// console.log(message)
self.tableData.forEach(item => {
if (item.name == '3') {
item.a = message.RData.DS
@ -736,7 +710,7 @@ export default {
item.e = message.LData.ADD
}
})
self.reset()
self.resetHeart()
}
},
handleSaveTable() {
@ -751,31 +725,37 @@ export default {
},
objectSpanMethod({ row, column, rowIndex, columnIndex }) {
if (columnIndex === 0) {
if (rowIndex === 0 || rowIndex === 3 || rowIndex === 6) {
if (rowIndex === 0 || rowIndex === 5) {
// [0,0][0,3][0,6] 31
return {
rowspan: 2,
colspan: 1
}
}
if (rowIndex === 2) {
return {
rowspan: 3,
colspan: 1
}
}
// [0,11] 91
if (rowIndex === 11) {
if (rowIndex === 9) {
return {
rowspan: 1,
colspan: 9
}
}
} else if (columnIndex === 1) {
if (rowIndex === 6 || rowIndex === 9 || rowIndex === 10) {
if (rowIndex === 7 || rowIndex === 8) {
return {
rowspan: 1,
colspan: 8
}
}
if (rowIndex === 1 || rowIndex === 2) {
if (rowIndex === 1) {
return {
rowspan: 1,
colspan: 7
colspan: 3
}
}
} else if (columnIndex === 3) {
@ -785,6 +765,12 @@ export default {
colspan: 2
}
}
if (rowIndex === 1) {
return {
rowspan: 1,
colspan: 3
}
}
} else if (columnIndex === 5) {
if (rowIndex === 0) {
return {
@ -792,8 +778,8 @@ export default {
colspan: 3
}
}
} else if (rowIndex === 6 || rowIndex === 9 || rowIndex === 10) {
if (columnIndex === 2 || columnIndex === 3 || columnIndex === 4 || columnIndex === 5 || columnIndex === 3) {
} else if (rowIndex === 7 || rowIndex === 8) {
if (columnIndex === 2 || columnIndex === 3 || columnIndex === 4 || columnIndex === 5 || columnIndex === 6) {
return {
rowspan: 0,
colspan: 0
@ -805,7 +791,7 @@ export default {
}
</script>
<style lang="scss" scoped>
<style lang="scss">
.flex{
display: flex;
}
@ -820,19 +806,14 @@ export default {
.printBox{
page-break-inside: avoid !important;
.el-input__inner {
border: none;
font-size: 16px;
border-bottom: 1px solid #ccc;
border-radius: 0;
padding: 0;
}
}
//@media print{
// @page {
// size:A5 landscape !important;
// }
//}
#operation-record {
//height: 93%;
// overflow: auto;
.operation-record-table {
width: 100%;
.operation-text {
@ -885,14 +866,17 @@ export default {
width: 80px;
}
}
.width-180 {
.el-input {
width: 180px;
}
}
.el-input__inner {
font-size: 16px !important;
border: none;
height: 26px !important;
line-height: 26px !important;
text-align: center;
}
.el-input__inner {
border-bottom: 1px solid #ccc;
border-radius: 0;
padding: 0;
@ -953,3 +937,4 @@ export default {
}
}
</style>

2
src/components/360View/commonForm/threeVision.vue

@ -673,8 +673,6 @@ export default {
height: 26px !important;
line-height: 26px !important;
text-align: center;
}
.el-input__inner {
border-bottom: 1px solid #ccc;
border-radius: 0;
padding: 0;

Loading…
Cancel
Save