@cbm-common/cbm-types 0.0.276 → 0.0.278
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/detail-by-section/detail-by-section.d.ts +75 -0
- package/lib/components/detail-by-section/detail-by-section.model.d.ts +30 -0
- package/lib/components/pms-add-charge/pms-add-charge.d.ts +1 -1
- package/lib/domain/models/charge.domain.model.d.ts +1 -1
- package/lib/domain/models/sales-pending-document.domain.model.d.ts +2 -1
- package/package.json +2 -2
- package/public-api.d.ts +8 -0
- package/lib/components/accounting-seat/directives/drop-down-menu.directive.d.ts +0 -13
- package/lib/components/accounting-seat/directives/drop-down.directive.d.ts +0 -10
- package/lib/components/record-detail-metadata/components/options/options.d.ts +0 -13
- package/lib/components/record-detail-metadata/directives/drop-down-menu.directive.d.ts +0 -13
- package/lib/components/record-detail-metadata/directives/drop-down.directive.d.ts +0 -9
- package/lib/infrastructure/repositories/blanket-agreement-category-service..infrastructure.repository.d.ts +0 -7
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import { CdkDragDrop } from '@angular/cdk/drag-drop';
|
|
2
|
+
import { DestroyRef } from '@angular/core';
|
|
3
|
+
import { FormControl } from '@angular/forms';
|
|
4
|
+
import { CbmDetailBySectionModel } from './detail-by-section.model';
|
|
5
|
+
type TDetailCategory = 'all' | 'item' | 'service' | 'subcontracted';
|
|
6
|
+
declare class DetailSectionControl {
|
|
7
|
+
readonly id: `${string}-${string}-${string}-${string}-${string}`;
|
|
8
|
+
readonly defaultTitle: string;
|
|
9
|
+
constructor(title: string);
|
|
10
|
+
title: import("@angular/core").WritableSignal<string>;
|
|
11
|
+
items: import("@angular/core").WritableSignal<CbmDetailBySectionModel.SectionDetail[]>;
|
|
12
|
+
isDetailHidden: import("@angular/core").WritableSignal<boolean>;
|
|
13
|
+
itemsCount: import("@angular/core").Signal<number>;
|
|
14
|
+
subtotal: import("@angular/core").Signal<number>;
|
|
15
|
+
hasItems: import("@angular/core").Signal<boolean>;
|
|
16
|
+
summaryMessage: import("@angular/core").Signal<string>;
|
|
17
|
+
addItems(details: Array<CbmDetailBySectionModel.SectionDetail>): void;
|
|
18
|
+
replaceItems(details: Array<CbmDetailBySectionModel.SectionDetail>): void;
|
|
19
|
+
removeItem(detailKey: string): boolean;
|
|
20
|
+
resetTitleIfEmpty(value: string): void;
|
|
21
|
+
toggleDetailVisibility(): void;
|
|
22
|
+
}
|
|
23
|
+
export declare class CbmDetailBySectionComponent {
|
|
24
|
+
private readonly destroyRef;
|
|
25
|
+
EType: typeof CbmDetailBySectionModel.Type;
|
|
26
|
+
constructor(destroyRef: DestroyRef);
|
|
27
|
+
labels: import("@angular/core").WritableSignal<{
|
|
28
|
+
labelDetail: string;
|
|
29
|
+
labelSection: string;
|
|
30
|
+
}>;
|
|
31
|
+
sectionsChange: import("@angular/core").OutputEmitterRef<CbmDetailBySectionModel.SectionSnapshot[]>;
|
|
32
|
+
searchItemsControl: FormControl<string>;
|
|
33
|
+
detailCategory: import("@angular/core").WritableSignal<{
|
|
34
|
+
all: boolean;
|
|
35
|
+
item: boolean;
|
|
36
|
+
service: boolean;
|
|
37
|
+
subcontracted: boolean;
|
|
38
|
+
}>;
|
|
39
|
+
selectedCategory: import("@angular/core").WritableSignal<TDetailCategory>;
|
|
40
|
+
detail: import("@angular/core").WritableSignal<CbmDetailBySectionModel.SectionDetail[]>;
|
|
41
|
+
sectionsDetail: import("@angular/core").WritableSignal<DetailSectionControl[]>;
|
|
42
|
+
editingSectionIndex: import("@angular/core").WritableSignal<number | null>;
|
|
43
|
+
nextSectionNumber: import("@angular/core").WritableSignal<number>;
|
|
44
|
+
visibleDetail: import("@angular/core").Signal<CbmDetailBySectionModel.SectionDetail[]>;
|
|
45
|
+
detailSectionAssignments: import("@angular/core").Signal<Map<string, string[]>>;
|
|
46
|
+
dropListIds: import("@angular/core").Signal<string[]>;
|
|
47
|
+
allSectionsConsolidated: import("@angular/core").Signal<boolean>;
|
|
48
|
+
setLabels(labels: Partial<ReturnType<typeof this.labels>>): void;
|
|
49
|
+
setDetail(input: Array<CbmDetailBySectionModel.InputDetail>): void;
|
|
50
|
+
reset(): void;
|
|
51
|
+
searchTerm(term: string): void;
|
|
52
|
+
createSection(): void;
|
|
53
|
+
distributeSections(): void;
|
|
54
|
+
startEditSectionTitle(index: number): void;
|
|
55
|
+
saveSectionTitle(index: number, value: string): void;
|
|
56
|
+
removeSection(index: number): void;
|
|
57
|
+
removeItemFromSection(sectionId: string, detailKey: string, event?: Event): void;
|
|
58
|
+
addItemsByTypeToSection(sectionIndex: number, type: CbmDetailBySectionModel.Type): void;
|
|
59
|
+
toggleSectionDetailVisibility(sectionIndex: number): void;
|
|
60
|
+
toggleAllSectionsDetailVisibility(): void;
|
|
61
|
+
isDetailAssigned(detailKey: string): boolean;
|
|
62
|
+
getDetailAssignedSections(detailKey: string): string[];
|
|
63
|
+
onDropToSection(event: CdkDragDrop<Array<CbmDetailBySectionModel.SectionDetail>>, targetSectionIndex: number): void;
|
|
64
|
+
getSectionDropListId(id: string): string;
|
|
65
|
+
getSectionsSnapshot(): Array<CbmDetailBySectionModel.SectionSnapshot>;
|
|
66
|
+
getDetailAmount(detail: Pick<CbmDetailBySectionModel.SectionDetail, 'amount'>): number;
|
|
67
|
+
getDetailTotal(detail: Pick<CbmDetailBySectionModel.SectionDetail, 'total' | 'total_price'>): number;
|
|
68
|
+
private getDistributionSectionDefinitions;
|
|
69
|
+
private getSourceDetails;
|
|
70
|
+
private getAvailableDetailsByType;
|
|
71
|
+
private getSourceDetailsByType;
|
|
72
|
+
private loadCategory;
|
|
73
|
+
private getDetailKey;
|
|
74
|
+
}
|
|
75
|
+
export {};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
export declare namespace CbmDetailBySectionModel {
|
|
2
|
+
enum Type {
|
|
3
|
+
ITEM = "item",
|
|
4
|
+
SERVICE = "service",
|
|
5
|
+
SUBCONTRACTED = "subcontracted"
|
|
6
|
+
}
|
|
7
|
+
interface InputDetail {
|
|
8
|
+
_id?: string;
|
|
9
|
+
item_id: string;
|
|
10
|
+
item_code: string;
|
|
11
|
+
item_name: string;
|
|
12
|
+
amount: number;
|
|
13
|
+
total: number;
|
|
14
|
+
type: Type;
|
|
15
|
+
visible: boolean;
|
|
16
|
+
item_barcode?: string;
|
|
17
|
+
total_price?: number;
|
|
18
|
+
unit_measure_name?: string;
|
|
19
|
+
}
|
|
20
|
+
interface SectionDetail extends InputDetail {
|
|
21
|
+
key: string;
|
|
22
|
+
}
|
|
23
|
+
interface SectionSnapshot {
|
|
24
|
+
id: string;
|
|
25
|
+
title: string;
|
|
26
|
+
isDetailHidden: boolean;
|
|
27
|
+
subtotal: number;
|
|
28
|
+
items: Array<SectionDetail>;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
@@ -50,7 +50,7 @@ export declare class CbmPmsAddCharge implements OnInit {
|
|
|
50
50
|
room: FormControl<Partial<CbmRoomModel.RoomStateResponse.Items> | null>;
|
|
51
51
|
cost_center: FormControl<Partial<CbmCostCenterModel.ListResponse.Data> | null>;
|
|
52
52
|
order: FormControl<string>;
|
|
53
|
-
|
|
53
|
+
pax: FormControl<number | null>;
|
|
54
54
|
}>;
|
|
55
55
|
protected rooms$: PaginatedListService<CbmRoomModel.RoomStateResponse, CbmRoomModel.RoomStateParams, CbmRoomModel.RoomStateResponse.Items[]>;
|
|
56
56
|
protected costCenter$: ListService<CbmCostCenterModel.ListResponse, CbmCostCenterModel.ListParams, CbmCostCenterModel.ListResponse.Data[]>;
|
|
@@ -24,8 +24,10 @@ export declare namespace CbmSalesPendingDocumentModel {
|
|
|
24
24
|
_id: string;
|
|
25
25
|
created_at: number;
|
|
26
26
|
document_nomenclature: string;
|
|
27
|
+
document_number: string;
|
|
27
28
|
document_emission_point_number: string;
|
|
28
29
|
document_sequence: string;
|
|
30
|
+
new_document_number: string;
|
|
29
31
|
balance: number;
|
|
30
32
|
client_id: string;
|
|
31
33
|
client_payment_deadline?: number;
|
|
@@ -73,7 +75,6 @@ export declare namespace CbmSalesPendingDocumentModel {
|
|
|
73
75
|
client_branch_contact_full_name?: string;
|
|
74
76
|
client_branch_contact_cellphone?: string;
|
|
75
77
|
client_branch_contact_email?: string[];
|
|
76
|
-
new_document_number: string;
|
|
77
78
|
date: number;
|
|
78
79
|
type: string;
|
|
79
80
|
checked?: boolean;
|
package/package.json
CHANGED
package/public-api.d.ts
CHANGED
|
@@ -587,3 +587,11 @@ export * from './lib/domain/models/charge-type.domain.model';
|
|
|
587
587
|
//#region type Of Service domain repository
|
|
588
588
|
export * from './lib/domain/repositories/type-of-service.domain.repository';
|
|
589
589
|
export * from './lib/domain/models/type-of-service.domain.model';
|
|
590
|
+
|
|
591
|
+
//#region type Of detail by section
|
|
592
|
+
export * from './lib/components/detail-by-section/detail-by-section';
|
|
593
|
+
export * from './lib/components/detail-by-section/detail-by-section.model';
|
|
594
|
+
|
|
595
|
+
|
|
596
|
+
//#region type Of SRefheshschedule service
|
|
597
|
+
export * from './lib/domain/services/refresch-schedules.domain.service';
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { AfterViewInit, ElementRef, OnChanges, Renderer2, SimpleChanges } from '@angular/core';
|
|
2
|
-
export declare class DropdownMenuDirective implements OnChanges, AfterViewInit {
|
|
3
|
-
private element;
|
|
4
|
-
private renderer2;
|
|
5
|
-
hiddenMenu: import("@angular/core").InputSignal<boolean>;
|
|
6
|
-
hiddenMenuOp: import("@angular/core").WritableSignal<boolean>;
|
|
7
|
-
constructor(element: ElementRef, renderer2: Renderer2);
|
|
8
|
-
ngAfterViewInit(): void;
|
|
9
|
-
ngOnChanges(changes: SimpleChanges): void;
|
|
10
|
-
toggle(event: Event): void;
|
|
11
|
-
private toggleMenu;
|
|
12
|
-
initStyle(): void;
|
|
13
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { AfterViewInit, ElementRef, Renderer2 } from '@angular/core';
|
|
2
|
-
export declare class DropdownDirective implements AfterViewInit {
|
|
3
|
-
private elementRef;
|
|
4
|
-
private renderer;
|
|
5
|
-
private isOpen;
|
|
6
|
-
constructor(elementRef: ElementRef, renderer: Renderer2);
|
|
7
|
-
ngAfterViewInit(): void;
|
|
8
|
-
toggleDropdown(event: MouseEvent): void;
|
|
9
|
-
closeDropdown(event: MouseEvent): void;
|
|
10
|
-
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { WritableSignal } from '@angular/core';
|
|
2
|
-
import { Router, ActivatedRoute, Params } from '@angular/router';
|
|
3
|
-
import { CbmRecordDetailMetadataModel } from "../../types";
|
|
4
|
-
export declare class OptionsComponent {
|
|
5
|
-
private router;
|
|
6
|
-
private route;
|
|
7
|
-
constructor(router: Router, route: ActivatedRoute);
|
|
8
|
-
metadata: import("@angular/core").InputSignal<CbmRecordDetailMetadataModel.metadata | null>;
|
|
9
|
-
options: import("@angular/core").InputSignal<CbmRecordDetailMetadataModel.options[] | undefined>;
|
|
10
|
-
optionInSignals: WritableSignal<WritableSignal<CbmRecordDetailMetadataModel.options>[]>;
|
|
11
|
-
executeFunction(option: WritableSignal<CbmRecordDetailMetadataModel.options>): void;
|
|
12
|
-
navigate(routerLink?: string, queryParams?: Params): void;
|
|
13
|
-
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { AfterViewInit, ElementRef, OnChanges, Renderer2, SimpleChanges } from '@angular/core';
|
|
2
|
-
export declare class DropdownMenuDirective implements OnChanges, AfterViewInit {
|
|
3
|
-
private element;
|
|
4
|
-
private renderer2;
|
|
5
|
-
hiddenMenu: import("@angular/core").InputSignal<boolean>;
|
|
6
|
-
hiddenMenuOp: import("@angular/core").WritableSignal<boolean>;
|
|
7
|
-
constructor(element: ElementRef, renderer2: Renderer2);
|
|
8
|
-
ngAfterViewInit(): void;
|
|
9
|
-
ngOnChanges(changes: SimpleChanges): void;
|
|
10
|
-
toggle(event: Event): void;
|
|
11
|
-
private toggleMenu;
|
|
12
|
-
initStyle(): void;
|
|
13
|
-
}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { ElementRef, Renderer2 } from '@angular/core';
|
|
2
|
-
export declare class DropdownDirective {
|
|
3
|
-
private elementRef;
|
|
4
|
-
private renderer;
|
|
5
|
-
private isOpen;
|
|
6
|
-
constructor(elementRef: ElementRef, renderer: Renderer2);
|
|
7
|
-
toggleDropdown(event: MouseEvent): void;
|
|
8
|
-
closeDropdown(event: MouseEvent): void;
|
|
9
|
-
}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { Observable } from "rxjs";
|
|
2
|
-
import { CbmBlanketAgreementCategoryServiceModel } from "../../domain/models/blanket-agreement-category-service.domain.model";
|
|
3
|
-
export interface ICbmBlanketAgreementCategoryServiceRepository {
|
|
4
|
-
list(params: CbmBlanketAgreementCategoryServiceModel.ListParams): Observable<CbmBlanketAgreementCategoryServiceModel.ListResponse>;
|
|
5
|
-
save(data: CbmBlanketAgreementCategoryServiceModel.SaveBody): Observable<CbmBlanketAgreementCategoryServiceModel.ConfirmResponse>;
|
|
6
|
-
delete(id: string): Observable<CbmBlanketAgreementCategoryServiceModel.ConfirmResponse>;
|
|
7
|
-
}
|