@cbm-common/cbm-types 0.0.118 → 0.0.120

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.
@@ -1,4 +1,3 @@
1
- import { DecimalPipe } from '@angular/common';
2
1
  import { DestroyRef, OnInit } from '@angular/core';
3
2
  import { FormArray, FormGroup } from '@angular/forms';
4
3
  import { CbmClientModel, CbmCostCenterModel } from '@cbm-common/cbm-types';
@@ -6,20 +5,20 @@ import { CbmSalePriceModel } from '@cbm-common/cbm-types/lib/domain/models/sale-
6
5
  import { ListService, PaginatedListService } from '@cbm-common/data-access';
7
6
  import { Subject } from 'rxjs';
8
7
  import { CbmPriceListModel } from '../../domain/models/price-list.domain.model';
8
+ import { CbmUnitMeasureModel } from '../../domain/models/unit-measure.domain.model';
9
+ import { CbmCostCenterRepository } from '../../domain/repositories/cost-center.domain.repository';
9
10
  import { CbmItemDomainRepository } from '../../domain/repositories/item.domain.repository';
11
+ import { CbmSalePriceDomainRepository } from '../../domain/repositories/sale-price.domain.repository';
10
12
  import { CbmNotificationService } from '../../remotes/services.remote';
13
+ import { cbmStockWarehouseModalModel } from '../stock-by-warehouse/type';
11
14
  import { IItemDetails } from './item-details.types';
12
- import { CbmSalePriceDomainRepository } from '../../domain/repositories/sale-price.domain.repository';
13
- import { CbmCostCenterRepository } from '../../domain/repositories/cost-center.domain.repository';
14
- import { CbmUnitMeasureModel } from '../../domain/models/unit-measure.domain.model';
15
15
  export declare class ItemDetails implements OnInit {
16
16
  private readonly destroyRef;
17
17
  private readonly itemRepository;
18
18
  private readonly notificationService;
19
- private readonly decimalPipe;
20
19
  private readonly priceTypeRepository;
21
20
  private readonly costCenterRepository;
22
- constructor(destroyRef: DestroyRef, itemRepository: CbmItemDomainRepository, notificationService: CbmNotificationService, decimalPipe: DecimalPipe, priceTypeRepository: CbmSalePriceDomainRepository, costCenterRepository: CbmCostCenterRepository);
21
+ constructor(destroyRef: DestroyRef, itemRepository: CbmItemDomainRepository, notificationService: CbmNotificationService, priceTypeRepository: CbmSalePriceDomainRepository, costCenterRepository: CbmCostCenterRepository);
23
22
  'price-list': import("@angular/core").InputSignal<Partial<CbmPriceListModel.ListResponse.Data>>;
24
23
  'client-data': import("@angular/core").InputSignal<Partial<CbmClientModel.GetOneResponse.Data>>;
25
24
  'cost-center': import("@angular/core").InputSignal<Partial<CbmCostCenterModel.ListResponse.Data>>;
@@ -33,11 +32,15 @@ export declare class ItemDetails implements OnInit {
33
32
  clientData: import("@angular/core").Signal<Partial<CbmClientModel.GetOneResponse.Data>>;
34
33
  costCenterData: import("@angular/core").Signal<Partial<CbmCostCenterModel.ListResponse.Data>>;
35
34
  priceTypeOp: Map<string, CbmSalePriceModel.GetResponse.Data[]>;
36
- unitMeasureOp: Map<string, CbmUnitMeasureModel.ListResponse.DataWithFactor[]>;
35
+ unitMeasureOp: Map<string, Partial<CbmUnitMeasureModel.ListResponse.DataWithFactor>[]>;
36
+ itemConsulted: import("@angular/core").WritableSignal<cbmStockWarehouseModalModel.item | null>;
37
37
  ngOnInit(): void;
38
38
  getPriceType(params: CbmSalePriceModel.GetParams, control?: IItemDetails.FormGroupDetail['price_type']): Promise<void>;
39
39
  getUnitMeasure(control: IItemDetails.FormGroupDetail['item']): void;
40
40
  subObservers(): void;
41
41
  addNewRow(): void;
42
+ removeRow(index: number): void;
42
43
  resetItem(formGroup: FormGroup<IItemDetails.FormGroupDetail>): void;
44
+ getAllTaxes(): IItemDetails.Taxes[];
45
+ getRowTaxes(formGroup: FormGroup<IItemDetails.FormGroupDetail>): IItemDetails.Taxes[];
43
46
  }
@@ -17,4 +17,12 @@ export declare namespace IItemDetails {
17
17
  cost_center: FormControl<Partial<CbmCostCenterModel.ListResponse.Data> | null>;
18
18
  findItemByCode$: FormControl<FindItemCodeService | null>;
19
19
  }
20
+ interface Taxes {
21
+ type: string;
22
+ description: string;
23
+ tax_code: string;
24
+ tax_rate: number;
25
+ tax_base: number;
26
+ tax_value: number;
27
+ }
20
28
  }
