fix: 修复#444计费药品列表未显示药品名称
- 添加更多字段回退逻辑:chargeName, itemName等 - 确保即使contentJson中没有adviceName也能显示药品名称 - 添加默认值'未知药品'避免空显示
This commit is contained in:
@@ -1494,7 +1494,7 @@ function handleMedicalAdvice(row) {
|
|||||||
const jsonContent = item.contentJson || item.content_json;
|
const jsonContent = item.contentJson || item.content_json;
|
||||||
const contentData = jsonContent ? JSON.parse(jsonContent) : {};
|
const contentData = jsonContent ? JSON.parse(jsonContent) : {};
|
||||||
return {
|
return {
|
||||||
medicineName: contentData.adviceName || contentData.advice_name || item.adviceName || item.advice_name || '',
|
medicineName: contentData.adviceName || contentData.advice_name || item.adviceName || item.advice_name || item.chargeName || item.charge_name || contentData.itemName || contentData.item_name || '未知药品',
|
||||||
specification: contentData.volume || contentData.specification || item.volume || item.specification || '',
|
specification: contentData.volume || contentData.specification || item.volume || item.specification || '',
|
||||||
quantity: contentData.quantity || item.quantity || 0,
|
quantity: contentData.quantity || item.quantity || 0,
|
||||||
batchNumber: contentData.lotNumber || contentData.lot_number || item.lotNumber || item.lot_number || '',
|
batchNumber: contentData.lotNumber || contentData.lot_number || item.lotNumber || item.lot_number || '',
|
||||||
|
|||||||
Reference in New Issue
Block a user