taxtank-core 1.0.22 → 1.0.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1620,8 +1620,8 @@ class FinancialYear {
|
|
1620
1620
|
return +localStorage.getItem('financialYear');
|
1621
1621
|
}
|
1622
1622
|
constructor(date) {
|
1623
|
-
this.yearStartDate = '-07-
|
1624
|
-
this.yearEndDate = '-06-
|
1623
|
+
this.yearStartDate = '-07-01T00:00:00';
|
1624
|
+
this.yearEndDate = '-06-30T23:59:59';
|
1625
1625
|
if (date) {
|
1626
1626
|
this.year = date instanceof Date ? FinancialYear.toFinYear(date) : date;
|
1627
1627
|
}
|
@@ -1651,9 +1651,11 @@ class FinancialYear {
|
|
1651
1651
|
}
|
1652
1652
|
setStartDate(year) {
|
1653
1653
|
this.startDate = new Date(`${year - 1}${this.yearStartDate}`);
|
1654
|
+
this.startDateUTC = new Date(Date.UTC(this.startDate.getFullYear(), this.startDate.getMonth(), this.startDate.getDate()));
|
1654
1655
|
}
|
1655
1656
|
setEndDate(year) {
|
1656
1657
|
this.endDate = new Date(`${year}${this.yearEndDate}`);
|
1658
|
+
this.endDateUTC = new Date(Date.UTC(this.endDate.getFullYear(), this.endDate.getMonth(), this.endDate.getDate()));
|
1657
1659
|
}
|
1658
1660
|
getPastMonths() {
|
1659
1661
|
const months = [];
|
@@ -16494,7 +16496,7 @@ class UserService extends RestService$1 {
|
|
16494
16496
|
localStorage.setItem('userId', this.getCacheFirst().id.toString());
|
16495
16497
|
localStorage.setItem('financialYear', this.getCacheFirst().financialYear.toString());
|
16496
16498
|
localStorage.setItem('roles', JSON.stringify(this.getCacheFirst().roles));
|
16497
|
-
localStorage.setItem('timezone', JSON.stringify(this.getCacheFirst().clientDetails.timezone));
|
16499
|
+
// localStorage.setItem('timezone', JSON.stringify(this.getCacheFirst().clientDetails.timezone));
|
16498
16500
|
return users;
|
16499
16501
|
}));
|
16500
16502
|
}
|
@@ -22840,8 +22842,8 @@ function atLeastOneEnabledValidator(arrayName) {
|
|
22840
22842
|
* Form for import multiple basiq bank accounts
|
22841
22843
|
*/
|
22842
22844
|
class BankAccountsImportForm extends AbstractForm {
|
22843
|
-
static { this.minDate = new FinancialYear(new Date().getFullYear() - 1).
|
22844
|
-
static { this.maxDate = new FinancialYear(new Date()).
|
22845
|
+
static { this.minDate = new FinancialYear(new Date().getFullYear() - 1).startDateUTC; }
|
22846
|
+
static { this.maxDate = new FinancialYear(new Date()).endDateUTC; }
|
22845
22847
|
constructor(bankAccounts) {
|
22846
22848
|
super({
|
22847
22849
|
migrateFrom: new UntypedFormControl(BankAccountsImportForm.minDate, [Validators.required, dateRangeValidator(BankAccountsImportForm.minDate, BankAccountsImportForm.maxDate)]),
|