From 5d6de5d4370524ad78dc4b2b208095639a133339 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Wed, 26 Oct 2022 12:28:52 +0200 Subject: [PATCH] Bug 32030: I18N rewrite - replace $t with $__ Signed-off-by: Jonathan Field Signed-off-by: Martin Renvoize Signed-off-by: Kyle M Hall Signed-off-by: Tomas Cohen Arazi --- cypress/integration/Licenses_spec.ts | 2 +- .../intranet-tmpl/prog/en/modules/erm/erm.tt | 2 - .../vue/components/ERM/AgreementLicenses.vue | 28 ++--- .../vue/components/ERM/AgreementPeriods.vue | 18 +-- .../components/ERM/AgreementRelationships.vue | 22 ++-- .../vue/components/ERM/AgreementUserRoles.vue | 16 +-- .../vue/components/ERM/AgreementsFormAdd.vue | 46 +++---- .../ERM/AgreementsFormConfirmDelete.vue | 16 +-- .../js/vue/components/ERM/AgreementsList.vue | 10 +- .../js/vue/components/ERM/AgreementsShow.vue | 66 +++++------ .../vue/components/ERM/AgreementsToolbar.vue | 2 +- .../prog/js/vue/components/ERM/Breadcrumb.vue | 4 +- .../prog/js/vue/components/ERM/Dialog.vue | 2 +- .../prog/js/vue/components/ERM/Documents.vue | 36 +++--- .../vue/components/ERM/EHoldingsEBSCOHome.vue | 4 +- .../ERM/EHoldingsEBSCOPackageAgreements.vue | 8 +- .../ERM/EHoldingsEBSCOPackageTitlesList.vue | 18 +-- .../ERM/EHoldingsEBSCOPackagesList.vue | 26 ++-- .../ERM/EHoldingsEBSCOPackagesShow.vue | 22 ++-- .../ERM/EHoldingsEBSCOResourcesShow.vue | 30 ++--- .../ERM/EHoldingsEBSCOTitlePackagesList.vue | 14 +-- .../ERM/EHoldingsEBSCOTitlesList.vue | 24 ++-- .../ERM/EHoldingsEBSCOTitlesShow.vue | 58 ++++----- .../vue/components/ERM/EHoldingsLocalHome.vue | 4 +- .../ERM/EHoldingsLocalPackageAgreements.vue | 14 +-- .../ERM/EHoldingsLocalPackagesFormAdd.vue | 28 ++--- ...HoldingsLocalPackagesFormConfirmDelete.vue | 12 +- .../ERM/EHoldingsLocalPackagesList.vue | 4 +- .../ERM/EHoldingsLocalPackagesShow.vue | 30 ++--- .../ERM/EHoldingsLocalPackagesToolbar.vue | 2 +- .../ERM/EHoldingsLocalResourcesShow.vue | 26 ++-- .../ERM/EHoldingsLocalTitlesFormAdd.vue | 112 +++++++++--------- .../EHoldingsLocalTitlesFormAddResources.vue | 24 ++-- .../EHoldingsLocalTitlesFormConfirmDelete.vue | 12 +- .../ERM/EHoldingsLocalTitlesFormImport.vue | 10 +- .../ERM/EHoldingsLocalTitlesList.vue | 4 +- .../ERM/EHoldingsLocalTitlesShow.vue | 62 +++++----- .../ERM/EHoldingsLocalTitlesToolbar.vue | 4 +- .../js/vue/components/ERM/EHoldingsMain.vue | 8 +- .../prog/js/vue/components/ERM/ERMMain.vue | 20 ++-- .../js/vue/components/ERM/LicensesFormAdd.vue | 40 +++---- .../ERM/LicensesFormConfirmDelete.vue | 14 +-- .../js/vue/components/ERM/LicensesList.vue | 4 +- .../js/vue/components/ERM/LicensesShow.vue | 32 ++--- .../js/vue/components/ERM/LicensesToolbar.vue | 2 +- .../intranet-tmpl/prog/js/vue/main-erm.ts | 4 +- 46 files changed, 471 insertions(+), 475 deletions(-) diff --git a/cypress/integration/Licenses_spec.ts b/cypress/integration/Licenses_spec.ts index 6bf44853be..893df6cb8d 100644 --- a/cypress/integration/Licenses_spec.ts +++ b/cypress/integration/Licenses_spec.ts @@ -42,7 +42,7 @@ describe("License CRUD operations", () => { // GET licenses returns empty list cy.intercept("GET", "/api/v1/erm/licenses*", []); cy.visit("/cgi-bin/koha/erm/licenses"); - cy.get("#licenses_list").contains("There are no licenses defined."); + cy.get("#licenses_list").contains("There are no licenses defined"); // GET licenses returns something let license = get_license(); diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/erm/erm.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/erm/erm.tt index 3e00156a77..962537a304 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/erm/erm.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/erm/erm.tt @@ -56,8 +56,6 @@ const ERMModule = [% IF Koha.Preference('ERMModule') %]true[% ELSE %]false[% END %]; - const lang = "[% lang || 'en' | html %]"; - const logged_in_user_lists = [% To.json(logged_in_user.virtualshelves.unblessed) | $raw %]; diff --git a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementLicenses.vue b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementLicenses.vue index ecdd211737..4b523d84c3 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementLicenses.vue +++ b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementLicenses.vue @@ -1,6 +1,6 @@ - {{ $t("Required") }} + {{ $__("Required") }}
  • {{ $__("Status") }}: - {{ $t("Required") }} + {{ $__("Required") }}
  • {{ $__("Notes") }}:
  • {{ $__("URI") }}:
  • {{ $t("Add new license") }} {{ $__("Add new license") }} - {{ $t("There are no licenses created yet") }} + {{ $__("There are no licenses created yet") }} diff --git a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementPeriods.vue b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementPeriods.vue index e0398f8a8e..edaad8f06f 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementPeriods.vue +++ b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementPeriods.vue @@ -1,6 +1,6 @@ diff --git a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementRelationships.vue b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementRelationships.vue index 7110f00fc6..845fe7a6fb 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementRelationships.vue +++ b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementRelationships.vue @@ -1,22 +1,22 @@ - {{ $t("Required") }} + {{ $__("Required") }}
  • - {{ $t("Required") }} + {{ $__("Required") }}
  • {{ $__("Notes") }}:
  • @@ -75,10 +75,10 @@ class="btn btn-default" @click="addRelationship" > - {{ $t("Add new related agreement") }} {{ - $t("There are no other agreements created yet") + $__("There are no other agreements created yet") }} diff --git a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementUserRoles.vue b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementUserRoles.vue index fc2dd672d6..dad31f2bbe 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementUserRoles.vue +++ b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementUserRoles.vue @@ -1,20 +1,20 @@ - {{ $t("Required") }} + {{ $__("Required") }} @@ -55,7 +55,7 @@ id="selected_patron_id" /> {{ $t("Add new user") }} {{ $__("Add new user") }} diff --git a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementsFormAdd.vue b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementsFormAdd.vue index 96cd976582..9aeaf49ebb 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementsFormAdd.vue +++ b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementsFormAdd.vue @@ -1,10 +1,10 @@