更新
This commit is contained in:
@@ -92,29 +92,16 @@
|
||||
</div>
|
||||
</template>
|
||||
</template>
|
||||
<!-- 处方联:不写「主方/辅方」,药材连续展示 -->
|
||||
<template v-else>
|
||||
<template v-if="mainHerbs.length">
|
||||
<div class="rx-herb-section-label">主方</div>
|
||||
<div
|
||||
v-for="(h, i) in mainHerbs"
|
||||
:key="'user-main-' + i"
|
||||
class="rx-herb-cell"
|
||||
>
|
||||
<span class="rx-herb-name">{{ h.name }}</span>
|
||||
<span class="rx-herb-total">{{ h.dosage }}克</span>
|
||||
</div>
|
||||
</template>
|
||||
<template v-if="auxHerbs.length">
|
||||
<div class="rx-herb-section-label rx-herb-section-label--aux">辅方</div>
|
||||
<div
|
||||
v-for="(h, i) in auxHerbs"
|
||||
:key="'user-aux-' + i"
|
||||
class="rx-herb-cell"
|
||||
>
|
||||
<span class="rx-herb-name">{{ h.name }}</span>
|
||||
<span class="rx-herb-total">{{ h.dosage }}克</span>
|
||||
</div>
|
||||
</template>
|
||||
<div
|
||||
v-for="(h, i) in userHerbs"
|
||||
:key="'user-' + i"
|
||||
class="rx-herb-cell"
|
||||
>
|
||||
<span class="rx-herb-name">{{ h.name }}</span>
|
||||
<span class="rx-herb-total">{{ h.dosage }}克</span>
|
||||
</div>
|
||||
</template>
|
||||
</div>
|
||||
</div>
|
||||
@@ -229,6 +216,8 @@ const genderLabel = computed(() => slipGenderLabel(props.data?.gender))
|
||||
const ageText = computed(() => slipAgeText(props.data?.age))
|
||||
const mainHerbs = computed(() => getMainHerbs(props.data))
|
||||
const auxHerbs = computed(() => getAuxHerbs(props.data))
|
||||
/** 处方联用药列表:主+辅连续排列,不标注主/辅方 */
|
||||
const userHerbs = computed(() => [...mainHerbs.value, ...auxHerbs.value])
|
||||
const usageText = computed(() => rxUsageText(props.data))
|
||||
const auxUsageText = computed(() => rxAuxUsageText(props.data))
|
||||
const adviceText = computed(() => rxAdviceText(props.data))
|
||||
|
||||
Reference in New Issue
Block a user