diff --git a/src/locales/de.json b/src/locales/de.json index a2ca92a8..0d620441 100644 --- a/src/locales/de.json +++ b/src/locales/de.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "An array of string, each element is a column value", "functionParamIndexDescription": "The row index (0-based)", "functionReturnDescription": "An object representing a transaction (with the fields defined below), or null to skip this row", - "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss", - "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5", + "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss. You can also use the parseDateTime(value, format) function to convert a custom formatted time string to the standard format, where 'format' argument is the format of the custom time string, e.g. parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') means converting '12/31/2023 23:59' to the standard format '2023-12-31 23:59:00'", + "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5. You can also use the parseUtcOffset(timezoneName) function to get the timezone offset in minutes automatically according to the transaction time, where 'timezoneName' argument is the IANA time zone name, e.g. parseUtcOffset('Asia/Shanghai') means getting the timezone offset in minutes for Beijing Time", "fieldTypeDescription": "[required] Transaction type, must be one of 'TransactionType.Income', 'TransactionType.Expense' or 'TransactionType.Transfer'", "fieldCategoryNameDescription": "[optional] Category name", "fieldSourceAccountNameDescription": "[optional] Source account name", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "Please execute the custom script first", "Executing Script...": "Executing Script...", "No parse function defined": "No parse function defined", + "Failed to parse time": "Failed to parse time", "Failed to execute custom script": "Failed to execute custom script", "Batch Replace Selected Expense Categories": "Ausgewählte Ausgabenkategorien im Batch ersetzen", "Batch Replace Selected Income Categories": "Ausgewählte Einnahmenkategorien im Batch ersetzen", diff --git a/src/locales/en.json b/src/locales/en.json index 5b6cf21c..bf2aa230 100644 --- a/src/locales/en.json +++ b/src/locales/en.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "An array of string, each element is a column value", "functionParamIndexDescription": "The row index (0-based)", "functionReturnDescription": "An object representing a transaction (with the fields defined below), or null to skip this row", - "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss", - "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5", + "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss. You can also use the parseDateTime(value, format) function to convert a custom formatted time string to the standard format, where 'format' argument is the format of the custom time string, e.g. parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') means converting '12/31/2023 23:59' to the standard format '2023-12-31 23:59:00'", + "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5. You can also use the parseUtcOffset(timezoneName) function to get the timezone offset in minutes automatically according to the transaction time, where 'timezoneName' argument is the IANA time zone name, e.g. parseUtcOffset('Asia/Shanghai') means getting the timezone offset in minutes for Beijing Time", "fieldTypeDescription": "[required] Transaction type, must be one of 'TransactionType.Income', 'TransactionType.Expense' or 'TransactionType.Transfer'", "fieldCategoryNameDescription": "[optional] Category name", "fieldSourceAccountNameDescription": "[optional] Source account name", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "Please execute the custom script first", "Executing Script...": "Executing Script...", "No parse function defined": "No parse function defined", + "Failed to parse time": "Failed to parse time", "Failed to execute custom script": "Failed to execute custom script", "Batch Replace Selected Expense Categories": "Batch Replace Selected Expense Categories", "Batch Replace Selected Income Categories": "Batch Replace Selected Income Categories", diff --git a/src/locales/es.json b/src/locales/es.json index b15d15bf..0e7e50bf 100644 --- a/src/locales/es.json +++ b/src/locales/es.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "An array of string, each element is a column value", "functionParamIndexDescription": "The row index (0-based)", "functionReturnDescription": "An object representing a transaction (with the fields defined below), or null to skip this row", - "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss", - "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5", + "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss. You can also use the parseDateTime(value, format) function to convert a custom formatted time string to the standard format, where 'format' argument is the format of the custom time string, e.g. parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') means converting '12/31/2023 23:59' to the standard format '2023-12-31 23:59:00'", + "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5. You can also use the parseUtcOffset(timezoneName) function to get the timezone offset in minutes automatically according to the transaction time, where 'timezoneName' argument is the IANA time zone name, e.g. parseUtcOffset('Asia/Shanghai') means getting the timezone offset in minutes for Beijing Time", "fieldTypeDescription": "[required] Transaction type, must be one of 'TransactionType.Income', 'TransactionType.Expense' or 'TransactionType.Transfer'", "fieldCategoryNameDescription": "[optional] Category name", "fieldSourceAccountNameDescription": "[optional] Source account name", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "Please execute the custom script first", "Executing Script...": "Executing Script...", "No parse function defined": "No parse function defined", + "Failed to parse time": "Failed to parse time", "Failed to execute custom script": "Failed to execute custom script", "Batch Replace Selected Expense Categories": "Reemplazar por lotes categorías de gastos seleccionadas", "Batch Replace Selected Income Categories": "Reemplazo por lotes de categorías de ingresos seleccionadas", diff --git a/src/locales/fr.json b/src/locales/fr.json index d7d05e7c..cb5f00ac 100644 --- a/src/locales/fr.json +++ b/src/locales/fr.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "Un tableau de chaînes, chaque élément est une valeur de colonne", "functionParamIndexDescription": "L'index de ligne (basé sur 0)", "functionReturnDescription": "Un objet représentant une transaction (avec les champs définis ci-dessous), ou null pour ignorer cette ligne", - "fieldTimeDescription": "[requis] Heure de transaction, format : AAAA-MM-JJ HH:mm:ss", - "fieldUtcOffsetDescription": "[requis] Décalage de fuseau horaire de transaction en minutes, par ex. '480' pour UTC+8, '-300' pour UTC-5", + "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss. You can also use the parseDateTime(value, format) function to convert a custom formatted time string to the standard format, where 'format' argument is the format of the custom time string, e.g. parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') means converting '12/31/2023 23:59' to the standard format '2023-12-31 23:59:00'", + "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5. You can also use the parseUtcOffset(timezoneName) function to get the timezone offset in minutes automatically according to the transaction time, where 'timezoneName' argument is the IANA time zone name, e.g. parseUtcOffset('Asia/Shanghai') means getting the timezone offset in minutes for Beijing Time", "fieldTypeDescription": "[requis] Type de transaction, doit être l'un de 'TransactionType.Income', 'TransactionType.Expense' ou 'TransactionType.Transfer'", "fieldCategoryNameDescription": "[optionnel] Nom de catégorie", "fieldSourceAccountNameDescription": "[optionnel] Nom du compte source", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "Veuillez d'abord exécuter le script personnalisé", "Executing Script...": "Exécution du script...", "No parse function defined": "Aucune fonction d'analyse définie", + "Failed to parse time": "Failed to parse time", "Failed to execute custom script": "Échec de l'exécution du script personnalisé", "Batch Replace Selected Expense Categories": "Remplacer en lot les catégories de dépenses sélectionnées", "Batch Replace Selected Income Categories": "Remplacer en lot les catégories de revenus sélectionnées", diff --git a/src/locales/it.json b/src/locales/it.json index a91fb45e..e080c320 100644 --- a/src/locales/it.json +++ b/src/locales/it.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "An array of string, each element is a column value", "functionParamIndexDescription": "The row index (0-based)", "functionReturnDescription": "An object representing a transaction (with the fields defined below), or null to skip this row", - "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss", - "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5", + "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss. You can also use the parseDateTime(value, format) function to convert a custom formatted time string to the standard format, where 'format' argument is the format of the custom time string, e.g. parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') means converting '12/31/2023 23:59' to the standard format '2023-12-31 23:59:00'", + "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5. You can also use the parseUtcOffset(timezoneName) function to get the timezone offset in minutes automatically according to the transaction time, where 'timezoneName' argument is the IANA time zone name, e.g. parseUtcOffset('Asia/Shanghai') means getting the timezone offset in minutes for Beijing Time", "fieldTypeDescription": "[required] Transaction type, must be one of 'TransactionType.Income', 'TransactionType.Expense' or 'TransactionType.Transfer'", "fieldCategoryNameDescription": "[optional] Category name", "fieldSourceAccountNameDescription": "[optional] Source account name", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "Please execute the custom script first", "Executing Script...": "Executing Script...", "No parse function defined": "No parse function defined", + "Failed to parse time": "Failed to parse time", "Failed to execute custom script": "Failed to execute custom script", "Batch Replace Selected Expense Categories": "Sostituisci in blocco categorie di spesa selezionate", "Batch Replace Selected Income Categories": "Sostituisci in blocco categorie di entrata selezionate", diff --git a/src/locales/ja.json b/src/locales/ja.json index d0c3e34f..271083f5 100644 --- a/src/locales/ja.json +++ b/src/locales/ja.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "An array of string, each element is a column value", "functionParamIndexDescription": "The row index (0-based)", "functionReturnDescription": "An object representing a transaction (with the fields defined below), or null to skip this row", - "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss", - "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5", + "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss. You can also use the parseDateTime(value, format) function to convert a custom formatted time string to the standard format, where 'format' argument is the format of the custom time string, e.g. parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') means converting '12/31/2023 23:59' to the standard format '2023-12-31 23:59:00'", + "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5. You can also use the parseUtcOffset(timezoneName) function to get the timezone offset in minutes automatically according to the transaction time, where 'timezoneName' argument is the IANA time zone name, e.g. parseUtcOffset('Asia/Shanghai') means getting the timezone offset in minutes for Beijing Time", "fieldTypeDescription": "[required] Transaction type, must be one of 'TransactionType.Income', 'TransactionType.Expense' or 'TransactionType.Transfer'", "fieldCategoryNameDescription": "[optional] Category name", "fieldSourceAccountNameDescription": "[optional] Source account name", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "Please execute the custom script first", "Executing Script...": "Executing Script...", "No parse function defined": "No parse function defined", + "Failed to parse time": "Failed to parse time", "Failed to execute custom script": "Failed to execute custom script", "Batch Replace Selected Expense Categories": "バッチは選択した支出カテゴリを置き換えます", "Batch Replace Selected Income Categories": "バッチは選択した収入カテゴリを置き換えます", diff --git a/src/locales/kn.json b/src/locales/kn.json index f759423e..0ac86510 100644 --- a/src/locales/kn.json +++ b/src/locales/kn.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "ಸ್ಟ್ರಿಂಗ್‌ಗಳ ಸರಣಿ, ಪ್ರತಿಯೊಂದು ಮೌಲ್ಯವು ಒಂದು ಕಾಲಮ್‌ನ ಮೌಲ್ಯವಾಗಿರುತ್ತದೆ", "functionParamIndexDescription": "ಸಾಲಿನ ಸೂಚ್ಯಂಕ (0-ಆಧಾರಿತ)", "functionReturnDescription": "ವಹಿವಾಟನ್ನು ಪ್ರತಿನಿಧಿಸುವ ವಸ್ತು (ಕೆಳಗಿನ ಕ್ಷೇತ್ರಗಳೊಂದಿಗೆ), ಅಥವಾ ಈ ಸಾಲನ್ನು ತೊರೆಯಲು null ಅನ್ನು ಹಿಂತಿರುಗಿಸಿ", - "fieldTimeDescription": "[ಅಗತ್ಯ] ವಹಿವಾಟಿನ ಸಮಯ, ಸ್ವರೂಪ: YYYY-MM-DD HH:mm:ss", - "fieldUtcOffsetDescription": "[ಅಗತ್ಯ] ವಹಿವಾಟಿನ ಸಮಯ ವಲಯ ಆಫ್‌ಸೆಟ್ (ನಿಮಿಷಗಳಲ್ಲಿ), ಉದಾ: '480' UTC+8 ಗಾಗಿ, '-300' UTC-5 ಗಾಗಿ", + "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss. You can also use the parseDateTime(value, format) function to convert a custom formatted time string to the standard format, where 'format' argument is the format of the custom time string, e.g. parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') means converting '12/31/2023 23:59' to the standard format '2023-12-31 23:59:00'", + "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5. You can also use the parseUtcOffset(timezoneName) function to get the timezone offset in minutes automatically according to the transaction time, where 'timezoneName' argument is the IANA time zone name, e.g. parseUtcOffset('Asia/Shanghai') means getting the timezone offset in minutes for Beijing Time", "fieldTypeDescription": "[ಅಗತ್ಯ] ವಹಿವಾಟಿನ ಪ್ರಕಾರ, ಇದು 'TransactionType.Income', 'TransactionType.Expense' ಅಥವಾ 'TransactionType.Transfer' ಆಗಿರಬೇಕು", "fieldCategoryNameDescription": "[ಐಚ್ಛಿಕ] ವರ್ಗದ ಹೆಸರು", "fieldSourceAccountNameDescription": "[ಐಚ್ಛಿಕ] ಮೂಲ ಖಾತೆಯ ಹೆಸರು", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "ದಯವಿಟ್ಟು ಮೊದಲು ಕಸ್ಟಮ್ ಸ್ಕ್ರಿಪ್ಟ್ ನಿರ್ವಹಿಸಿ", "Executing Script...": "ಸ್ಕ್ರಿಪ್ಟ್ ಚಲಾಯಿಸಲಾಗುತ್ತಿದೆ...", "No parse function defined": "ಯಾವುದೇ ಪಾರ್ಸ್ ಫಂಕ್ಷನ್ ವ್ಯಾಖ್ಯಾನಿಸಲ್ಪಟ್ಟಿಲ್ಲ", + "Failed to parse time": "Failed to parse time", "Failed to execute custom script": "ಕಸ್ಟಮ್ ಸ್ಕ್ರಿಪ್ಟ್ ಚಲಾಯಿಸಲು ವಿಫಲವಾಗಿದೆ", "Batch Replace Selected Expense Categories": "ಆಯ್ಕೆ ಮಾಡಿದ ಖರ್ಚು ವರ್ಗಗಳನ್ನು ಬ್ಯಾಚ್ ಬದಲಾಯಿಸಿ", "Batch Replace Selected Income Categories": "ಆಯ್ಕೆ ಮಾಡಿದ ಆದಾಯ ವರ್ಗಗಳನ್ನು ಬ್ಯಾಚ್ ಬದಲಾಯಿಸಿ", diff --git a/src/locales/ko.json b/src/locales/ko.json index 3b2b80ae..62d575df 100644 --- a/src/locales/ko.json +++ b/src/locales/ko.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "문자열 배열, 각 요소는 열 값입니다.", "functionParamIndexDescription": "행 인덱스 (0 기반)", "functionReturnDescription": "거래를 나타내는 객체 (아래 정의된 필드 포함) 또는 이 행을 건너뛰기 위한 null", - "fieldTimeDescription": "[필수] 거래 시간, 형식: YYYY-MM-DD HH:mm:ss", - "fieldUtcOffsetDescription": "[필수] 거래 시간대 오프셋 (분 단위), 예: '480'은 UTC+8, '-300'은 UTC-5", + "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss. You can also use the parseDateTime(value, format) function to convert a custom formatted time string to the standard format, where 'format' argument is the format of the custom time string, e.g. parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') means converting '12/31/2023 23:59' to the standard format '2023-12-31 23:59:00'", + "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5. You can also use the parseUtcOffset(timezoneName) function to get the timezone offset in minutes automatically according to the transaction time, where 'timezoneName' argument is the IANA time zone name, e.g. parseUtcOffset('Asia/Shanghai') means getting the timezone offset in minutes for Beijing Time", "fieldTypeDescription": "[필수] 거래 유형, 'TransactionType.Income', 'TransactionType.Expense' 또는 'TransactionType.Transfer' 중 하나여야 합니다.", "fieldCategoryNameDescription": "[선택] 카테고리 이름", "fieldSourceAccountNameDescription": "[선택] 출처 계좌 이름", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "먼저 사용자 정의 스크립트를 실행하십시오", "Executing Script...": "스크립트 실행 중...", "No parse function defined": "구문 분석 함수가 정의되지 않았습니다", + "Failed to parse time": "Failed to parse time", "Failed to execute custom script": "사용자 정의 스크립트 실행에 실패했습니다", "Batch Replace Selected Expense Categories": "선택한 비용 카테고리 일괄 교체", "Batch Replace Selected Income Categories": "선택한 수입 카테고리 일괄 교체", diff --git a/src/locales/nl.json b/src/locales/nl.json index 8322bce8..31a03273 100644 --- a/src/locales/nl.json +++ b/src/locales/nl.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "An array of string, each element is a column value", "functionParamIndexDescription": "The row index (0-based)", "functionReturnDescription": "An object representing a transaction (with the fields defined below), or null to skip this row", - "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss", - "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5", + "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss. You can also use the parseDateTime(value, format) function to convert a custom formatted time string to the standard format, where 'format' argument is the format of the custom time string, e.g. parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') means converting '12/31/2023 23:59' to the standard format '2023-12-31 23:59:00'", + "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5. You can also use the parseUtcOffset(timezoneName) function to get the timezone offset in minutes automatically according to the transaction time, where 'timezoneName' argument is the IANA time zone name, e.g. parseUtcOffset('Asia/Shanghai') means getting the timezone offset in minutes for Beijing Time", "fieldTypeDescription": "[required] Transaction type, must be one of 'TransactionType.Income', 'TransactionType.Expense' or 'TransactionType.Transfer'", "fieldCategoryNameDescription": "[optional] Category name", "fieldSourceAccountNameDescription": "[optional] Source account name", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "Please execute the custom script first", "Executing Script...": "Executing Script...", "No parse function defined": "No parse function defined", + "Failed to parse time": "Failed to parse time", "Failed to execute custom script": "Failed to execute custom script", "Batch Replace Selected Expense Categories": "Geselecteerde uitgavecategorieën batchgewijs vervangen", "Batch Replace Selected Income Categories": "Geselecteerde inkomencategorieën batchgewijs vervangen", diff --git a/src/locales/pt_BR.json b/src/locales/pt_BR.json index f1577223..5026e8ff 100644 --- a/src/locales/pt_BR.json +++ b/src/locales/pt_BR.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "An array of string, each element is a column value", "functionParamIndexDescription": "The row index (0-based)", "functionReturnDescription": "An object representing a transaction (with the fields defined below), or null to skip this row", - "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss", - "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5", + "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss. You can also use the parseDateTime(value, format) function to convert a custom formatted time string to the standard format, where 'format' argument is the format of the custom time string, e.g. parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') means converting '12/31/2023 23:59' to the standard format '2023-12-31 23:59:00'", + "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5. You can also use the parseUtcOffset(timezoneName) function to get the timezone offset in minutes automatically according to the transaction time, where 'timezoneName' argument is the IANA time zone name, e.g. parseUtcOffset('Asia/Shanghai') means getting the timezone offset in minutes for Beijing Time", "fieldTypeDescription": "[required] Transaction type, must be one of 'TransactionType.Income', 'TransactionType.Expense' or 'TransactionType.Transfer'", "fieldCategoryNameDescription": "[optional] Category name", "fieldSourceAccountNameDescription": "[optional] Source account name", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "Please execute the custom script first", "Executing Script...": "Executing Script...", "No parse function defined": "No parse function defined", + "Failed to parse time": "Failed to parse time", "Failed to execute custom script": "Failed to execute custom script", "Batch Replace Selected Expense Categories": "Substituir em Lote as Categorias de Despesas Selecionadas", "Batch Replace Selected Income Categories": "Substituir em Lote as Categorias de Renda Selecionadas", diff --git a/src/locales/ru.json b/src/locales/ru.json index a1f67fec..ac209b65 100644 --- a/src/locales/ru.json +++ b/src/locales/ru.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "An array of string, each element is a column value", "functionParamIndexDescription": "The row index (0-based)", "functionReturnDescription": "An object representing a transaction (with the fields defined below), or null to skip this row", - "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss", - "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5", + "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss. You can also use the parseDateTime(value, format) function to convert a custom formatted time string to the standard format, where 'format' argument is the format of the custom time string, e.g. parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') means converting '12/31/2023 23:59' to the standard format '2023-12-31 23:59:00'", + "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5. You can also use the parseUtcOffset(timezoneName) function to get the timezone offset in minutes automatically according to the transaction time, where 'timezoneName' argument is the IANA time zone name, e.g. parseUtcOffset('Asia/Shanghai') means getting the timezone offset in minutes for Beijing Time", "fieldTypeDescription": "[required] Transaction type, must be one of 'TransactionType.Income', 'TransactionType.Expense' or 'TransactionType.Transfer'", "fieldCategoryNameDescription": "[optional] Category name", "fieldSourceAccountNameDescription": "[optional] Source account name", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "Please execute the custom script first", "Executing Script...": "Executing Script...", "No parse function defined": "No parse function defined", + "Failed to parse time": "Failed to parse time", "Failed to execute custom script": "Failed to execute custom script", "Batch Replace Selected Expense Categories": "Пакетная замена выбранных категорий расходов", "Batch Replace Selected Income Categories": "Пакетная замена выбранных категорий доходов", diff --git a/src/locales/th.json b/src/locales/th.json index 914c8ecf..812ee4ea 100644 --- a/src/locales/th.json +++ b/src/locales/th.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "อาร์เรย์ของสตริง แต่ละตัวแทนค่าของคอลัมน์", "functionParamIndexDescription": "ดัชนีของแถว (เริ่มจาก 0)", "functionReturnDescription": "อ็อบเจ็กต์แทนธุรกรรม (มีฟิลด์ตามที่กำหนดด้านล่าง) หรือ null เพื่อข้ามแถวนี้", - "fieldTimeDescription": "[จำเป็น] เวลาของธุรกรรม, รูปแบบ: YYYY-MM-DD HH:mm:ss", - "fieldUtcOffsetDescription": "[จำเป็น] ค่าชดเชยเขตเวลาเป็นนาที เช่น '480' สำหรับ UTC+8, '-300' สำหรับ UTC-5", + "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss. You can also use the parseDateTime(value, format) function to convert a custom formatted time string to the standard format, where 'format' argument is the format of the custom time string, e.g. parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') means converting '12/31/2023 23:59' to the standard format '2023-12-31 23:59:00'", + "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5. You can also use the parseUtcOffset(timezoneName) function to get the timezone offset in minutes automatically according to the transaction time, where 'timezoneName' argument is the IANA time zone name, e.g. parseUtcOffset('Asia/Shanghai') means getting the timezone offset in minutes for Beijing Time", "fieldTypeDescription": "[จำเป็น] ประเภทของธุรกรรม ต้องเป็นหนึ่งใน 'TransactionType.Income', 'TransactionType.Expense' หรือ 'TransactionType.Transfer'", "fieldCategoryNameDescription": "[ไม่จำเป็น] ชื่อหมวดหมู่", "fieldSourceAccountNameDescription": "[ไม่จำเป็น] ชื่อบัญชีต้นทาง", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "กรุณาเรียกใช้สคริปต์กำหนดเองก่อน", "Executing Script...": "กำลังเรียกใช้สคริปต์...", "No parse function defined": "ไม่ได้กำหนดฟังก์ชัน parse", + "Failed to parse time": "Failed to parse time", "Failed to execute custom script": "เรียกใช้สคริปต์กำหนดเองล้มเหลว", "Batch Replace Selected Expense Categories": "แทนที่หมวดค่าใช้จ่ายที่เลือกแบบกลุ่ม", "Batch Replace Selected Income Categories": "แทนที่หมวดรายได้ที่เลือกแบบกลุ่ม", diff --git a/src/locales/tr.json b/src/locales/tr.json index 9f2beaea..0a894d1f 100644 --- a/src/locales/tr.json +++ b/src/locales/tr.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "Dize dizisi (string array), her eleman bir sütun değeridir", "functionParamIndexDescription": "Satır indeksi (0 tabanlı)", "functionReturnDescription": "Bir işlemi temsil eden nesne (aşağıda tanımlanan alanlarla) veya bu satırı atlamak için null", - "fieldTimeDescription": "[zorunlu] İşlem zamanı, format: YYYY-AA-GG SS:dd:ss", - "fieldUtcOffsetDescription": "[zorunlu] Dakika cinsinden işlem saat dilimi sapması, örn. UTC+8 için '480', UTC-5 için '-300'", + "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss. You can also use the parseDateTime(value, format) function to convert a custom formatted time string to the standard format, where 'format' argument is the format of the custom time string, e.g. parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') means converting '12/31/2023 23:59' to the standard format '2023-12-31 23:59:00'", + "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5. You can also use the parseUtcOffset(timezoneName) function to get the timezone offset in minutes automatically according to the transaction time, where 'timezoneName' argument is the IANA time zone name, e.g. parseUtcOffset('Asia/Shanghai') means getting the timezone offset in minutes for Beijing Time", "fieldTypeDescription": "[zorunlu] İşlem türü, şunlardan biri olmalıdır: 'TransactionType.Income', 'TransactionType.Expense' veya 'TransactionType.Transfer'", "fieldCategoryNameDescription": "[isteğe bağlı] Kategori adı", "fieldSourceAccountNameDescription": "[isteğe bağlı] Kaynak hesap adı", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "Lütfen önce özel betiği çalıştırın", "Executing Script...": "Betik Çalıştırılıyor...", "No parse function defined": "Parse fonksiyonu tanımlanmamış", + "Failed to parse time": "Failed to parse time", "Failed to execute custom script": "Özel betik çalıştırılamadı", "Batch Replace Selected Expense Categories": "Seçili Gider Kategorilerini Toplu Değiştir", "Batch Replace Selected Income Categories": "Seçili Gelir Kategorilerini Toplu Değiştir", diff --git a/src/locales/uk.json b/src/locales/uk.json index 5ca586c9..5e1e73a0 100644 --- a/src/locales/uk.json +++ b/src/locales/uk.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "An array of string, each element is a column value", "functionParamIndexDescription": "The row index (0-based)", "functionReturnDescription": "An object representing a transaction (with the fields defined below), or null to skip this row", - "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss", - "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5", + "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss. You can also use the parseDateTime(value, format) function to convert a custom formatted time string to the standard format, where 'format' argument is the format of the custom time string, e.g. parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') means converting '12/31/2023 23:59' to the standard format '2023-12-31 23:59:00'", + "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5. You can also use the parseUtcOffset(timezoneName) function to get the timezone offset in minutes automatically according to the transaction time, where 'timezoneName' argument is the IANA time zone name, e.g. parseUtcOffset('Asia/Shanghai') means getting the timezone offset in minutes for Beijing Time", "fieldTypeDescription": "[required] Transaction type, must be one of 'TransactionType.Income', 'TransactionType.Expense' or 'TransactionType.Transfer'", "fieldCategoryNameDescription": "[optional] Category name", "fieldSourceAccountNameDescription": "[optional] Source account name", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "Please execute the custom script first", "Executing Script...": "Executing Script...", "No parse function defined": "No parse function defined", + "Failed to parse time": "Failed to parse time", "Failed to execute custom script": "Failed to execute custom script", "Batch Replace Selected Expense Categories": "Пакетна заміна вибраних категорій витрат", "Batch Replace Selected Income Categories": "Пакетна заміна вибраних категорій доходів", diff --git a/src/locales/vi.json b/src/locales/vi.json index c8886d25..fc5dc745 100644 --- a/src/locales/vi.json +++ b/src/locales/vi.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "An array of string, each element is a column value", "functionParamIndexDescription": "The row index (0-based)", "functionReturnDescription": "An object representing a transaction (with the fields defined below), or null to skip this row", - "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss", - "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5", + "fieldTimeDescription": "[required] Transaction time, format: YYYY-MM-DD HH:mm:ss. You can also use the parseDateTime(value, format) function to convert a custom formatted time string to the standard format, where 'format' argument is the format of the custom time string, e.g. parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') means converting '12/31/2023 23:59' to the standard format '2023-12-31 23:59:00'", + "fieldUtcOffsetDescription": "[required] Transaction timezone offset in minutes, e.g. '480' for UTC+8, '-300' for UTC-5. You can also use the parseUtcOffset(timezoneName) function to get the timezone offset in minutes automatically according to the transaction time, where 'timezoneName' argument is the IANA time zone name, e.g. parseUtcOffset('Asia/Shanghai') means getting the timezone offset in minutes for Beijing Time", "fieldTypeDescription": "[required] Transaction type, must be one of 'TransactionType.Income', 'TransactionType.Expense' or 'TransactionType.Transfer'", "fieldCategoryNameDescription": "[optional] Category name", "fieldSourceAccountNameDescription": "[optional] Source account name", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "Please execute the custom script first", "Executing Script...": "Executing Script...", "No parse function defined": "No parse function defined", + "Failed to parse time": "Failed to parse time", "Failed to execute custom script": "Failed to execute custom script", "Batch Replace Selected Expense Categories": "Thay thế hàng loạt các danh mục chi phí đã chọn", "Batch Replace Selected Income Categories": "Thay thế hàng loạt các danh mục thu nhập đã chọn", diff --git a/src/locales/zh_Hans.json b/src/locales/zh_Hans.json index 25bc8866..9773cd25 100644 --- a/src/locales/zh_Hans.json +++ b/src/locales/zh_Hans.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "字符串数组,每个元素为一列的值", "functionParamIndexDescription": "行索引 (从0开始)", "functionReturnDescription": "表示一笔交易的对象 (包含下面定义的字段),返回 null 时跳过此行", - "fieldTimeDescription": "[必填] 交易时间,格式:YYYY-MM-DD HH:mm:ss", - "fieldUtcOffsetDescription": "[必填] 交易时区的分钟偏移量,例如:'480' 表示 UTC+8,'-300' 表示 UTC-5", + "fieldTimeDescription": "[必填] 交易时间,格式:YYYY-MM-DD HH:mm:ss。也可以使用 parseDateTime(value, format) 函数将自定义格式的时间字符串转换为标准格式,'format' 参数为自定义时间字符串的格式,例如 parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') 表示将 '12/31/2025 12:34' 转换为标准格式 '2023-12-31 12:34:00'", + "fieldUtcOffsetDescription": "[必填] 交易时区的分钟偏移量,例如:'480' 表示 UTC+8,'-300' 表示 UTC-5。也可以使用 parseUtcOffset(timezoneName) 函数根据交易时间自动获取该时区的分钟偏移量,'timezoneName' 参数为 IANA 时区名称,例如 parseUtcOffset('Asia/Shanghai') 表示获取北京时间的分钟偏移量", "fieldTypeDescription": "[必填] 交易类型,必须为 'TransactionType.Income' (收入)、'TransactionType.Expense' (支出) 或 'TransactionType.Transfer' (转账)", "fieldCategoryNameDescription": "[可选] 分类名称", "fieldSourceAccountNameDescription": "[可选] 来源账户名称", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "请先执行自定义脚本", "Executing Script...": "正在执行脚本...", "No parse function defined": "没有定义解析函数 parse", + "Failed to parse time": "解析时间失败", "Failed to execute custom script": "执行自定义脚本失败", "Batch Replace Selected Expense Categories": "批量替换选中的支出分类", "Batch Replace Selected Income Categories": "批量替换选中的收入分类", diff --git a/src/locales/zh_Hant.json b/src/locales/zh_Hant.json index 9030c6c9..752b2d44 100644 --- a/src/locales/zh_Hant.json +++ b/src/locales/zh_Hant.json @@ -1404,8 +1404,8 @@ "functionParamRowDescription": "字串陣列,每個元素為一列的值", "functionParamIndexDescription": "行索引 (從0開始)", "functionReturnDescription": "表示一筆交易的物件 (包含下面定義的欄位),返回 null 時跳過此行", - "fieldTimeDescription": "[必填] 交易時間,格式:YYYY-MM-DD HH:mm:ss", - "fieldUtcOffsetDescription": "[必填] 交易時區的分鐘偏移量,例如:'480' 表示 UTC+8,'-300' 表示 UTC-5", + "fieldTimeDescription": "[必填] 交易時間,格式:YYYY-MM-DD HH:mm:ss。也可以使用 parseDateTime(value, format) 函數將自訂格式的時間字串轉換為標準格式,'format' 參數為自訂時間字串的格式,例如 parseDateTime('12/31/2023 23:59', 'MM/DD/YYYY HH:mm') 表示將 '12/31/2025 12:34' 轉換為標準格式 '2023-12-31 12:34:00'", + "fieldUtcOffsetDescription": "[必填] 交易時區的分鐘偏移量,例如:'480' 表示 UTC+8,'-300' 表示 UTC-5。也可以使用 parseUtcOffset(timezoneName) 函數根據交易時間自動獲取該時區的分鐘偏移量,'timezoneName' 參數為 IANA 時區名稱,例如 parseUtcOffset('Asia/Shanghai') 表示獲取北京時間的分鐘偏移量", "fieldTypeDescription": "[必填] 交易類型,必須為 'TransactionType.Income' (收入)、'TransactionType.Expense' (支出) 或 'TransactionType.Transfer' (轉帳)", "fieldCategoryNameDescription": "[可選] 分類名稱", "fieldSourceAccountNameDescription": "[可選] 來源帳戶名稱", @@ -1961,6 +1961,7 @@ "Please execute the custom script first": "請先執行自訂腳本", "Executing Script...": "正在執行腳本...", "No parse function defined": "沒有定義解析函式 parse", + "Failed to parse time": "解析時間失敗", "Failed to execute custom script": "執行自訂腳本失敗", "Batch Replace Selected Expense Categories": "批次替換選中的支出分類", "Batch Replace Selected Income Categories": "批次替換選中的收入分類", diff --git a/src/views/desktop/transactions/import/tabs/ImportTransactionExecuteCustomScriptTab.vue b/src/views/desktop/transactions/import/tabs/ImportTransactionExecuteCustomScriptTab.vue index b1d9a431..7ff2611d 100644 --- a/src/views/desktop/transactions/import/tabs/ImportTransactionExecuteCustomScriptTab.vue +++ b/src/views/desktop/transactions/import/tabs/ImportTransactionExecuteCustomScriptTab.vue @@ -47,16 +47,26 @@ import { ref, computed, useTemplateRef, onMounted, onUnmounted } from 'vue'; import { useI18n } from '@/locales/helpers.ts'; +import { useSettingsStore } from '@/stores/setting.ts'; + import type { NameNumeralValue } from '@/core/base.ts'; import type { NumeralSystem } from '@/core/numeral.ts'; +import { KnownDateTimeFormat } from '@/core/datetime.ts'; import { KnownFileType } from '@/core/file.ts'; import type { ImportTransactionRequest, ImportTransactionRequestItem } from '@/models/imported_transaction.ts'; -import { isDefined } from '@/lib/common.ts'; +import { + isDefined, + isObject, + isString +} from '@/lib/common.ts'; import { getTimezoneOffsetMinutes, - getCurrentUnixTime + getBrowserTimezoneName, + getCurrentUnixTime, + parseDateTimeFromKnownDateTimeFormat, + parseDateTimeFromString } from '@/lib/datetime.ts'; import { openTextFileContent, @@ -95,7 +105,13 @@ const props = defineProps<{ disabled?: boolean; }>(); -const { tt, getCurrentNumeralSystemType } = useI18n(); +const { + tt, + getCurrentNumeralSystemType, + formatDateTimeToGregorianDefaultDateTime +} = useI18n(); + +const settingsStore = useSettingsStore(); const sandbox = useTemplateRef('sandbox'); const snackbar = useTemplateRef('snackbar'); @@ -107,6 +123,7 @@ const executingScript = ref(false); const executionError = ref(''); const previewCount = ref(10); +const currentTimezoneName = computed(() => settingsStore.appSettings.timeZone || getBrowserTimezoneName()); const numeralSystem = computed(() => getCurrentNumeralSystemType()); const previewCounts = computed(() => getTablePageOptions(previewResult.value?.length)); @@ -123,17 +140,28 @@ function parse(row, index) { } return { - time: row[0], // ${tt('sample.importTransactionCustomScript.fieldTimeDescription')} - utcOffset: '${getTimezoneOffsetMinutes(getCurrentUnixTime())}', // ${tt('sample.importTransactionCustomScript.fieldUtcOffsetDescription')} - type: TransactionType.Expense, // ${tt('sample.importTransactionCustomScript.fieldTypeDescription')} - categoryName: row[4], // ${tt('sample.importTransactionCustomScript.fieldCategoryNameDescription')} - sourceAccountName: row[5], // ${tt('sample.importTransactionCustomScript.fieldSourceAccountNameDescription')} - destinationAccountName: row[8], // ${tt('sample.importTransactionCustomScript.fieldDestinationAccountNameDescription')} - sourceAmount: row[7], // ${tt('sample.importTransactionCustomScript.fieldSourceAmountDescription')} - destinationAmount: row[10], // ${tt('sample.importTransactionCustomScript.fieldDestinationAmountDescription')} - geoLocation: undefined, // ${tt('sample.importTransactionCustomScript.fieldGeoLocationDescription')} - tagNames: '', // ${tt('sample.importTransactionCustomScript.fieldTagNamesDescription')} - description: row[13] // ${tt('sample.importTransactionCustomScript.fieldCommentDescription')} + // ${tt('sample.importTransactionCustomScript.fieldTimeDescription')} + time: row[0], + // ${tt('sample.importTransactionCustomScript.fieldUtcOffsetDescription')} + utcOffset: ${currentTimezoneName.value ? 'parseUtcOffset(\'' + currentTimezoneName.value + '\')' : '\'' + getTimezoneOffsetMinutes(getCurrentUnixTime()) + '\''}, + // ${tt('sample.importTransactionCustomScript.fieldTypeDescription')} + type: TransactionType.Expense, + // ${tt('sample.importTransactionCustomScript.fieldCategoryNameDescription')} + categoryName: row[4], + // ${tt('sample.importTransactionCustomScript.fieldSourceAccountNameDescription')} + sourceAccountName: row[5], + // ${tt('sample.importTransactionCustomScript.fieldDestinationAccountNameDescription')} + destinationAccountName: row[8], + // ${tt('sample.importTransactionCustomScript.fieldSourceAmountDescription')} + sourceAmount: row[7], + // ${tt('sample.importTransactionCustomScript.fieldDestinationAmountDescription')} + destinationAmount: row[10], + // ${tt('sample.importTransactionCustomScript.fieldGeoLocationDescription')} + geoLocation: undefined, + // ${tt('sample.importTransactionCustomScript.fieldTagNamesDescription')} + tagNames: '', + // ${tt('sample.importTransactionCustomScript.fieldCommentDescription')} + description: row[13] }; }`); @@ -204,6 +232,19 @@ function reloadSandbox(): void { Transfer: 'Transfer' }; + window.parseDateTime = function(dateTime, format) { + return { + dateTime: dateTime, + format: format + }; + }; + + window.parseUtcOffset = function(timezoneName) { + return { + name: timezoneName + }; + }; + window.addEventListener('message', function (event) { try { const data = JSON.parse(event.data); @@ -308,20 +349,65 @@ function onMessage(event: MessageEvent): void { if (data.knownError) { snackbar.value?.showError(data.knownError); previewResult.value = undefined; - executionError.value = tt(data.knownError); + executionError.value = `// ${tt(data.knownError)}`; } else if (data.error) { logger.error('Failed to execute custom script: ' + data.error); snackbar.value?.showError('Failed to execute custom script'); previewResult.value = undefined; - executionError.value = data.error; + executionError.value = `// ${data.error}`; } else if (data.result) { const originalResult = JSON.parse(data.result) as Record[]; const finalResult: ImportTransactionRequestItem[] = []; for (const item of originalResult) { + let time: string = ''; + let unixTime: number | undefined = undefined; + let utcOffset: string = ''; + + if (isString(item['time'])) { + time = String(item['time']); + const dateTime = parseDateTimeFromKnownDateTimeFormat(time, KnownDateTimeFormat.DefaultDateTime); + + if (dateTime && KnownDateTimeFormat.DefaultDateTime.isValid(time)) { + unixTime = dateTime.getUnixTime(); + } + } else if (isObject(item['time']) && isDefined((item['time'] as Record)['dateTime']) && isDefined((item['time'] as Record)['format'])) { + const originalDateTime = String((item['time'] as Record)['dateTime']); + const format = String((item['time'] as Record)['format']); + const dateTime = parseDateTimeFromString(originalDateTime, format); + + if (dateTime) { + time = formatDateTimeToGregorianDefaultDateTime(dateTime); + unixTime = dateTime.getUnixTime(); + } + + if (!isDefined(unixTime)) { + logger.error('Failed to parse time "' + originalDateTime + '" with custom format "' + format + '"'); + snackbar.value?.showError('Failed to parse time'); + previewResult.value = undefined; + executionError.value = `// ${tt('Failed to parse time')} "${originalDateTime}"`; + return; + } + } + + if (!isDefined(unixTime)) { + logger.error('Failed to parse time "' + item['time'] + '"'); + snackbar.value?.showError('Failed to parse time'); + previewResult.value = undefined; + executionError.value = `// ${tt('Failed to parse time')} "${item['time']}"`; + return; + } + + if (isString(item['utcOffset'])) { + utcOffset = String(item['utcOffset']); + } else if (isObject(item['utcOffset']) && isDefined((item['utcOffset'] as Record)['name'])) { + const timezoneName = String((item['utcOffset'] as Record)['name']); + utcOffset = getTimezoneOffsetMinutes(unixTime, timezoneName).toString(10); + } + const finalItem: ImportTransactionRequestItem = { - time: (isDefined(item['time'])) ? String(item['time']) : '', - utcOffset: (isDefined(item['utcOffset'])) ? String(item['utcOffset']) : '', + time: time, + utcOffset: utcOffset, type: (isDefined(item['type'])) ? String(item['type']) : '', categoryName: (isDefined(item['categoryName']) && item['categoryName'] !== '') ? String(item['categoryName']) : undefined, sourceAccountName: (isDefined(item['sourceAccountName']) && item['sourceAccountName'] !== '') ? String(item['sourceAccountName']) : undefined,