669 [门诊医生站-中医处方] 中医处方头信息(费用性质、频次、天数、付数等)在保存并重新进入后回显为空
This commit is contained in:
@@ -656,6 +656,30 @@ async function getListInfo(addNewRow) {
|
||||
}
|
||||
|
||||
prescription.prescriptionList = groupedData[groupId];
|
||||
|
||||
// 🔧 BugFix#669: 从分组数据的第一条提取处方头字段回显
|
||||
const firstItem = groupedData[groupId]?.[0];
|
||||
if (firstItem) {
|
||||
if (firstItem.accountId !== undefined && firstItem.accountId !== null) {
|
||||
prescription.accountId = firstItem.accountId;
|
||||
}
|
||||
if (firstItem.methodCode !== undefined && firstItem.methodCode !== null) {
|
||||
prescription.methodCode = firstItem.methodCode;
|
||||
}
|
||||
if (firstItem.rateCode !== undefined && firstItem.rateCode !== null) {
|
||||
prescription.rateCode = firstItem.rateCode;
|
||||
}
|
||||
if (firstItem.dispensePerDuration !== undefined && firstItem.dispensePerDuration !== null) {
|
||||
prescription.dispensePerDuration = firstItem.dispensePerDuration;
|
||||
}
|
||||
if (firstItem.chineseHerbsDoseQuantity !== undefined && firstItem.chineseHerbsDoseQuantity !== null) {
|
||||
prescription.chineseHerbsDoseQuantity = firstItem.chineseHerbsDoseQuantity;
|
||||
}
|
||||
if (firstItem.sufferingFlag !== undefined && firstItem.sufferingFlag !== null) {
|
||||
prescription.sufferingFlag = firstItem.sufferingFlag;
|
||||
}
|
||||
}
|
||||
|
||||
return prescription;
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user