diff --git a/app/Console/Commands/VerifyDatabase.php b/app/Console/Commands/VerifyDatabase.php index aea9a40417..1eddd1fdab 100644 --- a/app/Console/Commands/VerifyDatabase.php +++ b/app/Console/Commands/VerifyDatabase.php @@ -112,7 +112,7 @@ class VerifyDatabase extends Command private function createLinkTypes() { $set = [ - 'Relates' => ['relates to', 'relates to'], + 'Related' => ['relates to', 'relates to'], 'Refund' => ['(partially) refunds', 'is (partially) refunded by'], 'Paid' => ['(partially) pays for', 'is (partially) paid for by'], 'Reimbursement' => ['(partially) reimburses', 'is (partially) reimbursed by'], diff --git a/app/Support/Twig/Translation.php b/app/Support/Twig/Translation.php index 40ce29ebdb..32426796f7 100644 --- a/app/Support/Twig/Translation.php +++ b/app/Support/Twig/Translation.php @@ -71,8 +71,8 @@ class Translation extends Twig_Extension public function journalLinkTranslation(): Twig_SimpleFunction { return new Twig_SimpleFunction( - 'journalLinkTranslation', function (int $linkTypeId, string $direction, string $original) { - $key = sprintf('firefly.%d_%s', $linkTypeId, $direction); + 'journalLinkTranslation', function (string $direction, string $original) { + $key = sprintf('firefly.%s_%s', $original, $direction); $translation = trans($key); if ($key === $translation) { return $original; diff --git a/resources/lang/en_US/firefly.php b/resources/lang/en_US/firefly.php index 66928138b4..964414594a 100644 --- a/resources/lang/en_US/firefly.php +++ b/resources/lang/en_US/firefly.php @@ -942,15 +942,6 @@ return [ 'overview_for_link' => 'Overview for link type ":name"', 'delete_journal_link' => 'Delete the link between :source and :destination', 'deleted_link' => 'Deleted link', - '1_outward' => 'relates to', - '2_outward' => '(partially) refunds', - '3_outward' => '(partially) pays for', - '4_outward' => '(partially) reimburses', - '1_inward' => 'relates to', - '2_inward' => 'is (partially) refunded by', - '3_inward' => 'is (partially) paid for by', - '4_inward' => 'is (partially) reimbursed by', - // split a transaction: 'splits' => 'Splits', diff --git a/resources/views/transactions/show.twig b/resources/views/transactions/show.twig index 8c50f019f6..3416cc4284 100644 --- a/resources/views/transactions/show.twig +++ b/resources/views/transactions/show.twig @@ -315,6 +315,7 @@ {% endif %} + {# show links: #} {% if links.count > 0 %}