|
@@ -5,18 +5,21 @@
|
|
|
<template v-for="(item, index) in tiShiBiaoTi" :key="index">
|
|
|
<el-alert :title="item.title" :type="item.type" effect="dark"></el-alert>
|
|
|
</template>
|
|
|
- <el-button icon="el-icon-arrow-left" style="font-size: 14px" text @click="router.go(-1)">返回</el-button>
|
|
|
+ <el-button icon="ArrowLeft" style="font-size: 14px" text type="primary" @click="router.go(-1)">返回</el-button>
|
|
|
<el-button type="primary" @click="muBanDuiHuaKuang = true">获取模板</el-button>
|
|
|
<el-button :disabled="yiZhuList.length === 0" type="primary" @click="baoCunMuBanClick">保存模板</el-button>
|
|
|
<el-button icon="el-icon-check" type="success" @click="baoCunYiZhuClick">保存</el-button>
|
|
|
{{ count }}
|
|
|
- <cuo-wu-xin-xi />
|
|
|
+ <cuo-wu-xin-xi/>
|
|
|
<el-divider direction="vertical"></el-divider>
|
|
|
- <el-button :disabled="yiZhuData.serial === '00' || stringIsBlank(yiZhuData.serial)" icon="el-icon-view" type="success" @click="HeLiYongYao.dialog = true"> 药品用法 </el-button>
|
|
|
+ <el-button :disabled="yiZhuData.serial === '00' || stringIsBlank(yiZhuData.serial)" icon="el-icon-view" type="success"
|
|
|
+ @click="HeLiYongYao.dialog = true"> 药品用法
|
|
|
+ </el-button>
|
|
|
<el-divider direction="vertical"></el-divider>
|
|
|
<el-button @click="tiaoZhuanZhiHeLiYongYao">合理用药</el-button>
|
|
|
<el-button @click="allergenDialog = true">患者过敏信息</el-button>
|
|
|
- <yao-ping-xiang-qing v-if="HeLiYongYao.dialog" :code="HeLiYongYao.code" @close="HeLiYongYao.dialog = false"></yao-ping-xiang-qing>
|
|
|
+ <yao-ping-xiang-qing v-if="HeLiYongYao.dialog" :code="HeLiYongYao.code"
|
|
|
+ @close="HeLiYongYao.dialog = false"></yao-ping-xiang-qing>
|
|
|
<el-form ref="yiZhuRef" v-model="yiZhuData" label-width="90px" size="small">
|
|
|
<el-row>
|
|
|
<el-col :span="span" @click="yiZhuMingDialog = true">
|
|
@@ -35,13 +38,16 @@
|
|
|
</el-col>
|
|
|
<el-col :span="span">
|
|
|
<el-form-item class="bi_tian" label="频率:" prop="frequCode">
|
|
|
- <XcSelect v-model="yiZhuData" :data="yaoPinPingLvData" :name="['frequCode', 'frequCodeName']" clearable remote @method="pinLvRemoteMethod" ref="pingLv"> </XcSelect>
|
|
|
+ <XcSelect v-model="yiZhuData" :data="yaoPinPingLvData" :name="['frequCode', 'frequCodeName']" clearable remote
|
|
|
+ @method="pinLvRemoteMethod" ref="pingLv"></XcSelect>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="span">
|
|
|
<el-form-item class="bi_tian" label="一次剂量:" prop="dose">
|
|
|
- <el-input-number v-model="yiZhuData.dose" :min="0" :precision="2" style="width: 110px" @change="jiSuanLingLiang"></el-input-number>
|
|
|
- <XcSelect v-model="yiZhuData" :data="yaoPinJiLiangData" :name="['doseUnit', 'doseUnitName']" :width="80" @change="xuanZheJiLiang">
|
|
|
+ <el-input-number v-model="yiZhuData.dose" :min="0" :precision="2" style="width: 110px"
|
|
|
+ @change="jiSuanLingLiang"></el-input-number>
|
|
|
+ <XcSelect v-model="yiZhuData" :data="yaoPinJiLiangData" :name="['doseUnit', 'doseUnitName']" :width="80"
|
|
|
+ @change="xuanZheJiLiang">
|
|
|
<XcOption label="value"></XcOption>
|
|
|
<XcOption label="name"></XcOption>
|
|
|
</XcSelect>
|
|
@@ -52,7 +58,8 @@
|
|
|
</el-col>
|
|
|
<el-col :span="span">
|
|
|
<el-form-item class="bi_tian" label="给药方式:" prop="supplyCode">
|
|
|
- <XcSelect v-model="yiZhuData" :data="geiYaoFangShiData" :name="['supplyCode', 'supplyCodeName']" clearable remote @method="geiYaoFangShiRemoteMethod"> </XcSelect>
|
|
|
+ <XcSelect v-model="yiZhuData" :data="geiYaoFangShiData" :name="['supplyCode', 'supplyCodeName']" clearable
|
|
|
+ remote @method="geiYaoFangShiRemoteMethod"></XcSelect>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="span">
|
|
@@ -63,23 +70,23 @@
|
|
|
<el-col :span="span">
|
|
|
<el-form-item class="bi_tian" label="开始时间:" prop="startTime">
|
|
|
<el-date-picker
|
|
|
- v-model="yiZhuData.startTime"
|
|
|
- :disabled-date="disabledDate"
|
|
|
- format="YYYY-MM-DD HH:mm:ss"
|
|
|
- type="datetime"
|
|
|
- value-format="YYYY-MM-DD HH:mm:ss"
|
|
|
+ v-model="yiZhuData.startTime"
|
|
|
+ :disabled-date="disabledDate"
|
|
|
+ format="YYYY-MM-DD HH:mm:ss"
|
|
|
+ type="datetime"
|
|
|
+ value-format="YYYY-MM-DD HH:mm:ss"
|
|
|
></el-date-picker>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="span">
|
|
|
<el-form-item class="bi_tian" label="停止时间:" prop="endTime">
|
|
|
<el-date-picker
|
|
|
- v-model="yiZhuData.endTime"
|
|
|
- :disabled="yiZhuData.frequCode === 'ONCE'"
|
|
|
- :disabled-date="disabledDate"
|
|
|
- format="YYYY-MM-DD HH:mm:ss"
|
|
|
- type="datetime"
|
|
|
- value-format="YYYY-MM-DD HH:mm:ss"
|
|
|
+ v-model="yiZhuData.endTime"
|
|
|
+ :disabled="yiZhuData.frequCode === 'ONCE'"
|
|
|
+ :disabled-date="disabledDate"
|
|
|
+ format="YYYY-MM-DD HH:mm:ss"
|
|
|
+ type="datetime"
|
|
|
+ value-format="YYYY-MM-DD HH:mm:ss"
|
|
|
></el-date-picker>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
@@ -90,12 +97,14 @@
|
|
|
</el-col>
|
|
|
<el-col :span="span">
|
|
|
<el-form-item class="bi_tian" label="执行科室:" prop="execUnit">
|
|
|
- <XcSelect v-model="yiZhuData" :data="zhiXingKeShiData" :name="['execUnit', 'execUnitName']" remote @method="metZhiXingKeShi"> </XcSelect>
|
|
|
+ <XcSelect v-model="yiZhuData" :data="zhiXingKeShiData" :name="['execUnit', 'execUnitName']" remote
|
|
|
+ @method="metZhiXingKeShi"></XcSelect>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="span">
|
|
|
<el-form-item label="父医嘱:" prop="orderName">
|
|
|
- <el-select v-model="yiZhuData.parentNo" :disabled="yiZhuData.serial === '00'" clearable @clear="yiZhuData.parentNo = null" @click="fuYiZhuClick">
|
|
|
+ <el-select v-model="yiZhuData.parentNo" :disabled="yiZhuData.serial === '00'" clearable
|
|
|
+ @clear="yiZhuData.parentNo = null" @click="fuYiZhuClick">
|
|
|
<el-option v-for="item in fuYiZhuData" :key="item.code" :label="item.name" :value="item.code">
|
|
|
<span style="color: #8492a6; font-size: 12px">{{ item.code }}</span>
|
|
|
<el-divider direction="vertical"></el-divider>
|
|
@@ -133,20 +142,23 @@
|
|
|
</el-col>
|
|
|
<el-col :span="span">
|
|
|
<el-form-item label="医保自费:">
|
|
|
- <el-switch v-model="yiZhuData.ybSelfFlag" active-color="#13ce66" active-text="自费" active-value="1" inactive-color="#ff4949" inactive-text="记账" inactive-value="0">
|
|
|
+ <el-switch v-model="yiZhuData.ybSelfFlag" active-color="#13ce66" active-text="自费" active-value="1"
|
|
|
+ inactive-color="#ff4949" inactive-text="记账" inactive-value="0">
|
|
|
</el-switch>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="span">
|
|
|
<el-form-item label="是否紧急:">
|
|
|
- <el-switch v-model="yiZhuData.emergencyFlag" active-color="#13ce66" active-text="是" active-value="1" inactive-color="#ff4949" inactive-text="否" inactive-value="0">
|
|
|
+ <el-switch v-model="yiZhuData.emergencyFlag" active-color="#13ce66" active-text="是" active-value="1"
|
|
|
+ inactive-color="#ff4949" inactive-text="否" inactive-value="0">
|
|
|
</el-switch>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col v-if="yiZhuData.orderCode === zkCode" :span="span">
|
|
|
<el-form-item label="转科:" class="bi_tian">
|
|
|
<el-select v-model="yiZhuData.zkObj">
|
|
|
- <el-option v-for="(item, index) in zkList" :key="item.value" :label="item.wardName + '|' + item.smallName" :value="item.value">
|
|
|
+ <el-option v-for="(item, index) in zkList" :key="item.value" :label="item.wardName + '|' + item.smallName"
|
|
|
+ :value="item.value">
|
|
|
<span>{{ item.wardName }}</span>
|
|
|
<el-divider direction="vertical"></el-divider>
|
|
|
<span>{{ item.smallName }}</span>
|
|
@@ -157,7 +169,8 @@
|
|
|
<el-col v-if="yiZhuData.kjywFlag !== 0" :span="span">
|
|
|
<el-form-item label="用药方式:">
|
|
|
<el-select v-model="yiZhuData.yyfs" style="width: 120px" @change="kangJunYaoYongYaoFangShiGaiBian">
|
|
|
- <el-option v-for="item in kangJunYaoWuYongYaoFangShi" :key="item.code" :label="item.name" :value="item.code">
|
|
|
+ <el-option v-for="item in kangJunYaoWuYongYaoFangShi" :key="item.code" :label="item.name"
|
|
|
+ :value="item.code">
|
|
|
<span style="color: #8492a6; font-size: 12px">{{ item.code }}</span>
|
|
|
<el-divider direction="vertical"></el-divider>
|
|
|
<span>{{ item.name }}</span>
|
|
@@ -168,11 +181,11 @@
|
|
|
<el-col :span="span">
|
|
|
<el-form-item v-if="yiZhuData.kjywFlag !== 0" label="切口等级:">
|
|
|
<el-select
|
|
|
- v-model="yiZhuData.ssqk"
|
|
|
- :disabled="yiZhuData.yyfs !== 1 && yiZhuData.yyfs !== 2 && yiZhuData.yyfs !== null"
|
|
|
- clearable
|
|
|
- style="width: 120px"
|
|
|
- @clear="yiZhuData.ssqk = null"
|
|
|
+ v-model="yiZhuData.ssqk"
|
|
|
+ :disabled="yiZhuData.yyfs !== 1 && yiZhuData.yyfs !== 2 && yiZhuData.yyfs !== null"
|
|
|
+ clearable
|
|
|
+ style="width: 120px"
|
|
|
+ @clear="yiZhuData.ssqk = null"
|
|
|
>
|
|
|
<el-option v-for="item in kangJunYaoWuQieKou" :key="item.code" :label="item.name" :value="item.code">
|
|
|
<span style="color: #8492a6; font-size: 12px">{{ item.code }}</span>
|
|
@@ -185,13 +198,14 @@
|
|
|
<el-col :span="span">
|
|
|
<el-form-item v-if="yiZhuData.kjywFlag !== 0" label="用药时间:">
|
|
|
<el-select
|
|
|
- v-model="yiZhuData.yysj"
|
|
|
- :disabled="yiZhuData.yyfs !== 1 && yiZhuData.yyfs !== 2 && yiZhuData.yyfs !== null"
|
|
|
- clearable
|
|
|
- style="width: 120px"
|
|
|
- @clear="yiZhuData.yysj = null"
|
|
|
+ v-model="yiZhuData.yysj"
|
|
|
+ :disabled="yiZhuData.yyfs !== 1 && yiZhuData.yyfs !== 2 && yiZhuData.yyfs !== null"
|
|
|
+ clearable
|
|
|
+ style="width: 120px"
|
|
|
+ @clear="yiZhuData.yysj = null"
|
|
|
>
|
|
|
- <el-option v-for="item in kangJunYaoWuYongYaoShiJian" :key="item.code" :label="item.name" :value="item.code">
|
|
|
+ <el-option v-for="item in kangJunYaoWuYongYaoShiJian" :key="item.code" :label="item.name"
|
|
|
+ :value="item.code">
|
|
|
<span style="color: #8492a6; font-size: 12px">{{ item.code }}</span>
|
|
|
<el-divider direction="vertical"></el-divider>
|
|
|
<span>{{ item.name }}</span></el-option
|
|
@@ -202,20 +216,20 @@
|
|
|
</el-row>
|
|
|
</el-form>
|
|
|
<el-button icon="el-icon-plus" type="primary" @click="tianJiaYiZhu">添加</el-button>
|
|
|
- <xc-code code="Ctrl + S" description="键盘添加" />
|
|
|
- <xc-code code="Ctrl + F" description="打开搜索框" />
|
|
|
- <xc-code code="Ctrl + 1" description="回到第一个输入框(数字1)" />
|
|
|
- <xc-code code="Alt + PgUp / PgDn" description="医嘱上下" />
|
|
|
- <xc-code code="Alt + ← / →" description="编辑(←) / 复制 (→)" />
|
|
|
- <xc-code code="Alt + D " description="删除选中的医嘱" />
|
|
|
+ <xc-code code="Ctrl + S" description="键盘添加"/>
|
|
|
+ <xc-code code="Ctrl + F" description="打开搜索框"/>
|
|
|
+ <xc-code code="Ctrl + 1" description="回到第一个输入框(数字1)"/>
|
|
|
+ <xc-code code="Alt + PgUp / PgDn" description="医嘱上下"/>
|
|
|
+ <xc-code code="Alt + ← / →" description="编辑(←) / 复制 (→)"/>
|
|
|
+ <xc-code code="Alt + D " description="删除选中的医嘱"/>
|
|
|
<el-button @click="dianJiXiuGaiZhiXingKeShi">修改执行科室</el-button>
|
|
|
<el-table
|
|
|
- :data="yiZhuList"
|
|
|
- ref="elTableRef"
|
|
|
- :height="windowSize.h / 2.4"
|
|
|
- @selection-change="dianJiXuanZhongShuJu"
|
|
|
- :row-class-name="doctorSOrderForm"
|
|
|
- @row-click="whenClickingOnTheForm"
|
|
|
+ :data="yiZhuList"
|
|
|
+ ref="elTableRef"
|
|
|
+ :height="windowSize.h / 2.4"
|
|
|
+ @selection-change="dianJiXuanZhongShuJu"
|
|
|
+ :row-class-name="doctorSOrderForm"
|
|
|
+ @row-click="whenClickingOnTheForm"
|
|
|
>
|
|
|
<el-table-column type="selection"></el-table-column>
|
|
|
<el-table-column label="排序" type="index"></el-table-column>
|
|
@@ -261,30 +275,46 @@
|
|
|
</el-table-column>
|
|
|
</el-table>
|
|
|
<!-- 这里是搜索医嘱的 -->
|
|
|
- <sou-suo-yi-zhu v-if="yiZhuMingDialog" @close="closeTheDoctorSOrderSearchBox()" @xuanZhongFeiYong="xuanZhongFeiYong"></sou-suo-yi-zhu>
|
|
|
- <AllergenEntry v-if="allergenDialog" :pat-no="huanZheXinXi.inpatientNo" @close="allergenDialog = false"></AllergenEntry>
|
|
|
+ <sou-suo-yi-zhu v-if="yiZhuMingDialog" @close="closeTheDoctorSOrderSearchBox()"
|
|
|
+ @xuanZhongFeiYong="xuanZhongFeiYong"></sou-suo-yi-zhu>
|
|
|
+ <AllergenEntry v-if="allergenDialog" :pat-no="huanZheXinXi.inpatientNo"
|
|
|
+ @close="allergenDialog = false"></AllergenEntry>
|
|
|
</template>
|
|
|
|
|
|
<script name="TianJiaYiZhu" setup>
|
|
|
-import { huoQuFeiYongXinXi, huoQuGeiYaoFangShi, huoQuZhiXinKeShi, huoQuZhuYuanPinLv, jiaoYan, shangChuanYiZhu } from '@/api/zhu-yuan-yi-sheng/yi-zhu-lu-ru'
|
|
|
-import { cuoWuXinXi, fuZhiYiZhu, getSelfBuy, huanZheXinXi, youWuXuanZheHuanZhe, zkList } from '@/views/hospitalization/zhu-yuan-yi-sheng/public-js/zhu-yuan-yi-sheng'
|
|
|
+import {
|
|
|
+ huoQuFeiYongXinXi,
|
|
|
+ huoQuGeiYaoFangShi,
|
|
|
+ huoQuZhiXinKeShi,
|
|
|
+ huoQuZhuYuanPinLv,
|
|
|
+ jiaoYan,
|
|
|
+ shangChuanYiZhu
|
|
|
+} from '@/api/zhu-yuan-yi-sheng/yi-zhu-lu-ru'
|
|
|
+import {
|
|
|
+ cuoWuXinXi,
|
|
|
+ fuZhiYiZhu,
|
|
|
+ getSelfBuy,
|
|
|
+ huanZheXinXi,
|
|
|
+ youWuXuanZheHuanZhe,
|
|
|
+ zkList
|
|
|
+} from '@/views/hospitalization/zhu-yuan-yi-sheng/public-js/zhu-yuan-yi-sheng'
|
|
|
import store from '../../../../store'
|
|
|
-import { listIsBlank, listNotBlank, stringIsBlank, stringNotBlank } from '@/utils/blank-utils'
|
|
|
-import { kangJunYaoWuQieKou, kangJunYaoWuYongYaoFangShi, kangJunYaoWuYongYaoShiJian } from '@/data'
|
|
|
-import { ElMessage, ElMessageBox } from 'element-plus'
|
|
|
-import { clone } from '@/utils/clone'
|
|
|
+import {listIsBlank, listNotBlank, stringIsBlank, stringNotBlank} from '@/utils/blank-utils'
|
|
|
+import {kangJunYaoWuQieKou, kangJunYaoWuYongYaoFangShi, kangJunYaoWuYongYaoShiJian} from '@/data'
|
|
|
+import {ElMessage, ElMessageBox} from 'element-plus'
|
|
|
+import {clone} from '@/utils/clone'
|
|
|
import HuoQuMuBan from '../../../../components/zhu-yuan-yi-sheng/yi-zhu-lu-ru/HuoQuMuBan.vue'
|
|
|
-import { uuid } from '@/utils/getUuid'
|
|
|
+import {uuid} from '@/utils/getUuid'
|
|
|
import BaoCunMuBan from '../../../../components/zhu-yuan-yi-sheng/yi-zhu-lu-ru/BaoCunMuBan.vue'
|
|
|
-import { getServerDateApi, whetherThePatientHasAllergens, yaoPinXiangMuPiPeiYiBao } from '@/api/public-api'
|
|
|
+import {getServerDateApi, whetherThePatientHasAllergens, yaoPinXiangMuPiPeiYiBao} from '@/api/public-api'
|
|
|
import router from '@/router'
|
|
|
import SouSuoYiZhu from '@/components/zhu-yuan-yi-sheng/yi-zhu-lu-ru/SouSuoYiZhu.vue'
|
|
|
import CuoWuXinXi from '@/components/zhu-yuan-yi-sheng/CuoWuXinXi.vue'
|
|
|
import YaoPingXiangQing from '@/components/zhu-yuan-yi-sheng/he-li-yong-yao/YaoPingXiangQing.vue'
|
|
|
import AllergenEntry from '@/components/zhu-yuan-yi-sheng/AllergenEntry.vue'
|
|
|
import Sleep from '@/utils/sleep'
|
|
|
-import { logoutShortcut, xcHotKey } from '@/utils/xckeydown'
|
|
|
-import { BizException, ExceptionEnum } from '@/utils/BizException'
|
|
|
+import {logoutShortcut, xcHotKey} from '@/utils/xckeydown'
|
|
|
+import {BizException, ExceptionEnum} from '@/utils/BizException'
|
|
|
|
|
|
const windowSize = computed(() => {
|
|
|
return store.state.app.windowSize
|
|
@@ -360,10 +390,10 @@ const spanSize = (val) => {
|
|
|
}
|
|
|
spanSize(windowSize.value.w)
|
|
|
watch(
|
|
|
- () => windowSize.value,
|
|
|
- () => {
|
|
|
- spanSize(windowSize.value.w)
|
|
|
- }
|
|
|
+ () => windowSize.value,
|
|
|
+ () => {
|
|
|
+ spanSize(windowSize.value.w)
|
|
|
+ }
|
|
|
)
|
|
|
|
|
|
// 搜索医嘱
|
|
@@ -375,75 +405,75 @@ const xuanZhongFeiYong = async (row) => {
|
|
|
yiZhuData.value = row
|
|
|
if (row.serial !== '00') {
|
|
|
huoQuFeiYongXinXi(row.orderCode, row.serial)
|
|
|
- .then((res) => {
|
|
|
- yiZhuData.value.drugFlag = row.orderType
|
|
|
- // 判断是否 是皮试的药 如果是就只能有这些 给药方式
|
|
|
- if (res.data.psFlag === 1) {
|
|
|
- geiYaoFangShiData.value = res.piShi
|
|
|
- tiShiBiaoTi.value.push({ title: '该药品为皮试药品给药方式只能是皮试类型', type: 'warning' })
|
|
|
- yiZhuData.value.psFlag = true
|
|
|
- } else {
|
|
|
- yiZhuData.value.psFlag = false
|
|
|
- }
|
|
|
- yiZhuData.value.kjywFlag = res.data.kjywFlag
|
|
|
- if (yiZhuData.value.kjywFlag === 1) {
|
|
|
- tiShiBiaoTi.value.push({ title: '该药品为抗菌药物,请填写抗菌药物医嘱附注信息录入。', type: 'error' })
|
|
|
- }
|
|
|
- if (res.data.selfFlagYb === 1) {
|
|
|
- tiShiBiaoTi.value.push({ title: '该药品医保自费药品,如符合条件请填写记账,不是请填写自费。' })
|
|
|
- }
|
|
|
- yiZhuData.value.miniUnitName = res.data.miniUnitName
|
|
|
- yaoPinJiLiangData.value = res.yaoPingJiLiang
|
|
|
- // 加载 剂量单位
|
|
|
- if (stringNotBlank(yiZhuData.value.doseUnit)) {
|
|
|
- yaoPinJiLiangData.value.forEach((item) => {
|
|
|
- if (item.code === yiZhuData.value.doseUnit) {
|
|
|
- jiLiangValue.value = item.value
|
|
|
- }
|
|
|
- })
|
|
|
- } else if (listNotBlank(yaoPinJiLiangData.value)) {
|
|
|
- // 没有剂量单位的时候默认加载第一个计量单位 并且计算
|
|
|
- yiZhuData.value.doseUnit = yaoPinJiLiangData.value[0].code
|
|
|
- yiZhuData.value.dose = yaoPinJiLiangData.value[0].value
|
|
|
- jiLiangValue.value = yaoPinJiLiangData.value[0].value
|
|
|
- jiSuanLingLiang(yaoPinJiLiangData.value[0].value)
|
|
|
- }
|
|
|
- // 加载默认频率 如果已经填写了 就用有的
|
|
|
- if (stringIsBlank(row.frequCode)) {
|
|
|
- if (stringNotBlank(res.data.frequCode)) {
|
|
|
- yiZhuData.value.frequCode = res.data.frequCode
|
|
|
+ .then((res) => {
|
|
|
+ yiZhuData.value.drugFlag = row.orderType
|
|
|
+ // 判断是否 是皮试的药 如果是就只能有这些 给药方式
|
|
|
+ if (res.data.psFlag === 1) {
|
|
|
+ geiYaoFangShiData.value = res.piShi
|
|
|
+ tiShiBiaoTi.value.push({title: '该药品为皮试药品给药方式只能是皮试类型', type: 'warning'})
|
|
|
+ yiZhuData.value.psFlag = true
|
|
|
} else {
|
|
|
- yiZhuData.value.frequCode = 'ONCE'
|
|
|
+ yiZhuData.value.psFlag = false
|
|
|
}
|
|
|
- }
|
|
|
- // 加载给药方式
|
|
|
- if (stringIsBlank(yiZhuData.value.supplyCode)) {
|
|
|
- if (stringNotBlank(res.data.supplyCode)) {
|
|
|
- yiZhuData.value.supplyCode = res.data.supplyCode
|
|
|
+ yiZhuData.value.kjywFlag = res.data.kjywFlag
|
|
|
+ if (yiZhuData.value.kjywFlag === 1) {
|
|
|
+ tiShiBiaoTi.value.push({title: '该药品为抗菌药物,请填写抗菌药物医嘱附注信息录入。', type: 'error'})
|
|
|
}
|
|
|
- }
|
|
|
- })
|
|
|
- .catch(async () => {
|
|
|
- await Sleep(500)
|
|
|
- qingKong()
|
|
|
- })
|
|
|
+ if (res.data.selfFlagYb === 1) {
|
|
|
+ tiShiBiaoTi.value.push({title: '该药品医保自费药品,如符合条件请填写记账,不是请填写自费。'})
|
|
|
+ }
|
|
|
+ yiZhuData.value.miniUnitName = res.data.miniUnitName
|
|
|
+ yaoPinJiLiangData.value = res.yaoPingJiLiang
|
|
|
+ // 加载 剂量单位
|
|
|
+ if (stringNotBlank(yiZhuData.value.doseUnit)) {
|
|
|
+ yaoPinJiLiangData.value.forEach((item) => {
|
|
|
+ if (item.code === yiZhuData.value.doseUnit) {
|
|
|
+ jiLiangValue.value = item.value
|
|
|
+ }
|
|
|
+ })
|
|
|
+ } else if (listNotBlank(yaoPinJiLiangData.value)) {
|
|
|
+ // 没有剂量单位的时候默认加载第一个计量单位 并且计算
|
|
|
+ yiZhuData.value.doseUnit = yaoPinJiLiangData.value[0].code
|
|
|
+ yiZhuData.value.dose = yaoPinJiLiangData.value[0].value
|
|
|
+ jiLiangValue.value = yaoPinJiLiangData.value[0].value
|
|
|
+ jiSuanLingLiang(yaoPinJiLiangData.value[0].value)
|
|
|
+ }
|
|
|
+ // 加载默认频率 如果已经填写了 就用有的
|
|
|
+ if (stringIsBlank(row.frequCode)) {
|
|
|
+ if (stringNotBlank(res.data.frequCode)) {
|
|
|
+ yiZhuData.value.frequCode = res.data.frequCode
|
|
|
+ } else {
|
|
|
+ yiZhuData.value.frequCode = 'ONCE'
|
|
|
+ }
|
|
|
+ }
|
|
|
+ // 加载给药方式
|
|
|
+ if (stringIsBlank(yiZhuData.value.supplyCode)) {
|
|
|
+ if (stringNotBlank(res.data.supplyCode)) {
|
|
|
+ yiZhuData.value.supplyCode = res.data.supplyCode
|
|
|
+ }
|
|
|
+ }
|
|
|
+ })
|
|
|
+ .catch(async () => {
|
|
|
+ await Sleep(500)
|
|
|
+ qingKong()
|
|
|
+ })
|
|
|
} else {
|
|
|
yiZhuData.value.kjywFlag = 0
|
|
|
huoQuFeiYongXinXi(row.orderCode, '00')
|
|
|
- .then((res) => {
|
|
|
- yiZhuData.value.drugFlag = row.orderType
|
|
|
- yiZhuData.value.frequCode = 'ONCE'
|
|
|
- if (stringNotBlank(res.paiChiYiZhu)) {
|
|
|
- tiShiBiaoTi.value.push({ title: res.paiChiYiZhu, type: 'error' })
|
|
|
- }
|
|
|
- if (!res.dose) {
|
|
|
- yiZhuData.value.dose = 1
|
|
|
- }
|
|
|
- })
|
|
|
- .catch(async () => {
|
|
|
- await Sleep(500)
|
|
|
- qingKong()
|
|
|
- })
|
|
|
+ .then((res) => {
|
|
|
+ yiZhuData.value.drugFlag = row.orderType
|
|
|
+ yiZhuData.value.frequCode = 'ONCE'
|
|
|
+ if (stringNotBlank(res.paiChiYiZhu)) {
|
|
|
+ tiShiBiaoTi.value.push({title: res.paiChiYiZhu, type: 'error'})
|
|
|
+ }
|
|
|
+ if (!res.dose) {
|
|
|
+ yiZhuData.value.dose = 1
|
|
|
+ }
|
|
|
+ })
|
|
|
+ .catch(async () => {
|
|
|
+ await Sleep(500)
|
|
|
+ qingKong()
|
|
|
+ })
|
|
|
}
|
|
|
// 判断这个是不是 新添加的数据 如果是空的就是 新数据
|
|
|
getServerDateApi().then((res) => {
|
|
@@ -514,7 +544,7 @@ const fuYiZhuClick = () => {
|
|
|
fuYiZhuData.value = []
|
|
|
yiZhuList.value.forEach((item, index) => {
|
|
|
if (stringNotBlank(item.drugFlag) && item.drugFlag === 'i' && item.id !== yiZhuData.value.id && stringIsBlank(item.parentNo)) {
|
|
|
- fuYiZhuData.value.push({ code: item.id, name: item.orderName })
|
|
|
+ fuYiZhuData.value.push({code: item.id, name: item.orderName})
|
|
|
}
|
|
|
})
|
|
|
}
|
|
@@ -557,20 +587,20 @@ const tianJiaYiZhu = () => {
|
|
|
list: list,
|
|
|
}
|
|
|
shangChuanYiZhu(data)
|
|
|
- .then((res) => {
|
|
|
- let index = tianJiaYiZhuWeiYiBiaoShi.value.indexOf(yiZhuData.value.id)
|
|
|
- if (index > -1) {
|
|
|
- yiZhuList.value.splice(index, 1)
|
|
|
- tianJiaYiZhuWeiYiBiaoShi.value.splice(index, 1)
|
|
|
- ElMessage.error('重复添加,老记录已删除。')
|
|
|
- }
|
|
|
- tianJiaYiZhuWeiYiBiaoShi.value.push(yiZhuData.value.id)
|
|
|
- yiZhuList.value.push(clone(yiZhuData.value))
|
|
|
- qingKong()
|
|
|
- })
|
|
|
- .catch((e) => {
|
|
|
- cuoWuXinXi.value = e
|
|
|
- })
|
|
|
+ .then((res) => {
|
|
|
+ let index = tianJiaYiZhuWeiYiBiaoShi.value.indexOf(yiZhuData.value.id)
|
|
|
+ if (index > -1) {
|
|
|
+ yiZhuList.value.splice(index, 1)
|
|
|
+ tianJiaYiZhuWeiYiBiaoShi.value.splice(index, 1)
|
|
|
+ ElMessage.error('重复添加,老记录已删除。')
|
|
|
+ }
|
|
|
+ tianJiaYiZhuWeiYiBiaoShi.value.push(yiZhuData.value.id)
|
|
|
+ yiZhuList.value.push(clone(yiZhuData.value))
|
|
|
+ qingKong()
|
|
|
+ })
|
|
|
+ .catch((e) => {
|
|
|
+ cuoWuXinXi.value = e
|
|
|
+ })
|
|
|
}
|
|
|
|
|
|
/**
|
|
@@ -624,10 +654,11 @@ const baoCunYiZhuClick = () => {
|
|
|
dangerouslyUseHTMLString: true,
|
|
|
confirmButtonText: '继续录入',
|
|
|
})
|
|
|
- .then(() => {
|
|
|
- baoCunYiZhu()
|
|
|
- })
|
|
|
- .catch(() => {})
|
|
|
+ .then(() => {
|
|
|
+ baoCunYiZhu()
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ })
|
|
|
} else {
|
|
|
baoCunYiZhu()
|
|
|
}
|
|
@@ -656,17 +687,18 @@ function baoCunYiZhu() {
|
|
|
type: 'warning',
|
|
|
closeOnClickModal: false,
|
|
|
})
|
|
|
- .then(() => {
|
|
|
- shangChuanYiZhu(data)
|
|
|
- .then((res) => {
|
|
|
- fuZhiYiZhu.value = []
|
|
|
- router.go(-1)
|
|
|
- })
|
|
|
- .catch((e) => {
|
|
|
- cuoWuXinXi.value = e
|
|
|
- })
|
|
|
- })
|
|
|
- .catch(() => {})
|
|
|
+ .then(() => {
|
|
|
+ shangChuanYiZhu(data)
|
|
|
+ .then((res) => {
|
|
|
+ fuZhiYiZhu.value = []
|
|
|
+ router.go(-1)
|
|
|
+ })
|
|
|
+ .catch((e) => {
|
|
|
+ cuoWuXinXi.value = e
|
|
|
+ })
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ })
|
|
|
}
|
|
|
|
|
|
/* 这里是抗菌药物,选择了除了 1和 2 的其他都可以不用填写 */
|
|
@@ -717,13 +749,13 @@ const baoCunMuBanClick = () => {
|
|
|
list: yiZhuList.value,
|
|
|
}
|
|
|
shangChuanYiZhu(data)
|
|
|
- .then((res) => {
|
|
|
- baoCunMuBanRef.value.daKaiBaoCunMuBan(yiZhuList.value)
|
|
|
- cuoWuXinXi.value = ''
|
|
|
- })
|
|
|
- .catch((e) => {
|
|
|
- cuoWuXinXi.value = e
|
|
|
- })
|
|
|
+ .then((res) => {
|
|
|
+ baoCunMuBanRef.value.daKaiBaoCunMuBan(yiZhuList.value)
|
|
|
+ cuoWuXinXi.value = ''
|
|
|
+ })
|
|
|
+ .catch((e) => {
|
|
|
+ cuoWuXinXi.value = e
|
|
|
+ })
|
|
|
}
|
|
|
// 医嘱限制时间不能在之前
|
|
|
const disabledDate = (time) => {
|
|
@@ -828,7 +860,8 @@ const countDown = () => {
|
|
|
if (seconds.value === 300) {
|
|
|
ElMessageBox.alert('您的操作时间过半', '提示', {
|
|
|
type: 'warning',
|
|
|
- }).then((res) => {})
|
|
|
+ }).then((res) => {
|
|
|
+ })
|
|
|
} else if (seconds.value === 60 || seconds.value === 30 || seconds.value === 20) {
|
|
|
ElMessage({
|
|
|
message: '剩余操作时间' + seconds.value + '秒',
|
|
@@ -887,7 +920,7 @@ const regainFocus = () => {
|
|
|
* @param rowIndex 下标
|
|
|
* @returns {string} 样式
|
|
|
*/
|
|
|
-const doctorSOrderForm = ({ row, rowIndex }) => {
|
|
|
+const doctorSOrderForm = ({row, rowIndex}) => {
|
|
|
row.tableIndex = rowIndex
|
|
|
if (dataIndex === rowIndex) {
|
|
|
return 'input_and_table_to_be_selected'
|
|
@@ -967,7 +1000,7 @@ const deleteSelectedOrders = () => {
|
|
|
|
|
|
// 注册快捷键的 list
|
|
|
let shortcutKeyRegistration = {
|
|
|
- ctrl: { s: saveOrAddADoctorSOrder, f: openSearchBox, 1: regainFocus },
|
|
|
+ ctrl: {s: saveOrAddADoctorSOrder, f: openSearchBox, 1: regainFocus},
|
|
|
alt: {
|
|
|
PageUp: upData,
|
|
|
PageDown: downData,
|