Skip to content

Open-source manufacturing ERP, MES and QMS. Quoting, MRP, inventory, shop floor, quality and lot/serial traceability on one Postgres schema, with a REST API and MCP server. Self-host or use Carbon Cloud.

fix: improve error handling in forwardToGtm function

naveenkash59d00270f4f0
diff --git a/packages/locale/locales/de/erp.po b/packages/locale/locales/de/erp.po
index dc4ffea94e..72d1ab06c1 100644
--- a/packages/locale/locales/de/erp.po
+++ b/packages/locale/locales/de/erp.po
@@ -764,7 +764,7 @@ msgstr "API-Schlüssel"
#: apps/erp/app/modules/settings/ui/ApiKeys/ApiKeysTable.tsx:215
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:124
-#: apps/erp/app/routes/x+/settings+/api-keys.tsx:13
+#: apps/erp/app/routes/x+/settings+/api-keys.tsx:15
msgid "API Keys"
msgstr "API-Schlüssel"
@@ -985,7 +985,7 @@ msgid "Are you sure you want to delete the account: {0} ({1})? This cannot be un
msgstr "Sind Sie sicher, dass Sie das Konto löschen möchten: {0} ({1})? Dies kann nicht rückgängig gemacht werden."
#. placeholder {0}: apiKey.name
-#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:56
+#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:64
msgid "Are you sure you want to delete the API key: {0}? This cannot be undone."
msgstr "Sind Sie sicher, dass Sie den API-Schlüssel: {0}? löschen möchten? Dies kann nicht rückgängig gemacht werden."
@@ -1181,7 +1181,7 @@ msgid "Are you sure you want to delete the view \"{0}\"?"
msgstr "Sind Sie sicher, dass Sie die Ansicht \"{0}\" löschen möchten?"
#. placeholder {0}: webhook.name
-#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:76
+#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:84
msgid "Are you sure you want to delete the webhook: {0}? This cannot be undone."
msgstr "Sind Sie sicher, dass Sie den Webhook löschen möchten: {0}? Dies kann nicht rückgängig gemacht werden."
@@ -14761,7 +14761,7 @@ msgstr "Webhook-URL"
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:160
#: apps/erp/app/modules/settings/ui/Webhooks/WebhooksTable.tsx:227
-#: apps/erp/app/routes/x+/settings+/webhooks.tsx:14
+#: apps/erp/app/routes/x+/settings+/webhooks.tsx:16
msgid "Webhooks"
msgstr "Webhooks"
diff --git a/packages/locale/locales/en/erp.po b/packages/locale/locales/en/erp.po
index 4a9b5e9800..5f2d7e3a73 100644
--- a/packages/locale/locales/en/erp.po
+++ b/packages/locale/locales/en/erp.po
@@ -764,7 +764,7 @@ msgstr "API Key"
#: apps/erp/app/modules/settings/ui/ApiKeys/ApiKeysTable.tsx:215
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:124
-#: apps/erp/app/routes/x+/settings+/api-keys.tsx:13
+#: apps/erp/app/routes/x+/settings+/api-keys.tsx:15
msgid "API Keys"
msgstr "API Keys"
@@ -985,7 +985,7 @@ msgid "Are you sure you want to delete the account: {0} ({1})? This cannot be un
msgstr "Are you sure you want to delete the account: {0} ({1})? This cannot be undone."
#. placeholder {0}: apiKey.name
-#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:56
+#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:64
msgid "Are you sure you want to delete the API key: {0}? This cannot be undone."
msgstr "Are you sure you want to delete the API key: {0}? This cannot be undone."
@@ -1181,7 +1181,7 @@ msgid "Are you sure you want to delete the view \"{0}\"?"
msgstr "Are you sure you want to delete the view \"{0}\"?"
#. placeholder {0}: webhook.name
-#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:76
+#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:84
msgid "Are you sure you want to delete the webhook: {0}? This cannot be undone."
msgstr "Are you sure you want to delete the webhook: {0}? This cannot be undone."
@@ -14761,7 +14761,7 @@ msgstr "Webhook URL"
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:160
#: apps/erp/app/modules/settings/ui/Webhooks/WebhooksTable.tsx:227
-#: apps/erp/app/routes/x+/settings+/webhooks.tsx:14
+#: apps/erp/app/routes/x+/settings+/webhooks.tsx:16
msgid "Webhooks"
msgstr "Webhooks"
diff --git a/packages/locale/locales/es/erp.po b/packages/locale/locales/es/erp.po
index f33647daef..2b974bdb03 100644
--- a/packages/locale/locales/es/erp.po
+++ b/packages/locale/locales/es/erp.po
@@ -764,7 +764,7 @@ msgstr "Clave API"
#: apps/erp/app/modules/settings/ui/ApiKeys/ApiKeysTable.tsx:215
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:124
-#: apps/erp/app/routes/x+/settings+/api-keys.tsx:13
+#: apps/erp/app/routes/x+/settings+/api-keys.tsx:15
msgid "API Keys"
msgstr "Claves API"
@@ -985,7 +985,7 @@ msgid "Are you sure you want to delete the account: {0} ({1})? This cannot be un
msgstr "¿Estás seguro de que deseas eliminar la cuenta: {0} ({1})? Esto no se puede deshacer."
#. placeholder {0}: apiKey.name
-#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:56
+#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:64
msgid "Are you sure you want to delete the API key: {0}? This cannot be undone."
msgstr "¿Estás seguro de que deseas eliminar la clave API: {0}? Esto no se puede deshacer."
@@ -1181,7 +1181,7 @@ msgid "Are you sure you want to delete the view \"{0}\"?"
msgstr "¿Estás seguro de que deseas eliminar la vista \"{0}\"?"
#. placeholder {0}: webhook.name
-#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:76
+#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:84
msgid "Are you sure you want to delete the webhook: {0}? This cannot be undone."
msgstr "¿Estás seguro de que deseas eliminar el webhook: {0}? Esto no se puede deshacer."
@@ -14761,7 +14761,7 @@ msgstr "URL de Webhook"
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:160
#: apps/erp/app/modules/settings/ui/Webhooks/WebhooksTable.tsx:227
-#: apps/erp/app/routes/x+/settings+/webhooks.tsx:14
+#: apps/erp/app/routes/x+/settings+/webhooks.tsx:16
msgid "Webhooks"
msgstr "Webhooks"
diff --git a/packages/locale/locales/fr/erp.po b/packages/locale/locales/fr/erp.po
index cdba268414..b930620e45 100644
--- a/packages/locale/locales/fr/erp.po
+++ b/packages/locale/locales/fr/erp.po
@@ -764,7 +764,7 @@ msgstr "Clé API"
#: apps/erp/app/modules/settings/ui/ApiKeys/ApiKeysTable.tsx:215
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:124
-#: apps/erp/app/routes/x+/settings+/api-keys.tsx:13
+#: apps/erp/app/routes/x+/settings+/api-keys.tsx:15
msgid "API Keys"
msgstr "Clés API"
@@ -985,7 +985,7 @@ msgid "Are you sure you want to delete the account: {0} ({1})? This cannot be un
msgstr "Êtes-vous sûr de vouloir supprimer le compte : {0} ({1}) ? Cette action ne peut pas être annulée."
#. placeholder {0}: apiKey.name
-#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:56
+#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:64
msgid "Are you sure you want to delete the API key: {0}? This cannot be undone."
msgstr "Êtes-vous sûr de vouloir supprimer la clé API : {0}? Cette action ne peut pas être annulée."
@@ -1181,7 +1181,7 @@ msgid "Are you sure you want to delete the view \"{0}\"?"
msgstr "Êtes-vous sûr de vouloir supprimer la vue « {0} » ?"
#. placeholder {0}: webhook.name
-#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:76
+#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:84
msgid "Are you sure you want to delete the webhook: {0}? This cannot be undone."
msgstr "Êtes-vous sûr de vouloir supprimer le webhook : {0} ? Cette action ne peut pas être annulée."
@@ -14761,7 +14761,7 @@ msgstr "URL du webhook"
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:160
#: apps/erp/app/modules/settings/ui/Webhooks/WebhooksTable.tsx:227
-#: apps/erp/app/routes/x+/settings+/webhooks.tsx:14
+#: apps/erp/app/routes/x+/settings+/webhooks.tsx:16
msgid "Webhooks"
msgstr "Webhooks"
diff --git a/packages/locale/locales/hi/erp.po b/packages/locale/locales/hi/erp.po
index 53c1d6eb97..5638838304 100644
--- a/packages/locale/locales/hi/erp.po
+++ b/packages/locale/locales/hi/erp.po
@@ -764,7 +764,7 @@ msgstr "एपीआई कुंजी"
#: apps/erp/app/modules/settings/ui/ApiKeys/ApiKeysTable.tsx:215
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:124
-#: apps/erp/app/routes/x+/settings+/api-keys.tsx:13
+#: apps/erp/app/routes/x+/settings+/api-keys.tsx:15
msgid "API Keys"
msgstr "एपीआई कुंजियाँ"
@@ -985,7 +985,7 @@ msgid "Are you sure you want to delete the account: {0} ({1})? This cannot be un
msgstr "क्या आप सुनिश्चित हैं कि आप खाता हटाना चाहते हैं: {0} ({1})? यह पूर्ववत नहीं किया जा सकता।"
#. placeholder {0}: apiKey.name
-#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:56
+#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:64
msgid "Are you sure you want to delete the API key: {0}? This cannot be undone."
msgstr "क्या आप सुनिश्चित हैं कि आप API कुंजी को हटाना चाहते हैं: {0}? यह पूर्ववत नहीं किया जा सकता।"
@@ -1181,7 +1181,7 @@ msgid "Are you sure you want to delete the view \"{0}\"?"
msgstr "क्या आप सुनिश्चित हैं कि आप दृश्य \"{0}\" को हटाना चाहते हैं?"
#. placeholder {0}: webhook.name
-#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:76
+#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:84
msgid "Are you sure you want to delete the webhook: {0}? This cannot be undone."
msgstr "क्या आप सुनिश्चित हैं कि आप वेबहुक को हटाना चाहते हैं: {0}? यह पूर्ववत नहीं किया जा सकता।"
@@ -14761,7 +14761,7 @@ msgstr "वेबहुक URL"
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:160
#: apps/erp/app/modules/settings/ui/Webhooks/WebhooksTable.tsx:227
-#: apps/erp/app/routes/x+/settings+/webhooks.tsx:14
+#: apps/erp/app/routes/x+/settings+/webhooks.tsx:16
msgid "Webhooks"
msgstr "वेबहुक"
diff --git a/packages/locale/locales/it/erp.po b/packages/locale/locales/it/erp.po
index 018bdc10a2..ecea834032 100644
--- a/packages/locale/locales/it/erp.po
+++ b/packages/locale/locales/it/erp.po
@@ -764,7 +764,7 @@ msgstr "Chiave API"
#: apps/erp/app/modules/settings/ui/ApiKeys/ApiKeysTable.tsx:215
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:124
-#: apps/erp/app/routes/x+/settings+/api-keys.tsx:13
+#: apps/erp/app/routes/x+/settings+/api-keys.tsx:15
msgid "API Keys"
msgstr "Chiavi API"
@@ -985,7 +985,7 @@ msgid "Are you sure you want to delete the account: {0} ({1})? This cannot be un
msgstr "Sei sicuro di voler eliminare il conto: {0} ({1})? Questa azione non può essere annullata."
#. placeholder {0}: apiKey.name
-#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:56
+#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:64
msgid "Are you sure you want to delete the API key: {0}? This cannot be undone."
msgstr "Sei sicuro di voler eliminare la chiave API: {0}? Questa azione non può essere annullata."
@@ -1181,7 +1181,7 @@ msgid "Are you sure you want to delete the view \"{0}\"?"
msgstr "Sei sicuro di voler eliminare la vista \"{0}\"?"
#. placeholder {0}: webhook.name
-#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:76
+#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:84
msgid "Are you sure you want to delete the webhook: {0}? This cannot be undone."
msgstr "Sei sicuro di voler eliminare il webhook: {0}? Questa azione non può essere annullata."
@@ -14761,7 +14761,7 @@ msgstr "URL Webhook"
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:160
#: apps/erp/app/modules/settings/ui/Webhooks/WebhooksTable.tsx:227
-#: apps/erp/app/routes/x+/settings+/webhooks.tsx:14
+#: apps/erp/app/routes/x+/settings+/webhooks.tsx:16
msgid "Webhooks"
msgstr "Webhook"
diff --git a/packages/locale/locales/ja/erp.po b/packages/locale/locales/ja/erp.po
index 14741c1cc4..6672ee524d 100644
--- a/packages/locale/locales/ja/erp.po
+++ b/packages/locale/locales/ja/erp.po
@@ -764,7 +764,7 @@ msgstr "APIキー"
#: apps/erp/app/modules/settings/ui/ApiKeys/ApiKeysTable.tsx:215
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:124
-#: apps/erp/app/routes/x+/settings+/api-keys.tsx:13
+#: apps/erp/app/routes/x+/settings+/api-keys.tsx:15
msgid "API Keys"
msgstr "APIキー"
@@ -985,7 +985,7 @@ msgid "Are you sure you want to delete the account: {0} ({1})? This cannot be un
msgstr "このアカウントを削除してもよろしいですか: {0} ({1})? この操作は取り消せません。"
#. placeholder {0}: apiKey.name
-#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:56
+#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:64
msgid "Are you sure you want to delete the API key: {0}? This cannot be undone."
msgstr "API キー: {0} を削除してもよろしいですか?この操作は取り消せません。"
@@ -1181,7 +1181,7 @@ msgid "Are you sure you want to delete the view \"{0}\"?"
msgstr "本当に「{0}」ビューを削除してもよろしいですか?"
#. placeholder {0}: webhook.name
-#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:76
+#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:84
msgid "Are you sure you want to delete the webhook: {0}? This cannot be undone."
msgstr "本当にウェブフック: {0} を削除してもよろしいですか?この操作は取り消せません。"
@@ -14761,7 +14761,7 @@ msgstr "Webhook URL"
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:160
#: apps/erp/app/modules/settings/ui/Webhooks/WebhooksTable.tsx:227
-#: apps/erp/app/routes/x+/settings+/webhooks.tsx:14
+#: apps/erp/app/routes/x+/settings+/webhooks.tsx:16
msgid "Webhooks"
msgstr "ウェブフック"
diff --git a/packages/locale/locales/pl/erp.po b/packages/locale/locales/pl/erp.po
index 2b418a617e..d12af4e6c8 100644
--- a/packages/locale/locales/pl/erp.po
+++ b/packages/locale/locales/pl/erp.po
@@ -764,7 +764,7 @@ msgstr "Klucz API"
#: apps/erp/app/modules/settings/ui/ApiKeys/ApiKeysTable.tsx:215
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:124
-#: apps/erp/app/routes/x+/settings+/api-keys.tsx:13
+#: apps/erp/app/routes/x+/settings+/api-keys.tsx:15
msgid "API Keys"
msgstr "Klucze API"
@@ -985,7 +985,7 @@ msgid "Are you sure you want to delete the account: {0} ({1})? This cannot be un
msgstr "Czy na pewno chcesz usunąć konto: {0} ({1})? Tej operacji nie można cofnąć."
#. placeholder {0}: apiKey.name
-#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:56
+#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:64
msgid "Are you sure you want to delete the API key: {0}? This cannot be undone."
msgstr "Czy na pewno chcesz usunąć klucz API: {0}? Tej czynności nie można cofnąć."
@@ -1181,7 +1181,7 @@ msgid "Are you sure you want to delete the view \"{0}\"?"
msgstr "Czy na pewno chcesz usunąć widok \"{0}\"?"
#. placeholder {0}: webhook.name
-#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:76
+#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:84
msgid "Are you sure you want to delete the webhook: {0}? This cannot be undone."
msgstr "Czy na pewno chcesz usunąć webhook: {0}? Tej czynności nie można cofnąć."
@@ -14761,7 +14761,7 @@ msgstr "Adres URL webhooka"
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:160
#: apps/erp/app/modules/settings/ui/Webhooks/WebhooksTable.tsx:227
-#: apps/erp/app/routes/x+/settings+/webhooks.tsx:14
+#: apps/erp/app/routes/x+/settings+/webhooks.tsx:16
msgid "Webhooks"
msgstr "Webhooks"
diff --git a/packages/locale/locales/pt/erp.po b/packages/locale/locales/pt/erp.po
index e432772b48..df791d887f 100644
--- a/packages/locale/locales/pt/erp.po
+++ b/packages/locale/locales/pt/erp.po
@@ -764,7 +764,7 @@ msgstr "Chave de API"
#: apps/erp/app/modules/settings/ui/ApiKeys/ApiKeysTable.tsx:215
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:124
-#: apps/erp/app/routes/x+/settings+/api-keys.tsx:13
+#: apps/erp/app/routes/x+/settings+/api-keys.tsx:15
msgid "API Keys"
msgstr "Chaves de API"
@@ -985,7 +985,7 @@ msgid "Are you sure you want to delete the account: {0} ({1})? This cannot be un
msgstr "Tem a certeza de que deseja eliminar a conta: {0} ({1})? Esta ação não pode ser desfeita."
#. placeholder {0}: apiKey.name
-#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:56
+#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:64
msgid "Are you sure you want to delete the API key: {0}? This cannot be undone."
msgstr "Tem a certeza de que deseja eliminar a chave de API: {0}? Esta ação não pode ser desfeita."
@@ -1181,7 +1181,7 @@ msgid "Are you sure you want to delete the view \"{0}\"?"
msgstr "Tem a certeza de que deseja eliminar a vista \"{0}\"?"
#. placeholder {0}: webhook.name
-#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:76
+#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:84
msgid "Are you sure you want to delete the webhook: {0}? This cannot be undone."
msgstr "Tem a certeza de que deseja eliminar o webhook: {0}? Esta ação não pode ser desfeita."
@@ -14761,7 +14761,7 @@ msgstr "URL do Webhook"
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:160
#: apps/erp/app/modules/settings/ui/Webhooks/WebhooksTable.tsx:227
-#: apps/erp/app/routes/x+/settings+/webhooks.tsx:14
+#: apps/erp/app/routes/x+/settings+/webhooks.tsx:16
msgid "Webhooks"
msgstr "Webhooks"
diff --git a/packages/locale/locales/ru/erp.po b/packages/locale/locales/ru/erp.po
index 6a9b4839ef..ee009c5bcd 100644
--- a/packages/locale/locales/ru/erp.po
+++ b/packages/locale/locales/ru/erp.po
@@ -764,7 +764,7 @@ msgstr "API ключ"
#: apps/erp/app/modules/settings/ui/ApiKeys/ApiKeysTable.tsx:215
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:124
-#: apps/erp/app/routes/x+/settings+/api-keys.tsx:13
+#: apps/erp/app/routes/x+/settings+/api-keys.tsx:15
msgid "API Keys"
msgstr "API ключи"
@@ -985,7 +985,7 @@ msgid "Are you sure you want to delete the account: {0} ({1})? This cannot be un
msgstr "Вы уверены, что хотите удалить счет: {0} ({1})? Это действие невозможно отменить."
#. placeholder {0}: apiKey.name
-#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:56
+#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:64
msgid "Are you sure you want to delete the API key: {0}? This cannot be undone."
msgstr "Вы уверены, что хотите удалить API ключ: {0}? Это действие невозможно отменить."
@@ -1181,7 +1181,7 @@ msgid "Are you sure you want to delete the view \"{0}\"?"
msgstr "Вы уверены, что хотите удалить представление \"{0}\"?"
#. placeholder {0}: webhook.name
-#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:76
+#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:84
msgid "Are you sure you want to delete the webhook: {0}? This cannot be undone."
msgstr "Вы уверены, что хотите удалить webhook: {0}? Это действие невозможно отменить."
@@ -14761,7 +14761,7 @@ msgstr "URL вебхука"
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:160
#: apps/erp/app/modules/settings/ui/Webhooks/WebhooksTable.tsx:227
-#: apps/erp/app/routes/x+/settings+/webhooks.tsx:14
+#: apps/erp/app/routes/x+/settings+/webhooks.tsx:16
msgid "Webhooks"
msgstr "Вебхуки"
diff --git a/packages/locale/locales/zh/erp.po b/packages/locale/locales/zh/erp.po
index 3d7b6d83db..d558e1e369 100644
--- a/packages/locale/locales/zh/erp.po
+++ b/packages/locale/locales/zh/erp.po
@@ -764,7 +764,7 @@ msgstr "API 密钥"
#: apps/erp/app/modules/settings/ui/ApiKeys/ApiKeysTable.tsx:215
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:124
-#: apps/erp/app/routes/x+/settings+/api-keys.tsx:13
+#: apps/erp/app/routes/x+/settings+/api-keys.tsx:15
msgid "API Keys"
msgstr "API 密钥"
@@ -985,7 +985,7 @@ msgid "Are you sure you want to delete the account: {0} ({1})? This cannot be un
msgstr "您确定要删除账户:{0} ({1})?此操作无法撤销。"
#. placeholder {0}: apiKey.name
-#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:56
+#: apps/erp/app/routes/x+/settings+/api-keys.delete.$id.tsx:64
msgid "Are you sure you want to delete the API key: {0}? This cannot be undone."
msgstr "您确定要删除 API 密钥:{0}?此操作无法撤销。"
@@ -1181,7 +1181,7 @@ msgid "Are you sure you want to delete the view \"{0}\"?"
msgstr "你确定要删除视图\"{0}\"吗?"
#. placeholder {0}: webhook.name
-#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:76
+#: apps/erp/app/routes/x+/settings+/webhooks.delete.$id.tsx:84
msgid "Are you sure you want to delete the webhook: {0}? This cannot be undone."
msgstr "您确定要删除webhook: {0}吗?此操作无法撤销。"
@@ -14761,7 +14761,7 @@ msgstr "Webhook URL"
#: apps/erp/app/modules/settings/ui/useSettingsSubmodules.tsx:160
#: apps/erp/app/modules/settings/ui/Webhooks/WebhooksTable.tsx:227
-#: apps/erp/app/routes/x+/settings+/webhooks.tsx:14
+#: apps/erp/app/routes/x+/settings+/webhooks.tsx:16
msgid "Webhooks"
msgstr "Webhooks"
diff --git a/packages/stripe/src/gtm-events.server.ts b/packages/stripe/src/gtm-events.server.ts
index f91586988d..9b9efc2cad 100644
--- a/packages/stripe/src/gtm-events.server.ts
+++ b/packages/stripe/src/gtm-events.server.ts
@@ -4,21 +4,26 @@ export async function forwardToGtm(
type: string,
metadata: Record<string, unknown>
): Promise<void> {
- if (!GTM_URL || !GTM_EVENTS_API_SECRET_KEY) return;
+ if (!GTM_URL || !GTM_EVENTS_API_SECRET_KEY) {
+ console.error("[gtm-events] missing GTM_URL or GTM_EVENTS_API_SECRET_KEY");
+ return;
+ }
- const res = await fetch(`${GTM_URL}/api/events`, {
- method: "POST",
- headers: {
- "content-type": "application/json",
- "x-gtm-events-key": GTM_EVENTS_API_SECRET_KEY
- },
- body: JSON.stringify({ type, metadata }),
- signal: AbortSignal.timeout(5000)
- });
+ try {
+ const res = await fetch(`${GTM_URL}/api/events`, {
+ method: "POST",
+ headers: {
+ "content-type": "application/json",
+ "x-gtm-events-key": GTM_EVENTS_API_SECRET_KEY
+ },
+ body: JSON.stringify({ type, metadata })
+ });
- if (!res.ok) {
- throw new Error(
- `[gtm-events] ${res.status}: ${await res.text().catch(() => "")}`
- );
+ if (!res.ok) {
+ const body = await res.text().catch(() => "");
+ console.error(`[gtm-events] ${res.status}: ${body}`);
+ }
+ } catch (err) {
+ console.error("[gtm-events] request failed", err);
}
}