Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update exportDate translations #41268

Merged
merged 3 commits into from
Apr 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/CONST.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4698,9 +4698,9 @@ const CONST = {
},

QUICKBOOKS_EXPORT_DATE: {
LAST_EXPENSE: 'lastExpense',
EXPORTED_DATE: 'exportedDate',
SUBMITTED_DATA: 'submittedData',
LAST_EXPENSE: 'LAST_EXPENSE',
REPORT_EXPORTED: 'REPORT_EXPORTED',
REPORT_SUBMITTED: 'REPORT_SUBMITTED',
},

QUICKBOOKS_EXPORT_COMPANY_CARD: {
Expand Down
23 changes: 18 additions & 5 deletions src/languages/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1911,11 +1911,24 @@ export default {
exportExpensifyCard: 'Export Expensify Card transactions as',
deepDiveExpensifyCard: 'Expensify Card transactions automatically export to a "Expensify Card Liability Account" created with',
deepDiveExpensifyCardIntegration: 'our integration.',
exportDate: 'Export date',
exportDateDescription: 'Use this date when exporting reports to QuickBooks Online.',
lastExpense: {label: 'Date of last expense', description: 'The date of the most recent expense on the report'},
exportedDate: {label: 'Export date', description: 'The date the report was exported to QuickBooks Online'},
submittedData: {label: 'Submitted date', description: 'The date the report was submitted for approval'},
exportDate: {
label: 'Export date',
description: 'Use this date when exporting reports to QuickBooks Online.',
values: {
[CONST.QUICKBOOKS_EXPORT_DATE.LAST_EXPENSE]: {
label: 'Date of last expense',
description: 'The date of the most recent expense on the report',
},
[CONST.QUICKBOOKS_EXPORT_DATE.REPORT_EXPORTED]: {
label: 'Export date',
description: 'The date the report was exported to QuickBooks Online',
},
[CONST.QUICKBOOKS_EXPORT_DATE.REPORT_SUBMITTED]: {
label: 'Submitted date',
description: 'The date the report was submitted for approval',
},
},
},
receivable: 'Accounts receivable', // This is an account name that will come directly from QBO, so I don't know why we need a translation for it. It should take whatever the name of the account is in QBO. Leaving this note for CS.
archive: 'Accounts receivable archive', // This is an account name that will come directly from QBO, so I don't know why we need a translation for it. It should take whatever the name of the account is in QBO. Leaving this note for CS.
exportInvoicesDescription: 'Invoices will be exported to this account in QuickBooks Online.',
Expand Down
23 changes: 18 additions & 5 deletions src/languages/es.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1935,11 +1935,24 @@ export default {
deepDiveExpensifyCard: 'Las transacciones de la Tarjeta Expensify se exportan automáticamente a una "Cuenta de Responsabilidad de la Tarjeta Expensify" creada con',
deepDiveExpensifyCardIntegration: 'nuestra integración.',
exportExpensifyCard: 'Exportar las transacciones de las tarjetas Expensify como',
exportDate: 'Fecha de exportación',
exportDateDescription: 'Use this date when exporting reports to QuickBooks Online.',
lastExpense: {label: 'Date of last expense', description: 'The date of the most recent expense on the report'},
exportedDate: {label: 'Fecha de exportación', description: 'Fecha de exportación del informe a QuickBooks Online'},
submittedData: {label: 'Fecha de envío', description: 'Fecha en la que el informe se envió para su aprobación'},
exportDate: {
label: 'Fecha de exportación',
description: 'Usa esta fecha al exportar informe a QuickBooks Online.',
values: {
[CONST.QUICKBOOKS_EXPORT_DATE.LAST_EXPENSE]: {
label: 'Fecha del último gasto',
description: 'Fecha del gasto mas reciente en el informe',
},
[CONST.QUICKBOOKS_EXPORT_DATE.REPORT_EXPORTED]: {
label: 'Fecha de exportación',
description: 'Fecha de exportación del informe a QuickBooks Online',
},
[CONST.QUICKBOOKS_EXPORT_DATE.REPORT_SUBMITTED]: {
label: 'Fecha de envío',
description: 'Fecha en la que el informe se envió para su aprobación',
},
},
},
receivable: 'Cuentas por cobrar', // This is an account name that will come directly from QBO, so I don't know why we need a translation for it. It should take whatever the name of the account is in QBO. Leaving this note for CS.
archive: 'Archivo de cuentas por cobrar', // This is an account name that will come directly from QBO, so I don't know why we need a translation for it. It should take whatever the name of the account is in QBO. Leaving this note for CS.
exportInvoicesDescription: 'Las facturas se exportarán a esta cuenta en QuickBooks Online.',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ function QuickbooksExportConfigurationPage({policy}: WithPolicyConnectionsProps)
description: translate('workspace.qbo.date'),
onPress: () => Navigation.navigate(ROUTES.POLICY_ACCOUNTING_QUICKBOOKS_ONLINE_EXPORT_DATE_SELECT.getRoute(policyID)),
brickRoadIndicator: errorFields?.exportDate ? CONST.BRICK_ROAD_INDICATOR_STATUS.ERROR : undefined,
title: exportDate ? translate(`workspace.qbo.${exportDate}.label`) : undefined,
title: exportDate ? translate(`workspace.qbo.exportDate.values.${exportDate}.label`) : undefined,
pendingAction: pendingFields?.exportDate,
error: errorFields?.exportDate ? translate('common.genericErrorMessage') : undefined,
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ function QuickbooksExportDateSelectPage({policy}: WithPolicyConnectionsProps) {
const {exportDate} = policy?.connections?.quickbooksOnline?.config ?? {};
const data: CardListItem[] = Object.values(CONST.QUICKBOOKS_EXPORT_DATE).map((dateType) => ({
value: dateType,
text: translate(`workspace.qbo.${dateType}.label`),
alternateText: translate(`workspace.qbo.${dateType}.description`),
text: translate(`workspace.qbo.exportDate.values.${dateType}.label`),
alternateText: translate(`workspace.qbo.exportDate.values.${dateType}.description`),
keyForList: dateType,
isSelected: exportDate === dateType,
}));
Expand All @@ -52,9 +52,9 @@ function QuickbooksExportDateSelectPage({policy}: WithPolicyConnectionsProps) {
includeSafeAreaPaddingBottom={false}
testID={QuickbooksExportDateSelectPage.displayName}
>
<HeaderWithBackButton title={translate('workspace.qbo.exportDate')} />
<HeaderWithBackButton title={translate('workspace.qbo.exportDate.label')} />
<SelectionList
headerContent={<Text style={[styles.ph5, styles.pb5]}>{translate('workspace.qbo.exportDateDescription')}</Text>}
headerContent={<Text style={[styles.ph5, styles.pb5]}>{translate('workspace.qbo.exportDate.description')}</Text>}
sections={[{data}]}
ListItem={RadioListItem}
onSelectRow={selectExportDate}
Expand Down
Loading