@cbm-common/cbm-types 0.0.239 → 0.0.240
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/components/attachments/components/icons/ellipsis-icon/ellipsis-icon.component.d.ts +2 -0
- package/lib/components/item-stock-modal/item-stock-modal.component.d.ts +22 -0
- package/lib/components/modals-search/modal-search-outsourcing/modal-search-outsourcing.component.d.ts +69 -0
- package/lib/components/modals-search/modal-search-service/modal-search-service.component.d.ts +75 -0
- package/lib/components/order-vehicle-add-charge/order-vehicle-add-charge.d.ts +351 -0
- package/lib/components/order-vehicle-add-charge/sale-account-modal/sale-account-modal.d.ts +53 -0
- package/lib/components/outsourcing-services-movements-modal/outsourcing-services-movements-modal.component.d.ts +26 -0
- package/lib/components/pms-add-charge/folios-modal/folios-modal.d.ts +4 -4
- package/lib/components/pms-add-charge/pms-add-charge.d.ts +10 -10
- package/lib/components/price-history-modal/price-history-modal.component.d.ts +29 -0
- package/lib/components/sort-detail-modal/sort-detail-modal.component.d.ts +69 -0
- package/lib/components/ui/details-resume/details-resume.component.d.ts +29 -0
- package/lib/components/ui/warning-add-items-without-order-message/warning-add-items-without-order-message.component.d.ts +8 -0
- package/lib/domain/models/employee.model.d.ts +176 -0
- package/lib/domain/models/general.domain.model.d.ts +6 -0
- package/lib/domain/models/invoice.domain.model.d.ts +1 -1
- package/lib/domain/models/outsourcing-services-movements.domain.model.d.ts +160 -0
- package/lib/domain/models/sale-price.domain.model.d.ts +4 -1
- package/lib/domain/repositories/outsourcing-services-movements.domain.repository.d.ts +7 -0
- package/lib/domain/repositories/sales-account.domain.repository.d.ts +1 -1
- package/lib/domain/services/general.domain.service.d.ts +3 -0
- package/lib/domain/services/sale-account.domain.service.d.ts +24 -0
- package/lib/domain/services/service/form-group-tracker.service.d.ts +13 -0
- package/lib/infrastructure/repositories/outsourcing-services-movements.infrastructure.repository.d.ts +5 -0
- package/lib/infrastructure/services/outsourcing-services-movements.infrastructure.service.d.ts +10 -0
- package/lib/utils/debounce.d.ts +1 -0
- package/lib/utils/form-error-location.d.ts +2 -0
- package/lib/utils/resize.d.ts +14 -0
- package/package.json +1 -1
- package/public-api.d.ts +3 -0
|
@@ -2,26 +2,26 @@ import { DestroyRef, OnInit } from '@angular/core';
|
|
|
2
2
|
import { FormControl, FormGroup } from '@angular/forms';
|
|
3
3
|
import { ListService, PaginatedListService } from '@cbm-common/data-access';
|
|
4
4
|
import { Subject } from 'rxjs';
|
|
5
|
+
import { CbmClientModel } from '../../domain/models/client.domain.model';
|
|
6
|
+
import { CbmContactModel } from '../../domain/models/contact.domain.model';
|
|
5
7
|
import { CbmCostCenterModel } from '../../domain/models/cost-center.domain.model';
|
|
6
8
|
import { STATE } from '../../domain/models/general.domain.model';
|
|
9
|
+
import { CbmPriceListModel } from '../../domain/models/price-list.domain.model';
|
|
7
10
|
import { CbmRoomModel } from '../../domain/models/room.domain.model';
|
|
8
11
|
import { CbmSalesAccountModel } from '../../domain/models/sales-account.domain.model';
|
|
9
12
|
import { CbmChargeRepository } from '../../domain/repositories/charge.domain.repository';
|
|
13
|
+
import { CbmClientDomainRepository } from '../../domain/repositories/client.domain.repository';
|
|
10
14
|
import { CbmCostCenterRepository } from '../../domain/repositories/cost-center.domain.repository';
|
|
11
15
|
import { CbmRoomRepository } from '../../domain/repositories/room.domain.repository';
|
|
12
|
-
import {
|
|
16
|
+
import { CbmSalesAccountDomainRepository } from '../../domain/repositories/sales-account.domain.repository';
|
|
17
|
+
import { CbmAuthReactiveService } from '../../domain/services/auth-reactive.domain.service';
|
|
18
|
+
import { CbmIrbpnrDomainService } from '../../domain/services/taxes/irbpnr.domain.service';
|
|
13
19
|
import { CbmNotificationService } from '../../remotes/services.remote';
|
|
14
20
|
import { ItemDetails } from '../item-details/item-details';
|
|
15
21
|
import { CbmModalConfirmComponent } from '../modal-confirm/modal-confirm';
|
|
16
|
-
import { FoliosModal } from './folios-modal/folios-modal';
|
|
17
|
-
import { CbmTaxesModal } from '../taxes-modal/taxes-modal.model';
|
|
18
|
-
import { CbmIrbpnrDomainService } from '../../domain/services/taxes/irbpnr.domain.service';
|
|
19
22
|
import { CbmServiceDetails } from '../service-details/service-details';
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import { CbmContactModel } from '../../domain/models/contact.domain.model';
|
|
23
|
-
import { CbmClientDomainRepository } from '../../domain/repositories/client.domain.repository';
|
|
24
|
-
import { CbmAuthReactiveService } from '../../domain/services/auth-reactive.domain.service';
|
|
23
|
+
import { CbmTaxesModal } from '../taxes-modal/taxes-modal.model';
|
|
24
|
+
import { FoliosModal } from './folios-modal/folios-modal';
|
|
25
25
|
export declare class CbmPmsAddCharge implements OnInit {
|
|
26
26
|
private readonly destroyRef;
|
|
27
27
|
private readonly roomRepository;
|
|
@@ -32,7 +32,7 @@ export declare class CbmPmsAddCharge implements OnInit {
|
|
|
32
32
|
private readonly costCenterRepository;
|
|
33
33
|
private readonly irbpnrService;
|
|
34
34
|
private readonly clientRepository;
|
|
35
|
-
constructor(destroyRef: DestroyRef, roomRepository: CbmRoomRepository, chargeRepository: CbmChargeRepository, notificationService: CbmNotificationService, authService: CbmAuthReactiveService, salesAccountRepository:
|
|
35
|
+
constructor(destroyRef: DestroyRef, roomRepository: CbmRoomRepository, chargeRepository: CbmChargeRepository, notificationService: CbmNotificationService, authService: CbmAuthReactiveService, salesAccountRepository: CbmSalesAccountDomainRepository, costCenterRepository: CbmCostCenterRepository, irbpnrService: CbmIrbpnrDomainService, clientRepository: CbmClientDomainRepository);
|
|
36
36
|
disableGuard: boolean;
|
|
37
37
|
formDirty: () => boolean;
|
|
38
38
|
chargeFormGroup: FormGroup<{
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { DestroyRef, OnChanges, SimpleChanges } from '@angular/core';
|
|
2
|
+
import { Router } from '@angular/router';
|
|
3
|
+
import { CbmNotificationService } from "@cbm-common/cbm-types";
|
|
4
|
+
import { GeneralDomainService } from '../../domain/services/general.domain.service';
|
|
5
|
+
import { CbmInvoiceDomainRepository } from '../../domain/repositories/invoice.domain.repository';
|
|
6
|
+
import { CbmInvoiceModel } from '../../domain/models/invoice.domain.model';
|
|
7
|
+
import { PaginatedListService } from '@cbm-common/data-access';
|
|
8
|
+
export interface IPriceHistoryModel {
|
|
9
|
+
clientId: string;
|
|
10
|
+
itemId: string;
|
|
11
|
+
}
|
|
12
|
+
export declare class CbmPriceHistoryModalComponent implements OnChanges {
|
|
13
|
+
private router;
|
|
14
|
+
private destroyRef;
|
|
15
|
+
private generalService;
|
|
16
|
+
private invoiceRepository;
|
|
17
|
+
private readonly notificationService;
|
|
18
|
+
constructor(router: Router, destroyRef: DestroyRef, generalService: GeneralDomainService, invoiceRepository: CbmInvoiceDomainRepository, notificationService: CbmNotificationService);
|
|
19
|
+
modalId: import("@angular/core").InputSignal<string>;
|
|
20
|
+
priceHistoryRequest: import("@angular/core").InputSignal<IPriceHistoryModel | null>;
|
|
21
|
+
lastMovements: import("@angular/core").WritableSignal<CbmInvoiceModel.ListLastMovementsResponse.Item[]>;
|
|
22
|
+
totals: import("@angular/core").WritableSignal<CbmInvoiceModel.ListLastMovementsResponse.TotalAmount | null>;
|
|
23
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
24
|
+
lastMovements$: PaginatedListService<CbmInvoiceModel.ListLastMovementsResponse, CbmInvoiceModel.ListLastMovementsParams, CbmInvoiceModel.ListLastMovementsResponse.Item[]>;
|
|
25
|
+
fetchLastMovementsInventory(): void;
|
|
26
|
+
openModal(): void;
|
|
27
|
+
closeModal(): void;
|
|
28
|
+
redirectTo(data: CbmInvoiceModel.ListLastMovementsResponse.Item): void;
|
|
29
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import { CdkDragDrop } from '@angular/cdk/drag-drop';
|
|
2
|
+
import { ElementRef, OnChanges, SimpleChanges } from '@angular/core';
|
|
3
|
+
import { CbmNotificationService } from "@cbm-common/cbm-types";
|
|
4
|
+
import { CbmModalConfirmComponent } from '../modal-confirm/modal-confirm';
|
|
5
|
+
import { GeneralDomainService } from '../../domain/services/general.domain.service';
|
|
6
|
+
export declare namespace ISortDetailModel {
|
|
7
|
+
type DetailType = 'item' | 'service' | 'kit' | 'outsourcing' | 'fixed_asset';
|
|
8
|
+
interface Data {
|
|
9
|
+
original_index?: number;
|
|
10
|
+
item_id?: string;
|
|
11
|
+
category_id?: string;
|
|
12
|
+
tax_iva_id?: string;
|
|
13
|
+
amount?: number;
|
|
14
|
+
price_base?: number;
|
|
15
|
+
total_price?: number;
|
|
16
|
+
discount_rate?: number;
|
|
17
|
+
unit_discount?: number;
|
|
18
|
+
total_discount?: number;
|
|
19
|
+
replace_item_name?: string;
|
|
20
|
+
commentary_item?: string;
|
|
21
|
+
tax_iva_rate?: number;
|
|
22
|
+
item_code?: string;
|
|
23
|
+
item_barcode?: string;
|
|
24
|
+
item_name?: string;
|
|
25
|
+
category_name?: string;
|
|
26
|
+
type?: DetailType;
|
|
27
|
+
tax_iva?: Data.TaxIva;
|
|
28
|
+
manage_by?: string;
|
|
29
|
+
}
|
|
30
|
+
namespace Data {
|
|
31
|
+
interface TaxIva {
|
|
32
|
+
_id: string;
|
|
33
|
+
country_id?: string;
|
|
34
|
+
code?: string;
|
|
35
|
+
percentage?: number;
|
|
36
|
+
description?: string;
|
|
37
|
+
enabled?: boolean;
|
|
38
|
+
created_user?: string;
|
|
39
|
+
created_at?: number;
|
|
40
|
+
updated_user?: string;
|
|
41
|
+
updated_at?: number;
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
export declare class CbmSortDetailModalComponent implements OnChanges {
|
|
46
|
+
private generalService;
|
|
47
|
+
private readonly notificationService;
|
|
48
|
+
itemDetailsTableRef: import("@angular/core").Signal<ElementRef<HTMLTableElement> | undefined>;
|
|
49
|
+
modalConfirmRef: import("@angular/core").Signal<CbmModalConfirmComponent>;
|
|
50
|
+
modalId: import("@angular/core").InputSignal<string>;
|
|
51
|
+
data: import("@angular/core").InputSignal<ISortDetailModel.Data[]>;
|
|
52
|
+
type: import("@angular/core").InputSignal<ISortDetailModel.DetailType>;
|
|
53
|
+
onlyAmount: import("@angular/core").InputSignal<boolean>;
|
|
54
|
+
newSortedData: import("@angular/core").OutputEmitterRef<ISortDetailModel.Data[]>;
|
|
55
|
+
sortType: {
|
|
56
|
+
[key: string]: {
|
|
57
|
+
label: string;
|
|
58
|
+
rowLabel: string;
|
|
59
|
+
};
|
|
60
|
+
};
|
|
61
|
+
columnWidths: number[];
|
|
62
|
+
constructor(generalService: GeneralDomainService, notificationService: CbmNotificationService);
|
|
63
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
64
|
+
captureColumnWidths(): void;
|
|
65
|
+
onDropItemDetails(event: CdkDragDrop<ISortDetailModel.Data[]>): void;
|
|
66
|
+
openModal(): void;
|
|
67
|
+
closeModal(): void;
|
|
68
|
+
onConfirm(): Promise<void>;
|
|
69
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { CbmCompanyCustomModel } from '@cbm-common/cbm-types';
|
|
2
|
+
export interface IFreeItemAmountModel {
|
|
3
|
+
item_id?: string;
|
|
4
|
+
item_name: string;
|
|
5
|
+
item_code: string;
|
|
6
|
+
free_amount: number;
|
|
7
|
+
price_type_sequence?: string;
|
|
8
|
+
}
|
|
9
|
+
export declare class CbmDetailsResumeComponent {
|
|
10
|
+
id: import("@angular/core").InputSignal<string | null | undefined>;
|
|
11
|
+
showFreeItems: import("@angular/core").InputSignal<boolean | undefined>;
|
|
12
|
+
freeItems: import("@angular/core").InputSignal<IFreeItemAmountModel[] | undefined>;
|
|
13
|
+
companyCustom: import("@angular/core").InputSignal<CbmCompanyCustomModel.FindResponse>;
|
|
14
|
+
itemsArrayLenght: import("@angular/core").InputSignal<number | undefined>;
|
|
15
|
+
kitsArrayLenght: import("@angular/core").InputSignal<number | undefined>;
|
|
16
|
+
servicesArrayLenght: import("@angular/core").InputSignal<number | undefined>;
|
|
17
|
+
outsourcingsArrayLenght: import("@angular/core").InputSignal<number | undefined>;
|
|
18
|
+
fixedAssetsArrayLenght: import("@angular/core").InputSignal<number | undefined>;
|
|
19
|
+
itemsAmount: import("@angular/core").InputSignal<number | undefined>;
|
|
20
|
+
kitsAmount: import("@angular/core").InputSignal<number | undefined>;
|
|
21
|
+
servicesAmount: import("@angular/core").InputSignal<number | undefined>;
|
|
22
|
+
outsourcingsAmount: import("@angular/core").InputSignal<number | undefined>;
|
|
23
|
+
fixedAssetsAmount: import("@angular/core").InputSignal<number | undefined>;
|
|
24
|
+
itemsSubtotalWithoutTaxes: import("@angular/core").InputSignal<number | undefined>;
|
|
25
|
+
kitsSubtotalWithoutTaxes: import("@angular/core").InputSignal<number | undefined>;
|
|
26
|
+
servicesSubtotalWithoutTaxes: import("@angular/core").InputSignal<number | undefined>;
|
|
27
|
+
outsourcingsSubtotalWithoutTaxes: import("@angular/core").InputSignal<number | undefined>;
|
|
28
|
+
fixedAssetsSubtotalWithoutTaxes: import("@angular/core").InputSignal<number | undefined>;
|
|
29
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { CbmInvoiceModel } from '../../../domain/models/invoice.domain.model';
|
|
2
|
+
export declare class CbmWarningAddItemsWithoutOrderMessageComponent {
|
|
3
|
+
module: import("@angular/core").InputSignal<string>;
|
|
4
|
+
type: import("@angular/core").InputSignal<CbmInvoiceModel.DetailType>;
|
|
5
|
+
textToShow: {
|
|
6
|
+
[key in CbmInvoiceModel.DetailType]: string;
|
|
7
|
+
};
|
|
8
|
+
}
|
|
@@ -0,0 +1,176 @@
|
|
|
1
|
+
export declare namespace CbmEmployeeModel {
|
|
2
|
+
interface ListParams {
|
|
3
|
+
page: number;
|
|
4
|
+
size: number;
|
|
5
|
+
department_id?: string;
|
|
6
|
+
position_id?: string;
|
|
7
|
+
marital_status_id?: string;
|
|
8
|
+
document_type_id?: string;
|
|
9
|
+
name_surname?: string;
|
|
10
|
+
enabled?: boolean;
|
|
11
|
+
}
|
|
12
|
+
interface ListResponse {
|
|
13
|
+
success: boolean;
|
|
14
|
+
items: ListResponse.Data[];
|
|
15
|
+
}
|
|
16
|
+
namespace ListResponse {
|
|
17
|
+
interface Data {
|
|
18
|
+
_id: string;
|
|
19
|
+
company_id: string;
|
|
20
|
+
company_NIF: string;
|
|
21
|
+
company_trade_name: string;
|
|
22
|
+
company_business_name: string;
|
|
23
|
+
company_address: string;
|
|
24
|
+
company_logo: string;
|
|
25
|
+
country_id: string;
|
|
26
|
+
country_code: string;
|
|
27
|
+
country_name: string;
|
|
28
|
+
country_short_name: string;
|
|
29
|
+
period_id: string;
|
|
30
|
+
period_year: string;
|
|
31
|
+
department_id: string;
|
|
32
|
+
department_code: number;
|
|
33
|
+
department_name: string;
|
|
34
|
+
position_id: string;
|
|
35
|
+
position_code: number;
|
|
36
|
+
position_name: string;
|
|
37
|
+
marital_status_id: string;
|
|
38
|
+
marital_status_code: string;
|
|
39
|
+
marital_status_name: string;
|
|
40
|
+
document_type_id: string;
|
|
41
|
+
document_type_code: string;
|
|
42
|
+
document_type_name: string;
|
|
43
|
+
sequence_number: number;
|
|
44
|
+
document_number: string;
|
|
45
|
+
names: string;
|
|
46
|
+
surnames: string;
|
|
47
|
+
address: string;
|
|
48
|
+
phone_code: string;
|
|
49
|
+
phone: string;
|
|
50
|
+
cellphone: string;
|
|
51
|
+
email: string[];
|
|
52
|
+
gender: string;
|
|
53
|
+
birthdate: number;
|
|
54
|
+
enabled: boolean;
|
|
55
|
+
deleted: boolean;
|
|
56
|
+
user_id: string;
|
|
57
|
+
created_user: string;
|
|
58
|
+
created_at: number;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
interface SaveBody {
|
|
62
|
+
company_NIF: string;
|
|
63
|
+
company_trade_name: string;
|
|
64
|
+
company_business_name: string;
|
|
65
|
+
company_address: string;
|
|
66
|
+
company_email?: string;
|
|
67
|
+
company_logo: string;
|
|
68
|
+
department_id: string;
|
|
69
|
+
department_code: number;
|
|
70
|
+
department_name: string;
|
|
71
|
+
position_id: string;
|
|
72
|
+
position_code: number;
|
|
73
|
+
position_name: string;
|
|
74
|
+
marital_status_id: string;
|
|
75
|
+
marital_status_code: string;
|
|
76
|
+
marital_status_name: string;
|
|
77
|
+
document_type_id: string;
|
|
78
|
+
document_type_code: string;
|
|
79
|
+
document_type_name: string;
|
|
80
|
+
document_number: string;
|
|
81
|
+
names: string;
|
|
82
|
+
surnames: string;
|
|
83
|
+
address: string;
|
|
84
|
+
phone_code: string;
|
|
85
|
+
phone: string;
|
|
86
|
+
cellphone: string;
|
|
87
|
+
email: string[];
|
|
88
|
+
email_business: string[];
|
|
89
|
+
gender: string;
|
|
90
|
+
birthdate: number;
|
|
91
|
+
}
|
|
92
|
+
interface UpdateBody {
|
|
93
|
+
company_NIF: string;
|
|
94
|
+
company_trade_name: string;
|
|
95
|
+
company_business_name: string;
|
|
96
|
+
company_address: string;
|
|
97
|
+
company_email?: string;
|
|
98
|
+
company_logo: string;
|
|
99
|
+
department_id: string;
|
|
100
|
+
department_code: number;
|
|
101
|
+
department_name: string;
|
|
102
|
+
position_id: string;
|
|
103
|
+
position_code: number;
|
|
104
|
+
position_name: string;
|
|
105
|
+
marital_status_id: string;
|
|
106
|
+
marital_status_code: string;
|
|
107
|
+
marital_status_name: string;
|
|
108
|
+
document_type_id: string;
|
|
109
|
+
document_type_code: string;
|
|
110
|
+
document_type_name: string;
|
|
111
|
+
document_number: string;
|
|
112
|
+
names: string;
|
|
113
|
+
surnames: string;
|
|
114
|
+
address: string;
|
|
115
|
+
phone_code: string;
|
|
116
|
+
phone: string;
|
|
117
|
+
cellphone: string;
|
|
118
|
+
email: string[];
|
|
119
|
+
email_business: string[];
|
|
120
|
+
gender: string;
|
|
121
|
+
birthdate: number;
|
|
122
|
+
}
|
|
123
|
+
interface GetOneResponse {
|
|
124
|
+
success: boolean;
|
|
125
|
+
data: GetOneResponse.Data;
|
|
126
|
+
}
|
|
127
|
+
namespace GetOneResponse {
|
|
128
|
+
interface Data {
|
|
129
|
+
_id: string;
|
|
130
|
+
company_id: string;
|
|
131
|
+
company_NIF: string;
|
|
132
|
+
company_trade_name: string;
|
|
133
|
+
company_business_name: string;
|
|
134
|
+
company_address: string;
|
|
135
|
+
company_logo: string;
|
|
136
|
+
country_id: string;
|
|
137
|
+
country_code: string;
|
|
138
|
+
country_name: string;
|
|
139
|
+
country_short_name: string;
|
|
140
|
+
period_id: string;
|
|
141
|
+
period_year: string;
|
|
142
|
+
department_id: string;
|
|
143
|
+
department_code: number;
|
|
144
|
+
department_name: string;
|
|
145
|
+
position_id: string;
|
|
146
|
+
position_code: number;
|
|
147
|
+
position_name: string;
|
|
148
|
+
marital_status_id: string;
|
|
149
|
+
marital_status_code: string;
|
|
150
|
+
marital_status_name: string;
|
|
151
|
+
document_type_id: string;
|
|
152
|
+
document_type_code: string;
|
|
153
|
+
document_type_name: string;
|
|
154
|
+
sequence_number: number;
|
|
155
|
+
document_number: string;
|
|
156
|
+
names: string;
|
|
157
|
+
surnames: string;
|
|
158
|
+
address: string;
|
|
159
|
+
phone_code: string;
|
|
160
|
+
phone: string;
|
|
161
|
+
cellphone: string;
|
|
162
|
+
email: string[];
|
|
163
|
+
emails_company: string[];
|
|
164
|
+
gender: string;
|
|
165
|
+
birthdate: number;
|
|
166
|
+
enabled: boolean;
|
|
167
|
+
deleted: boolean;
|
|
168
|
+
user_id: string;
|
|
169
|
+
user_inactive_at: number;
|
|
170
|
+
disabled_reason: string;
|
|
171
|
+
user_inactive_name: string;
|
|
172
|
+
created_user: string;
|
|
173
|
+
created_at: number;
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
}
|
|
@@ -23,6 +23,12 @@ export declare namespace IGeneral {
|
|
|
23
23
|
NO_DATA_FOUND = "No se encontraron datos que coincidan con los criterios de b\u00FAsqueda proporcionados.",
|
|
24
24
|
WED_SOCKET_STOCK = "El stock de algunos art\u00EDculos ha sido actualizado debido a movimientos recientes en el almac\u00E9n."
|
|
25
25
|
}
|
|
26
|
+
enum STATUS {
|
|
27
|
+
INIT = "init",
|
|
28
|
+
LOADING = "loading",
|
|
29
|
+
SUCCESS = "success",
|
|
30
|
+
FAILED = "failed"
|
|
31
|
+
}
|
|
26
32
|
type Item_manage_by = 'none' | 'series' | 'batch';
|
|
27
33
|
}
|
|
28
34
|
export declare enum STATE {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CbmSalePriceModel } from './sale-price.domain.model';
|
|
2
2
|
export declare namespace CbmInvoiceModel {
|
|
3
|
-
type DetailType = 'item' | 'service' | 'kit' | 'outsourcing_service';
|
|
3
|
+
type DetailType = 'item' | 'service' | 'kit' | 'outsourcing_service' | 'fixed_assets';
|
|
4
4
|
enum EPaymentTerm {
|
|
5
5
|
CREDIT = "credit",
|
|
6
6
|
DEBIT = "debit"
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
export declare namespace CbmOutsourcingServicesMovementsModel {
|
|
2
|
+
interface GetMovementsParams {
|
|
3
|
+
page: number;
|
|
4
|
+
size: number;
|
|
5
|
+
enabled?: boolean;
|
|
6
|
+
collection_origin_id?: string;
|
|
7
|
+
user_id?: string;
|
|
8
|
+
company_branch_id?: string;
|
|
9
|
+
item_id: string;
|
|
10
|
+
date_end?: number;
|
|
11
|
+
date_begin?: number;
|
|
12
|
+
}
|
|
13
|
+
interface GetMovementsResponse {
|
|
14
|
+
success: boolean;
|
|
15
|
+
pageNum: number;
|
|
16
|
+
pageSize: number;
|
|
17
|
+
pages: number;
|
|
18
|
+
total: number;
|
|
19
|
+
items: GetMovementsResponse.Item[];
|
|
20
|
+
}
|
|
21
|
+
namespace GetMovementsResponse {
|
|
22
|
+
interface Item {
|
|
23
|
+
_id: string;
|
|
24
|
+
company_id: string;
|
|
25
|
+
company_branch_id: string;
|
|
26
|
+
user_id: string;
|
|
27
|
+
collection_origin_id: string;
|
|
28
|
+
collection_origin_name: string;
|
|
29
|
+
event_module: string;
|
|
30
|
+
header_data: Item.Header;
|
|
31
|
+
outsourcing_service_data: Item.Data;
|
|
32
|
+
enabled: boolean;
|
|
33
|
+
created_user: string;
|
|
34
|
+
created_at: number;
|
|
35
|
+
}
|
|
36
|
+
namespace Item {
|
|
37
|
+
interface Header {
|
|
38
|
+
authorization_number: string;
|
|
39
|
+
tax_support_code: string;
|
|
40
|
+
tax_support_id: string;
|
|
41
|
+
tax_support_name: string;
|
|
42
|
+
SRI_payment: string;
|
|
43
|
+
provider_id: string;
|
|
44
|
+
document_type_code: string;
|
|
45
|
+
document_type_id: string;
|
|
46
|
+
document_type_name: string;
|
|
47
|
+
document_emission_point_number: string;
|
|
48
|
+
document_branch_identification_number: string;
|
|
49
|
+
document_sequence: string;
|
|
50
|
+
deadline: number;
|
|
51
|
+
installment_number: number;
|
|
52
|
+
tax_base: number;
|
|
53
|
+
discount: number;
|
|
54
|
+
tax_base_iva: number;
|
|
55
|
+
tax_base_iva_rate_0: number;
|
|
56
|
+
tax_base_iva_exempt: number;
|
|
57
|
+
tax_base_iva_not_subject: number;
|
|
58
|
+
tax_base_irbpnr: number;
|
|
59
|
+
tax_base_ice: number;
|
|
60
|
+
rate_iva: number;
|
|
61
|
+
code_iva: string;
|
|
62
|
+
tax_iva: number;
|
|
63
|
+
tax_irbpnr: number;
|
|
64
|
+
tax_ice: number;
|
|
65
|
+
service: number;
|
|
66
|
+
total: number;
|
|
67
|
+
provider_document_number: string;
|
|
68
|
+
provider_trade_name: string;
|
|
69
|
+
provider_business_name: string;
|
|
70
|
+
provider_phone_code: string;
|
|
71
|
+
provider_address: string;
|
|
72
|
+
provider_category_name: string;
|
|
73
|
+
provider_document_code: string;
|
|
74
|
+
provider_cellphone: string;
|
|
75
|
+
provider_email: string[];
|
|
76
|
+
company_NIF: string;
|
|
77
|
+
company_address: string;
|
|
78
|
+
company_trade_name: string;
|
|
79
|
+
company_business_name: string;
|
|
80
|
+
company_required_accounting: boolean;
|
|
81
|
+
company_special_taxpayer: null;
|
|
82
|
+
company_branch_identification_number: string;
|
|
83
|
+
company_branch_trade_name: string;
|
|
84
|
+
company_branch_logo: string;
|
|
85
|
+
company_branch_address: string;
|
|
86
|
+
company_branch_email: string;
|
|
87
|
+
company_branch_cellphone: string;
|
|
88
|
+
company_branch_phone: string;
|
|
89
|
+
company_branch_artisan_qualification: null;
|
|
90
|
+
company_custom_comentary: string;
|
|
91
|
+
company_taxpayer_type: string;
|
|
92
|
+
commentary: string;
|
|
93
|
+
default_cost_center_id: string;
|
|
94
|
+
default_discount_rate: number;
|
|
95
|
+
company_id: string;
|
|
96
|
+
company_branch_id: string;
|
|
97
|
+
user_id: string;
|
|
98
|
+
created_user: string;
|
|
99
|
+
document_number: string;
|
|
100
|
+
document_nomenclature: string;
|
|
101
|
+
purchase_receipt_installment?: Header.Installment[];
|
|
102
|
+
}
|
|
103
|
+
namespace Header {
|
|
104
|
+
interface Installment {
|
|
105
|
+
installment: string;
|
|
106
|
+
credit: number;
|
|
107
|
+
expired_in: number;
|
|
108
|
+
date: number;
|
|
109
|
+
purchase_receipt_id: string;
|
|
110
|
+
created_user: string;
|
|
111
|
+
created_at: number;
|
|
112
|
+
credit_management_id: string;
|
|
113
|
+
debit: number;
|
|
114
|
+
retention: number;
|
|
115
|
+
credit_note: number;
|
|
116
|
+
return: number;
|
|
117
|
+
balance: number;
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
interface Data {
|
|
121
|
+
item_id: string;
|
|
122
|
+
category_id: string;
|
|
123
|
+
cost_center_id: string;
|
|
124
|
+
tax_iva_id: string;
|
|
125
|
+
tax_iva_code: string;
|
|
126
|
+
amount: number;
|
|
127
|
+
unit_cost: number;
|
|
128
|
+
total_cost: number;
|
|
129
|
+
discount_rate: number;
|
|
130
|
+
unit_discount: number;
|
|
131
|
+
total_discount: number;
|
|
132
|
+
commentary_item: null;
|
|
133
|
+
replace_item_name: null;
|
|
134
|
+
tax_iva_rate: number;
|
|
135
|
+
item_code: string;
|
|
136
|
+
item_barcode: string;
|
|
137
|
+
item_name: string;
|
|
138
|
+
item_manage_by: string;
|
|
139
|
+
category_name: string;
|
|
140
|
+
cost_center_code: string;
|
|
141
|
+
cost_center_name: string;
|
|
142
|
+
purchase_receipt_detail_tax: Data.Tax[];
|
|
143
|
+
type: string;
|
|
144
|
+
purchase_receipt_id: string;
|
|
145
|
+
created_user: string;
|
|
146
|
+
}
|
|
147
|
+
namespace Data {
|
|
148
|
+
interface Tax {
|
|
149
|
+
type: string;
|
|
150
|
+
tax_code: string;
|
|
151
|
+
tax_rate: number;
|
|
152
|
+
tax_base: number;
|
|
153
|
+
tax_value: number;
|
|
154
|
+
validation_id: string;
|
|
155
|
+
purchase_receipt_detail_id: string;
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
}
|
|
@@ -28,7 +28,8 @@ export declare namespace CbmSalePriceModel {
|
|
|
28
28
|
PRICE_LIST_SERVICE = "price_list_service",
|
|
29
29
|
PRICE_LIST_KIT = "price_list_kit",
|
|
30
30
|
PRICE_LIST_PERSONALIZED = "price_list_personalized",
|
|
31
|
-
PERIOD_DISCOUNT = "period_discount"
|
|
31
|
+
PERIOD_DISCOUNT = "period_discount",
|
|
32
|
+
DISCOUNT_GROUP_BY_RANK = "discount_group_by_rank"
|
|
32
33
|
}
|
|
33
34
|
type TName = `${EName}`;
|
|
34
35
|
interface GetParams {
|
|
@@ -62,6 +63,8 @@ export declare namespace CbmSalePriceModel {
|
|
|
62
63
|
collection_id: string;
|
|
63
64
|
sequence?: string;
|
|
64
65
|
amount_discount?: boolean;
|
|
66
|
+
min_percentage?: number;
|
|
67
|
+
max_percentage?: number;
|
|
65
68
|
details_amount_discount?: Data.AmountDiscount[];
|
|
66
69
|
}
|
|
67
70
|
namespace Data {
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { CbmOutsourcingServicesMovementsModel } from '../models/outsourcing-services-movements.domain.model';
|
|
2
|
+
import { ICbmOutsourcingServicesMovementsInfrastructureRepository } from '../../infrastructure/repositories/outsourcing-services-movements.infrastructure.repository';
|
|
3
|
+
export declare class CbmOutsourcingServicesMovementsDomainRepository {
|
|
4
|
+
private service;
|
|
5
|
+
constructor(service: ICbmOutsourcingServicesMovementsInfrastructureRepository);
|
|
6
|
+
getMovements(params: CbmOutsourcingServicesMovementsModel.GetMovementsParams): import("rxjs").Observable<CbmOutsourcingServicesMovementsModel.GetMovementsResponse>;
|
|
7
|
+
}
|
|
@@ -2,7 +2,7 @@ import { Observable } from 'rxjs';
|
|
|
2
2
|
import { ICbmSalesAccountRepository } from '../../infrastructure/repositories/sales-account.infrastructure.repository';
|
|
3
3
|
import { CbmSalesAccountModel } from '../models/sales-account.domain.model';
|
|
4
4
|
import { IGeneral } from '../models/general.domain.model';
|
|
5
|
-
export declare class
|
|
5
|
+
export declare class CbmSalesAccountDomainRepository {
|
|
6
6
|
private readonly service;
|
|
7
7
|
constructor(service: ICbmSalesAccountRepository);
|
|
8
8
|
list(params: CbmSalesAccountModel.ListParams): Observable<CbmSalesAccountModel.ListResponse>;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ValidatorFn } from '@angular/forms';
|
|
1
2
|
export declare class GeneralDomainService {
|
|
2
3
|
modalShow(modalId: string): void;
|
|
3
4
|
modalHide(modalId: string): void;
|
|
@@ -20,3 +21,5 @@ export declare function findRoute(eventModule: string, collectionName: string):
|
|
|
20
21
|
collection: string;
|
|
21
22
|
} | undefined;
|
|
22
23
|
};
|
|
24
|
+
export declare function noWhitespaceValidator(): ValidatorFn;
|
|
25
|
+
export declare function amountValidator(): ValidatorFn;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { DestroyRef } from '@angular/core';
|
|
2
|
+
import { FormControl, FormGroup } from '@angular/forms';
|
|
3
|
+
import { CbmClientModel } from '../models/client.domain.model';
|
|
4
|
+
import { CbmSellerModel } from '../models/seller.domain.model';
|
|
5
|
+
import { CbmUserModel } from '../models/user.domain.model';
|
|
6
|
+
import { CbmClientBranchModel } from '../models/client-branch.domain.model';
|
|
7
|
+
import { CbmCompanyBranchModel } from '../models/company-branch.domain.model';
|
|
8
|
+
import { FormGroupTracker } from './service/form-group-tracker.service';
|
|
9
|
+
export declare class SaleAccountDomainService {
|
|
10
|
+
private destroyRef;
|
|
11
|
+
constructor(destroyRef: DestroyRef);
|
|
12
|
+
formToFilter: FormGroup<{
|
|
13
|
+
date_begin: FormControl<string | null>;
|
|
14
|
+
date_end: FormControl<string | null>;
|
|
15
|
+
client: FormControl<CbmClientModel.ListResponse.Item | null>;
|
|
16
|
+
client_branch: FormControl<CbmClientBranchModel.ListResponse.Data | null>;
|
|
17
|
+
seller: FormControl<CbmSellerModel.ListResponse.Data | null>;
|
|
18
|
+
document_number: FormControl<string | null>;
|
|
19
|
+
enabled: FormControl<boolean | null>;
|
|
20
|
+
user: FormControl<CbmUserModel.ListResponse.Item | null>;
|
|
21
|
+
userRoleBranch: FormControl<CbmCompanyBranchModel.ListResponse.Data | null>;
|
|
22
|
+
}>;
|
|
23
|
+
formGroupTracker$: FormGroupTracker;
|
|
24
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { DestroyRef } from "@angular/core";
|
|
2
|
+
import { FormGroup } from "@angular/forms";
|
|
3
|
+
export declare class FormGroupTracker {
|
|
4
|
+
private readonly formGroup;
|
|
5
|
+
private readonly destroyRef;
|
|
6
|
+
constructor(formGroup: FormGroup, destroyRef: DestroyRef);
|
|
7
|
+
private cancel;
|
|
8
|
+
private compare;
|
|
9
|
+
change: import("@angular/core").WritableSignal<boolean>;
|
|
10
|
+
setComparisonValue(init: Record<string, unknown>): void;
|
|
11
|
+
onEmit(op: boolean): void;
|
|
12
|
+
private isEqual;
|
|
13
|
+
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { Observable } from 'rxjs';
|
|
2
|
+
import { CbmOutsourcingServicesMovementsModel } from '../../domain/models/outsourcing-services-movements.domain.model';
|
|
3
|
+
export interface ICbmOutsourcingServicesMovementsInfrastructureRepository {
|
|
4
|
+
getMovements(params: CbmOutsourcingServicesMovementsModel.GetMovementsParams): Observable<CbmOutsourcingServicesMovementsModel.GetMovementsResponse>;
|
|
5
|
+
}
|
package/lib/infrastructure/services/outsourcing-services-movements.infrastructure.service.d.ts
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { HttpClient } from '@angular/common/http';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { ICbmOutsourcingServicesMovementsInfrastructureRepository } from '../repositories/outsourcing-services-movements.infrastructure.repository';
|
|
4
|
+
import { CbmOutsourcingServicesMovementsModel } from '../../domain/models/outsourcing-services-movements.domain.model';
|
|
5
|
+
export declare class CbmOutsourcingServicesMovementsInfrastructureService implements ICbmOutsourcingServicesMovementsInfrastructureRepository {
|
|
6
|
+
private httpClient;
|
|
7
|
+
private readonly urlOutsourcingServicesMovements;
|
|
8
|
+
constructor(httpClient: HttpClient);
|
|
9
|
+
getMovements(params: CbmOutsourcingServicesMovementsModel.GetMovementsParams): Observable<CbmOutsourcingServicesMovementsModel.GetMovementsResponse>;
|
|
10
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const debounce: (fn: Function, delay: number) => (...args: any[]) => void;
|