22 lines
489 B
TypeScript
22 lines
489 B
TypeScript
import { Component } from '@angular/core';
|
|
import { FormsModule, NgForm } from '@angular/forms';
|
|
|
|
@Component({
|
|
selector: 'app-add-task',
|
|
standalone: true,
|
|
imports: [FormsModule],
|
|
templateUrl: './add-task.component.html',
|
|
styleUrl: './add-task.component.scss',
|
|
})
|
|
export class AddTaskComponent {
|
|
taskData = {
|
|
title: '',
|
|
description: '',
|
|
};
|
|
|
|
onSubmit(ngForm: NgForm) {
|
|
if (ngForm.submitted && ngForm.form.valid) {
|
|
console.log('Send completed');
|
|
}
|
|
}
|
|
}
|