@@ -3,27 +3,45 @@ import { FormControl, FormGroup } from '@angular/forms';
3
3
  import { PaginatedListService } from '@cbm-common/data-access';
4
4
  import { CbmRoomModel } from '../../domain/models/room.domain.model';
5
5
  import { CbmRoomRepository } from '../../domain/repositories/room.domain.repository';
6
+ import { ItemDetails } from '../item-details/item-details';
6
7
  import { FoliosModal } from './folios-modal/folios-modal';
7
8
  import { CbmSalesAccountModel } from '../../domain/models/sales-account.domain.model';
8
9
  import { CbmClientModel, CbmPriceListModel } from '@cbm-common/cbm-types';
9
10
  import { CbmCostCenterModel } from '../../domain/models/cost-center.domain.model';
11
+ import { STATE } from '../../domain/models/general.domain.model';
12
+ import { CbmChargeRepository } from '../../domain/repositories/charge.domain.repository';
13
+ import { CbmNotificationService } from '../../remotes/services.remote';
14
+ import { CbmSalesAccountRepository } from '../../domain/repositories/sales-account.domain.repository';
15
+ import { CbmAuthService } from '../../domain/services/auth/auth.service';
10
16
  export declare class CbmPmsAddCharge implements OnInit {
11
17
  private readonly destroyRef;
12
18
  private readonly roomRepository;
13
- constructor(destroyRef: DestroyRef, roomRepository: CbmRoomRepository);
19
+ private readonly chargeRepository;
20
+ private readonly notificationService;
21
+ private readonly authService;
22
+ private readonly salesAccountRepository;
23
+ constructor(destroyRef: DestroyRef, roomRepository: CbmRoomRepository, chargeRepository: CbmChargeRepository, notificationService: CbmNotificationService, authService: CbmAuthService, salesAccountRepository: CbmSalesAccountRepository);
14
24
  chargeFormGroup: FormGroup<{
15
25
  service_type: FormControl<number | null>;
16
26
  charge_type: FormControl<number | null>;
17
27
  room: FormControl<Partial<CbmRoomModel.RoomStateResponse.Items> | null>;
18
28
  }>;
19
29
  protected rooms$: PaginatedListService<CbmRoomModel.RoomStateResponse, CbmRoomModel.RoomStateParams, CbmRoomModel.RoomStateResponse.Items[]>;
20
- foliosRoomId: import("@angular/core").WritableSignal<string | null>;
21
- selectedFolio: import("@angular/core").WritableSignal<CbmSalesAccountModel.ListResponse.Item | null>;
22
- priceList: import("@angular/core").Signal<Partial<CbmPriceListModel.ListResponse.Data>>;
23
- client: import("@angular/core").Signal<Partial<CbmClientModel.GetOneResponse.Data>>;
24
- costCenter: import("@angular/core").Signal<Partial<CbmCostCenterModel.ListResponse.Data>>;
25
- foliosModalRef: import("@angular/core").Signal<FoliosModal>;
30
+ protected foliosRoomId: import("@angular/core").WritableSignal<string | null>;
31
+ protected selectedFolio: import("@angular/core").WritableSignal<CbmSalesAccountModel.GetOneResponse.Data<CbmSalesAccountModel.SalesAccountRelatedDocuments> | null>;
32
+ protected priceList: import("@angular/core").Signal<Partial<CbmPriceListModel.ListResponse.Data>>;
33
+ protected client: import("@angular/core").Signal<Partial<CbmClientModel.GetOneResponse.Data>>;
34
+ protected costCenter: import("@angular/core").Signal<Partial<CbmCostCenterModel.ListResponse.Data>>;
35
+ protected relatedDocument: import("@angular/core").Signal<CbmSalesAccountModel.SalesAccountRelatedDocuments | null>;
36
+ protected foliosModalRef: import("@angular/core").Signal<FoliosModal>;
37
+ protected itemDetailsComp: import("@angular/core").Signal<ItemDetails>;
38
+ 'on-charge-saved': import("@angular/core").OutputEmitterRef<void>;
39
+ 'on-cancel': import("@angular/core").OutputEmitterRef<void>;
40
+ protected STATE: typeof STATE;
41
+ protected stOfSaveCharge: import("@angular/core").WritableSignal<STATE>;
26
42
  ngOnInit(): void;
27
43
  private initRooms;
28
- subObservers(): void;
44
+ protected subObservers(): void;
45
+ saveCharge(): Promise<void>;
46
+ protected getFolio(folio: CbmSalesAccountModel.ListResponse.Item): Promise<void>;
29
47
  }
