@unifylib/ui-lib 1.0.3 → 1.1.4
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/esm2022/iq-ui-lib.mjs +5 -0
- package/esm2022/lib/base-model/SearchStrConfig.mjs +11 -0
- package/esm2022/lib/base-model/api-response.mjs +2 -0
- package/esm2022/lib/base-model/audit-log-entry.mjs +3 -0
- package/esm2022/lib/base-model/button-action-settings.mjs +16 -0
- package/esm2022/lib/base-model/column-def.model.mjs +28 -0
- package/esm2022/lib/base-model/do-action-request.mjs +8 -0
- package/esm2022/lib/base-model/field-action.mjs +6 -0
- package/esm2022/lib/base-model/field-filter.model.mjs +3 -0
- package/esm2022/lib/base-model/field-info.mjs +57 -0
- package/esm2022/lib/base-model/field-predicate.model.mjs +10 -0
- package/esm2022/lib/base-model/filter-request.mjs +13 -0
- package/esm2022/lib/base-model/filter.model.mjs +25 -0
- package/esm2022/lib/base-model/get-items-list.mjs +10 -0
- package/esm2022/lib/base-model/index.mjs +12 -0
- package/esm2022/lib/base-model/items-total.model.mjs +8 -0
- package/esm2022/lib/base-model/line-item.model.mjs +11 -0
- package/esm2022/lib/base-model/lookupItem.mjs +16 -0
- package/esm2022/lib/base-model/page-info.mjs +17 -0
- package/esm2022/lib/base-model/report-request.model.mjs +17 -0
- package/esm2022/lib/base-model/response-envelop.model.mjs +10 -0
- package/esm2022/lib/base-model/snack-message.model.mjs +11 -0
- package/esm2022/lib/base-model/table-column.interface.mjs +2 -0
- package/esm2022/lib/base-model/table-page-user-action.interface.mjs +21 -0
- package/esm2022/lib/base-model/workflow/workflow-steps.model.mjs +9 -0
- package/esm2022/lib/base-model/workflow/workflow.model.mjs +42 -0
- package/esm2022/lib/components/action-comment/action-comment.component.mjs +101 -0
- package/esm2022/lib/components/action-confirmation/action-confirmation.component.mjs +55 -0
- package/esm2022/lib/components/activity-report-form/activity-report-form.component.mjs +499 -0
- package/esm2022/lib/components/advanced-filter/field-filter/field-filter.component.mjs +41 -0
- package/esm2022/lib/components/advanced-filter/filter-builder/filter-builder.component.mjs +162 -0
- package/esm2022/lib/components/audit-log-details-dialog/audit-log-details-dialog.component.mjs +70 -0
- package/esm2022/lib/components/audit-log-list/audit-log.component.mjs +99 -0
- package/esm2022/lib/components/auto-complete/auto-complete.component.mjs +292 -0
- package/esm2022/lib/components/base-form/base-form.component.mjs +297 -0
- package/esm2022/lib/components/base-form-canvas/base-form-canvas.component.mjs +591 -0
- package/esm2022/lib/components/base-input-dialog/base-input-dialog.component.mjs +72 -0
- package/esm2022/lib/components/base-table/base-table.component.mjs +514 -0
- package/esm2022/lib/components/button-actions/button-actions.component.mjs +70 -0
- package/esm2022/lib/components/editable-base-table/editable-base-table.component.mjs +496 -0
- package/esm2022/lib/components/equation-builder/equation-builder.component.mjs +112 -0
- package/esm2022/lib/components/item-line-editor/item-line-editor.component.mjs +299 -0
- package/esm2022/lib/components/multi-auto-complete/multi-auto-complete.component.mjs +278 -0
- package/esm2022/lib/components/paginator/paginator.component.mjs +91 -0
- package/esm2022/lib/components/report-details-dialog/report-details-dialog.component.mjs +102 -0
- package/esm2022/lib/components/report-form/report-form.component.mjs +498 -0
- package/esm2022/lib/components/search-bar/search-bar.component.mjs +62 -0
- package/esm2022/lib/components/section-form-canvas/section-form-canvas.component.mjs +81 -0
- package/esm2022/lib/components/shared/action-button/action-button.component.mjs +59 -0
- package/esm2022/lib/components/shared/action-card/action-card.component.mjs +93 -0
- package/esm2022/lib/components/shared/attachment-uploader/attachment-uploader.component.mjs +70 -0
- package/esm2022/lib/components/shared-list/shared-list.component.mjs +47 -0
- package/esm2022/lib/components/snackbar-static/snackbar-static.component.mjs +43 -0
- package/esm2022/lib/components/title-bar/title-bar.component.mjs +119 -0
- package/esm2022/lib/services/backend-service.mjs +240 -0
- package/esm2022/lib/services/index.mjs +4 -0
- package/esm2022/lib/services/top-panel.mjs +22 -0
- package/esm2022/lib/services/trigger-form.service.mjs +17 -0
- package/esm2022/lib/utils/base-utils.mjs +97 -0
- package/esm2022/lib/validators/date-range-validator.mjs +27 -0
- package/esm2022/lib/validators/index.mjs +4 -0
- package/esm2022/lib/validators/match-list.validator.mjs +9 -0
- package/esm2022/lib/validators/multi-email-validator.mjs +13 -0
- package/esm2022/public-api.mjs +29 -0
- package/esm2022/q-btech-ui-lib.mjs +5 -0
- package/esm2022/unifylib-ui-lib.mjs +5 -0
- package/fesm2022/iq-ui-lib.mjs +5625 -0
- package/fesm2022/iq-ui-lib.mjs.map +1 -0
- package/fesm2022/q-btech-ui-lib.mjs +5619 -0
- package/fesm2022/q-btech-ui-lib.mjs.map +1 -0
- package/fesm2022/unifylib-ui-lib.mjs +5625 -0
- package/fesm2022/unifylib-ui-lib.mjs.map +1 -0
- package/index.d.ts +5 -0
- package/lib/base-model/SearchStrConfig.d.ts +8 -0
- package/{src/lib/base-model/api-response.ts → lib/base-model/api-response.d.ts} +5 -7
- package/lib/base-model/audit-log-entry.d.ts +7 -0
- package/lib/base-model/button-action-settings.d.ts +15 -0
- package/lib/base-model/column-def.model.d.ts +11 -0
- package/lib/base-model/do-action-request.d.ts +10 -0
- package/lib/base-model/field-action.d.ts +6 -0
- package/lib/base-model/field-filter.model.d.ts +7 -0
- package/lib/base-model/field-info.d.ts +53 -0
- package/lib/base-model/field-predicate.model.d.ts +7 -0
- package/lib/base-model/filter-request.d.ts +15 -0
- package/lib/base-model/filter.model.d.ts +22 -0
- package/lib/base-model/get-items-list.d.ts +21 -0
- package/lib/base-model/index.d.ts +11 -0
- package/lib/base-model/items-total.model.d.ts +6 -0
- package/lib/base-model/line-item.model.d.ts +9 -0
- package/lib/base-model/lookupItem.d.ts +13 -0
- package/{src/lib/base-model/page-info.ts → lib/base-model/page-info.d.ts} +25 -24
- package/lib/base-model/report-request.model.d.ts +18 -0
- package/lib/base-model/response-envelop.model.d.ts +8 -0
- package/lib/base-model/snack-message.model.d.ts +7 -0
- package/lib/base-model/table-column.interface.d.ts +28 -0
- package/lib/base-model/table-page-user-action.interface.d.ts +14 -0
- package/lib/base-model/workflow/workflow-steps.model.d.ts +7 -0
- package/lib/base-model/workflow/workflow.model.d.ts +13 -0
- package/lib/components/action-comment/action-comment.component.d.ts +32 -0
- package/lib/components/action-confirmation/action-confirmation.component.d.ts +19 -0
- package/lib/components/activity-report-form/activity-report-form.component.d.ts +93 -0
- package/lib/components/advanced-filter/field-filter/field-filter.component.d.ts +20 -0
- package/lib/components/advanced-filter/filter-builder/filter-builder.component.d.ts +28 -0
- package/lib/components/audit-log-details-dialog/audit-log-details-dialog.component.d.ts +25 -0
- package/lib/components/audit-log-list/audit-log.component.d.ts +36 -0
- package/lib/components/auto-complete/auto-complete.component.d.ts +51 -0
- package/lib/components/base-form/base-form.component.d.ts +59 -0
- package/lib/components/base-form-canvas/base-form-canvas.component.d.ts +124 -0
- package/lib/components/base-input-dialog/base-input-dialog.component.d.ts +23 -0
- package/lib/components/base-table/base-table.component.d.ts +128 -0
- package/lib/components/button-actions/button-actions.component.d.ts +17 -0
- package/lib/components/editable-base-table/editable-base-table.component.d.ts +106 -0
- package/lib/components/equation-builder/equation-builder.component.d.ts +23 -0
- package/lib/components/item-line-editor/item-line-editor.component.d.ts +64 -0
- package/lib/components/multi-auto-complete/multi-auto-complete.component.d.ts +51 -0
- package/lib/components/paginator/paginator.component.d.ts +26 -0
- package/lib/components/report-details-dialog/report-details-dialog.component.d.ts +34 -0
- package/lib/components/report-form/report-form.component.d.ts +92 -0
- package/lib/components/search-bar/search-bar.component.d.ts +29 -0
- package/lib/components/section-form-canvas/section-form-canvas.component.d.ts +27 -0
- package/lib/components/shared/action-button/action-button.component.d.ts +17 -0
- package/lib/components/shared/action-card/action-card.component.d.ts +37 -0
- package/lib/components/shared/attachment-uploader/attachment-uploader.component.d.ts +16 -0
- package/lib/components/shared-list/shared-list.component.d.ts +21 -0
- package/lib/components/snackbar-static/snackbar-static.component.d.ts +15 -0
- package/lib/components/title-bar/title-bar.component.d.ts +42 -0
- package/lib/services/backend-service.d.ts +59 -0
- package/{src/lib/services/index.ts → lib/services/index.d.ts} +1 -1
- package/lib/services/top-panel.d.ts +8 -0
- package/lib/services/trigger-form.service.d.ts +7 -0
- package/lib/utils/base-utils.d.ts +13 -0
- package/lib/validators/date-range-validator.d.ts +2 -0
- package/lib/validators/match-list.validator.d.ts +4 -0
- package/lib/validators/multi-email-validator.d.ts +6 -0
- package/package.json +19 -4
- package/{src/public-api.ts → public-api.d.ts} +22 -18
- package/ng-package.json +0 -7
- package/src/lib/base-model/SearchStrConfig.ts +0 -12
- package/src/lib/base-model/audit-log-entry.ts +0 -7
- package/src/lib/base-model/button-action-settings.ts +0 -25
- package/src/lib/base-model/column-def.model.ts +0 -34
- package/src/lib/base-model/do-action-request.ts +0 -11
- package/src/lib/base-model/field-action.ts +0 -7
- package/src/lib/base-model/field-filter.model.ts +0 -14
- package/src/lib/base-model/field-info.ts +0 -98
- package/src/lib/base-model/field-predicate.model.ts +0 -7
- package/src/lib/base-model/filter-request.ts +0 -27
- package/src/lib/base-model/filter.model.ts +0 -49
- package/src/lib/base-model/get-items-list.ts +0 -24
- package/src/lib/base-model/index.ts +0 -11
- package/src/lib/base-model/lookupItem.ts +0 -21
- package/src/lib/base-model/null-snackmessage.ts +0 -9
- package/src/lib/base-model/report-request.model.ts +0 -33
- package/src/lib/base-model/response-envelop.model.ts +0 -15
- package/src/lib/base-model/snack-message.model.ts +0 -14
- package/src/lib/base-model/snackmessage-interface.ts +0 -7
- package/src/lib/base-model/table-column.interface.ts +0 -29
- package/src/lib/base-model/table-page-user-action.interface.ts +0 -33
- package/src/lib/base-model/workflow/workflow-steps.model.ts +0 -9
- package/src/lib/base-model/workflow/workflow.model.ts +0 -52
- package/src/lib/components/action-confirmation/action-confirmation.component.css +0 -34
- package/src/lib/components/action-confirmation/action-confirmation.component.html +0 -18
- package/src/lib/components/action-confirmation/action-confirmation.component.spec.ts +0 -23
- package/src/lib/components/action-confirmation/action-confirmation.component.ts +0 -58
- package/src/lib/components/activity-report-form/activity-report-form.component.html +0 -109
- package/src/lib/components/activity-report-form/activity-report-form.component.scss +0 -0
- package/src/lib/components/activity-report-form/activity-report-form.component.spec.ts +0 -25
- package/src/lib/components/activity-report-form/activity-report-form.component.ts +0 -605
- package/src/lib/components/audit-log-details-dialog/audit-log-details-dialog.component.css +0 -51
- package/src/lib/components/audit-log-details-dialog/audit-log-details-dialog.component.html +0 -23
- package/src/lib/components/audit-log-details-dialog/audit-log-details-dialog.component.spec.ts +0 -23
- package/src/lib/components/audit-log-details-dialog/audit-log-details-dialog.component.ts +0 -69
- package/src/lib/components/audit-log-list/audit-log.component.html +0 -23
- package/src/lib/components/audit-log-list/audit-log.component.scss +0 -0
- package/src/lib/components/audit-log-list/audit-log.component.spec.ts +0 -25
- package/src/lib/components/audit-log-list/audit-log.component.ts +0 -116
- package/src/lib/components/auto-complete/auto-complete.component.css +0 -14
- package/src/lib/components/auto-complete/auto-complete.component.html +0 -29
- package/src/lib/components/auto-complete/auto-complete.component.spec.ts +0 -23
- package/src/lib/components/auto-complete/auto-complete.component.ts +0 -330
- package/src/lib/components/base-form/base-form.component.html +0 -58
- package/src/lib/components/base-form/base-form.component.scss +0 -0
- package/src/lib/components/base-form/base-form.component.spec.ts +0 -25
- package/src/lib/components/base-form/base-form.component.ts +0 -305
- package/src/lib/components/base-form-canvas/base-form-canvas.component.css +0 -22
- package/src/lib/components/base-form-canvas/base-form-canvas.component.html +0 -1006
- package/src/lib/components/base-form-canvas/base-form-canvas.component.spec.ts +0 -23
- package/src/lib/components/base-form-canvas/base-form-canvas.component.ts +0 -573
- package/src/lib/components/base-input-dialog/base-input-dialog.component.css +0 -0
- package/src/lib/components/base-input-dialog/base-input-dialog.component.html +0 -42
- package/src/lib/components/base-input-dialog/base-input-dialog.component.spec.ts +0 -23
- package/src/lib/components/base-input-dialog/base-input-dialog.component.ts +0 -78
- package/src/lib/components/base-table/base-table.component.html +0 -242
- package/src/lib/components/base-table/base-table.component.scss +0 -31
- package/src/lib/components/base-table/base-table.component.spec.ts +0 -25
- package/src/lib/components/base-table/base-table.component.ts +0 -568
- package/src/lib/components/button-actions/button-actions.component.html +0 -28
- package/src/lib/components/button-actions/button-actions.component.scss +0 -6
- package/src/lib/components/button-actions/button-actions.component.spec.ts +0 -23
- package/src/lib/components/button-actions/button-actions.component.ts +0 -72
- package/src/lib/components/editable-base-table/editable-base-table.component.html +0 -372
- package/src/lib/components/editable-base-table/editable-base-table.component.scss +0 -44
- package/src/lib/components/editable-base-table/editable-base-table.component.spec.ts +0 -25
- package/src/lib/components/editable-base-table/editable-base-table.component.ts +0 -570
- package/src/lib/components/equation-builder/equation-builder.component.css +0 -0
- package/src/lib/components/equation-builder/equation-builder.component.html +0 -31
- package/src/lib/components/equation-builder/equation-builder.component.spec.ts +0 -23
- package/src/lib/components/equation-builder/equation-builder.component.ts +0 -121
- package/src/lib/components/multi-auto-complete/multi-auto-complete.component.css +0 -11
- package/src/lib/components/multi-auto-complete/multi-auto-complete.component.html +0 -38
- package/src/lib/components/multi-auto-complete/multi-auto-complete.component.spec.ts +0 -23
- package/src/lib/components/multi-auto-complete/multi-auto-complete.component.ts +0 -317
- package/src/lib/components/paginator/paginator.component.css +0 -25
- package/src/lib/components/paginator/paginator.component.html +0 -34
- package/src/lib/components/paginator/paginator.component.ts +0 -94
- package/src/lib/components/rejection-comment/action-comment.component.css +0 -33
- package/src/lib/components/rejection-comment/action-comment.component.html +0 -46
- package/src/lib/components/rejection-comment/action-comment.component.spec.ts +0 -23
- package/src/lib/components/rejection-comment/action-comment.component.ts +0 -86
- package/src/lib/components/report-details-dialog/report-details-dialog.component.css +0 -17
- package/src/lib/components/report-details-dialog/report-details-dialog.component.html +0 -16
- package/src/lib/components/report-details-dialog/report-details-dialog.component.spec.ts +0 -23
- package/src/lib/components/report-details-dialog/report-details-dialog.component.ts +0 -113
- package/src/lib/components/report-form/report-form.component.html +0 -94
- package/src/lib/components/report-form/report-form.component.scss +0 -0
- package/src/lib/components/report-form/report-form.component.spec.ts +0 -25
- package/src/lib/components/report-form/report-form.component.ts +0 -588
- package/src/lib/components/search-bar/search-bar.component.html +0 -62
- package/src/lib/components/search-bar/search-bar.component.scss +0 -8
- package/src/lib/components/search-bar/search-bar.component.spec.ts +0 -25
- package/src/lib/components/search-bar/search-bar.component.ts +0 -70
- package/src/lib/components/shared/attachment-uploader/attachment-uploader.component.css +0 -54
- package/src/lib/components/shared/attachment-uploader/attachment-uploader.component.html +0 -22
- package/src/lib/components/shared/attachment-uploader/attachment-uploader.component.spec.ts +0 -23
- package/src/lib/components/shared/attachment-uploader/attachment-uploader.component.ts +0 -45
- package/src/lib/components/shared-list/shared-list.component.css +0 -0
- package/src/lib/components/shared-list/shared-list.component.html +0 -17
- package/src/lib/components/shared-list/shared-list.component.spec.ts +0 -23
- package/src/lib/components/shared-list/shared-list.component.ts +0 -53
- package/src/lib/components/title-bar/title-bar.component.css +0 -0
- package/src/lib/components/title-bar/title-bar.component.css.map +0 -1
- package/src/lib/components/title-bar/title-bar.component.html +0 -31
- package/src/lib/components/title-bar/title-bar.component.scss +0 -23
- package/src/lib/components/title-bar/title-bar.component.spec.ts +0 -23
- package/src/lib/components/title-bar/title-bar.component.ts +0 -119
- package/src/lib/services/backend-service.ts +0 -286
- package/src/lib/services/top-panel.ts +0 -17
- package/src/lib/services/trigger-form.service.ts +0 -11
- package/src/lib/share-module/shared-module.ts +0 -10
- package/src/lib/styles/invoiceq-theme.scss +0 -252
- package/src/lib/styles/styles.scss +0 -1723
- package/src/lib/utils/base-utils.ts +0 -102
- package/src/lib/validators/date-range-validator.ts +0 -31
- package/src/lib/validators/match-list.validator.ts +0 -10
- package/src/lib/validators/multi-email-validator.ts +0 -15
- package/tsconfig.lib.json +0 -15
- package/tsconfig.lib.prod.json +0 -11
- package/tsconfig.spec.json +0 -15
- /package/{src/lib/validators/index.ts → lib/validators/index.d.ts} +0 -0
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
import {Component, EventEmitter, Input, OnInit, Output} from '@angular/core';
|
|
2
|
-
import {MatFormField, MatLabel} from "@angular/material/form-field";
|
|
3
|
-
import {MatOption, MatSelect} from "@angular/material/select";
|
|
4
|
-
import {FormsModule} from "@angular/forms";
|
|
5
|
-
import {MatIcon} from "@angular/material/icon";
|
|
6
|
-
import {FlexModule} from "@angular/flex-layout";
|
|
7
|
-
import {MatInput} from "@angular/material/input";
|
|
8
|
-
import {MatIconButton} from "@angular/material/button";
|
|
9
|
-
import {NgForOf} from "@angular/common";
|
|
10
|
-
import {TableColumn} from "../../base-model";
|
|
11
|
-
import {TranslateModule} from "@ngx-translate/core";
|
|
12
|
-
type SearchType = 'exact' | 'like';
|
|
13
|
-
type SortType = 'ASC' | 'DESC';
|
|
14
|
-
@Component({
|
|
15
|
-
selector: 'ag-search-bar',
|
|
16
|
-
templateUrl: './search-bar.component.html',
|
|
17
|
-
standalone: true,
|
|
18
|
-
imports: [
|
|
19
|
-
MatFormField,
|
|
20
|
-
MatSelect,
|
|
21
|
-
MatOption,
|
|
22
|
-
FormsModule,
|
|
23
|
-
MatIcon,
|
|
24
|
-
FlexModule,
|
|
25
|
-
MatInput,
|
|
26
|
-
MatIconButton,
|
|
27
|
-
NgForOf,
|
|
28
|
-
TranslateModule
|
|
29
|
-
],
|
|
30
|
-
styleUrls: ['./search-bar.component.scss']
|
|
31
|
-
})
|
|
32
|
-
export class SearchBarComponent implements OnInit {
|
|
33
|
-
@Input() columns: TableColumn<any>[];
|
|
34
|
-
@Input() defaultSortKey: string = '';
|
|
35
|
-
|
|
36
|
-
searchValue: string = '';
|
|
37
|
-
searchType: SearchType = 'like';
|
|
38
|
-
selectedSortKey: string = '';
|
|
39
|
-
selectedSortType: SortType = 'ASC';
|
|
40
|
-
@Output() searchTriggered = new EventEmitter<{
|
|
41
|
-
searchValue: string;
|
|
42
|
-
searchType: SearchType;
|
|
43
|
-
sortKey: string;
|
|
44
|
-
sortType: string;
|
|
45
|
-
}>();
|
|
46
|
-
|
|
47
|
-
onSearch() {
|
|
48
|
-
this.selectedSortKey ||= this.defaultSortKey || this.columns[0]?.property;
|
|
49
|
-
|
|
50
|
-
this.searchTriggered.emit({
|
|
51
|
-
searchValue: this.searchValue,
|
|
52
|
-
searchType: this.searchType,
|
|
53
|
-
sortKey: this.selectedSortKey,
|
|
54
|
-
sortType: this.selectedSortType
|
|
55
|
-
});
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
labelKey(column: { label?: string; property: string }): string {
|
|
59
|
-
return column.label || column.property;
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
ngOnInit(): void {
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
getColumns() {
|
|
66
|
-
return this.columns.filter(
|
|
67
|
-
(column) => ['text', 'date', 'localDateTime'].includes(column.type)
|
|
68
|
-
);
|
|
69
|
-
}
|
|
70
|
-
}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
.attachment-uploader {
|
|
2
|
-
display: flex;
|
|
3
|
-
align-items: center;
|
|
4
|
-
justify-content: flex-start; /* <== Ensures buttons align left*/
|
|
5
|
-
gap: 10px;
|
|
6
|
-
flex-wrap: wrap;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
.upload-button {
|
|
10
|
-
display: flex;
|
|
11
|
-
align-items: center;
|
|
12
|
-
gap: 8px;
|
|
13
|
-
padding: 10px 18px;
|
|
14
|
-
border-radius: 8px;
|
|
15
|
-
font-weight: 500;
|
|
16
|
-
transition: all 0.3s ease;
|
|
17
|
-
min-width: 200px;
|
|
18
|
-
text-align: left;
|
|
19
|
-
overflow: hidden;
|
|
20
|
-
text-overflow: ellipsis;
|
|
21
|
-
white-space: nowrap;
|
|
22
|
-
|
|
23
|
-
mat-icon {
|
|
24
|
-
font-size: 20px;
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
.clear-button {
|
|
29
|
-
background-color: transparent;
|
|
30
|
-
border: none;
|
|
31
|
-
color: #d32f2f;
|
|
32
|
-
transition: color 0.2s ease;
|
|
33
|
-
padding: 4px;
|
|
34
|
-
|
|
35
|
-
&:hover {
|
|
36
|
-
color: #b71c1c;
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
mat-icon {
|
|
40
|
-
font-size: 20px;
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
.hidden-input {
|
|
45
|
-
display: none;
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
.icon-design {
|
|
50
|
-
display: flex;
|
|
51
|
-
align-items: center;
|
|
52
|
-
cursor: pointer;
|
|
53
|
-
|
|
54
|
-
}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
<div class="attachment-uploader">
|
|
2
|
-
<button mat-raised-button
|
|
3
|
-
[color]="selectedFile ? 'accent' : 'primary'"
|
|
4
|
-
class="upload-button"
|
|
5
|
-
(click)="triggerAttachmentUpload()">
|
|
6
|
-
<div class="icon-design">
|
|
7
|
-
<mat-icon>attach_file</mat-icon>
|
|
8
|
-
<span *ngIf="!selectedFile">{{ 'uploadAttachment' | translate }}</span>
|
|
9
|
-
<span *ngIf="selectedFile">{{ selectedFile.name }}</span>
|
|
10
|
-
</div>
|
|
11
|
-
</button>
|
|
12
|
-
|
|
13
|
-
<button *ngIf="selectedFile"
|
|
14
|
-
mat-icon-button
|
|
15
|
-
class="clear-button"
|
|
16
|
-
(click)="clearFile()"
|
|
17
|
-
matTooltip="Remove file">
|
|
18
|
-
<mat-icon>close</mat-icon>
|
|
19
|
-
</button>
|
|
20
|
-
|
|
21
|
-
<input #fileUpload type="file" class="hidden-input" (change)="uploadFileToServer()" />
|
|
22
|
-
</div>
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
|
2
|
-
|
|
3
|
-
import { AttachmentUploaderComponent } from './attachment-uploader.component';
|
|
4
|
-
|
|
5
|
-
describe('AttachmentUploaderComponent', () => {
|
|
6
|
-
let component: AttachmentUploaderComponent;
|
|
7
|
-
let fixture: ComponentFixture<AttachmentUploaderComponent>;
|
|
8
|
-
|
|
9
|
-
beforeEach(async () => {
|
|
10
|
-
await TestBed.configureTestingModule({
|
|
11
|
-
imports: [AttachmentUploaderComponent]
|
|
12
|
-
})
|
|
13
|
-
.compileComponents();
|
|
14
|
-
|
|
15
|
-
fixture = TestBed.createComponent(AttachmentUploaderComponent);
|
|
16
|
-
component = fixture.componentInstance;
|
|
17
|
-
fixture.detectChanges();
|
|
18
|
-
});
|
|
19
|
-
|
|
20
|
-
it('should create', () => {
|
|
21
|
-
expect(component).toBeTruthy();
|
|
22
|
-
});
|
|
23
|
-
});
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
import {Component, ElementRef, EventEmitter, Output, ViewChild} from '@angular/core';
|
|
2
|
-
import {MatIcon} from "@angular/material/icon";
|
|
3
|
-
import {TranslateModule} from "@ngx-translate/core";
|
|
4
|
-
import {MatButton, MatIconButton} from "@angular/material/button";
|
|
5
|
-
import {NgIf} from "@angular/common";
|
|
6
|
-
import {MatTooltip} from "@angular/material/tooltip";
|
|
7
|
-
|
|
8
|
-
@Component({
|
|
9
|
-
selector: 'app-attachment-uploader',
|
|
10
|
-
standalone: true,
|
|
11
|
-
imports: [
|
|
12
|
-
MatIcon,
|
|
13
|
-
TranslateModule,
|
|
14
|
-
MatButton,
|
|
15
|
-
NgIf,
|
|
16
|
-
MatTooltip,
|
|
17
|
-
MatIconButton,
|
|
18
|
-
],
|
|
19
|
-
templateUrl: './attachment-uploader.component.html',
|
|
20
|
-
styleUrl: './attachment-uploader.component.css'
|
|
21
|
-
})
|
|
22
|
-
export class AttachmentUploaderComponent {
|
|
23
|
-
@ViewChild('fileUpload') fileUpload!: ElementRef<HTMLInputElement>;
|
|
24
|
-
@Output() fileSelected = new EventEmitter<File | null>();
|
|
25
|
-
|
|
26
|
-
selectedFile: File | null = null;
|
|
27
|
-
|
|
28
|
-
triggerAttachmentUpload(): void {
|
|
29
|
-
this.fileUpload.nativeElement.click();
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
uploadFileToServer(): void {
|
|
33
|
-
const file = this.fileUpload.nativeElement.files?.[0];
|
|
34
|
-
if (file) {
|
|
35
|
-
this.selectedFile = file;
|
|
36
|
-
this.fileSelected.emit(file);
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
clearFile(): void {
|
|
41
|
-
this.selectedFile = null;
|
|
42
|
-
this.fileUpload.nativeElement.value = '';
|
|
43
|
-
this.fileSelected.emit(null);
|
|
44
|
-
}
|
|
45
|
-
}
|
|
File without changes
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
<ng-container *ngIf="readyToLoad">
|
|
2
|
-
@if (editableTable) {
|
|
3
|
-
<app-editable-base-table [filterRequest]="filterRequest" [pageInfo]="pageInfo"
|
|
4
|
-
[fields]="fields"
|
|
5
|
-
[isPending]="isPending"
|
|
6
|
-
></app-editable-base-table>
|
|
7
|
-
|
|
8
|
-
} @else {
|
|
9
|
-
|
|
10
|
-
<app-base-table [filters]="filters" [pageInfo]="pageInfo"
|
|
11
|
-
[columns]="columnsDefinition"
|
|
12
|
-
[listAction]="listAction"
|
|
13
|
-
[isPending]="isPending"
|
|
14
|
-
></app-base-table>
|
|
15
|
-
|
|
16
|
-
}
|
|
17
|
-
</ng-container>
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
|
2
|
-
|
|
3
|
-
import { SharedListComponent } from './shared-list.component';
|
|
4
|
-
|
|
5
|
-
describe('SharedListComponent', () => {
|
|
6
|
-
let component: SharedListComponent;
|
|
7
|
-
let fixture: ComponentFixture<SharedListComponent>;
|
|
8
|
-
|
|
9
|
-
beforeEach(async () => {
|
|
10
|
-
await TestBed.configureTestingModule({
|
|
11
|
-
imports: [SharedListComponent]
|
|
12
|
-
})
|
|
13
|
-
.compileComponents();
|
|
14
|
-
|
|
15
|
-
fixture = TestBed.createComponent(SharedListComponent);
|
|
16
|
-
component = fixture.componentInstance;
|
|
17
|
-
fixture.detectChanges();
|
|
18
|
-
});
|
|
19
|
-
|
|
20
|
-
it('should create', () => {
|
|
21
|
-
expect(component).toBeTruthy();
|
|
22
|
-
});
|
|
23
|
-
});
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
import {Component, OnInit} from '@angular/core';
|
|
2
|
-
import {ActivatedRoute} from "@angular/router";
|
|
3
|
-
import {NgIf} from "@angular/common";
|
|
4
|
-
import {BaseTableComponent} from "../base-table/base-table.component";
|
|
5
|
-
import {ButtonActionSettings, EMPTY_PAGE_INFO, FieldInfo, FilterRequest, PageInfo, TableColumn} from "../../base-model";
|
|
6
|
-
import {Filter} from "../../base-model";
|
|
7
|
-
import {EditableBaseTableComponent} from "../editable-base-table/editable-base-table.component";
|
|
8
|
-
|
|
9
|
-
@Component({
|
|
10
|
-
selector: 'app-shared-list',
|
|
11
|
-
standalone: true,
|
|
12
|
-
imports: [
|
|
13
|
-
BaseTableComponent,
|
|
14
|
-
NgIf,
|
|
15
|
-
EditableBaseTableComponent
|
|
16
|
-
],
|
|
17
|
-
templateUrl: './shared-list.component.html',
|
|
18
|
-
styleUrls:[ './shared-list.component.css']
|
|
19
|
-
})
|
|
20
|
-
export class SharedListComponent implements OnInit {
|
|
21
|
-
pageInfo: PageInfo = EMPTY_PAGE_INFO;
|
|
22
|
-
columnsDefinition: TableColumn<any>[] = [];
|
|
23
|
-
fields: FieldInfo[] = [];
|
|
24
|
-
filters: Filter[] = [];
|
|
25
|
-
readyToLoad: boolean = false;
|
|
26
|
-
isPending: boolean = false;
|
|
27
|
-
listAction: ButtonActionSettings[] = [];
|
|
28
|
-
editableTable : boolean = false;
|
|
29
|
-
filterRequest: FilterRequest = new FilterRequest();
|
|
30
|
-
constructor(private activatedRoute: ActivatedRoute) { }
|
|
31
|
-
|
|
32
|
-
ngOnInit(): void {
|
|
33
|
-
this.activatedRoute.data.subscribe(data => {
|
|
34
|
-
this.pageInfo = data['pageInfo'];
|
|
35
|
-
this.columnsDefinition = data["columnsDefinition"];
|
|
36
|
-
this.filters = data["filters"] || [];
|
|
37
|
-
|
|
38
|
-
this.isPending = 'pending' === data["mode"];
|
|
39
|
-
this.listAction = data['actions'];
|
|
40
|
-
this.editableTable = data['editableTable'] || false;
|
|
41
|
-
this.fields = data['fields'];
|
|
42
|
-
|
|
43
|
-
this.filterRequest = new FilterRequest();
|
|
44
|
-
this.filterRequest.columns = this.fields?.filter(c => c.type !== 'button').map(c => c.property) || [];
|
|
45
|
-
this.filterRequest.filters = this.filters;
|
|
46
|
-
|
|
47
|
-
this.readyToLoad = true;
|
|
48
|
-
|
|
49
|
-
});
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
}
|
|
File without changes
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sourceRoot":"","sources":[],"names":[],"mappings":"","file":"title-bar.component.css"}
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
<div [fxLayout]="!hideBackButton ? 'row' : 'column'" fxLayout.lt-md="column" fxLayoutGap="20px" fxLayoutGap.xs="1px" fxLayoutAlign="start center" fxLayoutAlign.lt-lg="start end" class="mainTitleBar">
|
|
2
|
-
<div fxLayout="column" fxFlex="auto" class="textTitle">
|
|
3
|
-
<h2><span class="textTitle__titleMode">{{titleMode | translate}}</span>
|
|
4
|
-
{{listTitle | translate}} <span *ngIf="titleCorporateAdmin&&isRoot">({{titleCorporateAdmin}})</span> {{extraData}}</h2>
|
|
5
|
-
</div>
|
|
6
|
-
<div fxLayout="column" fxFlex="auto" style="place-items: end">
|
|
7
|
-
<button mat-flat-button color="primary" style="width: 100px" *ngIf="!hideBackButton" (click)="goBack()">
|
|
8
|
-
<mat-icon color="second">{{ backIcon }}</mat-icon>
|
|
9
|
-
<span style="font-weight: bold">{{ 'back' | translate }}</span>
|
|
10
|
-
</button>
|
|
11
|
-
</div>
|
|
12
|
-
</div>
|
|
13
|
-
<div fxLayout="row" fxLayout.lt-md="column" fxLayoutGap="20px" fxLayoutGap.xs="1px" fxLayoutAlign="start center" class="mainTitleBar" style="width: 100% !important;">
|
|
14
|
-
<button mat-raised-button class="btn-none-background-primary" (click)="publishEvent()" color="primary"
|
|
15
|
-
*ngIf="newAction">
|
|
16
|
-
{{ 'add_new' | translate }}
|
|
17
|
-
</button>
|
|
18
|
-
|
|
19
|
-
<button [disabled]="totalElements == 0" mat-stroked-button [matMenuTriggerFor]="appMenu" *ngIf="showExtractButton">
|
|
20
|
-
{{ 'extract' | translate }}
|
|
21
|
-
<mat-icon class="expand_more actionButton__expand">expand_more</mat-icon>
|
|
22
|
-
</button>
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
</div>
|
|
26
|
-
<mat-menu #appMenu="matMenu">
|
|
27
|
-
<button mat-menu-item (click)="doExtractReport('pdf')">PDF</button>
|
|
28
|
-
<button mat-menu-item (click)="doExtractReport('xlsx')">Excel</button>
|
|
29
|
-
<button mat-menu-item (click)="doExtractReport('csv')">CSV</button>
|
|
30
|
-
<button mat-menu-item *ngFor="let detail of showDetails" (click)="doExtractReport(detail.type)">{{detail.title}}</button>
|
|
31
|
-
</mat-menu>
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
.mainTitleBar {
|
|
2
|
-
width: 100%;
|
|
3
|
-
padding: 0 20px;
|
|
4
|
-
.textTitle {
|
|
5
|
-
width: 100%;
|
|
6
|
-
&__titleMode {
|
|
7
|
-
font-style: italic;
|
|
8
|
-
font-weight: 200;
|
|
9
|
-
color: grey;
|
|
10
|
-
}
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
.actionButton {
|
|
14
|
-
width: 100%;
|
|
15
|
-
|
|
16
|
-
&__expand {
|
|
17
|
-
font-size: 20px !important;
|
|
18
|
-
color: var(--accent-color);
|
|
19
|
-
margin-top: 5px
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
|
2
|
-
|
|
3
|
-
import { TitleBarComponent } from './title-bar.component';
|
|
4
|
-
|
|
5
|
-
describe('TitleBarComponent', () => {
|
|
6
|
-
let component: TitleBarComponent;
|
|
7
|
-
let fixture: ComponentFixture<TitleBarComponent>;
|
|
8
|
-
|
|
9
|
-
beforeEach(async () => {
|
|
10
|
-
await TestBed.configureTestingModule({
|
|
11
|
-
imports: [TitleBarComponent]
|
|
12
|
-
})
|
|
13
|
-
.compileComponents();
|
|
14
|
-
|
|
15
|
-
fixture = TestBed.createComponent(TitleBarComponent);
|
|
16
|
-
component = fixture.componentInstance;
|
|
17
|
-
fixture.detectChanges();
|
|
18
|
-
});
|
|
19
|
-
|
|
20
|
-
it('should create', () => {
|
|
21
|
-
expect(component).toBeTruthy();
|
|
22
|
-
});
|
|
23
|
-
});
|
|
@@ -1,119 +0,0 @@
|
|
|
1
|
-
import {Component, EventEmitter, Input, OnChanges, OnInit, Output, SimpleChanges} from '@angular/core';
|
|
2
|
-
import {Location, NgForOf, NgIf} from "@angular/common";
|
|
3
|
-
import {MatIconModule} from "@angular/material/icon";
|
|
4
|
-
import {MatButton} from "@angular/material/button";
|
|
5
|
-
import {MatMenu, MatMenuItem, MatMenuTrigger} from "@angular/material/menu";
|
|
6
|
-
import {FlexLayoutModule} from "@angular/flex-layout";
|
|
7
|
-
import {TranslateModule} from "@ngx-translate/core";
|
|
8
|
-
import {Directionality} from "@angular/cdk/bidi";
|
|
9
|
-
|
|
10
|
-
@Component({
|
|
11
|
-
selector: 'app-title-bar',
|
|
12
|
-
standalone: true,
|
|
13
|
-
imports: [
|
|
14
|
-
NgIf,
|
|
15
|
-
MatIconModule,
|
|
16
|
-
MatButton,
|
|
17
|
-
MatMenuItem,
|
|
18
|
-
MatMenu,
|
|
19
|
-
NgForOf,
|
|
20
|
-
MatMenuTrigger,
|
|
21
|
-
FlexLayoutModule,
|
|
22
|
-
TranslateModule,
|
|
23
|
-
|
|
24
|
-
],
|
|
25
|
-
templateUrl: './title-bar.component.html',
|
|
26
|
-
styleUrls: ['./title-bar.component.css', 'title-bar.component.scss']
|
|
27
|
-
})
|
|
28
|
-
export class TitleBarComponent implements OnInit, OnChanges {
|
|
29
|
-
@Input()
|
|
30
|
-
pageTitle: string = "";
|
|
31
|
-
|
|
32
|
-
@Input()
|
|
33
|
-
showExtractButton: boolean = false;
|
|
34
|
-
|
|
35
|
-
@Input()
|
|
36
|
-
totalElements?: number;
|
|
37
|
-
|
|
38
|
-
@Input()
|
|
39
|
-
titleMode: string = '';
|
|
40
|
-
|
|
41
|
-
@Input()
|
|
42
|
-
statusDesc?: string;
|
|
43
|
-
|
|
44
|
-
@Input()
|
|
45
|
-
newAction: boolean = false;
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
@Input() // @ts-ignore
|
|
49
|
-
extraButton: string;
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
@Input()
|
|
53
|
-
showDetails: any = [];
|
|
54
|
-
|
|
55
|
-
@Input()
|
|
56
|
-
showImport = false;
|
|
57
|
-
|
|
58
|
-
@Input()
|
|
59
|
-
showButton = false;
|
|
60
|
-
|
|
61
|
-
@Output()
|
|
62
|
-
newActionClicked = new EventEmitter();
|
|
63
|
-
|
|
64
|
-
@Output()
|
|
65
|
-
extraButtonClicked = new EventEmitter();
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
@Output()
|
|
69
|
-
extractReport = new EventEmitter();
|
|
70
|
-
|
|
71
|
-
@Input()
|
|
72
|
-
extraData = '';
|
|
73
|
-
|
|
74
|
-
listTitle = '';
|
|
75
|
-
newButton = '';
|
|
76
|
-
|
|
77
|
-
@Input()
|
|
78
|
-
titleCorporateAdmin: string = '';
|
|
79
|
-
|
|
80
|
-
isRoot: boolean = false;
|
|
81
|
-
@Input()
|
|
82
|
-
hideBackButton: boolean = true;
|
|
83
|
-
|
|
84
|
-
constructor(private location:Location,
|
|
85
|
-
private dir: Directionality) {
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
ngOnInit(): void {
|
|
89
|
-
this.listTitle = this.pageTitle;
|
|
90
|
-
this.newButton = this.extraButton;
|
|
91
|
-
// this.isRoot = this.authService.isRootOrg();
|
|
92
|
-
this.isRoot = false;
|
|
93
|
-
}
|
|
94
|
-
get backIcon(): string {
|
|
95
|
-
return this.dir.value === 'rtl' ? 'arrow_back' : 'arrow_forward';
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
publishEvent() {
|
|
99
|
-
this.newActionClicked.emit(true);
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
doExtractReport(value: any) {
|
|
104
|
-
this.extractReport.emit(value);
|
|
105
|
-
}
|
|
106
|
-
publishExtraButtonEvent() {
|
|
107
|
-
this.extraButtonClicked.emit(true);
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
ngOnChanges(changes: SimpleChanges): void {
|
|
111
|
-
if (changes["pageTitle"] && !changes["pageTitle"].isFirstChange() ) {
|
|
112
|
-
this.listTitle = this.pageTitle;
|
|
113
|
-
}
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
goBack() {
|
|
117
|
-
this.location.back()
|
|
118
|
-
}
|
|
119
|
-
}
|