2026-03-29 18:07:10 +03:30
|
|
|
import { AbstractDialog } from '@/shared/abstractClasses/abstract-dialog';
|
|
|
|
|
import { UikitFlatpickrJalaliComponent } from '@/uikit';
|
|
|
|
|
import { Component, inject } from '@angular/core';
|
|
|
|
|
import { FormBuilder, ReactiveFormsModule, Validators } from '@angular/forms';
|
|
|
|
|
import { PosLandingStore } from '../store/main.store';
|
2026-04-27 21:53:11 +03:30
|
|
|
import { SharedDialogComponent } from '@/shared/components/dialog/dialog.component';
|
2026-03-29 18:07:10 +03:30
|
|
|
|
|
|
|
|
@Component({
|
|
|
|
|
selector: 'pos-pre-invoice-dialog',
|
|
|
|
|
templateUrl: './pre-invoice-dialog.component.html',
|
2026-04-27 21:53:11 +03:30
|
|
|
imports: [SharedDialogComponent, UikitFlatpickrJalaliComponent, ReactiveFormsModule],
|
2026-03-29 18:07:10 +03:30
|
|
|
})
|
|
|
|
|
export class PosPreInvoiceDialogComponent extends AbstractDialog {
|
|
|
|
|
private readonly store = inject(PosLandingStore);
|
|
|
|
|
private readonly fb = inject(FormBuilder);
|
|
|
|
|
|
|
|
|
|
private initForm() {
|
|
|
|
|
const form = this.fb.group({
|
|
|
|
|
invoiceDate: [this.store.invoiceDate(), [Validators.required]],
|
|
|
|
|
});
|
|
|
|
|
return form;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
form = this.initForm();
|
|
|
|
|
}
|