@@ -9,6 +9,7 @@ export declare class CbmRecordDetailMetadataComponent implements OnChanges, OnIn
9
9
  options: import("@angular/core").InputSignal<CbmRecordDetailMetadataModel.options[] | undefined>;
10
10
  optionsSignal: import("@angular/core").WritableSignal<CbmRecordDetailMetadataModel.options[]>;
11
11
  loadCss: import("@angular/core").WritableSignal<boolean>;
12
+ metadataComp: import("@angular/core").Signal<CbmRecordDetailMetadataModel.metadata | null>;
12
13
  ngOnInit(): void;
13
14
  ngOnChanges(changes: SimpleChanges): void;
14
15
  changeState(id: string, state: 'init' | 'loading' | 'success' | 'failed'): void;
@@ -1,9 +1,9 @@
1
1
  export declare namespace cbmStockWarehouseModalModel {
2
2
  interface item {
3
- code: string;
4
- name: string;
5
- _id: string;
6
- manage_by: string;
3
+ code?: string;
4
+ name?: string;
5
+ _id?: string;
6
+ manage_by?: string;
7
7
  }
8
8
  }
9
9
  export type status = 'init' | 'success' | 'failed' | 'loading';
@@ -0,0 +1,13 @@
1
+ import { StockByWarehouseModalCompModel } from './stock-by-warehouse-modal.model';
2
+ import { IGeneral } from '../../domain/models/general.domain.model';
3
+ import { GeneralDomainService } from '../../domain/services/general.domain.service';
4
+ export declare class StockByWarehouseModalComponent implements IGeneral.ModalRef {
5
+ private readonly generalService;
6
+ constructor(generalService: GeneralDomainService);
7
+ stOfModal: import("@angular/core").WritableSignal<"close" | "open">;
8
+ modalId: import("@angular/core").InputSignal<string>;
9
+ 'item-consulted': import("@angular/core").InputSignal<StockByWarehouseModalCompModel.ItemToConsulted | null>;
10
+ itemConsulted: import("@angular/core").Signal<StockByWarehouseModalCompModel.ItemToConsulted | null>;
11
+ closeModal: () => void;
12
+ openModal: () => void;
13
+ }
@@ -0,0 +1,4 @@
1
+ import { CbmItemModel } from '@cbm-common/cbm-types';
2
+ export declare namespace StockByWarehouseModalCompModel {
3
+ type ItemToConsulted = Partial<Pick<CbmItemModel.ListResponse.Item, '_id' | 'name' | 'code' | 'manage_by'>> | Partial<Pick<CbmItemModel.ListWithStockResponse.Item, '_id' | 'name' | 'code' | 'manage_by'>>;
4
+ }
@@ -0,0 +1,128 @@
1
+ export declare namespace CbmChargeModel {
2
+ interface Save {
3
+ collection_origin_id: string;
4
+ collection_origin_document_nomenclature_number: string;
5
+ company_NIF: string;
6
+ company_address: string;
7
+ company_trade_name: string;
8
+ company_business_name: string;
9
+ company_logo: string;
10
+ type_service: string;
11
+ type_charges: string;
12
+ num_vale: string;
13
+ num_command: string;
14
+ room_id: string;
15
+ room_name: string;
16
+ sales_account_id: string;
17
+ sales_account_document_nomenclature_number: string;
18
+ sales_account_document_type: string;
19
+ comment_check_in: string;
20
+ client_id: string;
21
+ client_business_name: string;
22
+ client_trade_name: string;
23
+ client_document_number: string;
24
+ client_credit_application: boolean;
25
+ client_document_type_id: string;
26
+ client_document_type_code: string;
27
+ client_document_type_name: string;
28
+ client_category_id: string;
29
+ client_category_name: string;
30
+ client_price_list_id: string;
31
+ client_price_list_code: string;
32
+ client_price_list_name: string;
33
+ client_branch_id: string;
34
+ client_branch_code: string;
35
+ client_branch_name: string;
36
+ client_branch_address: string;
37
+ client_branch_email: string[];
38
+ client_branch_phone_code: string;
39
+ client_branch_phone: string;
40
+ client_branch_cellphone: string;
41
+ client_branch_type_establishment: string;
42
+ client_branch_province_id?: string;
43
+ client_branch_province_code?: string;
44
+ client_branch_province_name?: string;
45
+ client_branch_canton_id?: string;
46
+ client_branch_canton_code?: string;
47
+ client_branch_canton_name?: string;
48
+ client_branch_parish_id?: string;
49
+ client_branch_parish_code?: string;
50
+ client_branch_parish_name?: string;
51
+ client_branch_longitude: number;
52
+ client_branch_latitude: number;
53
+ client_branch_seller_id: string;
54
+ client_branch_seller_identification_number: string;
55
+ client_branch_seller_full_name: string;
56
+ client_branch_seller_address: string;
57
+ client_branch_seller_email: string[];
58
+ client_branch_seller_cellphone: string;
59
+ client_branch_contact_id?: string;
60
+ client_branch_contact_identification_number?: string;
61
+ client_branch_contact_full_name?: string;
62
+ client_branch_contact_cellphone?: string;
63
+ client_branch_contact_email?: string[];
64
+ guest_id: string;
65
+ guest_document_type_id?: string;
66
+ guest_document_type_code?: string;
67
+ guest_document_type_name?: string;
68
+ guest_type?: string;
69
+ guest_document_number?: string;
70
+ guest_name: string;
71
+ guest_last_name?: string;
72
+ guest_code_phone?: string;
73
+ guest_cellphone?: string;
74
+ guest_nationality?: string;
75
+ guest_profession?: string;
76
+ guest_origin?: string;
77
+ guest_address?: string;
78
+ charges_detail: Save.ChargesDetail[];
79
+ }
80
+ namespace Save {
81
+ interface ChargesDetail {
82
+ item_id: string;
83
+ item_code: string;
84
+ item_barcode: string;
85
+ item_name: string;
86
+ category_id: string;
87
+ category_name: string;
88
+ price_list_id: string;
89
+ price_list_name: string;
90
+ cost_center_id: string;
91
+ cost_center_code: string;
92
+ cost_center_name: string;
93
+ cost_center_father_code: string;
94
+ cost_center_father_name: string;
95
+ tax_iva_id: string;
96
+ tax_iva_code: string;
97
+ tax_iva_rate: number;
98
+ unit_measure_id: string;
99
+ unit_measure_group_id: string;
100
+ unit_measure_abbreviation: string;
101
+ unit_measure_name: string;
102
+ unit_measure_group_name: string;
103
+ unit_measure_quantity: number;
104
+ amount: number;
105
+ price_type_id: string;
106
+ price_type: string;
107
+ price_type_description: string;
108
+ price_base: number;
109
+ total_price: number;
110
+ discount_rate: number;
111
+ unit_discount: number;
112
+ total_discount: number;
113
+ commentary_item: string;
114
+ replace_item_name: string;
115
+ charges_detail_tax: ChargesDetail.ChargesDetailTax[];
116
+ }
117
+ namespace ChargesDetail {
118
+ interface ChargesDetailTax {
119
+ type: string;
120
+ description: string;
121
+ tax_code: string;
122
+ tax_rate: number;
123
+ tax_base: number;
124
+ tax_value: number;
125
+ }
126
+ }
127
+ }
128
+ }
@@ -8,4 +8,23 @@ export declare namespace IGeneral {
8
8
  openModal(): void;
9
9
  closeModal(): void;
10
10
  }
