Commit 9e049834 authored by 王飞龙's avatar 王飞龙

Merge remote-tracking branch 'origin/master'

parents d0620876 3bbb8d0e
......@@ -51,4 +51,22 @@ export function timeRegister(params) {
params: params
})
}
// 打开开具处方
export function queryPrescribing(data) {
return request({
url: '/business/record/prescribing',
method: 'post',
data: data
})
}
/**
* 检查宠物是否有重复
*/
export function checkPet(data) {
return request({
url: '/business/register/checkPet',
method: 'post',
data: data
})
}
......@@ -79,8 +79,8 @@
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getContract"
style="margin: 0 50px 0 0"
@pagination="getContract"
/>
</div>
</template>
......
......@@ -35,7 +35,7 @@
<el-row>
<el-col :span="8">
<el-form-item label="宠物性别">
<span>{{ checkDetail.petSex === '0' ? '公' : (checkDetail.petSex === '1' ? '母' : '未知')}}</span>
<span>{{ checkDetail.petSex === '0' ? '公' : (checkDetail.petSex === '1' ? '母' : '未知') }}</span>
</el-form-item>
</el-col>
<el-col :span="8">
......@@ -45,7 +45,7 @@
</el-col>
<el-col :span="8">
<el-form-item label="宠物体重">
<span>{{ checkDetail.petWeight + 'kg'}}</span>
<span>{{ checkDetail.petWeight + 'kg' }}</span>
</el-form-item>
</el-col>
</el-row>
......@@ -160,7 +160,7 @@
<div class="title-paragraph">
<span class="title-text">检查信息</span>
</div>
<el-button class="fourWordsBtn" v-show="checkDetail.checkSchedule >=2 && checkDetail.reportTime === null">上传报告</el-button>
<el-button v-show="checkDetail.checkSchedule >=2 && checkDetail.reportTime === null" class="fourWordsBtn">上传报告</el-button>
<!-- 检查信息 -->
<el-row>
<el-col :span="8">
......
......@@ -95,6 +95,9 @@ export default {
},
data() {
return {
chooseForm: {
petStatus: ''
},
// 选中数据
chooseData: {},
// 总条数
......@@ -147,6 +150,7 @@ export default {
choosePet() {
this.$emit('petChoose', this.chooseData)
this.$emit('petModleClose', false)
this.form.petStatus = '1'
},
closeModle() {
this.$emit('petModleClose', false)
......
......@@ -5,7 +5,7 @@
<div v-if="docList.length>0" class="doctor-card">
<!--标签-->
<div class="progress-tip">
<div class="tip-green"/>
<div class="tip-green" />
<div
class="tip-content"
>挂号信息
......@@ -53,7 +53,7 @@
</div>
</div>
<!--分割线-->
<div class="divider"/>
<div class="divider" />
<!--卡片中间部分-->
<div class="mid-bottom-framework">
<div
......@@ -111,7 +111,7 @@
>
<div class="detail" @click="doctorDetail(item.id)">
<div class="detail-img">
<el-image :src="require('@/assets/register/xinzengguahao_xiangqing@2x.png')"/>
<el-image :src="require('@/assets/register/xinzengguahao_xiangqing@2x.png')" />
</div>
<el-button
type="text"
......@@ -121,14 +121,14 @@
<!--给它传一个userId,一个类型和一个默认页数-->
<div class="register" @click="registration(item.userId,'0',item)">
<div class="register-img">
<el-image :src="require('@/assets/register/xinzengguahao_guahaohui@2x.png')"/>
<el-image :src="require('@/assets/register/xinzengguahao_guahaohui@2x.png')" />
</div>
<el-button type="text">挂号</el-button>
</div>
<!--给它传一个userId,一个类型和一个默认页数-->
<div class="add" @click="registration(item.userId, '1',item)">
<div class="add-img">
<el-image :src="require('@/assets/register/xinzengguahao_jiahao@2x.png')"/>
<el-image :src="require('@/assets/register/xinzengguahao_jiahao@2x.png')" />
</div>
<el-button type="text">加号</el-button>
</div>
......@@ -137,7 +137,27 @@
</el-card>
</div>
</div>
<div v-else>-</div>
<div v-else class="doctor-card">
<!--标签-->
<div class="progress-tip">
<div class="tip-green" />
<div
class="tip-content"
>挂号信息
</div>
</div>
<!-- 详细内容-->
<div>
<div style=" margin: 20px; height: 200px; border: 1px solid #d6d7d7;">
<div style="margin-left:45%;margin-top: 5%;">
<div style=" width:50px;height: 50px;">
<el-image :src="require('@/assets/register/zanwushuju.png')" />
</div>
<div style="color: #b2b2b2">暂无数据</div>
</div>
</div>
</div>
</div>
</div>
</template>
......
......@@ -38,7 +38,11 @@
row-key="id"
@selection-change="handleSelectionChange"
>
<el-table-column align="center" label="日期" min-width="80" prop="workDate" show-overflow-tooltip />
<el-table-column align="center" label="日期" min-width="80" prop="workDate" show-overflow-tooltip>
<template slot-scope="scope">
<span>{{ parseTime(scope.row.workDate, '{y}/{m}/{d}') }}</span>
</template>
</el-table-column>
<el-table-column align="center" label="时段" min-width="80" prop="hours" show-overflow-tooltip />
<el-table-column align="center" label="总放号数" min-width="80" prop="allCount" show-overflow-tooltip />
<el-table-column align="center" label="剩余号数" min-width="80" prop="residueCount" show-overflow-tooltip />
......@@ -77,7 +81,7 @@
</template>
<script>
import { timeRegister } from '@/api/business/register'
import { addRegister, timeRegister } from '@/api/business/register'
export default {
name: 'RegisterModle',
......@@ -98,6 +102,14 @@ export default {
doctorForm: {
type: Object
},
// 医生选择
doctorChoose: {
type: Object
},
// 宠物选择
petChoose: {
type: Object
},
singleDoctor: {
type: Object
}
......@@ -154,65 +166,65 @@ export default {
console.log('这是弹窗本身的行信息:', data)
console.log('这是宠物宠主本身的信息:', this.doctorForm)
console.log('这是当日挂号列表信息 :', this.singleDoctor)
data.visitWay = '0'
data.visitFirstTime = ''
data.payStatus = '0'
data.petPicture = ''
// 进度
data.checkSchedule = '0'
data.payAmount = ''
data.payType = '0'
const temp = {
type: this.registrationType,
// 宠物宠主本身的信息
petsId: this.doctorForm.petsId,
petOwnersId: this.doctorForm.ownersId,
petsId: null,
petType: this.doctorForm.petStatus,
petOwnersId: this.doctorForm.ownerId,
ownersId: this.doctorForm.ownersId,
petOwnersName: this.doctorForm.nickName,
petOwnersPhone: this.doctorForm.phoneNumber,
petNickname: this.doctorForm.petNickname,
petBreed: this.doctorForm.petBreed,
petSex: this.doctorForm.petSex,
petAge: this.doctorForm.petBrithday,
petBirthday: this.doctorForm.petBirthday.replaceAll('-', '/'),
petWeight: this.doctorForm.petWeight,
petColor: this.doctorForm.petColor,
sterilizationStatus: this.doctorForm.sterilizationStatus,
vaccineSituation: this.doctorForm.vaccineSituation,
insure: this.doctorForm.insure,
// 进度
checkSchedule: data.checkSchedule,
payAmount: data.payAmount,
payType: data.payType,
visitDateTime: this.doctorForm.visitDateTime,
checkSchedule: '0',
payAmount: null,
payType: '0',
// 这是当日挂号列表信息
doctorId: this.singleDoctor.doctorCode,
userId: this.singleDoctor.userId,
doctorName: this.singleDoctor.doctorName,
hospitalId: this.singleDoctor.deptId,
hospitalName: this.singleDoctor.deptName,
hospitalDepartmentId: this.singleDoctor.departmentId,
hospitalDepartmentName: this.singleDoctor.departmentName,
doctorPhone: this.singleDoctor.doctorPhone,
// 给传0
visitWay: data.visitWay,
visitWay: '0',
// 下拉传值
firstVisit: this.queryParams.firstVisit,
visitDate: data.workDate,
visitTime: data.hours,
scheduleId: data.scheduleId,
// 拼接 (日期+时间段的第一个时间)
visitFirstTime: data.visitFirstTime,
visitFirstTime: data.workDate.replaceAll('/', '-') + ' ' + data.hours.split('~')[0],
// 默认是0代缴费
payStatus: data.payStatus,
payStatus: '0',
// 给传个null
petPicture: data.petPicture,
petPicture: null,
doctorSignatureUrl: this.singleDoctor.doctorSignatureUrl,
visitLocation: this.singleDoctor.visitLocation,
doctorTitleLabel: this.singleDoctor.doctorTitleValue
}
console.log('终极大表', temp)
addRegister(temp).then(response => {
this.$message({
type: 'success',
message: '预约成功!'
})
this.$emit('registerModleClose', false)
})
},
submit() {
},
/** 关闭弹窗*/
......
......@@ -157,8 +157,7 @@
style="width: 70px; border-radius: 6px 6px 6px 6px;border: 1px solid rgb(255,157,78);"
type="warning"
@click="handleDetail(scope.row, 'enter')"
>
</el-button>
/>
</template>
</el-table-column>
</el-table>
......@@ -281,7 +280,7 @@
</template>
<script>
import { listRegister, getRegister, delRegister, addRegister, updateRegister } from '@/api/business/register'
import { listRegister, getRegister, delRegister, addRegister, updateRegister, checkPet } from '@/api/business/register'
import { listAllArticle } from '@/api/business/article'
export default {
......@@ -602,9 +601,27 @@ export default {
this.reset()
// TODO: 请清除该行输出
console.log(`row`, row)
this.$router.push({
name: 'RegistrationDetail', params: { id: row.id, type }
})
if (type === 'detail') {
this.$router.push({
name: 'RegistrationDetail', params: { id: row.id, type }
})
} else {
// 进入挂号页面先获取是否有重复的宠物数据
checkPet(row).then(({ msg }) => {
if (msg) {
this.$modal.confirm('当前宠物已经存在是否覆盖数据')
.then(_ => {
this.$router.push({
name: 'RegistrationDetail', params: { id: row.id, type }
})
})
} else {
this.$router.push({
name: 'RegistrationDetail', params: { id: row.id, type }
})
}
})
}
}
}
......
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