trans-history: concepto multiidioma (helper de concepto compartido)
Extrae la lógica de concepto traducible a lib/tx-concept.ts (buildConcept + purchasedPD + SERVICE_CONCEPT) y la reutilizan points-history y trans-history. La columna Concepto de trans-history ahora se traduce (reusa History.points.concept.*) en vez de mostrar el product_name en español. Corrige también la sombra de variable en PlatformBox (map t -> tx). Verificado con la cuenta 15. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -73,22 +73,22 @@ async function PlatformBox({
|
||||
<th>{t('trans.thCreatedAt')}</th>
|
||||
<th>{t('trans.thAmount')}</th>
|
||||
</tr>
|
||||
{txs.map((t) => (
|
||||
<tr key={t.id}>
|
||||
{txs.map((tx) => (
|
||||
<tr key={tx.id}>
|
||||
<td className="long-td">
|
||||
<span>{t.id}</span>
|
||||
<span>{tx.id}</span>
|
||||
</td>
|
||||
<td>
|
||||
<StatusBadge status={t.status} />
|
||||
<StatusBadge status={tx.status} />
|
||||
</td>
|
||||
<td className="responsive-td">
|
||||
<span>{t.concept}</span>
|
||||
<span>{tx.conceptKey ? t(`points.concept.${tx.conceptKey}`, tx.conceptArgs) : tx.conceptRaw}</span>
|
||||
</td>
|
||||
<td>
|
||||
<span>{fmt(t.createdAt)}</span>
|
||||
<span>{fmt(tx.createdAt)}</span>
|
||||
</td>
|
||||
<td>
|
||||
<span>{t.amount.toFixed(2)} €</span>
|
||||
<span>{tx.amount.toFixed(2)} €</span>
|
||||
</td>
|
||||
</tr>
|
||||
))}
|
||||
|
||||
Reference in New Issue
Block a user