11
+ enum USER_MESSAGE {
12
+ INVALID_FIELDS = "El formulario contiene campos inv\u00E1lidos o incompletos. Por favor, revise y complete los campos requeridos antes de continuar.",
13
+ ERROR_IN_LOADING = "Ocurri\u00F3 un error inesperado al intentar cargar la informaci\u00F3n. Por favor, int\u00E9ntelo nuevamente.",
14
+ CHANGE_STATUS_PLACEHOLDER_INACTIVE = "Ingrese el motivo para inactivar este registro.",
15
+ CONFIRMATION_QUESTION = "\u00BFEst\u00E1 seguro de que desea procesar la transacci\u00F3n?",
16
+ LOAD_DATA_SUCCESS = "Datos cargados exitosamente.",
17
+ ELEMENTS_RELATED_TO_REVERSING = "No es posible reversar este registro, ya que est\u00E1 vinculado a otros datos. Reversarlo podr\u00EDa generar inconsistencias en la informaci\u00F3n relacionada.",
18
+ ELEMENTS_RELATED_TO_ELIMINATING = "No es posible eliminar este registro, ya que est\u00E1 vinculado a otros datos. Eliminarlo podr\u00EDa generar inconsistencias en la informaci\u00F3n relacionada.",
19
+ ELEMENTS_RELATED_TO_EDITING = "No es posible editar este registro, ya que est\u00E1 vinculado a otros datos. Editarlo podr\u00EDa generar inconsistencias en la informaci\u00F3n relacionada.",
20
+ ELEMENTS_RELATED_TO_CHANGE_STATUS = "No es posible cambiar estado a este registro, ya que est\u00E1 vinculado a otros datos. Cambiarlo podr\u00EDa generar inconsistencias en la informaci\u00F3n relacionada.",
21
+ INTERNAL_ERROR = "Se ha producido un error inesperado al ejecutar la operaci\u00F3n. Por favor, int\u00E9ntalo nuevamente o contacta al soporte t\u00E9cnico.",
22
+ NO_DATA_FOUND = "No se encontraron datos que coincidan con los criterios de b\u00FAsqueda proporcionados."
23
+ }
24
+ }
25
+ export declare enum STATE {
26
+ INIT = "init",
27
+ LOADING = "loading",
28
+ SUCCESS = "success",
29
+ FAILED = "failed"
11
30
  }
