Moved to Angular 20
Moved to Tailwind 4 Moved to Python 3.13 Enabled arm64/v8 Builds
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { PercentPipe, CurrencyPipe } from '@angular/common';
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { Component, OnInit, inject } from '@angular/core';
|
||||
import { FormControl, FormGroup, ReactiveFormsModule } from '@angular/forms';
|
||||
import { MatButtonModule } from '@angular/material/button';
|
||||
import { MatCardModule } from '@angular/material/card';
|
||||
@@ -12,7 +12,6 @@ import { ActivatedRoute, Router } from '@angular/router';
|
||||
import moment from 'moment';
|
||||
|
||||
import { ToCsvService } from '../shared/to-csv.service';
|
||||
|
||||
import { TaxReport } from './tax-report';
|
||||
import { TaxReportDatasource } from './tax-report-datasource';
|
||||
|
||||
@@ -34,6 +33,10 @@ import { TaxReportDatasource } from './tax-report-datasource';
|
||||
],
|
||||
})
|
||||
export class TaxReportComponent implements OnInit {
|
||||
private route = inject(ActivatedRoute);
|
||||
private router = inject(Router);
|
||||
private toCsv = inject(ToCsvService);
|
||||
|
||||
info: TaxReport = new TaxReport();
|
||||
dataSource: TaxReportDatasource = new TaxReportDatasource(this.info.amounts);
|
||||
form: FormGroup<{
|
||||
@@ -44,11 +47,7 @@ export class TaxReportComponent implements OnInit {
|
||||
/** Columns displayed in the table. Columns IDs can be added, removed, or reordered. */
|
||||
displayedColumns = ['name', 'taxRate', 'saleAmount', 'taxAmount'];
|
||||
|
||||
constructor(
|
||||
private route: ActivatedRoute,
|
||||
private router: Router,
|
||||
private toCsv: ToCsvService,
|
||||
) {
|
||||
constructor() {
|
||||
// Create form
|
||||
this.form = new FormGroup({
|
||||
startDate: new FormControl(new Date(), { nonNullable: true }),
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
import { Routes } from '@angular/router';
|
||||
|
||||
import { authGuard } from '../auth/auth-guard.service';
|
||||
|
||||
import { TaxReportComponent } from './tax-report.component';
|
||||
import { taxReportResolver } from './tax-report.resolver';
|
||||
|
||||
|
||||
@@ -1,10 +1,9 @@
|
||||
import { HttpClient, HttpParams } from '@angular/common/http';
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Injectable, inject } from '@angular/core';
|
||||
import { Observable } from 'rxjs';
|
||||
import { catchError } from 'rxjs/operators';
|
||||
|
||||
import { ErrorLoggerService } from '../core/error-logger.service';
|
||||
|
||||
import { TaxReport } from './tax-report';
|
||||
|
||||
const url = '/api/tax-report';
|
||||
@@ -14,10 +13,8 @@ const serviceName = 'TaxReportService';
|
||||
providedIn: 'root',
|
||||
})
|
||||
export class TaxReportService {
|
||||
constructor(
|
||||
private http: HttpClient,
|
||||
private log: ErrorLoggerService,
|
||||
) {}
|
||||
private http = inject(HttpClient);
|
||||
private log = inject(ErrorLoggerService);
|
||||
|
||||
get(startDate: string | null, finishDate: string | null): Observable<TaxReport> {
|
||||
const options = { params: new HttpParams() };
|
||||
|
||||
Reference in New Issue
Block a user