版本更新
This commit is contained in:
@@ -16,12 +16,24 @@
|
||||
<el-table-column label="单次剂量" align="center">
|
||||
<template #default="scope">
|
||||
<span>
|
||||
{{ parseFloat(scope.row.dose).toFixed(2) + scope.row.doseUnitCode_dictText }}
|
||||
{{
|
||||
parseFloat(scope.row.dose).toFixed(2) === '0.00'
|
||||
? '-'
|
||||
: parseFloat(scope.row.dose).toFixed(2) + scope.row.doseUnitCode_dictText
|
||||
}}
|
||||
</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="规格" align="center" prop="volume" />
|
||||
<el-table-column label="用法" align="center" prop="methodCode_dictText" />
|
||||
<!-- 修改价格列,从inventoryList中获取价格 -->
|
||||
<!-- <el-table-column label="价格" align="center">
|
||||
<template #default="scope">
|
||||
<span>
|
||||
{{ getPriceFromInventory(scope.row) }}
|
||||
</span>
|
||||
</template>
|
||||
</el-table-column> -->
|
||||
<el-table-column label="库存数量" align="center">
|
||||
<template #default="scope">{{ handleQuantity(scope.row) }}</template>
|
||||
</el-table-column>
|
||||
@@ -101,6 +113,7 @@ getList();
|
||||
function getList() {
|
||||
queryParams.value.organizationId = props.patientInfo.orgId;
|
||||
getAdviceBaseInfo(queryParams.value).then((res) => {
|
||||
console.log('ssssssssss', res.data.records);
|
||||
if (res.data.records.length > 0) {
|
||||
adviceBaseList.value = res.data.records.filter((item) => {
|
||||
if (item.adviceType == 1 || item.adviceType == 2) {
|
||||
@@ -117,7 +130,14 @@ function getList() {
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
// 从priceList列表中获取价格
|
||||
function getPriceFromInventory(row) {
|
||||
if (row.priceList && row.priceList.length > 0) {
|
||||
const price = row.priceList[0].price || 0;
|
||||
return Number(price).toFixed(2) + ' 元';
|
||||
}
|
||||
return '-';
|
||||
}
|
||||
// 处理键盘事件
|
||||
const handleKeyDown = (event) => {
|
||||
const key = event.key;
|
||||
@@ -182,9 +202,9 @@ defineExpose({
|
||||
handleKeyDown,
|
||||
});
|
||||
</script>
|
||||
|
||||
|
||||
<style scoped>
|
||||
.popover-table-wrapper:focus {
|
||||
outline: 2px solid #409eff; /* 聚焦时的高亮效果 */
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
|
||||
@@ -179,6 +179,17 @@ export function getEncounterDiagnosis(encounterId) {
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* 获取诊断集合数据
|
||||
*/
|
||||
export function getDiagnosisList(searchKey) {
|
||||
return request({
|
||||
url: '/doctor-station/diagnosis/get-diagnosis-list?searchKey=' + searchKey,
|
||||
method: 'get',
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* 删除就诊诊断
|
||||
@@ -671,3 +682,25 @@ export function getOrderGroup(data) {
|
||||
params: data
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询诊疗项目耗材绑定信息
|
||||
*/
|
||||
export function getActivityBindDevice(data) {
|
||||
return request({
|
||||
url: '/doctor-station/advice/activity-bind-device-info',
|
||||
method: 'get',
|
||||
params: data
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
* 是否是食源性诊断
|
||||
*/
|
||||
export function isFoodDiseasesNew(params) {
|
||||
return request({
|
||||
url: '/external-integration/foodborne-acquisition/is-food-diseases-new',
|
||||
method: 'get',
|
||||
params: params
|
||||
})
|
||||
}
|
||||
|
||||
@@ -85,7 +85,7 @@
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
|
||||
<script setup>
|
||||
import {
|
||||
getTcmCondition,
|
||||
@@ -418,4 +418,4 @@ function close() {
|
||||
padding: 20px 0;
|
||||
text-align: center;
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
|
||||
@@ -202,6 +202,7 @@ import {
|
||||
getChronicDisease,
|
||||
getTcmDiagnosis,
|
||||
delEncounterDiagnosis,
|
||||
isFoodDiseasesNew,
|
||||
} from '../api';
|
||||
import diagnosisdialog from '../diagnosis/diagnosisdialog.vue';
|
||||
import AddDiagnosisDialog from './addDiagnosisDialog.vue';
|
||||
@@ -455,6 +456,18 @@ function handleSaveDiagnosis() {
|
||||
getList();
|
||||
emits('diagnosisSave', false);
|
||||
proxy.$modal.msgSuccess('诊断已保存');
|
||||
//食源性疾病病例数据智能采集 ---START---
|
||||
isFoodDiseasesNew({
|
||||
encounterId: props.patientInfo.encounterId,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
let jumpUrl = res.data;
|
||||
if (jumpUrl) {
|
||||
window.open(jumpUrl, '_blank');
|
||||
}
|
||||
}
|
||||
});
|
||||
//食源性疾病病例数据智能采集 ---END---
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -548,4 +561,4 @@ defineExpose({ getList, getDetail, handleSaveDiagnosis });
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
|
||||
@@ -31,17 +31,20 @@
|
||||
</el-col> -->
|
||||
</el-row>
|
||||
|
||||
<el-table
|
||||
ref="diagnosisDefinitionRef"
|
||||
:data="diagnosisDefinitionList"
|
||||
row-key="patientId"
|
||||
@cell-click="clickRow"
|
||||
highlight-current-row
|
||||
@selection-change="handleSelectionChange"
|
||||
>
|
||||
<el-table-column label="诊断名称" align="center" prop="name" />
|
||||
<el-table-column label="医保编码" align="center" prop="ybNo" />
|
||||
</el-table>
|
||||
<el-scrollbar height="400px">
|
||||
<el-table
|
||||
ref="diagnosisDefinitionRef"
|
||||
:data="diagnosisDefinitionList"
|
||||
row-key="patientId"
|
||||
@cell-click="clickRow"
|
||||
highlight-current-row
|
||||
@selection-change="handleSelectionChange"
|
||||
>
|
||||
<el-table-column label="诊断名称" align="center" prop="name" />
|
||||
<el-table-column label="医保编码" align="center" prop="ybNo" />
|
||||
</el-table>
|
||||
</el-scrollbar>
|
||||
|
||||
<pagination
|
||||
v-show="total > 0"
|
||||
:total="total"
|
||||
@@ -58,10 +61,10 @@
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
|
||||
<script setup>
|
||||
import { computed } from "vue";
|
||||
import { getDiagnosisDefinitionList, saveDiagnosisBind } from "../api";
|
||||
import { computed } from 'vue';
|
||||
import { getDiagnosisDefinitionList, saveDiagnosisBind } from '../api';
|
||||
|
||||
const radio = ref(1);
|
||||
const props = defineProps({
|
||||
@@ -74,7 +77,7 @@ const props = defineProps({
|
||||
default: '',
|
||||
},
|
||||
});
|
||||
const emit = defineEmits(["close"]);
|
||||
const emit = defineEmits(['close']);
|
||||
const total = ref(0);
|
||||
const queryParams = ref({
|
||||
pageNo: 1,
|
||||
@@ -83,7 +86,7 @@ const queryParams = ref({
|
||||
const diagnosisDefinitionList = ref([]);
|
||||
const selectRow = ref({});
|
||||
const title = computed(() => {
|
||||
return props.radio == "个人" ? "个人常用诊断" : "科室常用诊断";
|
||||
return props.radio == '个人' ? '个人常用诊断' : '科室常用诊断';
|
||||
});
|
||||
|
||||
getList();
|
||||
@@ -98,10 +101,10 @@ function submit() {
|
||||
saveDiagnosisBind({
|
||||
definitionId: selectRow.value.id,
|
||||
definitionName: selectRow.value.name,
|
||||
bindingEnum: props.radio == "个人" ? 1 : 2,
|
||||
bindingEnum: props.radio == '个人' ? 1 : 2,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
emit("close", "success");
|
||||
emit('close', 'success');
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -111,7 +114,7 @@ function queryDiagnosisUse() {
|
||||
}
|
||||
|
||||
function close() {
|
||||
emit("close");
|
||||
emit('close');
|
||||
}
|
||||
|
||||
function clickRow(row) {
|
||||
@@ -120,7 +123,11 @@ function clickRow(row) {
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
:deep( .pagination-container .el-pagination) {
|
||||
:deep(.pagination-container .el-pagination) {
|
||||
right: 20px !important;
|
||||
}
|
||||
</style>
|
||||
:deep(.el-dialog__body) {
|
||||
max-height: 10vh; /* 设置最大高度为视口高度的 60% */
|
||||
overflow-y: auto; /* 超出时显示纵向滚动条 */
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -1,22 +1,23 @@
|
||||
<template>
|
||||
<div>
|
||||
<el-table
|
||||
ref="emrTemplateRef"
|
||||
:data="emrTemplate"
|
||||
row-key="id"
|
||||
highlight-current-row
|
||||
@cell-click="clickRow"
|
||||
>
|
||||
<el-table-column label="模板名称" align="center" prop="templateName" />
|
||||
<el-table-column label="使用范围" align="center" prop="useScopeCode" />
|
||||
<el-table-column label="操作" align="center">
|
||||
<template #default="scope">
|
||||
<el-button link type="primary" @click.stop="handelDelete(scope.row)"
|
||||
>删除</el-button
|
||||
>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<el-scrollbar height="200px">
|
||||
<el-table
|
||||
ref="emrTemplateRef"
|
||||
:data="emrTemplate"
|
||||
row-key="id"
|
||||
highlight-current-row
|
||||
@cell-click="clickRow"
|
||||
>
|
||||
<el-table-column label="模板名称" align="center" prop="templateName" />
|
||||
<el-table-column label="使用范围" align="center" prop="useScopeCode" />
|
||||
<el-table-column label="操作" align="center">
|
||||
<template #default="scope">
|
||||
<el-button link type="primary" @click.stop="handelDelete(scope.row)">删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-scrollbar>
|
||||
|
||||
<pagination
|
||||
v-show="total > 0"
|
||||
:total="total"
|
||||
@@ -26,14 +27,14 @@
|
||||
/>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
<script setup>
|
||||
import { getEmrTemplateList, deleteEmrTemplate } from "../api";
|
||||
import { getEmrTemplateList, deleteEmrTemplate } from '../api';
|
||||
|
||||
const queryParams = ref({});
|
||||
const emrTemplate = ref([]);
|
||||
const emrTemplateRef = ref();
|
||||
const emits = defineEmits(["selectRow"]);
|
||||
const emits = defineEmits(['selectRow']);
|
||||
const { proxy } = getCurrentInstance();
|
||||
const selectRow = ref({});
|
||||
const props = defineProps({
|
||||
@@ -42,12 +43,12 @@ const props = defineProps({
|
||||
required: true,
|
||||
},
|
||||
});
|
||||
getList();
|
||||
// getList();
|
||||
function getList() {
|
||||
queryParams.value.useScopeCode = 1;
|
||||
getEmrTemplateList(queryParams.value).then((res) => {
|
||||
emrTemplate.value = res.data.records;
|
||||
console.log(emrTemplate.value,"emrTemplate.value")
|
||||
console.log(emrTemplate.value, 'emrTemplate.value');
|
||||
});
|
||||
}
|
||||
|
||||
@@ -55,15 +56,15 @@ function clickRow(row) {
|
||||
console.log(2123);
|
||||
|
||||
selectRow.value = JSON.parse(row.contextJson);
|
||||
emits("selectRow", selectRow.value);
|
||||
emits('selectRow', selectRow.value);
|
||||
}
|
||||
|
||||
function handelDelete(row) {
|
||||
deleteEmrTemplate(row.id.toString()).then((res) => {
|
||||
if (res.code == 200) {
|
||||
proxy.$modal.msgSuccess("删除成功");
|
||||
proxy.$modal.msgSuccess('删除成功');
|
||||
getList();
|
||||
}
|
||||
});
|
||||
}
|
||||
</script>
|
||||
</script>
|
||||
|
||||
@@ -88,18 +88,22 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="诊断:" prop="conditionId" label-width="100px">
|
||||
<el-form-item label="诊断:" prop="conditionDefId" label-width="100px">
|
||||
<el-select
|
||||
v-model="conditionId"
|
||||
v-model="conditionDefId"
|
||||
placeholder="诊断"
|
||||
style="width: 180px"
|
||||
style="width: 220px"
|
||||
filterable
|
||||
remote-show-suffix
|
||||
remote
|
||||
:remote-method="getInit"
|
||||
:disabled="title == '查看处方'"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in diagnosisList"
|
||||
:key="item.conditionId"
|
||||
v-for="item in diagnosisListOption"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.conditionId"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
@@ -115,6 +119,36 @@
|
||||
</el-form-item>
|
||||
</el-col> -->
|
||||
</el-row>
|
||||
<el-row :gutter="24" class="mb8">
|
||||
<el-col :span="12">
|
||||
<el-form-item label="慢病诊断:" prop="speConditionId" label-width="100px">
|
||||
<el-select
|
||||
v-model="speConditionId"
|
||||
placeholder="慢病时必填,非慢病不填"
|
||||
style="width: 220px"
|
||||
:disabled="title == '查看处方'"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in speDiagnosisList"
|
||||
:key="item.ybNo"
|
||||
:label="item.name"
|
||||
:value="item.ybNo"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<!-- <el-col :span="12">
|
||||
<el-form-item label="就诊ID:" prop="encounterId" label-width="100px">
|
||||
<el-input
|
||||
v-model="infoForm.encounterId"
|
||||
placeholder="就诊ID"
|
||||
clearable
|
||||
style="width: 260px"
|
||||
disabled
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col> -->
|
||||
</el-row>
|
||||
</el-form>
|
||||
<el-form :model="form" ref="formRef" :rules="rowRules">
|
||||
<div style="margin-bottom: 5px" v-if="title != '查看处方'">
|
||||
@@ -393,12 +427,12 @@
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { computed } from 'vue';
|
||||
import { computed, onMounted, ref } from 'vue';
|
||||
// import { calculateQuantityByDays, formatNumber } from '@/utils/his';
|
||||
import { reactive } from 'vue';
|
||||
// import { useModal, useDict } from '@/hooks';
|
||||
import { parseTime, formatNumber } from '@/utils/his';
|
||||
import { queryYbCatalogue } from './api';
|
||||
import { queryYbCatalogue, getDiagnosisList } from './api';
|
||||
import { debounce } from 'lodash-es';
|
||||
|
||||
import {
|
||||
@@ -409,6 +443,7 @@ import {
|
||||
getEncounterDiagnosis,
|
||||
deletePrescriptionInfo,
|
||||
getMedicationInfo,
|
||||
getChronicDisease,
|
||||
} from './api';
|
||||
import prescriptionMedicineList from './prescription/prescriptionMedicineList';
|
||||
const { proxy } = getCurrentInstance();
|
||||
@@ -462,10 +497,14 @@ const medicineSearchKey = ref('');
|
||||
const conditionId = ref(undefined);
|
||||
const selectRow = ref({});
|
||||
const diagnosisList = ref([]);
|
||||
const speDiagnosisList = ref([]);
|
||||
const prescriptionTypeList = ref([]);
|
||||
const form = reactive({
|
||||
medicationInfoList: [],
|
||||
});
|
||||
const diagnosisListOption = ref([])
|
||||
const conditionDefId = ref('')
|
||||
const speConditionId = ref('')
|
||||
|
||||
const infoForm = reactive({
|
||||
patientId: '', // 患者
|
||||
@@ -524,6 +563,14 @@ const unitMap = ref({
|
||||
unit: 'unit',
|
||||
});
|
||||
|
||||
function getInit(searchKey) {
|
||||
if(searchKey) {
|
||||
getDiagnosisList(searchKey).then(res => {
|
||||
diagnosisListOption.value = res.data
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
function open() {
|
||||
conditionId.value = props.prescriptionData.conditionId;
|
||||
getDiagnosisInfo();
|
||||
@@ -566,9 +613,13 @@ function getDiagnosisInfo() {
|
||||
});
|
||||
diagnosisInfo.value = diagnosisInfo[0];
|
||||
if (title.value === '新增处方') {
|
||||
conditionId.value = diagnosisInfo[0].conditionId;
|
||||
conditionId.value = diagnosisInfo[0].id;
|
||||
}
|
||||
});
|
||||
getChronicDisease({ encounterId: props.patient.encounterId }).then((res) => {
|
||||
speDiagnosisList.value = res.data;
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -735,6 +786,8 @@ function submit() {
|
||||
encounterId: infoForm.encounterId,
|
||||
prescriptionNo: infoForm.prescriptionNo,
|
||||
conditionId: conditionId.value,
|
||||
conditionDefId: conditionDefId.value,
|
||||
opspDiseCode: speConditionId.value,
|
||||
// rxTypeCode: infoForm.rxTypeCode,
|
||||
validityDays: infoForm.validityDays,
|
||||
extensionReason: infoForm.extensionReason,
|
||||
|
||||
@@ -108,7 +108,10 @@ function handleUseOrderGroup(row) {
|
||||
}
|
||||
|
||||
function getList() {
|
||||
getAdviceHistoryInfo({ patientId: props.patientInfo.patientId, encounterId: props.patientInfo.encounterId }).then((res) => {
|
||||
getAdviceHistoryInfo({
|
||||
patientId: props.patientInfo.patientId,
|
||||
encounterId: props.patientInfo.encounterId,
|
||||
}).then((res) => {
|
||||
orderList.value = res.data;
|
||||
});
|
||||
}
|
||||
@@ -116,4 +119,4 @@ function getList() {
|
||||
defineExpose({
|
||||
handleOpen,
|
||||
});
|
||||
</script>
|
||||
</script>
|
||||
|
||||
@@ -350,6 +350,11 @@
|
||||
:label="item.label"
|
||||
@click="
|
||||
() => {
|
||||
if (item.type == unitMap['minUnit']) {
|
||||
scope.row.unitPrice = scope.row.minUnitPrice;
|
||||
} else {
|
||||
scope.row.unitPrice = scope.row.unitTempPrice;
|
||||
}
|
||||
scope.row.unitCode_dictText = item.label;
|
||||
}
|
||||
"
|
||||
@@ -728,6 +733,7 @@ import {
|
||||
updateGroupId,
|
||||
getContract,
|
||||
getAdviceBaseInfo,
|
||||
getActivityBindDevice,
|
||||
} from '../api';
|
||||
import adviceBaseList from '../advicebaselist';
|
||||
import { computed, getCurrentInstance, nextTick, watch } from 'vue';
|
||||
@@ -736,6 +742,7 @@ import OrderGroupDrawer from './orderGroupDrawer';
|
||||
import PrescriptionHistory from './prescriptionHistory';
|
||||
import Decimal from 'decimal.js';
|
||||
import useUserStore from '@/store/modules/user';
|
||||
import { ElMessageBox } from 'element-plus';
|
||||
|
||||
const emit = defineEmits(['selectDiagnosis']);
|
||||
const total = ref(0);
|
||||
@@ -986,6 +993,21 @@ function handleChange(value) {
|
||||
* 选择药品回调
|
||||
*/
|
||||
function selectAdviceBase(key, row) {
|
||||
if (row.adviceType == 3) {
|
||||
getActivityBindDevice({ activityId: row.adviceDefinitionId }).then((res) => {
|
||||
if (res.data.activityBindDeviceInfos?.length > 0) {
|
||||
ElMessageBox.confirm('该诊疗项目已绑定所需耗材,点击确定将自动添加到医嘱列表', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
closeOnClickModal: false,
|
||||
closeOnPressEscape: false,
|
||||
}).then(() => {
|
||||
handleSaveGroup(res.data.activityBindDeviceInfos);
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
getOrgList();
|
||||
unitCodeList.value = [];
|
||||
unitCodeList.value.push({ value: row.unitCode, label: row.unitCode_dictText, type: 'unit' });
|
||||
@@ -1064,6 +1086,7 @@ function selectAdviceBase(key, row) {
|
||||
prescriptionList.value[rowIndex.value].inventoryId = stock.inventoryId;
|
||||
prescriptionList.value[rowIndex.value].locationId = stock.locationId;
|
||||
prescriptionList.value[rowIndex.value].unitPrice = stock.price;
|
||||
prescriptionList.value[rowIndex.value].unitTempPrice = stock.price;
|
||||
prescriptionList.value[rowIndex.value].minUnitPrice = new Decimal(stock.price)
|
||||
.div(row.partPercent)
|
||||
.toFixed(2);
|
||||
@@ -1310,14 +1333,17 @@ function handleSaveSign(row, index) {
|
||||
row.minUnitQuantity = row.quantity;
|
||||
}
|
||||
row.conditionId = conditionId.value;
|
||||
// if (row.unitCodeList.find((item) => item.value == row.unitCode).type == 'unit') {
|
||||
// row.unitPrice = row.unitPrice;
|
||||
// } else {
|
||||
// row.unitCode_dictText = row.unitCodeList.find(
|
||||
// (item) => item.value == row.minUnitCode
|
||||
// ).label;
|
||||
// row.unitPrice = row.minUnitPrice;
|
||||
// }
|
||||
// 处理总量为小单位情况,需要把单价也保存成小单位的
|
||||
if (row.unitCodeList.find((item) => item.value == row.unitCode).type == 'unit') {
|
||||
if (row.adviceType != 3) {
|
||||
row.unitPrice = row.unitTempPrice;
|
||||
}
|
||||
} else {
|
||||
row.unitCode_dictText = row.unitCodeList.find(
|
||||
(item) => item.value == row.minUnitCode
|
||||
).label;
|
||||
row.unitPrice = row.minUnitPrice;
|
||||
}
|
||||
row.conditionDefinitionId = conditionDefinitionId.value;
|
||||
row.encounterDiagnosisId = encounterDiagnosisId.value;
|
||||
row.diagnosisName = diagnosisName.value;
|
||||
@@ -1429,7 +1455,7 @@ function setValue(row) {
|
||||
// 库存列表 + 价格列表拼成批次号的下拉框
|
||||
if (row.adviceType != 3) {
|
||||
if (row.inventoryList && row.inventoryList.length == 0) {
|
||||
expandOrder.value = [];
|
||||
// expandOrder.value = [];
|
||||
proxy.$modal.msgWarning('该项目无库存');
|
||||
return;
|
||||
}
|
||||
@@ -1457,6 +1483,9 @@ function setValue(row) {
|
||||
prescriptionList.value[rowIndex.value].locationId = stock.locationId;
|
||||
prescriptionList.value[rowIndex.value].unitPrice = stock.price;
|
||||
prescriptionList.value[rowIndex.value].positionName = stock.locationName;
|
||||
prescriptionList.value[rowIndex.value].minUnitPrice = new Decimal(stock.price)
|
||||
.div(row.partPercent)
|
||||
.toFixed(2);
|
||||
}
|
||||
} else {
|
||||
prescriptionList.value[rowIndex.value].orgId = JSON.parse(JSON.stringify(row)).positionId;
|
||||
@@ -1496,6 +1525,7 @@ function handleSaveGroup(orderGroupList) {
|
||||
prescriptionList.value[rowIndex.value] = {
|
||||
...prescriptionList.value[rowIndex.value],
|
||||
// ...orderGroupValue,
|
||||
uniqueKey: nextId.value++,
|
||||
patientId: props.patientInfo.patientId,
|
||||
encounterId: props.patientInfo.encounterId,
|
||||
accountId: accountId.value,
|
||||
@@ -1802,10 +1832,14 @@ const groupMarkers = ref([]);
|
||||
// 计算总价
|
||||
function calculateTotalPrice(row, index) {
|
||||
nextTick(() => {
|
||||
if (row.unitCode == row.minUnitCode) {
|
||||
row.totalPrice = new Decimal(row.unitPrice).div(row.partPercent) * row.quantity;
|
||||
} else {
|
||||
if (row.adviceType == 3) {
|
||||
row.totalPrice = (row.unitPrice * row.quantity * 100) / 100;
|
||||
} else {
|
||||
if (row.unitCode == row.minUnitCode) {
|
||||
row.totalPrice = row.minUnitPrice * row.quantity;
|
||||
} else {
|
||||
row.totalPrice = (row.unitPrice * row.quantity * 100) / 100;
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user