Commit beeed7fe authored by 高滢's avatar 高滢

Merge remote-tracking branch 'origin/master'

parents ef6f7fe3 fd57fa02
...@@ -77,3 +77,12 @@ export function getHospitalIds(query) { ...@@ -77,3 +77,12 @@ export function getHospitalIds(query) {
params: query params: query
}) })
} }
// 查询当前登陆医院账号的医院信息
export function signHospitalMessage(query) {
return request({
url: '/system/hospital/sign-in-hospital-message',
method: 'get',
params: query
})
}
...@@ -2,10 +2,10 @@ ...@@ -2,10 +2,10 @@
<div class="component-upload-image"> <div class="component-upload-image">
<ImageCropperModal <ImageCropperModal
:visible="cropperVisible" :visible="cropperVisible"
:url="file" :url="fileUrl"
:auto-crop-width="autoCropWidth" :auto-crop-width="autoCropWidth"
:auto-crop-height="autoCropHeight" :auto-crop-height="autoCropHeight"
@cancel="cropperVisible = false" @cancel="onConcel"
@confirm="onConfirm" @confirm="onConfirm"
/> />
<el-upload <el-upload
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
> >
<i slot="default" class="el-icon-plus" /> <i slot="default" class="el-icon-plus" />
<div slot="file" slot-scope="{file}" class="customer-upload-area"> <div slot="file" slot-scope="{file}" class="customer-upload-area">
<el-image :ref="file.url" class="el-upload-list__item-thumbnail customer-upload-error" :src="file.url" :preview-src-list="[file.url]"> <el-image v-show="fileList.length > 0" :ref="file.url" class="el-upload-list__item-thumbnail customer-upload-error" :src="file.url" :preview-src-list="[file.url]">
<div slot="error" class="image-slot"> <div slot="error" class="image-slot">
<i class="el-icon-picture-outline" /> <i class="el-icon-picture-outline" />
<div>加载失败</div> <div>加载失败</div>
...@@ -120,7 +120,7 @@ export default { ...@@ -120,7 +120,7 @@ export default {
}, },
autoCropWidth: '400', // 要裁剪的宽 autoCropWidth: '400', // 要裁剪的宽
autoCropHeight: '400', // 要裁剪的高 autoCropHeight: '400', // 要裁剪的高
file: '', fileUrl: '',
fileName: '', // 存放文件名 fileName: '', // 存放文件名
cropperVisible: false, // 控制弹窗打开关闭 cropperVisible: false, // 控制弹窗打开关闭
number: 0, number: 0,
...@@ -183,7 +183,7 @@ export default { ...@@ -183,7 +183,7 @@ export default {
const reader = new FileReader() const reader = new FileReader()
reader.onload = () => { reader.onload = () => {
// 把Array Buffer转化为blob 如果是base64不需要 // 把Array Buffer转化为blob 如果是base64不需要
this.file = typeof reader.result === 'object' ? window.URL.createObjectURL(new Blob([reader.result])) this.fileUrl = typeof reader.result === 'object' ? window.URL.createObjectURL(new Blob([reader.result]))
: reader.result : reader.result
} }
// 转化为base64 // 转化为base64
...@@ -229,6 +229,10 @@ export default { ...@@ -229,6 +229,10 @@ export default {
this.handleUploadError(err) this.handleUploadError(err)
}) })
}, },
onConcel(file) {
this.cropperVisible = false
this.$refs.imageUpload.handleRemove(file)
},
// 上传前loading加载 // 上传前loading加载
handleBeforeUpload(file) { handleBeforeUpload(file) {
console.log('图片file---,', file.name) console.log('图片file---,', file.name)
...@@ -347,17 +351,17 @@ export default { ...@@ -347,17 +351,17 @@ export default {
// .el-upload--picture-card 控制加号部分 // .el-upload--picture-card 控制加号部分
::v-deep.hide .el-upload--picture-card { ::v-deep.hide .el-upload--picture-card {
display: none; display: none;
} }
// 去掉动画效果 // 去掉动画效果
::v-deep .el-list-enter-active, ::v-deep .el-list-enter-active,
::v-deep .el-list-leave-active { ::v-deep .el-list-leave-active {
transition: all 0s; transition: all 0s;
} }
::v-deep .el-list-enter, .el-list-leave-active { ::v-deep .el-list-enter, .el-list-leave-active {
opacity: 0; opacity: 0;
transform: translateY(0); transform: translateY(0);
} }
::v-deep .el-upload-list--picture-card { ::v-deep .el-upload-list--picture-card {
line-height: 0; line-height: 0;
......
...@@ -58,7 +58,9 @@ export default { ...@@ -58,7 +58,9 @@ export default {
}, },
methods: { methods: {
onCancel() { onCancel() {
this.$emit('cancel') this.$refs.imageCropper.getCropBlob((blob) => {
this.$emit('cancel', blob)
})
}, },
onConfirm() { onConfirm() {
this.$refs.imageCropper.getCropBlob((blob) => { this.$refs.imageCropper.getCropBlob((blob) => {
......
...@@ -106,7 +106,7 @@ service.interceptors.response.use(res => { ...@@ -106,7 +106,7 @@ service.interceptors.response.use(res => {
console.log('err' + error) console.log('err' + error)
let { message } = error; let { message } = error;
if (message == "Network Error") { if (message == "Network Error") {
message = "后端接口连接异常"; message = "网络异常";
} else if (message.includes("timeout")) { } else if (message.includes("timeout")) {
message = "系统接口请求超时"; message = "系统接口请求超时";
} else if (message.includes("Request failed with status code")) { } else if (message.includes("Request failed with status code")) {
......
...@@ -83,10 +83,12 @@ export default { ...@@ -83,10 +83,12 @@ export default {
<span>${_this.label}</span> <span>${_this.label}</span>
<span style=" <span style="
margin-left: 5px; margin-left: 5px;
background-image: -webkit-linear-gradient(top, ${_this.startColor}, ${_this.endColor}); font-size: 13px;
font-weight: bold;
background-image: -webkit-linear-gradient(top, #3490CD, #3490CD);
-webkit-background-clip:text; -webkit-background-clip:text;
-webkit-text-fill-color:transparent;"> -webkit-text-fill-color:transparent;">
${axis[0].value}(${_this.unit})</span> ${axis[0].value}${_this.unit}</span>
</div> </div>
</div>` </div>`
} }
......
...@@ -80,7 +80,7 @@ export default { ...@@ -80,7 +80,7 @@ export default {
symbolSize: 6, symbolSize: 6,
itemStyle: { itemStyle: {
color: new this.$echarts.graphic.LinearGradient( // 设置渐变色 color: new this.$echarts.graphic.LinearGradient( // 设置渐变色
0, 0, 0, 1, 0, 0, 1, 0,
[ [
{ offset: 0, color: '#7245D9' }, { offset: 0, color: '#7245D9' },
{ offset: 1, color: '#5A5FE6' } { offset: 1, color: '#5A5FE6' }
...@@ -105,7 +105,7 @@ export default { ...@@ -105,7 +105,7 @@ export default {
symbolSize: 6, symbolSize: 6,
itemStyle: { itemStyle: {
color: new this.$echarts.graphic.LinearGradient( // 设置渐变色 color: new this.$echarts.graphic.LinearGradient( // 设置渐变色
0, 0, 0, 1, 0, 0, 1, 0,
[ [
{ offset: 0, color: '#3994C1' }, { offset: 0, color: '#3994C1' },
{ offset: 1, color: '#5BB158' } { offset: 1, color: '#5BB158' }
......
...@@ -112,12 +112,12 @@ export default { ...@@ -112,12 +112,12 @@ export default {
<div style="display: flex"> <div style="display: flex">
<div style="background-color: ${color1};width: 10px;height: 10px;margin-top: 7px;margin-right:5px;border-radius: 10px"></div> <div style="background-color: ${color1};width: 10px;height: 10px;margin-top: 7px;margin-right:5px;border-radius: 10px"></div>
<span>${label1}</span> <span>${label1}</span>
<span style="margin-left: 5px;color: ${color1}">${axis[0].value}(${unit1})</span> <span style="margin-left: 5px;color: ${color1}">${Number(axis[0].value).toFixed(2)}${unit1}</span>
</div> </div>
<div style="display: flex"> <div style="display: flex">
<div style="background-color: ${color2};width: 10px;height: 10px;margin-top: 7px;margin-right:5px;border-radius: 10px"></div> <div style="background-color: ${color2};width: 10px;height: 10px;margin-top: 7px;margin-right:5px;border-radius: 10px"></div>
<span>${label2}</span> <span>${label2}</span>
<span style="margin-left: 5px;color: ${color2}">${axis[1].value}(${unit2})</span> <span style="margin-left: 5px;color: ${color2}">${Number(axis[1].value).toFixed(2)}${unit2}</span>
</div> </div>
</div>` </div>`
} }
......
...@@ -124,21 +124,21 @@ ...@@ -124,21 +124,21 @@
<div class="rank_hospital_name_font"> <div class="rank_hospital_name_font">
<overlong-tool :text="item.hospitalName" :max="30" /> <overlong-tool :text="item.hospitalName" :max="30" />
</div> </div>
<el-row> <div>
<el-col :span="19"> <div style="display: flex;margin: 0 auto">
<el-progress <div class="progressWidth">
:percentage="item.total/hospitalPrestoredRank[0].total*100" <el-progress
:stroke-width="9" :percentage="item.total/hospitalPrestoredRank[0].total*100"
:show-text="false" :stroke-width="9"
class="prestoredRankProgress" :show-text="false"
/> class="prestoredRankProgress"
</el-col> />
<el-col :span="5"> </div>
<div class="prestoredRankFont"> <div class="prestoredRankFont">
{{ item.total }} {{ item.total }}
</div> </div>
</el-col> </div>
</el-row> </div>
</div> </div>
</div> </div>
</div> </div>
...@@ -305,7 +305,7 @@ ...@@ -305,7 +305,7 @@
size="mini" size="mini"
type="success" type="success"
icon="el-icon-document" icon="el-icon-document"
style="width: 50px; border-radius: 6px 6px 6px 6px;border: 1px solid rgb(95, 181, 75);color: #5FB54B;background: rgba(91,182,71,0.08);" class="el-button--success--solid"
plain plain
@click="handleDetail(scope.row)" @click="handleDetail(scope.row)"
>详情 >详情
...@@ -819,4 +819,7 @@ export default { ...@@ -819,4 +819,7 @@ export default {
height: 468px; height: 468px;
} }
} }
.progressWidth {
width: 330px;
}
</style> </style>
...@@ -1000,7 +1000,7 @@ export default { ...@@ -1000,7 +1000,7 @@ export default {
serviceDetail(row) { serviceDetail(row) {
this.$router.push({ this.$router.push({
name: 'CheckDetail', name: 'CheckDetail',
query: { checkId: row.id } query: { checkId: row.id, fromData: true }
}) })
} }
} }
......
...@@ -294,7 +294,7 @@ ...@@ -294,7 +294,7 @@
</el-row> </el-row>
</el-form> </el-form>
<el-row> <el-row>
<el-col style="display: flex;justify-content: center;margin-top: 20px"> <el-col style="display: flex;justify-content: left; margin-left: 20px; margin-top: 20px">
<el-button class="queryBtn" type="primary" size="mini" icon="el-icon-check" :disabled="loading" @click="submitForm"> <el-button class="queryBtn" type="primary" size="mini" icon="el-icon-check" :disabled="loading" @click="submitForm">
<span v-if="!loading">提交</span> <span v-if="!loading">提交</span>
<span v-else>提交...</span> <span v-else>提交...</span>
......
...@@ -283,7 +283,9 @@ ...@@ -283,7 +283,9 @@
v-model.trim="form.checkTypeText" v-model.trim="form.checkTypeText"
type="textarea" type="textarea"
style="width:705%;" style="width:705%;"
pacehpl
:row="4" :row="4"
placeholder="暂无数据"
disabled disabled
/> />
</el-form-item> </el-form-item>
...@@ -602,7 +604,7 @@ ...@@ -602,7 +604,7 @@
</el-row> </el-row>
</el-form> </el-form>
<el-row> <el-row>
<el-col style="display: flex;justify-content: center;margin-top: 20px"> <el-col style="display: flex;justify-content: left; margin-left: 20px; margin-top: 20px">
<el-button class="queryBtn" type="primary" size="mini" icon="el-icon-check" @click="submitForm">提交</el-button> <el-button class="queryBtn" type="primary" size="mini" icon="el-icon-check" @click="submitForm">提交</el-button>
<el-button class="resetBtn" size="mini" icon="el-icon-back" @click="cancel">返 回</el-button> <el-button class="resetBtn" size="mini" icon="el-icon-back" @click="cancel">返 回</el-button>
</el-col> </el-col>
...@@ -619,9 +621,10 @@ import { getAreNameById, getAreTreeStructure, getDevice, updateDevice } from '@/ ...@@ -619,9 +621,10 @@ import { getAreNameById, getAreTreeStructure, getDevice, updateDevice } from '@/
import { regionData } from 'element-china-area-data' import { regionData } from 'element-china-area-data'
import { getInfo } from '@/api/login' import { getInfo } from '@/api/login'
import { listCheckManage } from '@/api/business/manage' import { listCheckManage } from '@/api/business/manage'
import { isEmpty, parseTime, selectDictLabels } from '@/utils/ruoyi' import { isEmpty, parseTime } from '@/utils/ruoyi'
import { deepClone } from '@/utils' import { deepClone } from '@/utils'
import { listItemByType } from '@/api/business/item' import { listItemByType } from '@/api/business/item'
import { mapGetters } from 'vuex'
export default { export default {
name: 'EquipmentDetail', name: 'EquipmentDetail',
dicts: ['device_status', 'device_type', 'exam_type', 'check_type', 'service_area'], dicts: ['device_status', 'device_type', 'exam_type', 'check_type', 'service_area'],
...@@ -827,7 +830,7 @@ export default { ...@@ -827,7 +830,7 @@ export default {
}, },
// 登陆人类型 // 登陆人类型
userType: '', // userType: '',
// 是否显示 // 是否显示
isShow: '', isShow: '',
hpshow: '' hpshow: ''
...@@ -839,11 +842,14 @@ export default { ...@@ -839,11 +842,14 @@ export default {
this.getUserInfo() this.getUserInfo()
this.getuseList() this.getuseList()
}, },
computed: {
...mapGetters(['userType'])
},
methods: { methods: {
// 获取登陆人信息 // 获取登陆人信息
getUserInfo() { getUserInfo() {
getInfo().then(res => { getInfo().then(res => {
this.userType = res.user.userType // this.userType = res.user.userType
console.log(' this.userType', this.userType) console.log(' this.userType', this.userType)
if (this.userType === '3') { if (this.userType === '3') {
this.isShow = false this.isShow = false
...@@ -994,6 +1000,15 @@ export default { ...@@ -994,6 +1000,15 @@ export default {
console.log('检查项目', res) console.log('检查项目', res)
this.checkItemOptions = res.rows this.checkItemOptions = res.rows
console.log('xdddd', this.checkItemOptions) console.log('xdddd', this.checkItemOptions)
const result = []
const ids = [... this.form.checkType]
for (let i = 0; i < this.checkItemOptions.length; i++) {
if (ids.includes(parseInt(this.checkItemOptions[i].id))) {
result.push(this.checkItemOptions[i].name)
}
}
this.form.checkTypeText = result
console.log(' this.checkTypeText', this.form.checkTypeText)
}) })
}, },
// 获取地址数据 // 获取地址数据
...@@ -1159,15 +1174,11 @@ export default { ...@@ -1159,15 +1174,11 @@ export default {
getDevice(this.id).then(response => { getDevice(this.id).then(response => {
this.form = response.data this.form = response.data
this.form.selectedOptions = response.data.addressCode.split(',').map(Number) this.form.selectedOptions = response.data.addressCode.split(',').map(Number)
// console.log('查询到的地址信息', this.form.selectedOptions)
// console.log('this.form.serviceArea', response.data.serviceArea)
// console.log(' this.form.serviceAreaText', this.form.serviceAreaText)
this.form.serviceArea = response.data.serviceArea.split(';') this.form.serviceArea = response.data.serviceArea.split(';')
console.log(' this.areaOptions--------------------------', this.areaOptions) console.log(' this.areaOptions--------------------------', this.areaOptions)
console.log('支持检查地区回显值', this.form.serviceArea) console.log('支持检查地区回显值', this.form.serviceArea)
if (this.form.checkType != null && this.form.checkType !== '') { if (this.form.checkType != null && this.form.checkType !== '') {
this.form.checkTypeText = selectDictLabels(this.dict.type.exam_type, this.form.checkType)
console.log(' this.form.checkTypeText', this.form.checkTypeText)
this.form.checkType = response.data.checkType.split(',').map(Number) this.form.checkType = response.data.checkType.split(',').map(Number)
console.log('this.form.checkType', this.form.checkType) console.log('this.form.checkType', this.form.checkType)
} }
......
...@@ -499,10 +499,15 @@ export default { ...@@ -499,10 +499,15 @@ export default {
}, },
// 返回上一页 // 返回上一页
goBack() { goBack() {
// this.$router.push({ if (this.$route.query.fromData === true) {
// path: '/service-management/medical-record-management' this.$router.push({
// }) path: '/data-statistics/service-data-statistics'
this.$router.back() })
} else {
this.$router.push({
path: '/service-management/medical-record-management'
})
}
}, },
/** 点击上传报告按钮 */ /** 点击上传报告按钮 */
uploadReport() { uploadReport() {
......
...@@ -201,12 +201,13 @@ ...@@ -201,12 +201,13 @@
format="yyyy-MM-dd" format="yyyy-MM-dd"
value-format="yyyy-MM-dd" value-format="yyyy-MM-dd"
@change="changeDate" @change="changeDate"
:picker-options="pickerOptions"
/> />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col v-show="subscribeMessage.checkType === '2'" :span="8"> <el-col v-show="subscribeMessage.checkType === '2'" :span="8">
<el-form-item label="支出账户余额" label-width="96px"> <el-form-item label="支出账户余额" label-width="96px">
¥11800.00 <span>{{ '¥' + moneyFormat(currentHospital.currentBalance) }}</span>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
...@@ -217,7 +218,7 @@ ...@@ -217,7 +218,7 @@
:header-cell-style="{background:'#F4F4F4'}" :header-cell-style="{background:'#F4F4F4'}"
empty-text="当前暂无可预约设备" empty-text="当前暂无可预约设备"
> >
<el-table-column label="设备名称" align="center" prop="deviceName" /> <el-table-column show-overflow-tooltip="true" label="设备名称" align="center" prop="deviceName" />
<el-table-column label="检查日期" align="center" prop="checkDate"> <el-table-column label="检查日期" align="center" prop="checkDate">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ parseTime(scope.row.checkDate, '{y}/{m}/{d}') }}</span> <span>{{ parseTime(scope.row.checkDate, '{y}/{m}/{d}') }}</span>
...@@ -259,12 +260,22 @@ import { deviceUseInSubscribeList, listReservationDevice } from '@/api/business/ ...@@ -259,12 +260,22 @@ import { deviceUseInSubscribeList, listReservationDevice } from '@/api/business/
import { parseTime } from '@/utils/ruoyi' import { parseTime } from '@/utils/ruoyi'
import { updateCheck } from '@/api/business/mdeicalRecord' import { updateCheck } from '@/api/business/mdeicalRecord'
import { getManage } from '@/api/business/manage' import { getManage } from '@/api/business/manage'
import { signHospitalMessage } from '@/api/business/hospital'
import { moneyFormat } from '../../../utils'
export default { export default {
name: 'CheckSubscribe', name: 'CheckSubscribe',
dicts: ['pet_sex', 'sterilization_status', 'vaccine_situation', 'check_type'], dicts: ['pet_sex', 'sterilization_status', 'vaccine_situation', 'check_type'],
data() { data() {
return { return {
pickerOptions: {
disabledDate(time) {
const today = new Date()
const maxDate = new Date()
maxDate.setDate(today.getDate() + 14)
return time.getTime() < (today.getTime() - 1000 * 3600 * 24) || time.getTime() > maxDate.getTime()
}
},
checkDetail: {}, checkDetail: {},
queryParams: {}, queryParams: {},
total: 0, total: 0,
...@@ -294,34 +305,50 @@ export default { ...@@ -294,34 +305,50 @@ export default {
value: '1', value: '1',
label: '已购保险' label: '已购保险'
} }
] ],
// 当前登陆医院的信息
currentHospital: null
} }
}, },
created() { created() {
// const id = localStorage.getItem('checkId') this.currentCheckId = this.$route.query.checkId
const id = this.$route.query.checkId this.getHospitalMessage()
getManage(id).then(response => { setTimeout(() => {
this.subscribeMessage = response.data this.getManage()
console.log('立即预约页面', this.subscribeMessage) }, 300)
this.subscribeMessage.payAmount = this.keepTwoDecimals(this.subscribeMessage.payAmount)
// 时间
this.deviceQueryParams.reservationTime = parseTime(new Date(), '{y}-{m}-{d}')
// 服务类型(医院自有、外部服务)
if (this.subscribeMessage.checkType === '0') {
this.deviceQueryParams.isPrivate = '1'
} else if (this.subscribeMessage.checkType === '2') {
this.deviceQueryParams.isPrivate = '0'
}
// 检查项目
this.deviceQueryParams.checkTypeList.push(this.subscribeMessage.checkItemsId)
this.currentCheckId = this.subscribeMessage.id
this.currentPayAmount = this.subscribeMessage.payAmount
this.getDevice()
this.getAllDevice(this.subscribeMessage.checkItemsId, this.deviceQueryParams.isPrivate)
})
}, },
methods: { methods: {
moneyFormat,
parseTime, parseTime,
getManage() {
getManage(this.currentCheckId).then(response => {
this.subscribeMessage = response.data
this.subscribeMessage.payAmount = this.keepTwoDecimals(this.subscribeMessage.payAmount)
// 时间
this.deviceQueryParams.reservationTime = parseTime(new Date(), '{y}-{m}-{d}')
// 服务类型(医院自有、外部服务)
if (this.subscribeMessage.checkType === '0') {
this.deviceQueryParams.isPrivate = '1'
} else if (this.subscribeMessage.checkType === '2') {
this.deviceQueryParams.isPrivate = '0'
}
// 检查项目
this.deviceQueryParams.checkTypeList.push(this.subscribeMessage.checkItemsId)
this.currentPayAmount = this.subscribeMessage.payAmount
this.getDevice()
this.getAllDevice(this.subscribeMessage.checkItemsId, this.deviceQueryParams.isPrivate)
console.log('立即预约页面', this.subscribeMessage)
})
},
/** 获取当前医院信息 */
getHospitalMessage() {
signHospitalMessage().then(response => {
if (response.code === 200) {
console.log('获取当前医院信息')
this.currentHospital = response.data
}
})
},
// 点击立即预约 // 点击立即预约
handleBookNow(row) { handleBookNow(row) {
this.$confirm('立即预约此设备,是否确定?', '提示', { this.$confirm('立即预约此设备,是否确定?', '提示', {
...@@ -369,6 +396,7 @@ export default { ...@@ -369,6 +396,7 @@ export default {
getList() {}, getList() {},
// 返回上一页 // 返回上一页
goBack() { goBack() {
console.log('当前ID', this.currentCheckId)
this.$router.push({ this.$router.push({
name: 'CheckDetail', name: 'CheckDetail',
query: { checkId: this.currentCheckId } query: { checkId: this.currentCheckId }
...@@ -376,6 +404,7 @@ export default { ...@@ -376,6 +404,7 @@ export default {
}, },
// 获取设备列表 // 获取设备列表
getDevice() { getDevice() {
this.deviceQueryParams.serviceArea = this.currentHospital.addressCode
listReservationDevice(this.deviceQueryParams).then(res => { listReservationDevice(this.deviceQueryParams).then(res => {
this.deviceList = res.rows.table this.deviceList = res.rows.table
this.total = res.total this.total = res.total
...@@ -391,7 +420,15 @@ export default { ...@@ -391,7 +420,15 @@ export default {
getAllDevice(checkItemsId, isPrivate) { getAllDevice(checkItemsId, isPrivate) {
const list = [] const list = []
list.push(checkItemsId) list.push(checkItemsId)
deviceUseInSubscribeList({ isPrivate: isPrivate, checkTypeList: list }).then(res => { const obj = {
isPrivate: isPrivate,
checkTypeList: list
}
// 预约外部服务的时候,根据当前地区地址查询
if (isPrivate === '0') {
obj.serviceArea = this.currentHospital.addressCode
}
deviceUseInSubscribeList(obj).then(res => {
this.selectableDevice = res.data this.selectableDevice = res.data
}) })
}, },
......
...@@ -294,12 +294,13 @@ ...@@ -294,12 +294,13 @@
format="yyyy-MM-dd" format="yyyy-MM-dd"
value-format="yyyy-MM-dd" value-format="yyyy-MM-dd"
@change="changeDate" @change="changeDate"
:picker-options="pickerOptions"
/> />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col v-show="currentCheckType === '2'" :span="6"> <el-col v-show="currentCheckType === '2'" :span="6">
<el-form-item label="支出账户余额" prop="shadowReport" label-width="120"> <el-form-item label="支出账户余额" prop="shadowReport" label-width="120">
1200.00 <span v-if="currentHospital !== undefined && currentHospital !== null">{{ '¥' + moneyFormat(currentHospital.currentBalance || 0) }}</span>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
...@@ -311,7 +312,7 @@ ...@@ -311,7 +312,7 @@
:header-cell-style="{background:'#F4F4F4'}" :header-cell-style="{background:'#F4F4F4'}"
empty-text="当前暂无可预约设备" empty-text="当前暂无可预约设备"
> >
<el-table-column prop="deviceName" align="left" label="设备名称" /> <el-table-column prop="deviceName" align="left" label="设备名称" show-overflow-tooltip="true" />
<el-table-column prop="checkDate" align="left" label="检查日期"> <el-table-column prop="checkDate" align="left" label="检查日期">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ parseTime(scope.row.checkDate, '{y}/{m}/{d}') }}</span> <span>{{ parseTime(scope.row.checkDate, '{y}/{m}/{d}') }}</span>
...@@ -361,12 +362,22 @@ import { deviceUseInSubscribeList, listReservationDevice } from '@/api/business/ ...@@ -361,12 +362,22 @@ import { deviceUseInSubscribeList, listReservationDevice } from '@/api/business/
import { listItemByType, listPlatformItem } from '@/api/business/item' import { listItemByType, listPlatformItem } from '@/api/business/item'
import { parseTime } from '@/utils/ruoyi' import { parseTime } from '@/utils/ruoyi'
import { updateCheck } from '@/api/business/mdeicalRecord' import { updateCheck } from '@/api/business/mdeicalRecord'
import { signHospitalMessage } from '@/api/business/hospital'
import { moneyFormat } from '../../../utils'
export default { export default {
name: 'MedicalRecordManagement', name: 'MedicalRecordManagement',
dicts: ['exam_type', 'check_type', 'pet_insure', 'payment_status'], dicts: ['exam_type', 'check_type', 'pet_insure', 'payment_status'],
data() { data() {
return { return {
pickerOptions: {
disabledDate(time) {
const today = new Date()
const maxDate = new Date()
maxDate.setDate(today.getDate() + 14)
return time.getTime() < (today.getTime() - 1000 * 3600 * 24) || time.getTime() > maxDate.getTime()
}
},
isPlatRole: false, isPlatRole: false,
options: [], options: [],
// 遮罩层 // 遮罩层
...@@ -471,13 +482,16 @@ export default { ...@@ -471,13 +482,16 @@ export default {
currentPayAmount: null, currentPayAmount: null,
// 检查类型(0-自有、2-外部) // 检查类型(0-自有、2-外部)
currentCheckType: null, currentCheckType: null,
updateRow: {} updateRow: {},
// 当前医院信息
currentHospital: null
} }
}, },
created() { created() {
if (this.$store.state.user.userType !== '00') { if (this.$store.state.user.userType !== '00') {
console.log('非平台权限') console.log('非平台权限')
this.getList() this.getList()
this.getHospitalMessage()
} else { } else {
console.log('平台权限') console.log('平台权限')
this.getItemForPlat() this.getItemForPlat()
...@@ -487,7 +501,17 @@ export default { ...@@ -487,7 +501,17 @@ export default {
} }
}, },
methods: { methods: {
moneyFormat,
parseTime, parseTime,
/** 获取当前医院信息 */
getHospitalMessage() {
signHospitalMessage().then(response => {
console.log('当前医院信息', response)
if (response.code === 200) {
this.currentHospital = response.data
}
})
},
/** 查询业务管理-检查管理列表 */ /** 查询业务管理-检查管理列表 */
getList() { getList() {
this.loading = true this.loading = true
...@@ -593,7 +617,15 @@ export default { ...@@ -593,7 +617,15 @@ export default {
console.log('获取所有设备用于设备下拉', isPrivate) console.log('获取所有设备用于设备下拉', isPrivate)
const list = [] const list = []
list.push(checkItemsId) list.push(checkItemsId)
deviceUseInSubscribeList({ isPrivate: isPrivate, checkTypeList: list }).then(res => { const obj = {
isPrivate: isPrivate,
checkTypeList: list
}
// 预约外部服务的时候,根据当前地区地址查询
if (isPrivate === '0') {
obj.serviceArea = this.currentHospital.addressCode
}
deviceUseInSubscribeList(obj).then(res => {
console.log('设备下拉框', res) console.log('设备下拉框', res)
this.selectableDevice = res.data this.selectableDevice = res.data
}) })
...@@ -645,6 +677,7 @@ export default { ...@@ -645,6 +677,7 @@ export default {
} else if (row.checkType === '0') { } else if (row.checkType === '0') {
this.deviceQueryParams.isPrivate = '1' this.deviceQueryParams.isPrivate = '1'
} }
this.deviceQueryParams.serviceArea = this.currentHospital.addressCode
this.deviceQueryParams.checkTypeList.push(row.checkItemsId) this.deviceQueryParams.checkTypeList.push(row.checkItemsId)
this.deviceQueryParams.checkTypeList = [...new Set(this.deviceQueryParams.checkTypeList)] this.deviceQueryParams.checkTypeList = [...new Set(this.deviceQueryParams.checkTypeList)]
this.deviceQueryParams.reservationTime = this.getCurrentTime() this.deviceQueryParams.reservationTime = this.getCurrentTime()
......
...@@ -187,7 +187,7 @@ ...@@ -187,7 +187,7 @@
@click="handleDetails(scope.row)" @click="handleDetails(scope.row)"
>详情</el-button> >详情</el-button>
<el-button <el-button
v-if="scope.row.treatSchedule==='1'&&scope.row.payType==='1'" v-if="scope.row.treatSchedule === '1' && scope.row.payType === '1' && scope.row.payType === '2'"
class="bookNow" class="bookNow"
size="mini" size="mini"
icon="el-icon-orange" icon="el-icon-orange"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment