Skip to content

Commit

Permalink
C1: QA fixes - 9 (#603)
Browse files Browse the repository at this point in the history
* C1: QA fixes - 9

* search filter

* config

* fixes

* few more fixes

* fix

* fix brand name
  • Loading branch information
ashwin1111 authored Feb 29, 2024
1 parent 0bc1d22 commit 0542b29
Show file tree
Hide file tree
Showing 33 changed files with 180 additions and 131 deletions.
16 changes: 8 additions & 8 deletions src/app/branding/branding-config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ const content: ContentConfiguration = {
exportSetting: {
stepName: 'Export Settings',
headerText: 'Export Corporate Card Expenses',
contentText: 'Enable this to export the Non-Reimbursable expenses from ' + brandingConfig.brandName + '. If not enabled, any <b>out-of-pocket</b> expenses will not be exported to QuickBooks Online',
contentText: 'Enable this to export the Non-Reimbursable expenses from ' + brandingConfig.brandName + '. If not enabled, any <b>out-of-pocket</b> expenses will not be exported to QuickBooks Online.',
corporateCard: {
expenseState: 'Select CCC expense state',
sectionLabel: '',
Expand All @@ -230,17 +230,17 @@ const content: ContentConfiguration = {
accountsPayableLabel: 'To which Accounts Payable account should the ',
accountsPayableSubLabel: ' to the selected Accounts Payable Account.',
creditCardExpenseSubLabel: 'You could choose to export CCC expenses when they have been approved and are awaiting payment clearance, OR simply when they have been paid out.',
creditCardExportTypeSubLabel: 'Expense can either be exported as single line items (Expense) or as a grouped report with multiple line items (Expense Report)',
creditCardExportTypeSubLabel: 'Expense can either be exported as single line items (Expense) or as a grouped report with multiple line items (Expense Report).',
journalOptionLabel: 'Name in Journal Entry (CCC)',
journalOptionSubLabel: 'You can select either the \'Merchant Name\' or the \'Employee Name\' to appear in the \'Name\' field of your Journal Entries'
journalOptionSubLabel: 'You can select either the \'Merchant Name\' or the \'Employee Name\' to appear in the \'Name\' field of your Journal Entries.'
}
},
importSetting: {
stepName: 'Import Settings',
headerText: '',
contentText: '',
importCategoriesLabel: 'Import the Chart of Accounts as Categories in ',
importCategoriesSubLabel: 'Imported account will be available as Categories in ',
importCategoriesSubLabel: 'Imported account will be available as Categories in ' + brandingConfig.brandName + '.',
importItemsLabel: 'Import Products/Services from QuickBooks Online',
importItemsSubLabel: 'Products/services from QuickBooks Online will be imported as Categories in ',
taxCodeLabel: 'Import Tax from QuickBooks Online',
Expand Down Expand Up @@ -322,7 +322,7 @@ const content: ContentConfiguration = {
exportSetting: {
stepName: 'Export settings',
headerText: 'Export corporate card expenses',
contentText: 'Enable this to export the non-reimbursable expenses from ' + brandingConfig.brandName + ' if not enabled, any <b>out-of-pocket</b> expenses will not be exported to QuickBooks Online',
contentText: 'Enable this to export the non-reimbursable expenses from ' + brandingConfig.brandName + ' if not enabled, any <b>out-of-pocket</b> expenses will not be exported to QuickBooks Online.',
corporateCard: {
expenseState: 'Select ccc expense state',
sectionLabel: '',
Expand All @@ -336,17 +336,17 @@ const content: ContentConfiguration = {
accountsPayableLabel: 'To which accounts payable account should the ',
accountsPayableSubLabel: ' to the selected accounts payable Account.',
creditCardExpenseSubLabel: 'You could choose to export ccc expenses when they have been approved and are awaiting payment clearance, or simply when they have been paid out.',
creditCardExportTypeSubLabel: 'Expense can either be exported as single line items (expense) or as a grouped report with multiple line items (expense report)',
creditCardExportTypeSubLabel: 'Expense can either be exported as single line items (expense) or as a grouped report with multiple line items (expense report).',
journalOptionLabel: 'Name in journal entry (ccc)',
journalOptionSubLabel: 'You can select either the \'merchant name\' or the \'employee name\' to appear in the \'name\' field of your journal entries'
journalOptionSubLabel: 'You can select either the \'merchant name\' or the \'employee name\' to appear in the \'name\' field of your journal entries.'
}
},
importSetting: {
stepName: 'Import settings',
headerText: '',
contentText: '',
importCategoriesLabel: 'Import the chart of accounts as categories in ',
importCategoriesSubLabel: 'Imported account will be available as categories in ',
importCategoriesSubLabel: 'Imported account will be available as categories in ' + brandingConfig.brandName + '.',
importItemsLabel: 'Import products/services from QuickBooks Online',
importItemsSubLabel: 'Products/services from QuickBooks Online will be imported as categories in ',
taxCodeLabel: 'Import tax from QuickBooks Online',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export class QBOImportSettingModel extends ImportSettingsModel {
return new FormGroup({
importCategories: new FormControl(importSettings?.workspace_general_settings.import_categories ?? false),
expenseFields: new FormArray(expenseFieldsArray),
chartOfAccountTypes: new FormControl(importSettings?.workspace_general_settings.charts_of_accounts ? importSettings.workspace_general_settings.charts_of_accounts : []),
chartOfAccountTypes: new FormControl(importSettings?.workspace_general_settings.charts_of_accounts ? importSettings.workspace_general_settings.charts_of_accounts : ['Expense']),
importItems: new FormControl(importSettings?.workspace_general_settings.import_items ?? false),
taxCode: new FormControl(importSettings?.workspace_general_settings.import_tax_codes ?? false),
importVendorsAsMerchants: new FormControl(importSettings?.workspace_general_settings.import_vendors_as_merchants ?? false),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,20 +120,18 @@ export class BusinessCentralCompleteExportLogComponent implements OnInit {

this.exportLogForm.controls.start.valueChanges.subscribe((dateRange) => {
const paginator: Paginator = this.paginatorService.getPageSize(PaginatorPage.EXPORT_LOG);
if (dateRange[1]) {
if (dateRange) {
this.selectedDateFilter = {
startDate: dateRange[0],
endDate: dateRange[1]
};

this.trackDateFilter('existing', this.selectedDateFilter);
this.getAccountingExports(paginator.limit, paginator.offset);
}
} else {
if (!dateRange) {
this.dateOptions = AccountingExportModel.getDateOptionsV2();
this.selectedDateFilter = null;
this.getAccountingExports(paginator.limit, paginator.offset);
} else if (dateRange.length && dateRange[1]) {
this.selectedDateFilter = {
startDate: dateRange[0],
endDate: dateRange[1]
};

this.trackDateFilter('existing', this.selectedDateFilter);
this.getAccountingExports(paginator.limit, paginator.offset);
}
});
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,20 +98,18 @@ export class BusinessCentralSkippedExportLogComponent implements OnInit {

this.skipExportLogForm.controls.start.valueChanges.subscribe((dateRange) => {
const paginator: Paginator = this.paginatorService.getPageSize(PaginatorPage.EXPORT_LOG);
if (dateRange[1]) {
if (dateRange) {
this.selectedDateFilter = {
startDate: dateRange[0],
endDate: dateRange[1]
};

this.trackDateFilter('existing', this.selectedDateFilter);
this.getSkippedExpenses(paginator.limit, paginator.offset);
}
} else {
if (!dateRange) {
this.dateOptions = AccountingExportModel.getDateOptionsV2();
this.selectedDateFilter = null;
this.getSkippedExpenses(paginator.limit, paginator.offset);
} else if (dateRange.length && dateRange[1]) {
this.selectedDateFilter = {
startDate: dateRange[0],
endDate: dateRange[1]
};

this.trackDateFilter('existing', this.selectedDateFilter);
this.getSkippedExpenses(paginator.limit, paginator.offset);
}
});
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -212,15 +212,15 @@ export class DashboardComponent implements OnInit {

private setupDateFilterWatcher(): void {
this.exportLogForm.controls.start.valueChanges.subscribe((dateRange) => {
if (dateRange[1]) {
if (!dateRange) {
this.selectedDateFilter = null;
this.dateFilter();
} else if (dateRange.length && dateRange[1]) {
this.selectedDateFilter = {
startDate: dateRange[0],
endDate: dateRange[1]
};

this.dateFilter();
} else {
this.selectedDateFilter = null;
this.dateFilter();
}
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -113,18 +113,16 @@ export class QboCompleteExportLogComponent implements OnInit {

this.exportLogForm.controls.start.valueChanges.subscribe((dateRange) => {
const paginator: Paginator = this.paginatorService.getPageSize(PaginatorPage.EXPORT_LOG);
if (dateRange[1]) {
if (dateRange) {
this.selectedDateFilter = {
startDate: dateRange[0],
endDate: dateRange[1]
};

this.getAccountingExports(paginator.limit, paginator.offset);
}
} else {
if (!dateRange) {
this.dateOptions = AccountingExportModel.getDateOptionsV2();
this.selectedDateFilter = null;
this.getAccountingExports(paginator.limit, paginator.offset);
} else if (dateRange.length && dateRange[1]) {
this.selectedDateFilter = {
startDate: dateRange[0],
endDate: dateRange[1]
};

this.getAccountingExports(paginator.limit, paginator.offset);
}
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<div *ngIf="isGradientAllowed" class="tw-absolute tw-bg-header-2 tw-h-84-px tw-w-[100%]"></div>

<div class="tw-py-40-px" [ngClass]="{'tw-px-120-px': brandingConfig.brandId === 'fyle', 'tw-px-60-px': brandingConfig.brandId === 'co'}">
<app-sub-menu [modules]="modules" [activeModule]="activeModule"></app-sub-menu>
<app-sub-menu *ngIf="brandingFeatureConfig.featureFlags.advancedSettings.skipExport" [modules]="modules" [activeModule]="activeModule"></app-sub-menu>
<div>
<router-outlet></router-outlet>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ export class QboExportLogComponent implements OnInit {

readonly brandingConfig = brandingConfig;

readonly brandingFeatureConfig = brandingFeatureConfig;

constructor(
private router: Router
) { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,18 +103,16 @@ export class QboSkippedExportLogComponent implements OnInit {

this.skipExportLogForm.controls.start.valueChanges.subscribe((dateRange) => {
const paginator: Paginator = this.paginatorService.getPageSize(PaginatorPage.EXPORT_LOG);
if (dateRange[1]) {
if (dateRange) {
this.selectedDateFilter = {
startDate: dateRange[0],
endDate: dateRange[1]
};

this.getSkippedExpenses(paginator.limit, paginator.offset);
}
} else {
if (!dateRange) {
this.dateOptions = AccountingExportModel.getDateOptionsV2();
this.selectedDateFilter = null;
this.getSkippedExpenses(paginator.limit, paginator.offset);
} else if (dateRange.length && dateRange[1]) {
this.selectedDateFilter = {
startDate: dateRange[0],
endDate: dateRange[1]
};

this.getSkippedExpenses(paginator.limit, paginator.offset);
}
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<div>
<app-configuration-step-header
[headerText]="'Connect to QuickBooks Online'"
[contentText]="'Connect to the QuickBooks Online Company from which you would like to import and export data. The ' + brandingConfig.brandName + ' org and QuickBooks Online company cannot be changed once the configuration steps are complete'"
[contentText]="'Connect to the QuickBooks Online Company from which you would like to import and export data. The ' + brandingConfig.brandName + ' org and QuickBooks Online company cannot be changed once the configuration steps are complete.'"
[redirectLink]="redirectLink">
</app-configuration-step-header>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
<app-configuration-toggle-field
[form]="advancedSettingForm"
[label]="'Schedule automatic export'"
[subLabel]="'Set up a schedule to frequently automate the export of expenses from ' + brandingConfig.brandName + ' to QuickBooks Online'"
[subLabel]="'Set up a schedule to frequently automate the export of expenses from ' + brandingConfig.brandName + ' to QuickBooks Online.'"
[formControllerName]="'exportSchedule'"
[iconPath]="'calendar'">
</app-configuration-toggle-field>
Expand All @@ -37,7 +37,7 @@
[isFieldMandatory]="false"
[mandatoryErrorListName]="'automatic export method'"
[label]="'Set up export frequency'"
[subLabel]="'Set a frequency based on how often you want your expenses in ' + brandingConfig.brandName + ' to be exported to QuickBooks Online'"
[subLabel]="'Set a frequency based on how often you want your expenses in ' + brandingConfig.brandName + ' to be exported to QuickBooks Online.'"
[options]="hours"
[isEmailPresent]="brandingFeatureConfig.featureFlags.advancedSettings.emailNotification ? true: false"
[formControllerName]="'exportScheduleFrequency'"
Expand Down Expand Up @@ -104,7 +104,7 @@
[form]="advancedSettingForm"
[iconPath]="'user-plus'"
[label]="brandingContent.autoCreateMerchantsAsVendorsLabel"
[subLabel]="brandingConfig.brandName + ' will auto-create a new vendor in QuickBooks Online if a merchant added by an employee does not have a corresponding match in QuickBooks Online'"
[subLabel]="brandingConfig.brandName + ' will auto-create a new vendor in QuickBooks Online if a merchant added by an employee does not have a corresponding match in QuickBooks Online.'"
[formControllerName]="'autoCreateMerchantsAsVendors'">
</app-configuration-toggle-field>
</div>
Expand Down
Loading

0 comments on commit 0542b29

Please sign in to comment.