feat: add sale invoice card component with functionality for sending and retrieving invoice status
- Implemented sale invoice card component with HTML and TypeScript files. - Added API routes for sale invoices including sending, retrying, and checking status. - Created models for sale invoice fiscal actions and filters. - Developed service for handling sale invoice operations. - Introduced store for managing sale invoice state. - Created views for listing and displaying single sale invoices. - Added support for managing stock keeping units with forms and services. - Implemented reusable select components for measure units and SKUs. - Enhanced shared components for input fields including fiscal ID, SKU type, and VAT.
This commit is contained in:
+8
-3
@@ -4,10 +4,15 @@ import { InputComponent } from '../input/input.component';
|
||||
|
||||
@Component({
|
||||
selector: 'field-fiscal-code',
|
||||
template: `<app-input label="کد مالیاتی" [control]="control" [name]="name" type="number" />`,
|
||||
template: `<app-input
|
||||
label="کد مالیاتی"
|
||||
[control]="control"
|
||||
[name]="name"
|
||||
[isLtrInput]="true"
|
||||
/>`,
|
||||
imports: [ReactiveFormsModule, InputComponent],
|
||||
})
|
||||
export class FiscalCodeComponent {
|
||||
export class FiscalIdComponent {
|
||||
@Input({ required: true }) control = new FormControl<string>('');
|
||||
@Input() name = 'fiscal_code';
|
||||
@Input() name = 'fiscal_id';
|
||||
}
|
||||
@@ -8,7 +8,7 @@ export * from './device_id.component';
|
||||
export * from './economic_code.component';
|
||||
export * from './email.component';
|
||||
export * from './first_name.component';
|
||||
export * from './fiscal_code.component';
|
||||
export * from './fiscal_id.component';
|
||||
export * from './guild_id.component';
|
||||
export * from './last_name.component';
|
||||
export * from './legal_name.component';
|
||||
@@ -29,6 +29,8 @@ export * from './registration_number.component';
|
||||
export * from './serial_number.component';
|
||||
export * from './set_off.component';
|
||||
export * from './sku.component';
|
||||
export * from './sku_type.component';
|
||||
export * from './terminal.component';
|
||||
export * from './unit_price.component';
|
||||
export * from './username.component';
|
||||
export * from './vat.component';
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
import { CatalogSkuSelectComponent } from '@/shared/catalog/sku';
|
||||
import { Component, Input } from '@angular/core';
|
||||
import { FormControl, ReactiveFormsModule } from '@angular/forms';
|
||||
import { InputComponent } from '../input/input.component';
|
||||
|
||||
@Component({
|
||||
selector: 'field-sku',
|
||||
template: `<app-input label="شناسه عمومی" [control]="control" [name]="name" />`,
|
||||
imports: [ReactiveFormsModule, InputComponent],
|
||||
template: `<catalog-sku-select label="شناسهی کالا" [control]="control" [name]="name" />`,
|
||||
imports: [ReactiveFormsModule, CatalogSkuSelectComponent],
|
||||
})
|
||||
export class SkuComponent {
|
||||
@Input({ required: true }) control = new FormControl<string>('');
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
import { Component, Input } from '@angular/core';
|
||||
import { FormControl, ReactiveFormsModule } from '@angular/forms';
|
||||
import { InputComponent } from '../input/input.component';
|
||||
|
||||
@Component({
|
||||
selector: 'field-sku-type',
|
||||
template: `<app-input label="نوع" [control]="control" [name]="name" />`,
|
||||
imports: [ReactiveFormsModule, InputComponent],
|
||||
})
|
||||
export class SkuTypeComponent {
|
||||
@Input({ required: true }) control = new FormControl<string>('');
|
||||
@Input() name = 'type';
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
import { Component, Input } from '@angular/core';
|
||||
import { FormControl, ReactiveFormsModule } from '@angular/forms';
|
||||
import { InputComponent } from '../input/input.component';
|
||||
|
||||
@Component({
|
||||
selector: 'field-vat',
|
||||
template: `<app-input label="مالیات بر ارزش افزوده" [control]="control" [name]="name" type="price" />`,
|
||||
imports: [ReactiveFormsModule, InputComponent],
|
||||
})
|
||||
export class VatComponent {
|
||||
@Input({ required: true }) control = new FormControl<number | string>('');
|
||||
@Input() name = 'VAT';
|
||||
}
|
||||
Reference in New Issue
Block a user