@@ -1,7 +1,6 @@
1
1
  export declare namespace CbmSalesAccountModel {
2
- export type DetailType = 'item' | 'service' | 'kit' | 'outsourcing_service';
3
- type TTypeEstablishment = 'matrix' | 'branch';
4
- export interface ListParams {
2
+ type DetailType = 'item' | 'service' | 'kit' | 'outsourcing_service';
3
+ interface ListParams {
5
4
  page: number;
6
5
  size: number;
7
6
  balance_amount?: number;
@@ -17,7 +16,7 @@ export declare namespace CbmSalesAccountModel {
17
16
  check_in_id?: string;
18
17
  room_id?: string;
19
18
  }
20
- export interface ListResponse {
19
+ interface ListResponse {
21
20
  success: boolean;
22
21
  pageNum: number;
23
22
  pageSize: number;
@@ -25,7 +24,7 @@ export declare namespace CbmSalesAccountModel {
25
24
  total: number;
26
25
  items: ListResponse.Item[];
27
26
  }
28
- export namespace ListResponse {
27
+ namespace ListResponse {
29
28
  interface Item {
30
29
  _id: string;
31
30
  company_id: string;
@@ -131,12 +130,12 @@ export declare namespace CbmSalesAccountModel {
131
130
  client_branch_contact_email?: string[];
132
131
  }
133
132
  }
134
- export interface GetOneResponse {
133
+ interface GetOneResponse<T> {
135
134
  success: boolean;
136
- data: GetOneResponse.Data;
135
+ data: GetOneResponse.Data<T>;
137
136
  }
138
- export namespace GetOneResponse {
139
- interface Data {
137
+ namespace GetOneResponse {
138
+ interface Data<T> {
140
139
  _id: string;
141
140
  company_id: string;
142
141
  company_NIF: string;
@@ -157,9 +156,36 @@ export declare namespace CbmSalesAccountModel {
157
156
  country_short_name: string;
158
157
  period_id: string;
159
158
  period_year: string;
160
- default_price_list_id: string;
161
- default_price_list_name: string;
162
- default_price_list_type: string;
159
+ client_id: string;
160
+ client_business_name: string;
161
+ client_trade_name: string;
162
+ client_document_number: string;
163
+ client_credit_application: boolean;
164
+ client_document_type_id: string;
165
+ client_document_type_name: string;
166
+ client_document_type_code: string;
167
+ client_category_id: string;
168
+ client_category_name: string;
169
+ client_price_list_id: string;
170
+ client_price_list_name: string;
171
+ client_branch_id: string;
172
+ client_branch_code: string;
173
+ client_branch_name: string;
174
+ client_branch_address: string;
175
+ client_branch_email: string[];
176
+ client_branch_phone_code: string;
177
+ client_branch_phone: string;
178
+ client_branch_cellphone: string;
179
+ client_branch_type_establishment: string;
180
+ client_branch_longitude: number;
181
+ client_branch_latitude: number;
182
+ client_branch_seller_id: string;
183
+ client_branch_seller_identification_number: string;
184
+ client_branch_seller_full_name: string;
185
+ client_branch_seller_address: string;
186
+ client_branch_seller_email: any[];
187
+ client_branch_seller_cellphone: string;
188
+ client_branch_contact_email: any[];
163
189
  default_cost_center_id: string;
164
190
  default_cost_center_code: string;
165
191
  default_cost_center_name: string;
@@ -191,50 +217,7 @@ export declare namespace CbmSalesAccountModel {
191
217
  user_id: string;
192
218
  created_at: number;
193
219
  created_user: string;
194
- client_id: string;
195
- client_business_name: string;
196
- client_trade_name: string;
197
- client_document_number: string;
198
- client_credit_application: boolean;
199
- client_document_type_id: string;
200
- client_document_type_name: string;
201
- client_document_type_code: string;
202
- client_category_id: string;
203
- client_category_name: string;
204
- client_price_list_id?: string;
205
- client_price_list_code?: string;
206
- client_price_list_name?: string;
207
- client_branch_id: string;
208
- client_branch_code: string;
209
- client_branch_name: string;
210
- client_branch_address: string;
211
- client_branch_email: string[];
212
- client_branch_phone_code?: string;
213
- client_branch_phone?: string;
214
- client_branch_cellphone?: string;
215
- client_branch_type_establishment: `${TTypeEstablishment}`;
216
- client_branch_province_id?: string;
217
- client_branch_province_code?: string;
218
- client_branch_province_name?: string;
219
- client_branch_canton_id?: string;
220
- client_branch_canton_code?: string;
221
- client_branch_canton_name?: string;
222
- client_branch_parish_id?: string;
223
- client_branch_parish_code?: string;
224
- client_branch_parish_name?: string;
225
- client_branch_longitude?: number;
226
- client_branch_latitude?: number;
227
- client_branch_seller_id: string;
228
- client_branch_seller_identification_number: string;
229
- client_branch_seller_full_name: string;
230
- client_branch_seller_address: string;
231
- client_branch_seller_email?: string[];
232
- client_branch_seller_cellphone?: string;
233
- client_branch_contact_id?: string;
234
- client_branch_contact_identification_number?: string;
235
- client_branch_contact_full_name?: string;
236
- client_branch_contact_cellphone?: string;
237
- client_branch_contact_email?: string[];
220
+ sales_account_related_documents: T;
238
221
  sales_account_detail?: Data.Detail[];
239
222
  }
240
223
  namespace Data {
@@ -341,7 +324,29 @@ export declare namespace CbmSalesAccountModel {
341
324
  }
342
325
  }
343
326
  }
344
- export interface Save {
327
+ interface SalesAccountRelatedDocuments {
328
+ _id: string;
329
+ company_id: string;
330
+ country_id: string;
331
+ collection_origin_id: string;
332
+ collection_origin_name: string;
333
+ collection_origin_document_nomenclature_number: string;
334
+ event_module_origin: string;
335
+ sales_account_id: string;
336
+ room_id: string;
337
+ room_name: string;
338
+ guest_id: string;
339
+ guest_document_type_id: string;
340
+ guest_document_type_code: string;
341
+ guest_document_type_name: string;
342
+ guest_name: string;
343
+ guest_last_name: string;
344
+ enabled: boolean;
345
+ user_id: string;
346
+ created_at: number;
347
+ created_user: string;
348
+ }
349
+ interface Save {
345
350
  company_NIF: string;
346
351
  company_address: string;
347
352
  company_trade_name: string;
@@ -440,5 +445,4 @@ export declare namespace CbmSalesAccountModel {
440
445
  guest_last_name: string;
441
446
  sales_account_detail: [];
442
447
  }
443
- export {};
444
448
  }
@@ -0,0 +1,9 @@
1
+ import { ICbmChargeRepository } from "../../infrastructure/repositories/charge.infrastructure.repository";
2
+ import { Observable } from "rxjs";
3
+ import { CbmChargeModel } from "../models/charge.domain.model";
4
+ import { IGeneral } from "../models/general.domain.model";
5
+ export declare class CbmChargeRepository implements ICbmChargeRepository {
6
+ private readonly chargeService;
7
+ constructor(chargeService: ICbmChargeRepository);
8
+ save(request: CbmChargeModel.Save): Observable<IGeneral.Confirm>;
9
+ }
@@ -6,6 +6,6 @@ export declare class CbmSalesAccountRepository {
6
6
  private readonly service;
7
7
  constructor(service: ICbmSalesAccountRepository);
8
8
  list(params: CbmSalesAccountModel.ListParams): Observable<CbmSalesAccountModel.ListResponse>;
9
- getOne(id: string): Observable<CbmSalesAccountModel.GetOneResponse>;
9
+ getOne<T>(id: string): Observable<CbmSalesAccountModel.GetOneResponse<T>>;
10
10
  save(data: CbmSalesAccountModel.Save): Observable<IGeneral.Confirm>;
11
11
  }
@@ -0,0 +1,6 @@
1
+ import { Observable } from "rxjs";
2
+ import { CbmChargeModel } from "../../domain/models/charge.domain.model";
3
+ import { IGeneral } from "../../domain/models/general.domain.model";
4
+ export interface ICbmChargeRepository {
5
+ save(request: CbmChargeModel.Save): Observable<IGeneral.Confirm>;
6
+ }
@@ -3,6 +3,6 @@ import { CbmSalesAccountModel } from '../../domain/models/sales-account.domain.m
3
3
  import { IGeneral } from '../../domain/models/general.domain.model';
4
4
  export interface ICbmSalesAccountRepository {
5
5
  list(params: CbmSalesAccountModel.ListParams): Observable<CbmSalesAccountModel.ListResponse>;
6
- getOne(id: string): Observable<CbmSalesAccountModel.GetOneResponse>;
6
+ getOne<T>(id: string): Observable<CbmSalesAccountModel.GetOneResponse<T>>;
7
7
  save(data: CbmSalesAccountModel.Save): Observable<IGeneral.Confirm>;
8
8
  }
@@ -0,0 +1,11 @@
1
+ import { HttpClient } from "@angular/common/http";
2
+ import { ICbmChargeRepository } from "../repositories/charge.infrastructure.repository";
3
+ import { Observable } from "rxjs";
4
+ import { CbmChargeModel } from "../../domain/models/charge.domain.model";
5
+ import { IGeneral } from "../../domain/models/general.domain.model";
6
+ export declare class CbmChargeService implements ICbmChargeRepository {
7
+ private readonly http;
8
+ constructor(http: HttpClient);
9
+ private readonly url;
10
+ save(request: CbmChargeModel.Save): Observable<IGeneral.Confirm>;
11
+ }
@@ -8,6 +8,6 @@ export declare class CbmSalesAccountService implements ICbmSalesAccountRepositor
8
8
  constructor(http: HttpClient);
9
9
  private readonly baseUrl;
10
10
  list(params: CbmSalesAccountModel.ListParams): Observable<CbmSalesAccountModel.ListResponse>;
11
- getOne(id: string): Observable<CbmSalesAccountModel.GetOneResponse>;
11
+ getOne<T>(id: string): Observable<CbmSalesAccountModel.GetOneResponse<T>>;
12
12
  save(data: CbmSalesAccountModel.Save): Observable<IGeneral.Confirm>;
13
13
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cbm-common/cbm-types",
3
- "version": "0.0.118",
3
+ "version": "0.0.120",
4
4
  "main": "index.js",
5
5
  "types": "public-api.d.ts",
6
6
  "exports": {
package/public-api.d.ts CHANGED
@@ -469,4 +469,7 @@ export * from './lib/domain/repositories/down-payment.domain.repository';
469
469
  export * from './lib/domain/models/down-payment.domain.model';
470
470
 
471
471
  //#region global state service
472
- export * from './lib/domain/services/global-state.domain.service';
472
+ export * from './lib/domain/services/global-state.domain.service';
473
+
474
+ //#region pms add charge component
475
+ export * from './lib/components/pms-add-charge/pms-add-charge';
@@ -1,3 +0,0 @@
1
- import { Router } from "@angular/router";
2
- import { CbmAuthService } from "../../domain/services/auth/auth.service";
3
- export declare function authFactory(router: Router): CbmAuthService;
@@ -1,4 +0,0 @@
1
- import { ApplicationRef } from "@angular/core";
2
- import { Router } from "@angular/router";
3
- import { CbmWebSocketService } from "../../domain/services/web-socket/web-socket.service";
4
- export declare function webSocketFactory(appRef: ApplicationRef, router: Router): CbmWebSocketService;
@@ -1,3 +0,0 @@
1
- export * from "../domain/services/notification/notification.service";
2
- export * from "./services/auth.service";
3
- export * from "./services/web-socket.service";