Moved to Angular v20 and Tailwind v4 plus all related dependencies
Renamed Docker directory. Also serving static files from FastAPI.
This commit is contained in:
+9
-10
@@ -1,21 +1,20 @@
|
||||
import { AfterViewInit, Component, ElementRef, OnInit, ViewChild } from '@angular/core';
|
||||
import { AfterViewInit, Component, ElementRef, inject, OnInit, ViewChild } from '@angular/core';
|
||||
import { FormControl, FormGroup, ReactiveFormsModule } from '@angular/forms';
|
||||
import { MatButton } from '@angular/material/button';
|
||||
import { MatCard, MatCardHeader, MatCardTitle, MatCardContent, MatCardActions } from '@angular/material/card';
|
||||
import { MatCard, MatCardActions, MatCardContent, MatCardHeader, MatCardTitle } from '@angular/material/card';
|
||||
import { MatCheckbox } from '@angular/material/checkbox';
|
||||
import { MatFormField, MatLabel } from '@angular/material/form-field';
|
||||
import { MatInput } from '@angular/material/input';
|
||||
import { MatSnackBar } from '@angular/material/snack-bar';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
|
||||
import { ProductGroup } from '../../core/product-group';
|
||||
import { MatSnackBar } from '@angular/material/snack-bar';
|
||||
import { ProductGroupService } from '../product-group.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-product-group-detail',
|
||||
templateUrl: './product-group-detail.component.html',
|
||||
styleUrls: ['./product-group-detail.component.css'],
|
||||
standalone: true,
|
||||
imports: [
|
||||
MatCard,
|
||||
MatCardHeader,
|
||||
@@ -31,6 +30,11 @@ import { ProductGroupService } from '../product-group.service';
|
||||
],
|
||||
})
|
||||
export class ProductGroupDetailComponent implements OnInit, AfterViewInit {
|
||||
private route = inject(ActivatedRoute);
|
||||
private router = inject(Router);
|
||||
private snackBar = inject(MatSnackBar);
|
||||
private ser = inject(ProductGroupService);
|
||||
|
||||
@ViewChild('nameElement', { static: true }) nameElement!: ElementRef<HTMLInputElement>;
|
||||
form: FormGroup<{
|
||||
name: FormControl<string | null>;
|
||||
@@ -40,12 +44,7 @@ export class ProductGroupDetailComponent implements OnInit, AfterViewInit {
|
||||
|
||||
item: ProductGroup = new ProductGroup();
|
||||
|
||||
constructor(
|
||||
private route: ActivatedRoute,
|
||||
private router: Router,
|
||||
private snackBar: MatSnackBar,
|
||||
private ser: ProductGroupService,
|
||||
) {
|
||||
constructor() {
|
||||
this.form = new FormGroup({
|
||||
name: new FormControl<string | null>(null),
|
||||
nutritional: new FormControl<boolean>(false, { nonNullable: true }),
|
||||
|
||||
Reference in New Issue
Block a user