Compare commits

...

2 Commits

Author SHA1 Message Date
zdnpc 3c86af5f53 病案 2 years ago
Recoding a953fbf08e Initial commit 2 years ago
  1. 14
      .gitignore
  2. 3
      .vscode/settings.json
  3. 3
      README.md
  4. 2
      src/components/patient/select-patient-date.vue
  5. 8
      src/config/axios-config.js
  6. 329
      src/views/medical-record/medical-record-apply.vue
  7. 213
      src/views/medical-record/medical-record-history.vue

14
.gitignore vendored

@ -1 +1,15 @@
<<<<<<< HEAD
# ---> Vue
# gitignore template for Vue.js projects
#
# Recommended template: Node.gitignore
# TODO: where does this rule come from?
docs/_book
# TODO: where does this rule come from?
test/
=======
.DS_Store .DS_Store
>>>>>>> 138ef2bd84a1ed677008ac49aa7a4a953d9a8f25

@ -0,0 +1,3 @@
{
"liveServer.settings.port": 5501
}

@ -0,0 +1,3 @@
# wxUI
微信公众号前端模版

@ -658,7 +658,7 @@ export default {
width: 100%; width: 100%;
} }
.date__box--right { .date__box--right {
width: 78px; width: 78px;
display: flex; display: flex;
align-items: center; align-items: center;

@ -8,7 +8,7 @@ const Axios = (function (Axios, store) {
const RUN_ENV = HOST_NAME === '127.0.0.1' || HOST_NAME === 'localhost' ? 'development' : 'production' const RUN_ENV = HOST_NAME === '127.0.0.1' || HOST_NAME === 'localhost' ? 'development' : 'production'
// 请求路径配置 // 请求路径配置
const baseUrl = RUN_ENV === 'development' ? 'http://www.lclhzzzxdermyy.cn/' : '' const baseUrl = RUN_ENV === 'development' ? 'http://192.168.12.102:8080/' : ''
// 模板请求路径 // 模板请求路径
console.warn('==========当前运行环境:' + RUN_ENV + '==========' + (RUN_ENV === 'development' ? '(注意测试数据的影响)' : '')) console.warn('==========当前运行环境:' + RUN_ENV + '==========' + (RUN_ENV === 'development' ? '(注意测试数据的影响)' : ''))
@ -282,7 +282,7 @@ const Axios = (function (Axios, store) {
{ {
id: 0, id: 0,
openid: 'oeso-t62kkoRwLVVkSkwmmjPfUXk', openid: 'oeso-t62kkoRwLVVkSkwmmjPfUXk',
patientId: '60428633',// 12 - 17 patientId: '1442',// 12 - 17
name: '蒙自测试', name: '蒙自测试',
sex: '男', sex: '男',
age: '10岁', age: '10岁',
@ -292,7 +292,7 @@ const Axios = (function (Axios, store) {
address: '云南', address: '云南',
uuid: null uuid: null
}, },
{ {
id: 0, id: 0,
@ -430,7 +430,7 @@ const Axios = (function (Axios, store) {
// winDiv.innerHTML = '<section id=oauth_view style="top:0;bottom:0;transition:.22s all ease;background:rgb(0,0,0,.5);height:100vh;width:100vw;z-index:100;position:fixed"><div style="transition:.22s all ease;position:fixed;box-sizing:border-box;bottom:0;width:100%;height:200px;background-color:#fff;border-radius:9px 9px 0 0;box-shadow:2px 2px 8px rgba(0,0,0,.1);padding:30px 16px"id=oauth_view_card><div style=display:flex;align-items:center><span style=display:flex;align-items:center><svg class=icon height=20 p-id=3319 style="padding:5px;border:1px solid #efeaea;border-radius:50%;border-right:none;border-top:none;box-shadow:2px 2px 12px rgb(0,0,0,.1)"t=1666790518761 version=1.1 viewBox="0 0 1024 1024"width=20 xmlns=http://www.w3.org/2000/svg><path d="M917.9 375.9L716.5 140.7a35.35 35.35 0 0 0-26.8-12.3H333.9c-10.4 0-20.2 4.5-26.9 12.4L107.2 376c-10.8 12.7-11.2 31.4-1 44.5l377.7 485.3c6.7 8.6 16.9 13.6 27.8 13.6 10.9 0 21.1-4.9 27.8-13.6l379.3-485.3c10.4-13.1 9.9-31.9-0.9-44.6zM495.4 696.8l-169-281.4c-3.6-6-10.1-9.7-17.1-9.7h-32.7c-11 0-20-9-20-20v-24.4c0-11 9-20 20-20h96.1c7.2 0 13.8 3.9 17.4 10.1l123.1 217c7.5 13.1 26.2 13.6 34.3 0.8l138.4-218.7c3.7-5.8 10-9.3 16.9-9.3h45.9c11 0 20 9 20 20v24.4c0 11-9 20-20 20H716c-7 0-13.5 3.7-17.1 9.7L529.7 696.8c-7.7 12.9-26.5 12.9-34.3 0z m399.8-294.7L527.7 872.3l311.5-459.1c5.2-6.7 5-16.2-0.5-22.6L661.4 226.9c-3.4-4-8.3-6.2-13.6-6.2H334.7c-5.2 0-10.2 2.3-13.6 6.3l-168 141.4 176.8-208.2c1-1.2 2.5-1.9 4-1.9h355.8c1.5 0 3 0.7 4 1.8l201.4 235.3c1.6 2 1.7 4.8 0.1 6.7z"fill=#2680F0 p-id=3320></path><path d="M698.8 415.4c3.6-6 10.1-9.7 17.1-9.7h32.7c11 0 20-9 20-20v-24.4c0-11-9-20-20-20h-45.9c-6.9 0-13.2 3.5-16.9 9.3L547.4 569.3c-8.1 12.8-26.8 12.3-34.3-0.8L390 351.4c-3.6-6.3-10.2-10.1-17.4-10.1h-96.1c-11 0-20 9-20 20v24.4c0 11 9 20 20 20h32.7c7 0 13.5 3.7 17.1 9.7l169.1 281.4c7.8 12.9 26.5 12.9 34.3 0l169.1-281.4z"fill=#FFFFFF p-id=3321></path></svg> <span style=margin-left:6px>公众号</span> </span><span style=margin-left:.5em>申请</span></div><div style="padding:15px 6px;font-size:14px;border-bottom:1px solid #f2f6fc">获取你的昵称、头像</div><div style=display:flex;align-items:center;justify-content:center;margin-top:30px><button id=oauth_btn_cancel style="background:#f2f2f2;color:#58be6b;font-size:16px;border:none;border-radius:6px;height:36px;width:108px;box-shadow:2px 2px 6px rgba(0,0,0,.05)">取消</button> <button id=oauth_btn_ok style="margin-left:20px;background:#58be6b;color:#fff;font-size:16px;border:none;border-radius:6px;height:36px;width:108px;box-shadow:2px 2px 6px rgba(0,0,0,.1)">允许</button></div></div></section>' // winDiv.innerHTML = '<section id=oauth_view style="top:0;bottom:0;transition:.22s all ease;background:rgb(0,0,0,.5);height:100vh;width:100vw;z-index:100;position:fixed"><div style="transition:.22s all ease;position:fixed;box-sizing:border-box;bottom:0;width:100%;height:200px;background-color:#fff;border-radius:9px 9px 0 0;box-shadow:2px 2px 8px rgba(0,0,0,.1);padding:30px 16px"id=oauth_view_card><div style=display:flex;align-items:center><span style=display:flex;align-items:center><svg class=icon height=20 p-id=3319 style="padding:5px;border:1px solid #efeaea;border-radius:50%;border-right:none;border-top:none;box-shadow:2px 2px 12px rgb(0,0,0,.1)"t=1666790518761 version=1.1 viewBox="0 0 1024 1024"width=20 xmlns=http://www.w3.org/2000/svg><path d="M917.9 375.9L716.5 140.7a35.35 35.35 0 0 0-26.8-12.3H333.9c-10.4 0-20.2 4.5-26.9 12.4L107.2 376c-10.8 12.7-11.2 31.4-1 44.5l377.7 485.3c6.7 8.6 16.9 13.6 27.8 13.6 10.9 0 21.1-4.9 27.8-13.6l379.3-485.3c10.4-13.1 9.9-31.9-0.9-44.6zM495.4 696.8l-169-281.4c-3.6-6-10.1-9.7-17.1-9.7h-32.7c-11 0-20-9-20-20v-24.4c0-11 9-20 20-20h96.1c7.2 0 13.8 3.9 17.4 10.1l123.1 217c7.5 13.1 26.2 13.6 34.3 0.8l138.4-218.7c3.7-5.8 10-9.3 16.9-9.3h45.9c11 0 20 9 20 20v24.4c0 11-9 20-20 20H716c-7 0-13.5 3.7-17.1 9.7L529.7 696.8c-7.7 12.9-26.5 12.9-34.3 0z m399.8-294.7L527.7 872.3l311.5-459.1c5.2-6.7 5-16.2-0.5-22.6L661.4 226.9c-3.4-4-8.3-6.2-13.6-6.2H334.7c-5.2 0-10.2 2.3-13.6 6.3l-168 141.4 176.8-208.2c1-1.2 2.5-1.9 4-1.9h355.8c1.5 0 3 0.7 4 1.8l201.4 235.3c1.6 2 1.7 4.8 0.1 6.7z"fill=#2680F0 p-id=3320></path><path d="M698.8 415.4c3.6-6 10.1-9.7 17.1-9.7h32.7c11 0 20-9 20-20v-24.4c0-11-9-20-20-20h-45.9c-6.9 0-13.2 3.5-16.9 9.3L547.4 569.3c-8.1 12.8-26.8 12.3-34.3-0.8L390 351.4c-3.6-6.3-10.2-10.1-17.4-10.1h-96.1c-11 0-20 9-20 20v24.4c0 11 9 20 20 20h32.7c7 0 13.5 3.7 17.1 9.7l169.1 281.4c7.8 12.9 26.5 12.9 34.3 0l169.1-281.4z"fill=#FFFFFF p-id=3321></path></svg> <span style=margin-left:6px>公众号</span> </span><span style=margin-left:.5em>申请</span></div><div style="padding:15px 6px;font-size:14px;border-bottom:1px solid #f2f6fc">获取你的昵称、头像</div><div style=display:flex;align-items:center;justify-content:center;margin-top:30px><button id=oauth_btn_cancel style="background:#f2f2f2;color:#58be6b;font-size:16px;border:none;border-radius:6px;height:36px;width:108px;box-shadow:2px 2px 6px rgba(0,0,0,.05)">取消</button> <button id=oauth_btn_ok style="margin-left:20px;background:#58be6b;color:#fff;font-size:16px;border:none;border-radius:6px;height:36px;width:108px;box-shadow:2px 2px 6px rgba(0,0,0,.1)">允许</button></div></div></section>'
// var btnOk = winDiv.querySelector('#oauth_btn_ok') // var btnOk = winDiv.querySelector('#oauth_btn_ok')
// btnOk.onclick = function () { // btnOk.onclick = function () {
// var oauth_view_card = winDiv.querySelector('#oauth_view_card') // var oauth_view_card = <winDiv className="querySe"></winDiv>lector('#oauth_view_card')
// oauth_view_card.style.bottom = '-200px' // oauth_view_card.style.bottom = '-200px'
// var oauth_view = winDiv.querySelector('#oauth_view') // var oauth_view = winDiv.querySelector('#oauth_view')

@ -1,12 +1,15 @@
<template> <template>
<div class="ptint-revserve"> <div class="ptint-reserve">
<nav-header></nav-header> <select-patient-date :show-code="false"
:days="0"
:show-navbar="false"
:show-date="false"></select-patient-date>
<div style="margin: 5px;"> <div style="margin: 5px;">
<van-form ref="formRef" <van-form ref="formRef"
error-message-align="right"> error-message-align="right">
<van-cell-group title="" <van-cell-group title=""
insert> insert>
<van-field v-model="form.ispID" <van-field v-model="form.ipsID"
label="住院号" label="住院号"
is-link is-link
readonly readonly
@ -26,11 +29,11 @@
placeholder="选择住院记录"></van-field> placeholder="选择住院记录"></van-field>
<van-field v-model="form.deptName" <van-field v-model="form.deptName"
label="出院科室" label="出院科室"
readonly
required required
placeholder="选择住院记录"></van-field> placeholder="选择住院记录"></van-field>
<van-field v-model="form.ptIdcID" <van-field v-model="form.showCardNo"
required required
readonly
label="身份证" label="身份证"
placeholder="身份证号" placeholder="身份证号"
:rules="[{required: true, message: '请输入身份证号', trigger: 'onSubmit'}]"></van-field> :rules="[{required: true, message: '请输入身份证号', trigger: 'onSubmit'}]"></van-field>
@ -66,17 +69,27 @@
placeholder="邮寄地址" placeholder="邮寄地址"
:rules="[{required: true, message: '请输入邮寄地址', trigger: 'onSubmit'}]"></van-field> :rules="[{required: true, message: '请输入邮寄地址', trigger: 'onSubmit'}]"></van-field>
<van-field v-model="form.useWay" <van-field v-model="form.useWay"
label="模板"></van-field> readonly
required
is-link
label="用途"
placeholder="点击选择翻拍用途"
@click="state.templateShow = true"></van-field>
</van-cell-group> </van-cell-group>
<van-cell-group title="" <van-cell-group title=""
insert insert
style="margin-top: 5px;"> style="margin-top: 5px;">
<div class="img_item"> <div class="img_item">
<div class="img_item_label"><span style="color: red;">*</span>本人身份证正面照片</div> <div class="img_item_label">
<section>
<span style="color: red;">*</span>本人身份证正面照片
</section>
</div>
<div class="img_item_upload"> <div class="img_item_upload">
<van-uploader v-model="form.ptImg1" <van-uploader v-model="state.img.ptImg1"
style="width: 100%;height: 100%;" style="width: 100%;height: 100%;"
:max-count="1"> :max-count="1"
:after-read="(file) => afterRead(file, 'ptImg1')">
<div style="height: 100%;display: flex;flex-direction: column;align-items: center;justify-content: center;"> <div style="height: 100%;display: flex;flex-direction: column;align-items: center;justify-content: center;">
<svg t="1685244688694" <svg t="1685244688694"
class="icon" class="icon"
@ -99,11 +112,16 @@
</div> </div>
<div class="img_item"> <div class="img_item">
<div class="img_item_label"><span style="color: red;">*</span>本人身份证背面照片</div> <div class="img_item_label">
<section>
<span style="color: red;">*</span>本人身份证背面照片
</section>
</div>
<div class="img_item_upload"> <div class="img_item_upload">
<van-uploader v-model="form.ptImg2" <van-uploader v-model="state.img.ptImg2"
style="width: 100%;height: 100%;" style="width: 100%;height: 100%;"
:max-count="1"> :max-count="1"
:after-read="(file) => afterRead(file, 'ptImg2')">
<div style="height: 100%;display: flex;flex-direction: column;align-items: center;justify-content: center;"> <div style="height: 100%;display: flex;flex-direction: column;align-items: center;justify-content: center;">
<svg t="1685244916978" <svg t="1685244916978"
class="icon" class="icon"
@ -124,13 +142,14 @@
<div v-if="state.imgBlankError.ptImg2" <div v-if="state.imgBlankError.ptImg2"
class="img__blank_error">请上传本人身份证背面照片</div> class="img__blank_error">请上传本人身份证背面照片</div>
</div> </div>
<!--
<div class="img_item"> <!-- <div class="img_item">
<div class="img_item_label"><span style="color: red;">*</span>申请人身份证正面照片</div> <div class="img_item_label"><span style="color: red;">*</span>申请人身份证正面照片</div>
<div class="img_item_upload"> <div class="img_item_upload">
<van-uploader v-model="form.applicantIdcImg1" <van-uploader v-model="state.img.applicantIdcImg1"
style="width: 100%;height: 100%;" style="width: 100%;height: 100%;"
:max-count="1"> :max-count="1"
:after-read="(file) => afterRead(file, 'applicantIdcImg1')">
<div style="height: 100%;display: flex;flex-direction: column;align-items: center;justify-content: center;"> <div style="height: 100%;display: flex;flex-direction: column;align-items: center;justify-content: center;">
<svg t="1685244688694" <svg t="1685244688694"
class="icon" class="icon"
@ -155,9 +174,10 @@
<div class="img_item"> <div class="img_item">
<div class="img_item_label"><span style="color: red;">*</span>申请人身份证背面照片</div> <div class="img_item_label"><span style="color: red;">*</span>申请人身份证背面照片</div>
<div class="img_item_upload"> <div class="img_item_upload">
<van-uploader v-model="form.applicantIdcImg2" <van-uploader v-model="state.img.applicantIdcImg2"
style="width: 100%;height: 100%;" style="width: 100%;height: 100%;"
:max-count="1"> :max-count="1"
:after-read="(file) => afterRead(file, 'applicantIdcImg2')">
<div style="height: 100%; display: flex;flex-direction: column;align-items: center;justify-content: center;"> <div style="height: 100%; display: flex;flex-direction: column;align-items: center;justify-content: center;">
<svg t="1685244916978" <svg t="1685244916978"
class="icon" class="icon"
@ -180,11 +200,56 @@
</div> --> </div> -->
<div class="img_item"> <div class="img_item">
<div class="img_item_label"><span style="color: red;">*</span>申请书照片</div> <div class="img_item_label">
<section style="width: 60px;">
<span style="color: red;">*</span>住院证
</section>
</div>
<div class="img_item_upload">
<van-uploader v-model="state.img.applyImg"
style="width: 100%;height: 100%;"
:max-count="1"
:after-read="(file) => afterRead(file, 'applyImg')">
<div style="height: 100%; display: flex;flex-direction: column;align-items: center;justify-content: center;">
<svg t="1686896283841"
class="icon"
viewBox="0 0 1024 1024"
version="1.1"
xmlns="http://www.w3.org/2000/svg"
p-id="4962"
width="64"
height="64">
<path d="M230.4 364.8z m38.4-32c22.4 0 41.6-19.2 41.6-41.6V179.2c0-22.4-19.2-41.6-41.6-41.6-22.4 0-41.6 19.2-41.6 41.6v112c3.2 22.4 19.2 41.6 41.6 41.6zM928 265.6c-3.2-57.6-48-48-48-48h-32v96s-6.4 48-48 48h-80c-41.6 0-48-48-48-48v-96h-310.4v96s-6.4 48-48 48H230.4c-41.6 0-48-48-48-48v-96h-32s-44.8-9.6-48 48v560c0 57.6 57.6 57.6 57.6 57.6h713.6s57.6 0 57.6-57.6V268.8s-3.2 0-3.2-3.2zM515.2 764.8c0 44.8-83.2 54.4-160 54.4S192 809.6 192 764.8v-12.8c0-32 57.6-64 105.6-83.2 3.2 0 19.2-9.6 9.6-35.2-25.6-25.6-41.6-64-41.6-105.6 0-60.8 38.4-92.8 86.4-92.8s86.4 32 86.4 92.8c0 38.4-19.2 80-41.6 105.6-9.6 28.8 6.4 35.2 6.4 35.2 51.2 16 108.8 48 108.8 83.2 3.2 3.2 3.2 12.8 3.2 12.8z m291.2-12.8h-163.2c-22.4 0-41.6-19.2-41.6-41.6 0-22.4 19.2-41.6 41.6-41.6h163.2c22.4 0 41.6 19.2 41.6 41.6 0 25.6-19.2 41.6-41.6 41.6z m0-160h-163.2c-22.4 0-41.6-19.2-41.6-41.6 0-22.4 19.2-41.6 41.6-41.6h163.2c22.4 0 41.6 19.2 41.6 41.6s-19.2 41.6-41.6 41.6z m-6.4-227.2z m-41.6-32c22.4 0 41.6-19.2 41.6-41.6V179.2c0-22.4-19.2-41.6-41.6-41.6-22.4 0-41.6 19.2-41.6 41.6v112c0 22.4 19.2 41.6 41.6 41.6z"
fill="#dbdbdb"
p-id="4963"></path>
</svg>
<span>点击选择照片或拍照</span>
</div>
</van-uploader>
</div>
<div v-if="state.imgBlankError.applyImg"
class="img__blank_error">请上传住院证照片</div>
</div>
<!-- <div class="img_item">
<div class="img_item_label">
<section>
<span style="color: red;">*</span>申请书照片
</section>
<div style="width: calc(100% - 80px);display: flex;flex-direction: row;justify-content: flex-end;flex-wrap: nowrap;font-size: 13px;">
<div style="margin-right: 10px;">
<a href=""
style="color: var(--color-primary);border-bottom: 1px solid var(--color-primary);">下载模板</a>
</div>
<div style="background-color: var(--color-primary);width: 45px;line-height: 24px;text-align: center;border-radius: 4px;color: #fff;"
@click.stop="onExample">示例</div>
</div>
</div>
<div class="img_item_upload"> <div class="img_item_upload">
<van-uploader v-model="form.agreementLetterImg" <van-uploader v-model="state.img.agreementLetterImg"
style="width: 100%;height: 100%;" style="width: 100%;height: 100%;"
:max-count="1"> :max-count="1"
:after-read="(file) => afterRead(file, 'agreementLetterImg')">
<div style="height: 100%; display: flex;flex-direction: column;align-items: center;justify-content: center;"> <div style="height: 100%; display: flex;flex-direction: column;align-items: center;justify-content: center;">
<svg t="1685250803648" <svg t="1685250803648"
class="icon" class="icon"
@ -210,7 +275,7 @@
</div> </div>
<div v-if="state.imgBlankError.agreementLetterImg" <div v-if="state.imgBlankError.agreementLetterImg"
class="img__blank_error">请上传申请书照片</div> class="img__blank_error">请上传申请书照片</div>
</div> </div> -->
</van-cell-group> </van-cell-group>
<div class="footer"> <div class="footer">
<van-button type="primary" <van-button type="primary"
@ -248,19 +313,16 @@
<div class="treat_cont"> <div class="treat_cont">
<template v-if="state.treatRecord.length > 0"> <template v-if="state.treatRecord.length > 0">
<section v-for="item in state.treatRecord" <section v-for="item in state.treatRecord"
:key="item.mzNum"> :key="item.ipsId">
<div class="cont_item" <div class="cont_item"
:class="[treat.mzNum === item.mzNum ? 'border_click' : 'border_default']" :class="[state.currTreat.ipsId === item.ipsId ? 'border_click' : 'border_default']"
@click="onClickTreat(item)"> @click="state.currTreat = item">
<div><span>&emsp;&emsp;</span><span>{{ item.registerDate }}</span></div> <div><span>患者姓名</span><span>{{ item.ptName }}&emsp;&emsp;{{ item.ptId }}</span></div>
<div><span>患者姓名</span><span>{{ item.patientName }}&emsp;&emsp;{{ item.patientId }}</span></div> <div><span>住院编号</span><span>{{ item.ipsId }}</span></div>
<div><span>住院编号</span><span>{{ item.mzNum }}</span></div> <div><span>出院科室</span><span>{{ item.deptName }}</span></div>
<div><span>&emsp;&emsp;</span><span>{{ item.complaint }}</span></div> <div><span>&emsp;&emsp;</span><span>{{ item.dx }}</span></div>
<div><span>医生姓名</span><span>{{ item.doctName }}</span></div>
<div><span>西医诊断</span><span>{{ item.diagnose }}</span></div>
<div><span>中医诊断</span><span>{{ item.diagnoseZY }}</span></div>
<div class="item_checked" <div class="item_checked"
v-if="treat.mzNum === item.mzNum"> v-if="state.currTreat.ipsId === item.ipsId">
<van-icon name="passed" <van-icon name="passed"
color="var(--color-primary)" color="var(--color-primary)"
size="20" /> size="20" />
@ -274,17 +336,38 @@
</div> </div>
</div> </div>
</van-popup> </van-popup>
<!-- 模板 -->
<van-popup v-model:show="state.templateShow"
round
lock-scroll
position="bottom">
<!-- :columns-field-names="{text: 'templatename'}" -->
<van-picker title="用 途"
:columns="state.templateList"
value-key="templateno"
@confirm="onTemplateConfirm"
@cancel="state.templateShow = false">
<template #option="option">
<div style="margin: 5px 0;overflow: hidden">
<div style="text-align: center;padding:8px 0 0;">{{ option.Borrow_UseTo_Name }}</div>
</div>
</template>
</van-picker>
</van-popup>
</div> </div>
</template> </template>
<script> <script>
import { reactive, ref } from 'vue'; import { reactive, ref, watch } from 'vue';
import { useRoute, useRouter } from 'vue-router'; import { useRoute, useRouter } from 'vue-router';
import { axios } from 'axios' import { axios } from 'axios'
import { store } from 'vue-helper'
import ImageUtil from '@/utils/image-util.mjs'
export default { export default {
name: 'ptint-revserve', name: 'ptint-reserve',
component: { components: {
'nav-header': VueConfig.vueLoader('@/components/tab-router.vue') 'select-patient-date': VueConfig.vueLoader('@/components/patient/select-patient-date.vue')
}, },
setup(props, context) { setup(props, context) {
const route = useRoute(); const route = useRoute();
@ -299,9 +382,6 @@ export default {
}, { }, {
code: '1', code: '1',
label: '邮寄' label: '邮寄'
}, {
code: '2',
label: '电子版'
} }
], ],
getWayColumnFieldName: { // getWayColumnFieldName: { //
@ -309,16 +389,29 @@ export default {
}, },
ispShow: false, // ispShow: false, //
treatRecord: [], // treatRecord: [], //
currTreat: '', //
imgBlankError: { // imgBlankError: { //
ptImg1: false, ptImg1: false,
ptImg2: false, ptImg2: false,
applicantIdcImg1: false, // applicantIdcImg1: false,
applicantIdcImg2: false, // applicantIdcImg2: false,
agreementLetterImg: false // agreementLetterImg: false
} applyImg: false
},
img: {
ptImg1: [], //
ptImg2: [], //
applicantIdcImg1: [], //
applicantIdcImg2: [], //
agreementLetterImg: [], //
applyImg: [], //
},
templateShow: false, //
templateList: [], //
}) })
const form = reactive({
ispID: '', // const creatForm = () => ({
ipsID: '', //
dx: '', // dx: '', //
ptId: '', // ID ptId: '', // ID
ptName: '', // ptName: '', //
@ -329,37 +422,34 @@ export default {
applicantName: '', // applicantName: '', //
applicantRel: '', // applicantRel: '', //
applicantRelId: '', // applicantRelId: '', //
ptImg1: [], // ptImg1: '', //
ptImg2: [], // ptImg2: '', //
applicantIdcImg1: [], // applicantIdcImg1: '', //
applicantIdcImg2: [], // applicantIdcImg2: '', //
agreementLetterImg: [], // agreementLetterImg: '', //
useWay: '', // (templateName) useWay: '', // (templateName)
useWayId: '', // id (templateNo) useWayId: '', // id (templateNo)
getWay: '', // :0. 1. 2. getWay: '', // :0. 1. 2.
address: '' // address: '', //
applyImg: '', //
showCardNo: '', //
}) })
const form = reactive(creatForm())
const formLabel = reactive({ const formLabel = reactive({
getWayLabel: '' getWayLabel: ''
}) })
function getMedicalRecordList(){
axios.post('/wx/xbd/getMedicalRecordList',{patientId: patientId}).then((resp) => {
console.log(resp)
})
}
/** /**
* 判断照片是否上传 * 判断照片是否上传
*/ */
function isImgBlank() { function isImgBlank() {
let checked = 0 let checked = 0
Object.keys(state.imgBlankError).forEach(key => { Object.keys(state.imgBlankError).forEach(key => {
if (form[key].length === 0) { if (form[key] === '') {
checked++ checked++
state.imgBlankError[key] = true state.imgBlankError[key] = true
} else if (form[key].length > 0 && state.imgBlankError[key]) { } else if (form[key] !== '' && state.imgBlankError[key]) {
state.imgBlankError[key] = false state.imgBlankError[key] = false
} }
}) })
@ -370,6 +460,8 @@ export default {
* 提交预约 * 提交预约
*/ */
function onSubmit() { function onSubmit() {
patient.value = store.getters.getPatient
if (!patient.value || (patient.value && !patient.value.patientId)) return vant.Toast.fail('参数缺失,无法查询住院记录!')
formRef.value.validate().then(() => { formRef.value.validate().then(() => {
if (isImgBlank()) { if (isImgBlank()) {
return vant.Toast.fail('提交内容出现错误,请检查!') return vant.Toast.fail('提交内容出现错误,请检查!')
@ -378,8 +470,21 @@ export default {
title: '提示', title: '提示',
message: '确定提交打印预约申请?' message: '确定提交打印预约申请?'
}).then(() => { }).then(() => {
// /wx/xbd/addMRReserve const params = {
axios.post('/wx/xbd/addMRReserve', JSON.stringify(form)).then(response => { openId: patient.value.openid,
patientId: patient.value.patientId,
zyNum: form.ipsID,
applyName: form.ptName,
useToNo: form.useWayId,
useToName: form.useWay,
getWay: form.getWay,
address: form.address,
phone: form.phone,
ptImg1: form.ptImg1,
ptImg2: form.ptImg2,
applyImg: form.applyImg
}
axios.post('/wx/xbd/addMRReserve', params).then(response => {
if (response.code === 200) { if (response.code === 200) {
vant.Toast.success('预约成功') vant.Toast.success('预约成功')
} }
@ -397,7 +502,6 @@ export default {
* @param {Object} value 获取方式 * @param {Object} value 获取方式
*/ */
function onGetWayConfirm(value) { function onGetWayConfirm(value) {
console.log(value)
form.getWay = value.code form.getWay = value.code
formLabel.getWayLabel = value.label formLabel.getWayLabel = value.label
state.getWayShow = false state.getWayShow = false
@ -407,8 +511,84 @@ export default {
* 选择住院记录 * 选择住院记录
* @param {Object} value 住院记录 * @param {Object} value 住院记录
*/ */
function onIspConfirm(value) { function onIspConfirm() {
state.ispShow = false
if (state.currTreat) {
form.ipsID = state.currTreat.ipsId
form.ipsID = state.currTreat.ipsId
form.dx = state.currTreat.dx
form.ptId = state.currTreat.ptId
form.ptName = state.currTreat.ptName
form.deptID = state.currTreat.deptId
form.deptName = state.currTreat.deptName
form.ptIdcID = patient.value.idCardNo
form.showCardNo = patient.value.showCardNo
}
}
const patient = ref(null)
/**
* 获取住院记录
*/
function getMedicalRecordList() {
patient.value = store.getters.getPatient
const idCard = patient.value.idCardNo
patient.value.showCardNo = idCard.length === 18 ? idCard.substring(0, 3) + '********' + idCard.substring(idCard.length - 4) : idCard
if (!patient.value || (patient.value && !patient.value.patientId)) return vant.Toast.fail('患者参数缺失,无法查询住院记录!')
axios.RGet('wx/xbd/getMedicalRecordList', {
patientId: patient.value.patientId
}).then(response => {
if (response.code === 200) {
state.treatRecord = response.data
}
})
}
getMedicalRecordList()
/**
* 图片压缩赋值
* @param {File} file 图片
* @param {*} state 参数名
*/
function afterRead(file, state) {
ImageUtil.compressBySize(file.file, { isQuality: true }).then(res => {
form[state] = res.base64.includes(',') ? res.base64.split(',')[1] : ''
}).catch(error => {
console.log('error', error)
})
}
watch(() => state.ispShow, (newVal) => {
if (newVal && !form.ipsID) {
state.currTreat = ''
}
})
watch(() => store.getters.getPatient, () => {
getMedicalRecordList()
Object.assign(form, creatForm())
})
/**
* 获取模板
*/
function getTemplates() {
axios.RGet('wx/xbd/getMRTemplateList').then(response => {
if (response.code === 200) {
state.templateList = response.data
}
})
}
getTemplates()
function onTemplateConfirm(value) {
state.templateShow = false
form.useWayId = value.Borrow_UseTo_No
form.useWay = value.Borrow_UseTo_Name
}
function onExample() {
console.log('look example')
} }
return { return {
@ -419,13 +599,15 @@ export default {
onSubmit, onSubmit,
onGetWayConfirm, onGetWayConfirm,
onIspConfirm, onIspConfirm,
getMedicalRecordList afterRead,
onTemplateConfirm,
onExample
} }
}, },
} }
</script> </script>
<style scoped> <style scoped>
.ptint-revserve { .ptint-reserve {
} }
.img_item { .img_item {
border-bottom: 1px solid var(--border-c); border-bottom: 1px solid var(--border-c);
@ -434,6 +616,10 @@ export default {
line-height: 25px; line-height: 25px;
padding: 5px 16px; padding: 5px 16px;
color: #646566; color: #646566;
display: flex;
flex-direction: row;
justify-content: space-between;
align-items: center;
} }
.img_item_upload { .img_item_upload {
height: 150px; height: 150px;
@ -466,7 +652,7 @@ export default {
text-align: right; text-align: right;
padding: 0px 10px 5px; padding: 0px 10px 5px;
} }
.ptint-revserve >>> .van-field__control { .ptint-reserve >>> .van-field__control {
text-align: right; text-align: right;
} }
@ -520,8 +706,11 @@ export default {
overflow: hidden; overflow: hidden;
} }
.cont_item div {
padding: 3px 0px;
}
.cont_item div span:nth-child(1) { .cont_item div span:nth-child(1) {
color: var(--text-b); color: var(--text-c);
} }
.cont_item div span:nth-child(2) { .cont_item div span:nth-child(2) {
@ -547,4 +736,8 @@ export default {
.treat_filed >>> .van-field__control { .treat_filed >>> .van-field__control {
text-align: right; text-align: right;
} }
.ptint-reserve >>> .van-popup .van-picker .van-picker-column__item {
/* height: 50px !important; */
}
</style> </style>

@ -1,34 +1,201 @@
<template> <template>
<select-patient-date :show-code="false" <div class="history">
:days="0" <select-patient-date :show-code="false"
:show-navbar="false" :days="0"
:show-date="false"></select-patient-date> :show-navbar="false"
:show-date="false"></select-patient-date>
<section>
<section v-for="(item, k) in state.recordList"
:key="k"
:i="item.setup = getSetup(item)">
<div class="record_item">
<div style="height: 50px;margin-right: 40px;padding: 8px 8px 0px;">
<div style="margin: 5px 0;">
<span style="color: var(--text-c);">申请时间</span>{{ item.baBorrowOperDate }}
</div>
<div style="margin: 5px 0;">
<span style="color: var(--text-c);"> </span>{{ item.baBorrowApplyName }}
</div>
</div>
<div style="padding: 0 8px 8px;">
<div><span style="color: var(--text-c);line-height: 20px;"> </span>{{ item.zyNum }}</div>
<div><span style="color: var(--text-c);line-height: 20px;">&emsp;&emsp;</span>{{ item.baBorrowUsetoName }}</div>
<!-- <div><span style="color: var(--text-c);line-height: 20px;">住院科室</span>{{ item.deptName }}</div> -->
<div><span style="color: var(--text-c);line-height: 20px;">获取方式</span>{{ item.baBorrowGetway === 0?'自提': item.baBorrowGetway === 1?'邮寄': ''}}</div>
<div><span style="color: var(--text-c);line-height: 20px;">联系电话</span>{{ item.baBorrowPhone}}</div>
<div><span style="color: var(--text-c);line-height: 20px;">&emsp;&emsp;</span>{{ item.baBorrowAddress }}</div>
<div><span style="color: var(--text-c);line-height: 20px;">&emsp;&emsp;</span>{{ item.baBorrowNote }}</div>
<!-- <div><span style="color: var(--text-c);line-height: 20px;">&emsp;&emsp;</span>{{ item.pages }}</div> -->
<!-- <van-steps :active="item.setup">
<van-step>申请</van-step>
<van-step>审核</van-step>
<van-step>复印成功</van-step>
<van-step>完成</van-step>
</van-steps> -->
</div>
<div style="display: flex;flex-direction: row;justify-content: space-between;align-items: center;">
<!-- <div v-if="item.baBorrowIsApproved"
style="flex: 1;text-align: center;line-height: 35px;background-color: var(--color-success);color: #fdfdfd;padding: 0 5px 5px;margin-right: 2px;"
@click="toPay(item)">
&emsp;
</div> -->
<!-- <div style="flex: 1;text-align: center;line-height: 35px;background-color: var(--color-primary);color: #fdfdfd;padding: 0 5px 5px;"
@click="onOpenDetail(item)">
&emsp;
</div> -->
</div>
<div v-if="item.baBorrowIsApproved === null || item.baBorrowIsApproved === undefined"
class="recipe_tag">待审核</div>
<div v-else-if="item.baBorrowIsApproved"
class="recipe_tag"
style="background-color: var(--color-primary);color: #fff;">已审核</div>
<div v-else-if="!item.baBorrowIsApproved"
class="recipe_tag"
style="background-color: var(--color-danger);color: #fff;"> </div>
</div>
</section>
</section>
<van-popup v-model:show="state.show">
<div style="width: 82vw;max-height: 80vh;min-height: 300px;background-color: #fff;padding: 5px;">
<div style="padding: 5px 10px 8px;font-size: 15px;color: var(--text-a);text-align: center;">病案打印详情</div>
<div>
<van-steps :active="state.setup">
<van-step>申请</van-step>
<van-step>审核</van-step>
<van-step>复印成功</van-step>
<van-step>完成</van-step>
</van-steps>
</div>
</div>
</van-popup>
</div>
</template> </template>
<script> <script>
import { reactive } from 'vue' import { reactive, ref, watch } from 'vue'
import { route } from 'vue-helper' import { useRoute, useRouter } from 'vue-helper'
import { axios } from 'axios' import { axios } from 'axios'
import { SetView } from '@/utils/common-util.mjs'
import { store } from 'vue-helper' import { store } from 'vue-helper'
export default { export default {
components: { name: 'history',
'select-patient-date': VueConfig.vueLoader('@/components/patient/select-patient-date.vue') components: {
}, 'select-patient-date': VueConfig.vueLoader('@/components/patient/select-patient-date.vue')
},
setup(props) {
const biInfo = reactive({ setup(props) {
url: '', const state = reactive({
description: '' recordList: [], //
}) show: false, //
return { setup: 0
biInfo, })
}
} const mockData = [
{
id: 1,
ipsId: '123456789',
dx: '高血压',
ptId: '11111111',
ptName: '张三',
deptId: '0032',
deptName: '心血管医学中心',
ptIdcId: '111111111111111111',
phone: '15977775551',
applyerName: '',
applyerRel: '',
applyerRelId: '',
ptIdcImg1: '',
ptIdcImg2: '',
applyerIdcImg1: '',
applyerIdcImg2: '',
agreementLetterImg: '',
applyTime: '2023-06-01 12:12:00',
useway: '自用留存',
usewayId: 123,
getWay: '邮寄',
address: '云南省昆明市五华区荷塘月色8栋2单元102室',
expressInfo: '',
stateId: null,
noReviewNote: '',
pages: 15,
isPay: 0,
isPrint: 0,
statusId: null,
statusDate: null,
statusNote: ''
}
]
const patient = ref(null)
function getHistory() {
patient.value = store.getters.getPatient
if (!patient.value || (patient.value && !patient.value.patientId)) return vant.Toast.fail('患者参数缺失,无法查询翻拍记录!')
axios.RGet('wx/xbd/getMRHistory', {
patientId: patient.value.patientId,
}).then(response => {
if (response.code === 200) {
state.recordList = response.data
}
})
}
getHistory()
function onOpenDetail(item) {
// state.show = true
}
function toPay(item) {
}
function getSetup(item) {
if(!item.baBorrowOperDate) return 0
if(item.baBorrowIsApproved) return 1
if(item.baBorrowIsPrint) return 2
if(item.baBorrowIsPay) return 4
}
watch(() => store.getters.getPatient, () => {
getHistory()
})
return {
state,
onOpenDetail,
toPay,
getSetup
}
}
} }
</script> </script>
<style> <style scoped>
.history {
}
.record_item {
margin: 5px;
border: 1px solid var(--border-a);
border-radius: 5px;
font-size: 13px;
position: relative;
overflow: hidden;
background-color: #fff;
}
.recipe_tag {
text-align: center;
position: absolute;
background-color: grey;
color: #fff;
width: 100px;
height: 18px;
line-height: 18px;
top: 10px;
right: -30px;
transform: rotate(45deg);
font-size: 13px;
}
.history >>> .van-popup--center {
border-radius: 5px;
}
</style> </style>
Loading…
Cancel
Save