版本更新
This commit is contained in:
@@ -70,6 +70,7 @@
|
||||
|
||||
<script setup>
|
||||
import { getYbMedicationList, queryYbCatalogue } from './medicine';
|
||||
import { formatDateStr } from '@/utils/index';
|
||||
|
||||
const emit = defineEmits(['selectMedicine']);
|
||||
const visible = ref(false);
|
||||
@@ -107,28 +108,33 @@ function cancel() {
|
||||
}
|
||||
|
||||
function handlewAddMedicine(row) {
|
||||
queryYbCatalogue({ hilistCode: row.medicalCatalogCode, dateStr: '2020-01-01' }).then((res) => {
|
||||
if (res.data.length > 0) {
|
||||
let resultList = res.data.filter((item) => {
|
||||
return (
|
||||
item.memo != null &&
|
||||
item.memo != '' &&
|
||||
item.memo != 'null' &&
|
||||
item.memo != '目录变更' &&
|
||||
item.memo != '历史数据迁移' &&
|
||||
item.memo != '0' &&
|
||||
item.memo != ' '
|
||||
);
|
||||
});
|
||||
if (resultList.length > 0) {
|
||||
row.restrictedFlag = 1;
|
||||
row.restrictedScope = resultList[0].memo;
|
||||
queryYbCatalogue({
|
||||
hilistCode: row.medicalCatalogCode,
|
||||
dateStr: formatDateStr(new Date(), 'YYYY') + '-01-01',
|
||||
})
|
||||
.then((res) => {
|
||||
if (res.data.length > 0) {
|
||||
let resultList = res.data.filter((item) => {
|
||||
return (
|
||||
item.memo != null &&
|
||||
item.memo != '' &&
|
||||
item.memo != 'null' &&
|
||||
item.memo != '目录变更' &&
|
||||
item.memo != '历史数据迁移' &&
|
||||
item.memo != '0' &&
|
||||
item.memo != ' '
|
||||
);
|
||||
});
|
||||
if (resultList.length > 0) {
|
||||
row.restrictedFlag = 1;
|
||||
row.restrictedScope = resultList[0].memo;
|
||||
}
|
||||
}
|
||||
}
|
||||
emit('selectMedicine', row);
|
||||
}).catch(() => {
|
||||
emit('selectMedicine', row);
|
||||
});
|
||||
emit('selectMedicine', row);
|
||||
})
|
||||
.catch(() => {
|
||||
emit('selectMedicine', row);
|
||||
});
|
||||
cancel();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user