57 lines
1.7 KiB
TypeScript
57 lines
1.7 KiB
TypeScript
import { Component, OnInit } from '@angular/core';
|
|
|
|
import { ReactiveFormsModule, FormsModule, FormBuilder, FormGroup } from '@angular/forms';
|
|
@Component({
|
|
selector: 'app-jobfinder',
|
|
standalone: true,
|
|
imports: [ReactiveFormsModule],
|
|
template: `
|
|
<div class="container mt-5">
|
|
<div class="row text-left">
|
|
<h2>Wyszukiwarka ofert pracy(w toku)</h2>
|
|
</div>
|
|
<div class="row frame col-8">
|
|
<form class="form" [formGroup]="searchForm" (ngSubmit)="onSubmit()">
|
|
<div class="row ">
|
|
<div class="col p-0 form-floating">
|
|
<label for="title">Stanowisko</label>
|
|
<input class="form-control" type="text" id="title" formControlName="title" placeholder="Wprowadź stanowisko">
|
|
</div>
|
|
|
|
<div class="col p-0 form-floating">
|
|
<label for="location">Lokalizacja:</label>
|
|
<input class="form-control" id="location" formControlName="location" placeholder="Wprowadź lokalizację">
|
|
</div>
|
|
<button class="btn btn-secondary col-2" type="submit">Szukaj</button>
|
|
|
|
</div>
|
|
</form>
|
|
</div>
|
|
|
|
</div>
|
|
`
|
|
,
|
|
styleUrl: './jobfinder.component.css'
|
|
})
|
|
|
|
export class JobfinderComponent implements OnInit {
|
|
|
|
searchForm: FormGroup;
|
|
|
|
constructor(private fb: FormBuilder) {
|
|
this.searchForm = this.fb.group({
|
|
title: [''],
|
|
location: [''],
|
|
company: [''],
|
|
datePosted: ['']
|
|
});
|
|
}
|
|
|
|
ngOnInit(): void {}
|
|
|
|
onSubmit(): void {
|
|
const searchCriteria = this.searchForm.value;
|
|
console.log('Search criteria:', searchCriteria);
|
|
// Tutaj możesz dodać logikę do wyszukiwania ofert pracy
|
|
}
|
|
} |