@sd-angular/core 19.0.0-beta.1 → 19.0.0-beta.10

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.
Files changed (82) hide show
  1. package/assets/scss/core/bootstrap.scss +25 -0
  2. package/assets/scss/core/form.scss +4 -10
  3. package/components/document-builder/src/document-builder.component.d.ts +23 -6
  4. package/components/document-builder/src/document-builder.config.d.ts +21 -0
  5. package/components/document-builder/src/document-builder.model.d.ts +1 -0
  6. package/components/document-builder/src/document-builder.utils.d.ts +10 -0
  7. package/components/document-builder/src/plugins/heading/heading.plugin.d.ts +4 -0
  8. package/components/document-builder/src/plugins/{image-upload.plugin.d.ts → image-upload/image-upload.plugin.d.ts} +0 -4
  9. package/components/document-builder/src/plugins/index.d.ts +6 -5
  10. package/components/table/src/models/table-item.model.d.ts +2 -1
  11. package/components/table/src/models/table-option.model.d.ts +2 -1
  12. package/components/workflow/src/models/index.d.ts +1 -0
  13. package/fesm2022/sd-angular-core-components-badge.mjs +2 -2
  14. package/fesm2022/sd-angular-core-components-badge.mjs.map +1 -1
  15. package/fesm2022/sd-angular-core-components-document-builder.mjs +721 -513
  16. package/fesm2022/sd-angular-core-components-document-builder.mjs.map +1 -1
  17. package/fesm2022/sd-angular-core-components-table.mjs +366 -77
  18. package/fesm2022/sd-angular-core-components-table.mjs.map +1 -1
  19. package/fesm2022/sd-angular-core-components-workflow.mjs +23 -23
  20. package/fesm2022/sd-angular-core-components-workflow.mjs.map +1 -1
  21. package/fesm2022/sd-angular-core-forms-autocomplete.mjs +24 -2
  22. package/fesm2022/sd-angular-core-forms-autocomplete.mjs.map +1 -1
  23. package/fesm2022/sd-angular-core-forms-date.mjs +15 -3
  24. package/fesm2022/sd-angular-core-forms-date.mjs.map +1 -1
  25. package/fesm2022/sd-angular-core-forms-datetime.mjs +17 -3
  26. package/fesm2022/sd-angular-core-forms-datetime.mjs.map +1 -1
  27. package/fesm2022/sd-angular-core-forms-input-number.mjs +18 -3
  28. package/fesm2022/sd-angular-core-forms-input-number.mjs.map +1 -1
  29. package/fesm2022/sd-angular-core-forms-input.mjs +20 -6
  30. package/fesm2022/sd-angular-core-forms-input.mjs.map +1 -1
  31. package/fesm2022/sd-angular-core-forms-radio.mjs +17 -2
  32. package/fesm2022/sd-angular-core-forms-radio.mjs.map +1 -1
  33. package/fesm2022/sd-angular-core-forms-select.mjs +15 -2
  34. package/fesm2022/sd-angular-core-forms-select.mjs.map +1 -1
  35. package/fesm2022/sd-angular-core-forms-textarea.mjs +21 -2
  36. package/fesm2022/sd-angular-core-forms-textarea.mjs.map +1 -1
  37. package/fesm2022/sd-angular-core-modules-auth.mjs +137 -0
  38. package/fesm2022/sd-angular-core-modules-auth.mjs.map +1 -0
  39. package/fesm2022/sd-angular-core-modules-layout.mjs +1 -1
  40. package/fesm2022/sd-angular-core-modules-layout.mjs.map +1 -1
  41. package/fesm2022/sd-angular-core-modules.mjs +1 -0
  42. package/fesm2022/sd-angular-core-modules.mjs.map +1 -1
  43. package/fesm2022/sd-angular-core-pipes.mjs +21 -1
  44. package/fesm2022/sd-angular-core-pipes.mjs.map +1 -1
  45. package/fesm2022/sd-angular-core-services-confirm.mjs +60 -25
  46. package/fesm2022/sd-angular-core-services-confirm.mjs.map +1 -1
  47. package/fesm2022/sd-angular-core-utilities-extensions.mjs +66 -1
  48. package/fesm2022/sd-angular-core-utilities-extensions.mjs.map +1 -1
  49. package/fesm2022/sd-angular-core-utilities-models.mjs +12 -3
  50. package/fesm2022/sd-angular-core-utilities-models.mjs.map +1 -1
  51. package/forms/autocomplete/src/autocomplete.component.d.ts +5 -1
  52. package/forms/date/src/date.component.d.ts +4 -1
  53. package/forms/datetime/src/datetime.component.d.ts +4 -1
  54. package/forms/input/src/input.component.d.ts +6 -4
  55. package/forms/input-number/src/input-number.component.d.ts +4 -1
  56. package/forms/radio/src/radio.component.d.ts +5 -1
  57. package/forms/select/src/select.component.d.ts +5 -1
  58. package/forms/textarea/src/textarea.component.d.ts +3 -1
  59. package/modules/auth/configurations/auth.configuration.d.ts +19 -0
  60. package/modules/auth/configurations/index.d.ts +1 -0
  61. package/modules/auth/guards/auth.guard.d.ts +11 -0
  62. package/modules/auth/guards/index.d.ts +2 -0
  63. package/modules/auth/guards/portal.guard.d.ts +11 -0
  64. package/modules/auth/index.d.ts +3 -0
  65. package/modules/auth/services/auth.model.d.ts +8 -0
  66. package/modules/auth/services/auth.service.d.ts +17 -0
  67. package/modules/auth/services/index.d.ts +2 -0
  68. package/modules/index.d.ts +1 -0
  69. package/package.json +56 -52
  70. package/pipes/index.d.ts +1 -0
  71. package/pipes/src/empty.pipe.d.ts +7 -0
  72. package/sd-angular-core-19.0.0-beta.10.tgz +0 -0
  73. package/services/confirm/src/lib/components/dialog-confirm/dialog-confirm.component.d.ts +8 -0
  74. package/services/confirm/src/lib/confirm.service.d.ts +14 -0
  75. package/utilities/extensions/index.d.ts +1 -0
  76. package/utilities/extensions/src/color.extension.d.ts +20 -0
  77. package/utilities/models/src/maybe-async.model.d.ts +1 -0
  78. package/utilities/models/src/pattern.model.d.ts +2 -2
  79. /package/components/document-builder/src/plugins/{comment.plugin.d.ts → comment/comment.plugin.d.ts} +0 -0
  80. /package/components/document-builder/src/plugins/{page-orientation.plugin.d.ts → page-orientation/page-orientation.plugin.d.ts} +0 -0
  81. /package/components/document-builder/src/plugins/{table-fit.plugin.d.ts → table-fit/table-fit.plugin.d.ts} +0 -0
  82. /package/components/document-builder/src/plugins/{variable.plugin.d.ts → variable/variable.plugin.d.ts} +0 -0
@@ -227,7 +227,7 @@ class ColumnFilterComponent {
227
227
  this.ref.markForCheck();
228
228
  };
229
229
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: ColumnFilterComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
230
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: ColumnFilterComponent, isStandalone: true, selector: "column-filter", inputs: { _autoId: ["autoId", "_autoId"], _value: ["value", "_value"], _inlineOperator: ["inlineOperator", "_inlineOperator"], _columnFilter: ["columnFilter", "_columnFilter"], cacheValues: "cacheValues", _column: ["column", "_column"] }, outputs: { inlineOperatorChange: "inlineOperatorChange", operatorChange: "operatorChange", filterChange: "filterChange" }, ngImport: i0, template: "<div class=\"d-flex c-inline-column align-items-end\">\r\n @if (\r\n column.type === 'string' ||\r\n column.type === 'number' ||\r\n column.type === 'boolean' ||\r\n column.type === 'values' ||\r\n column.type === 'lazy-values' ||\r\n column.type === 'date' ||\r\n column.type === 'datetime' ||\r\n column.type === 'time'\r\n ) {\r\n <div class=\"d-flex align-items-center\" *ngIf=\"operators.length\">\r\n <!-- Only number column icon broken. add mb when not default symbol -->\r\n <sd-button\r\n class=\"{{ column.type === 'number' && inlineSymbol !== 'filter_alt' ? 'mb-4 mr-2 ' : 'mr-2 ' }}\"\r\n fontSet=\"material-symbols-outlined\"\r\n [prefixIcon]=\"inlineSymbol\"\r\n [matMenuTriggerFor]=\"menu\"\r\n type=\"link\">\r\n </sd-button>\r\n <mat-menu #menu=\"matMenu\">\r\n <button *ngFor=\"let operator of operators\" (click)=\"onChangeOperator(operator)\" mat-menu-item type=\"button\">\r\n <mat-icon fontSet=\"material-symbols-outlined\" class=\"{{ column.type === 'number' ? 'mb-8 ' : '' }}\">{{\r\n operator.symbol\r\n }}</mat-icon>\r\n <span> {{ operator.display }}</span>\r\n </button>\r\n </mat-menu>\r\n </div>\r\n @if (column.type === 'string') {\r\n <sd-input\r\n *ngIf=\"column.type === 'string'\"\r\n [autoId]=\"autoId + column.field\"\r\n style=\"flex: 1\"\r\n size=\"sm\"\r\n type=\"text\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (keyupEnter)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-input>\r\n } @else if (column.type === 'number') {\r\n @if (!column.filter?.type) {\r\n <sd-input-number\r\n [autoId]=\"autoId + column.field\"\r\n style=\"flex: 1\"\r\n size=\"sm\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (keyupEnter)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-input-number>\r\n } @else if (column.filter?.type === 'split-number') {\r\n <div class=\"d-flex align-items-center\">\r\n <sd-input-number\r\n [autoId]=\"autoId + '-from-' + column.field\"\r\n style=\"flex: 1\"\r\n size=\"sm\"\r\n [(model)]=\"columnFilter[column.field].from\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-input-number>\r\n <div class=\"mx-4\">-</div>\r\n <sd-input-number\r\n [autoId]=\"autoId + '-to-' + column.field\"\r\n style=\"flex: 1\"\r\n size=\"sm\"\r\n [(model)]=\"columnFilter[column.field].to\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-input-number>\r\n </div>\r\n }\r\n } @else if (column.type === 'boolean') {\r\n <sd-select\r\n *ngIf=\"column.type === 'boolean'\"\r\n [autoId]=\"autoId + column.field\"\r\n [style.flex]=\"1\"\r\n [style.width]=\"'100%'\"\r\n size=\"sm\"\r\n [items]=\"[\r\n { value: '1', display: column.option?.displayOnTrue || 'True' },\r\n { value: '0', display: column.option?.displayOnFalse || 'False' }\r\n ]\"\r\n valueField=\"value\"\r\n displayField=\"display\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n <ng-template sdSelectDisplayDef let-item=\"item\">\r\n <sd-badge *ngIf=\"item.value === '1'\" color=\"success\" [title]=\"column.option?.displayOnTrue || 'True'\"> </sd-badge>\r\n <sd-badge *ngIf=\"item.value === '0'\" color=\"error\" [title]=\"column.option?.displayOnFalse || 'False'\"> </sd-badge>\r\n </ng-template>\r\n </sd-select>\r\n } @else if (column.type === 'values') {\r\n <sd-select\r\n *ngIf=\"column.option?.selection !== 'AUTOCOMPLETE'\"\r\n [autoId]=\"autoId + column.field\"\r\n [style.flex]=\"1\"\r\n [style.width]=\"'100%'\"\r\n size=\"sm\"\r\n [items]=\"items\"\r\n [valueField]=\"column.option.valueField\"\r\n [displayField]=\"column.option.displayField\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n [multiple]=\"column.option.selection === 'MULTIPLE' || column.option.selection === 'MULTIPLEAUTOCOMPLETE'\"\r\n hideInlineError>\r\n </sd-select>\r\n <sd-autocomplete\r\n *ngIf=\"column.option?.selection === 'AUTOCOMPLETE'\"\r\n [autoId]=\"autoId + column.field\"\r\n style=\"flex: 1\"\r\n size=\"sm\"\r\n [items]=\"items\"\r\n [valueField]=\"column.option.valueField\"\r\n [displayField]=\"column.option.displayField\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-autocomplete>\r\n } @else if (column.type === 'lazy-values') {\r\n <sd-select\r\n *ngIf=\"column.option?.selection === 'MULTIPLE'\"\r\n [autoId]=\"autoId + column.field\"\r\n [style.flex]=\"1\"\r\n [style.width]=\"'100%'\"\r\n size=\"sm\"\r\n [items]=\"items\"\r\n [valueField]=\"column.option.valueField\"\r\n [displayField]=\"column.option.displayField\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n multiple\r\n hideInlineError>\r\n </sd-select>\r\n <sd-autocomplete\r\n *ngIf=\"!column.option?.selection\"\r\n [autoId]=\"autoId + column.field\"\r\n style=\"flex: 1\"\r\n size=\"sm\"\r\n [items]=\"items\"\r\n [valueField]=\"column.option.valueField\"\r\n [displayField]=\"column.option.displayField\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-autocomplete>\r\n } @else if (column.type === 'date' || column.type === 'datetime' || column.type === 'time') {\r\n @if (!column.filter?.type || column.filter?.type === 'daterange') {\r\n <sd-date-range\r\n style=\"flex: 1\"\r\n size=\"sm\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-date-range>\r\n } @else if (column.filter?.type === 'date') {\r\n <sd-date\r\n [autoId]=\"autoId + column.field\"\r\n style=\"flex: 1\"\r\n type=\"date\"\r\n size=\"sm\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-date>\r\n } @else if (column.filter?.type === 'split-date') {\r\n <div class=\"d-flex align-items-center\">\r\n <sd-date\r\n [autoId]=\"autoId + '-from-' + column.field\"\r\n style=\"flex: 1\"\r\n type=\"date\"\r\n size=\"sm\"\r\n [(model)]=\"columnFilter[column.field].from\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-date>\r\n <div class=\"mx-4\">-</div>\r\n <sd-date\r\n [autoId]=\"autoId + '-to-' + column.field\"\r\n style=\"flex: 1\"\r\n type=\"date\"\r\n size=\"sm\"\r\n [(model)]=\"columnFilter[column.field].to\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-date>\r\n </div>\r\n }\r\n }\r\n } @else {\r\n <sd-input [autoId]=\"autoId + column.field\" type=\"text\" size=\"sm\" disabled></sd-input>\r\n }\r\n</div>\r\n", styles: [":host ::ng-deep .c-inline-column .mat-mdc-text-field-wrapper{background-color:#fff}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i2.MatMenu, selector: "mat-menu", inputs: ["backdropClass", "aria-label", "aria-labelledby", "aria-describedby", "xPosition", "yPosition", "overlapTrigger", "hasBackdrop", "class", "classList"], outputs: ["closed", "close"], exportAs: ["matMenu"] }, { kind: "component", type: i2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i2.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData", "matMenuTriggerRestoreFocus"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: SdButton, selector: "sd-button", inputs: ["autoId", "type", "color", "title", "width", "size", "tooltip", "prefixIcon", "suffixIcon", "fontSet", "disabled", "loading"], outputs: ["click"] }, { kind: "component", type: SdInput, selector: "sd-input", inputs: ["autoId", "name", "appearance", "size", "form", "label", "helperText", "placeholder", "type", "hideInlineError", "blurOnEnter", "model", "required", "readonly", "minlength", "maxlength", "pattern", "patternErrorMessage", "validator", "inlineError", "disabled", "tooltip"], outputs: ["modelChange", "sdChange", "sdFocus", "sdBlur", "sdFocusForceBlur", "keyupEnter"] }, { kind: "component", type: SdInputNumber, selector: "sd-input-number", inputs: ["autoId", "name", "size", "form", "label", "helperText", "placeholder", "hideInlineError", "blurOnEnter", "model", "required", "type", "precision", "readonly", "min", "max", "validator", "inlineError", "disabled", "appearance"], outputs: ["modelChange", "sdChange", "sdFocus", "sdBlur", "sdFocusForceBlur", "keyupEnter"] }, { kind: "component", type: SdSelect, selector: "sd-select", inputs: ["autoId", "name", "appearance", "hideInlineError", "size", "form", "label", "helperText", "placeholder", "model", "items", "valueField", "displayField", "disabledField", "cacheChecksum", "required", "validator", "inlineError", "disabled", "multiple", "limit"], outputs: ["modelChange", "sdChange", "sdSelection"] }, { kind: "component", type: SdAutocomplete, selector: "sd-autocomplete", inputs: ["autoId", "name", "appearance", "size", "form", "label", "helperText", "valueField", "displayField", "disabledField", "placeholder", "items", "limit", "cacheChecksum", "model", "addable", "disabled", "required", "validator", "inlineError", "hideInlineError"], outputs: ["modelChange", "sdChange", "sdSelection", "sdAdd"] }, { kind: "component", type: SdDate, selector: "sd-date", inputs: ["autoId", "name", "appearance", "hideInlineError", "min", "max", "size", "form", "disabled", "required", "inlineError", "label", "helperText", "placeholder", "minDate", "maxDate", "model"], outputs: ["sdChange", "sdFocus", "modelChange"] }, { kind: "component", type: SdDateRange, selector: "sd-date-range", inputs: ["autoId", "name", "appearance", "size", "form", "disabled", "required", "label", "helperText", "hideInlineError", "min", "max", "model"], outputs: ["modelChange", "sdChange"] }, { kind: "component", type: SdBadge, selector: "sd-badge", inputs: ["type", "color", "primary", "secondary", "success", "info", "warning", "error", "fontSet", "title", "description", "tooltip", "icon", "size"], outputs: ["sdClick"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
230
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: ColumnFilterComponent, isStandalone: true, selector: "column-filter", inputs: { _autoId: ["autoId", "_autoId"], _value: ["value", "_value"], _inlineOperator: ["inlineOperator", "_inlineOperator"], _columnFilter: ["columnFilter", "_columnFilter"], cacheValues: "cacheValues", _column: ["column", "_column"] }, outputs: { inlineOperatorChange: "inlineOperatorChange", operatorChange: "operatorChange", filterChange: "filterChange" }, ngImport: i0, template: "<div class=\"d-flex c-inline-column align-items-end\">\r\n @if (\r\n column.type === 'string' ||\r\n column.type === 'number' ||\r\n column.type === 'boolean' ||\r\n column.type === 'values' ||\r\n column.type === 'lazy-values' ||\r\n column.type === 'date' ||\r\n column.type === 'datetime' ||\r\n column.type === 'time'\r\n ) {\r\n <div class=\"d-flex align-items-center\" *ngIf=\"operators.length\">\r\n <!-- Only number column icon broken. add mb when not default symbol -->\r\n <sd-button\r\n class=\"{{ column.type === 'number' && inlineSymbol !== 'filter_alt' ? 'mb-4 mr-2 ' : 'mr-2 ' }}\"\r\n fontSet=\"material-symbols-outlined\"\r\n [prefixIcon]=\"inlineSymbol\"\r\n [matMenuTriggerFor]=\"menu\"\r\n type=\"link\">\r\n </sd-button>\r\n <mat-menu #menu=\"matMenu\">\r\n <button *ngFor=\"let operator of operators\" (click)=\"onChangeOperator(operator)\" mat-menu-item type=\"button\">\r\n <mat-icon fontSet=\"material-symbols-outlined\" class=\"{{ column.type === 'number' ? 'mb-8 ' : '' }}\">{{\r\n operator.symbol\r\n }}</mat-icon>\r\n <span> {{ operator.display }}</span>\r\n </button>\r\n </mat-menu>\r\n </div>\r\n @if (column.type === 'string') {\r\n <sd-input\r\n *ngIf=\"column.type === 'string'\"\r\n [autoId]=\"autoId + column.field\"\r\n style=\"flex: 1\"\r\n size=\"sm\"\r\n type=\"text\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (keyupEnter)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-input>\r\n } @else if (column.type === 'number') {\r\n @if (!column.filter?.type) {\r\n <sd-input-number\r\n [autoId]=\"autoId + column.field\"\r\n style=\"flex: 1\"\r\n size=\"sm\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (keyupEnter)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-input-number>\r\n } @else if (column.filter?.type === 'split-number') {\r\n <div class=\"d-flex align-items-center\">\r\n <sd-input-number\r\n [autoId]=\"autoId + '-from-' + column.field\"\r\n style=\"flex: 1\"\r\n size=\"sm\"\r\n [(model)]=\"columnFilter[column.field].from\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-input-number>\r\n <div class=\"mx-4\">-</div>\r\n <sd-input-number\r\n [autoId]=\"autoId + '-to-' + column.field\"\r\n style=\"flex: 1\"\r\n size=\"sm\"\r\n [(model)]=\"columnFilter[column.field].to\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-input-number>\r\n </div>\r\n }\r\n } @else if (column.type === 'boolean') {\r\n <sd-select\r\n *ngIf=\"column.type === 'boolean'\"\r\n [autoId]=\"autoId + column.field\"\r\n [style.flex]=\"1\"\r\n [style.width]=\"'100%'\"\r\n size=\"sm\"\r\n [items]=\"[\r\n { value: '1', display: column.option?.displayOnTrue || 'True' },\r\n { value: '0', display: column.option?.displayOnFalse || 'False' }\r\n ]\"\r\n valueField=\"value\"\r\n displayField=\"display\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n <ng-template sdSelectDisplayDef let-item=\"item\">\r\n <sd-badge *ngIf=\"item.value === '1'\" color=\"success\" [title]=\"column.option?.displayOnTrue || 'True'\"> </sd-badge>\r\n <sd-badge *ngIf=\"item.value === '0'\" color=\"error\" [title]=\"column.option?.displayOnFalse || 'False'\"> </sd-badge>\r\n </ng-template>\r\n </sd-select>\r\n } @else if (column.type === 'values') {\r\n <sd-select\r\n *ngIf=\"column.option?.selection !== 'AUTOCOMPLETE'\"\r\n [autoId]=\"autoId + column.field\"\r\n [style.flex]=\"1\"\r\n [style.width]=\"'100%'\"\r\n size=\"sm\"\r\n [items]=\"items\"\r\n [valueField]=\"column.option.valueField\"\r\n [displayField]=\"column.option.displayField\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n [multiple]=\"column.option.selection === 'MULTIPLE' || column.option.selection === 'MULTIPLEAUTOCOMPLETE'\"\r\n hideInlineError>\r\n </sd-select>\r\n <sd-autocomplete\r\n *ngIf=\"column.option?.selection === 'AUTOCOMPLETE'\"\r\n [autoId]=\"autoId + column.field\"\r\n style=\"flex: 1\"\r\n size=\"sm\"\r\n [items]=\"items\"\r\n [valueField]=\"column.option.valueField\"\r\n [displayField]=\"column.option.displayField\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-autocomplete>\r\n } @else if (column.type === 'lazy-values') {\r\n <sd-select\r\n *ngIf=\"column.option?.selection === 'MULTIPLE'\"\r\n [autoId]=\"autoId + column.field\"\r\n [style.flex]=\"1\"\r\n [style.width]=\"'100%'\"\r\n size=\"sm\"\r\n [items]=\"items\"\r\n [valueField]=\"column.option.valueField\"\r\n [displayField]=\"column.option.displayField\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n multiple\r\n hideInlineError>\r\n </sd-select>\r\n <sd-autocomplete\r\n *ngIf=\"!column.option?.selection\"\r\n [autoId]=\"autoId + column.field\"\r\n style=\"flex: 1\"\r\n size=\"sm\"\r\n [items]=\"items\"\r\n [valueField]=\"column.option.valueField\"\r\n [displayField]=\"column.option.displayField\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-autocomplete>\r\n } @else if (column.type === 'date' || column.type === 'datetime' || column.type === 'time') {\r\n @if (!column.filter?.type || column.filter?.type === 'daterange') {\r\n <sd-date-range\r\n style=\"flex: 1\"\r\n size=\"sm\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-date-range>\r\n } @else if (column.filter?.type === 'date') {\r\n <sd-date\r\n [autoId]=\"autoId + column.field\"\r\n style=\"flex: 1\"\r\n type=\"date\"\r\n size=\"sm\"\r\n [(model)]=\"columnFilter[column.field]\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-date>\r\n } @else if (column.filter?.type === 'split-date') {\r\n <div class=\"d-flex align-items-center\">\r\n <sd-date\r\n [autoId]=\"autoId + '-from-' + column.field\"\r\n style=\"flex: 1\"\r\n type=\"date\"\r\n size=\"sm\"\r\n [(model)]=\"columnFilter[column.field].from\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-date>\r\n <div class=\"mx-4\">-</div>\r\n <sd-date\r\n [autoId]=\"autoId + '-to-' + column.field\"\r\n style=\"flex: 1\"\r\n type=\"date\"\r\n size=\"sm\"\r\n [(model)]=\"columnFilter[column.field].to\"\r\n (sdChange)=\"onFilterChange()\"\r\n [disabled]=\"column.filter?.disabled\"\r\n hideInlineError>\r\n </sd-date>\r\n </div>\r\n }\r\n }\r\n } @else {\r\n <sd-input [autoId]=\"autoId + column.field\" type=\"text\" size=\"sm\" disabled></sd-input>\r\n }\r\n</div>\r\n", styles: [":host ::ng-deep .c-inline-column .mat-mdc-text-field-wrapper{background-color:#fff}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i2.MatMenu, selector: "mat-menu", inputs: ["backdropClass", "aria-label", "aria-labelledby", "aria-describedby", "xPosition", "yPosition", "overlapTrigger", "hasBackdrop", "class", "classList"], outputs: ["closed", "close"], exportAs: ["matMenu"] }, { kind: "component", type: i2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i2.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData", "matMenuTriggerRestoreFocus"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: SdButton, selector: "sd-button", inputs: ["autoId", "type", "color", "title", "width", "size", "tooltip", "prefixIcon", "suffixIcon", "fontSet", "disabled", "loading"], outputs: ["click"] }, { kind: "component", type: SdInput, selector: "sd-input", inputs: ["autoId", "name", "appearance", "size", "form", "label", "helperText", "placeholder", "type", "hideInlineError", "blurOnEnter", "model", "required", "readonly", "minlength", "maxlength", "pattern", "patternErrorMessage", "validator", "inlineError", "disabled", "viewed", "hyperlink", "tooltip"], outputs: ["modelChange", "sdChange", "sdFocus", "sdBlur", "sdFocusForceBlur", "keyupEnter"] }, { kind: "component", type: SdInputNumber, selector: "sd-input-number", inputs: ["autoId", "name", "size", "form", "label", "helperText", "placeholder", "hideInlineError", "blurOnEnter", "model", "required", "type", "precision", "readonly", "min", "max", "validator", "inlineError", "disabled", "viewed", "hyperlink", "appearance"], outputs: ["modelChange", "sdChange", "sdFocus", "sdBlur", "sdFocusForceBlur", "keyupEnter"] }, { kind: "component", type: SdSelect, selector: "sd-select", inputs: ["autoId", "name", "appearance", "hideInlineError", "size", "form", "label", "helperText", "placeholder", "model", "items", "valueField", "displayField", "disabledField", "cacheChecksum", "required", "validator", "inlineError", "disabled", "viewed", "hyperlink", "multiple", "limit"], outputs: ["modelChange", "sdChange", "sdSelection"] }, { kind: "component", type: SdAutocomplete, selector: "sd-autocomplete", inputs: ["autoId", "name", "appearance", "size", "form", "label", "helperText", "valueField", "displayField", "disabledField", "placeholder", "items", "limit", "cacheChecksum", "model", "addable", "disabled", "viewed", "hyperlink", "required", "validator", "inlineError", "hideInlineError"], outputs: ["modelChange", "sdChange", "sdSelection", "sdAdd"] }, { kind: "component", type: SdDate, selector: "sd-date", inputs: ["autoId", "name", "appearance", "hideInlineError", "min", "max", "size", "form", "disabled", "viewed", "hyperlink", "required", "inlineError", "label", "helperText", "placeholder", "minDate", "maxDate", "model"], outputs: ["sdChange", "sdFocus", "modelChange"] }, { kind: "component", type: SdDateRange, selector: "sd-date-range", inputs: ["autoId", "name", "appearance", "size", "form", "disabled", "required", "label", "helperText", "hideInlineError", "min", "max", "model"], outputs: ["modelChange", "sdChange"] }, { kind: "component", type: SdBadge, selector: "sd-badge", inputs: ["type", "color", "primary", "secondary", "success", "info", "warning", "error", "fontSet", "title", "description", "tooltip", "icon", "size"], outputs: ["sdClick"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
231
231
  }
232
232
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: ColumnFilterComponent, decorators: [{
233
233
  type: Component,
@@ -422,7 +422,7 @@ class ExternalFilterComponent {
422
422
  });
423
423
  };
424
424
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: ExternalFilterComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
425
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: ExternalFilterComponent, isStandalone: true, selector: "external-filter", inputs: { _autoId: ["autoId", "_autoId"], _filter: ["filter", "_filter"], _externalFilters: ["externalFilters", "_externalFilters"], _filterRegister: ["filterRegister", "_filterRegister"] }, ngImport: i0, template: "@if (!filter?.disabled) {\r\n @if (!isMobileOrTablet && externalFilters.length) {\r\n <sd-section [hideHeader]=\"filter?.hideExternalFilterToolbar\" icon=\"filter_alt\" iconColor=\"secondary\" title=\"B\u1ED9 l\u1ECDc\" collapsable>\r\n <div class=\"d-flex mr-4\" sdHeaderRight>\r\n <sd-button\r\n [autoId]=\"autoId + 'clearFilter'\"\r\n [disabled]=\"!filtered\"\r\n type=\"link\"\r\n prefixIcon=\"cleaning_services\"\r\n tooltip=\"X\u00F3a l\u1EF1a ch\u1ECDn\"\r\n (click)=\"$event.stopPropagation(); clearFilter($event)\"></sd-button>\r\n <sd-button\r\n [autoId]=\"autoId + 'setting'\"\r\n type=\"link\"\r\n prefixIcon=\"settings\"\r\n tooltip=\"T\u00F9y ch\u1EC9nh\"\r\n [matMenuTriggerFor]=\"menu\"\r\n (click)=\"$event.stopPropagation()\"></sd-button>\r\n <mat-menu #menu=\"matMenu\" class=\"sd-custom-panel-filter-configuration\">\r\n @for (externalFilter of externalFilters; track externalFilter.field) {\r\n <button mat-menu-item (click)=\"onCheckboxChange($event, externalFilter)\" [disabled]=\"externalFilter.required\">\r\n <sd-checkbox\r\n [label]=\"externalFilter.title\"\r\n [model]=\"inlineExternal[externalFilter.field]\"\r\n [disabled]=\"externalFilter.required\" />\r\n </button>\r\n }\r\n </mat-menu>\r\n </div>\r\n <div class=\"row mx-0\" style=\"row-gap: 16px\">\r\n @for (item of externalFilters; track item.field) {\r\n @if (inlineExternal[item.field]) {\r\n <div class=\"col-md-3 col-sm-6 px-8\" [class.col-lg-2]=\"col === 2\" [class.col-lg-3]=\"col === 3\">\r\n @if (item.type === 'string') {\r\n <sd-input\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n type=\"text\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (keyupEnter)=\"onKeyupEnter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-input>\r\n } @else if (item.type === 'number') {\r\n <sd-input-number\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (keyupEnter)=\"onKeyupEnter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-input-number>\r\n } @else if (item.type === 'boolean') {\r\n <sd-select\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [items]=\"[\r\n { value: true, display: item.option?.displayOnTrue || 'True' },\r\n { value: false, display: item.option?.displayOnFalse || 'False' }\r\n ]\"\r\n valueField=\"value\"\r\n displayField=\"display\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-select>\r\n } @else if (item.type === 'date') {\r\n <sd-date\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n [min]=\"item.minDate\"\r\n [max]=\"item.maxDate\"\r\n hideInlineError>\r\n </sd-date>\r\n } @else if (item.type === 'datetime') {\r\n <sd-datetime\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n [min]=\"item.minDate\"\r\n [max]=\"item.maxDate\"\r\n hideInlineError>\r\n </sd-datetime>\r\n } @else if (item.type === 'daterange') {\r\n <sd-date-range\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n [min]=\"item.minDate\"\r\n [max]=\"item.maxDate\"\r\n appearance=\"outline\"\r\n hideInlineError>\r\n </sd-date-range>\r\n } @else if (item.type === 'values') {\r\n @if (item.option.selection === 'MULTIPLE') {\r\n <sd-select\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [items]=\"item.option.items | filterValues | async\"\r\n [valueField]=\"item.option.valueField\"\r\n [displayField]=\"item.option.displayField\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n multiple\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-select>\r\n } @else if (item.option.selection === 'AUTOCOMPLETE') {\r\n <sd-select\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [items]=\"item.option.items | filterValues | async\"\r\n [valueField]=\"item.option.valueField\"\r\n [displayField]=\"item.option.displayField\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-select>\r\n } @else if (item.option.selection === 'MULTIPLEAUTOCOMPLETE') {\r\n <sd-select\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [items]=\"item.option.items | filterValues | async\"\r\n [valueField]=\"item.option.valueField\"\r\n [displayField]=\"item.option.displayField\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n multiple\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-select>\r\n } @else {\r\n <sd-select\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [items]=\"item.option.items | filterValues | async\"\r\n [valueField]=\"item.option.valueField\"\r\n [displayField]=\"item.option.displayField\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-select>\r\n }\r\n } @else if (item.type === 'lazy-values') {\r\n @if (item.option.selection === 'MULTIPLE') {\r\n <sd-select\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [items]=\"item.option.items\"\r\n [valueField]=\"item.option.valueField\"\r\n [displayField]=\"item.option.displayField\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n multiple\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-select>\r\n } @else {\r\n <sd-select\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [items]=\"item.option.items\"\r\n [valueField]=\"item.option.valueField\"\r\n [displayField]=\"item.option.displayField\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-select>\r\n }\r\n } @else if (item.type === 'custom' && item.filterDef) {\r\n <ng-container\r\n *ngTemplateOutlet=\"\r\n item.filterDef;\r\n context: { form: form, externalFilter: externalFilter, autoId: autoId + item.field }\r\n \"></ng-container>\r\n }\r\n </div>\r\n }\r\n }\r\n </div>\r\n @if (filter?.manualFilter) {\r\n <div class=\"d-flex justify-content-end mt-16 px-8\">\r\n <sd-button\r\n [autoId]=\"autoId + 'onSubmit'\"\r\n [disabled]=\"form.invalid\"\r\n type=\"fill\"\r\n color=\"primary\"\r\n title=\"T\u00ECm ki\u1EBFm\"\r\n prefixIcon=\"filter_alt\"\r\n (click)=\"onSubmit()\">\r\n </sd-button>\r\n </div>\r\n }\r\n </sd-section>\r\n }\r\n <!-- <sd-popup-filter [filterRegister]=\"filterRegister!\" [columns]=\"columns\" [externalFilters]=\"externalFilters\">\r\n </sd-popup-filter> -->\r\n}\r\n", styles: [":host{display:block;padding-left:0;padding-right:0}::ng-deep .sd-custom-panel-filter-configuration{width:240px;max-height:550px;overflow-y:auto}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i2.MatMenu, selector: "mat-menu", inputs: ["backdropClass", "aria-label", "aria-labelledby", "aria-describedby", "xPosition", "yPosition", "overlapTrigger", "hasBackdrop", "class", "classList"], outputs: ["closed", "close"], exportAs: ["matMenu"] }, { kind: "component", type: i2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i2.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData", "matMenuTriggerRestoreFocus"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: SdSection, selector: "sd-section", inputs: ["title", "subTitle", "icon", "iconColor", "collapsed", "collapsable", "hideHeader"] }, { kind: "component", type: SdInput, selector: "sd-input", inputs: ["autoId", "name", "appearance", "size", "form", "label", "helperText", "placeholder", "type", "hideInlineError", "blurOnEnter", "model", "required", "readonly", "minlength", "maxlength", "pattern", "patternErrorMessage", "validator", "inlineError", "disabled", "tooltip"], outputs: ["modelChange", "sdChange", "sdFocus", "sdBlur", "sdFocusForceBlur", "keyupEnter"] }, { kind: "component", type: SdInputNumber, selector: "sd-input-number", inputs: ["autoId", "name", "size", "form", "label", "helperText", "placeholder", "hideInlineError", "blurOnEnter", "model", "required", "type", "precision", "readonly", "min", "max", "validator", "inlineError", "disabled", "appearance"], outputs: ["modelChange", "sdChange", "sdFocus", "sdBlur", "sdFocusForceBlur", "keyupEnter"] }, { kind: "component", type: SdSelect, selector: "sd-select", inputs: ["autoId", "name", "appearance", "hideInlineError", "size", "form", "label", "helperText", "placeholder", "model", "items", "valueField", "displayField", "disabledField", "cacheChecksum", "required", "validator", "inlineError", "disabled", "multiple", "limit"], outputs: ["modelChange", "sdChange", "sdSelection"] }, { kind: "component", type: SdDate, selector: "sd-date", inputs: ["autoId", "name", "appearance", "hideInlineError", "min", "max", "size", "form", "disabled", "required", "inlineError", "label", "helperText", "placeholder", "minDate", "maxDate", "model"], outputs: ["sdChange", "sdFocus", "modelChange"] }, { kind: "component", type: SdDatetime, selector: "sd-datetime", inputs: ["autoId", "name", "appearance", "hideInlineError", "min", "max", "size", "form", "disabled", "required", "inlineError", "label", "helperText", "placeholder", "minDate", "maxDate", "model"], outputs: ["sdChange", "sdFocus", "modelChange"] }, { kind: "component", type: SdDateRange$1, selector: "sd-date-range", inputs: ["autoId", "name", "appearance", "size", "form", "disabled", "required", "label", "helperText", "hideInlineError", "min", "max", "model"], outputs: ["modelChange", "sdChange"] }, { kind: "component", type: SdButton, selector: "sd-button", inputs: ["autoId", "type", "color", "title", "width", "size", "tooltip", "prefixIcon", "suffixIcon", "fontSet", "disabled", "loading"], outputs: ["click"] }, { kind: "pipe", type: FilterValuesPipe, name: "filterValues" }, { kind: "component", type: SdCheckbox, selector: "sd-checkbox", inputs: ["autoId", "name", "form", "label", "color", "disabled", "model", "inlineError"], outputs: ["modelChange", "sdChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
425
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: ExternalFilterComponent, isStandalone: true, selector: "external-filter", inputs: { _autoId: ["autoId", "_autoId"], _filter: ["filter", "_filter"], _externalFilters: ["externalFilters", "_externalFilters"], _filterRegister: ["filterRegister", "_filterRegister"] }, ngImport: i0, template: "@if (!filter?.disabled) {\r\n @if (!isMobileOrTablet && externalFilters.length) {\r\n <sd-section [hideHeader]=\"filter?.hideExternalFilterToolbar\" icon=\"filter_alt\" iconColor=\"secondary\" title=\"B\u1ED9 l\u1ECDc\" collapsable>\r\n <div class=\"d-flex mr-4\" sdHeaderRight>\r\n <sd-button\r\n [autoId]=\"autoId + 'clearFilter'\"\r\n [disabled]=\"!filtered\"\r\n type=\"link\"\r\n prefixIcon=\"cleaning_services\"\r\n tooltip=\"X\u00F3a l\u1EF1a ch\u1ECDn\"\r\n (click)=\"$event.stopPropagation(); clearFilter($event)\"></sd-button>\r\n <sd-button\r\n [autoId]=\"autoId + 'setting'\"\r\n type=\"link\"\r\n prefixIcon=\"settings\"\r\n tooltip=\"T\u00F9y ch\u1EC9nh\"\r\n [matMenuTriggerFor]=\"menu\"\r\n (click)=\"$event.stopPropagation()\"></sd-button>\r\n <mat-menu #menu=\"matMenu\" class=\"sd-custom-panel-filter-configuration\">\r\n @for (externalFilter of externalFilters; track externalFilter.field) {\r\n <button mat-menu-item (click)=\"onCheckboxChange($event, externalFilter)\" [disabled]=\"externalFilter.required\">\r\n <sd-checkbox\r\n [label]=\"externalFilter.title\"\r\n [model]=\"inlineExternal[externalFilter.field]\"\r\n [disabled]=\"externalFilter.required\" />\r\n </button>\r\n }\r\n </mat-menu>\r\n </div>\r\n <div class=\"row mx-0\" style=\"row-gap: 16px\">\r\n @for (item of externalFilters; track item.field) {\r\n @if (inlineExternal[item.field]) {\r\n <div class=\"col-md-3 col-sm-6 px-8\" [class.col-lg-2]=\"col === 2\" [class.col-lg-3]=\"col === 3\">\r\n @if (item.type === 'string') {\r\n <sd-input\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n type=\"text\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (keyupEnter)=\"onKeyupEnter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-input>\r\n } @else if (item.type === 'number') {\r\n <sd-input-number\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (keyupEnter)=\"onKeyupEnter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-input-number>\r\n } @else if (item.type === 'boolean') {\r\n <sd-select\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [items]=\"[\r\n { value: true, display: item.option?.displayOnTrue || 'True' },\r\n { value: false, display: item.option?.displayOnFalse || 'False' }\r\n ]\"\r\n valueField=\"value\"\r\n displayField=\"display\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-select>\r\n } @else if (item.type === 'date') {\r\n <sd-date\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n [min]=\"item.minDate\"\r\n [max]=\"item.maxDate\"\r\n hideInlineError>\r\n </sd-date>\r\n } @else if (item.type === 'datetime') {\r\n <sd-datetime\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n [min]=\"item.minDate\"\r\n [max]=\"item.maxDate\"\r\n hideInlineError>\r\n </sd-datetime>\r\n } @else if (item.type === 'daterange') {\r\n <sd-date-range\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n [min]=\"item.minDate\"\r\n [max]=\"item.maxDate\"\r\n appearance=\"outline\"\r\n hideInlineError>\r\n </sd-date-range>\r\n } @else if (item.type === 'values') {\r\n @if (item.option.selection === 'MULTIPLE') {\r\n <sd-select\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [items]=\"item.option.items | filterValues | async\"\r\n [valueField]=\"item.option.valueField\"\r\n [displayField]=\"item.option.displayField\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n multiple\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-select>\r\n } @else if (item.option.selection === 'AUTOCOMPLETE') {\r\n <sd-select\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [items]=\"item.option.items | filterValues | async\"\r\n [valueField]=\"item.option.valueField\"\r\n [displayField]=\"item.option.displayField\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-select>\r\n } @else if (item.option.selection === 'MULTIPLEAUTOCOMPLETE') {\r\n <sd-select\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [items]=\"item.option.items | filterValues | async\"\r\n [valueField]=\"item.option.valueField\"\r\n [displayField]=\"item.option.displayField\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n multiple\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-select>\r\n } @else {\r\n <sd-select\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [items]=\"item.option.items | filterValues | async\"\r\n [valueField]=\"item.option.valueField\"\r\n [displayField]=\"item.option.displayField\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-select>\r\n }\r\n } @else if (item.type === 'lazy-values') {\r\n @if (item.option.selection === 'MULTIPLE') {\r\n <sd-select\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [items]=\"item.option.items\"\r\n [valueField]=\"item.option.valueField\"\r\n [displayField]=\"item.option.displayField\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n multiple\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-select>\r\n } @else {\r\n <sd-select\r\n [autoId]=\"autoId + item.field\"\r\n [label]=\"item.title\"\r\n [items]=\"item.option.items\"\r\n [valueField]=\"item.option.valueField\"\r\n [displayField]=\"item.option.displayField\"\r\n [(model)]=\"externalFilter![item.field]\"\r\n (sdChange)=\"onFilter()\"\r\n appearance=\"outline\"\r\n [form]=\"form\"\r\n [required]=\"item.required\"\r\n hideInlineError>\r\n </sd-select>\r\n }\r\n } @else if (item.type === 'custom' && item.filterDef) {\r\n <ng-container\r\n *ngTemplateOutlet=\"\r\n item.filterDef;\r\n context: { form: form, externalFilter: externalFilter, autoId: autoId + item.field }\r\n \"></ng-container>\r\n }\r\n </div>\r\n }\r\n }\r\n </div>\r\n @if (filter?.manualFilter) {\r\n <div class=\"d-flex justify-content-end mt-16 px-8\">\r\n <sd-button\r\n [autoId]=\"autoId + 'onSubmit'\"\r\n [disabled]=\"form.invalid\"\r\n type=\"fill\"\r\n color=\"primary\"\r\n title=\"T\u00ECm ki\u1EBFm\"\r\n prefixIcon=\"filter_alt\"\r\n (click)=\"onSubmit()\">\r\n </sd-button>\r\n </div>\r\n }\r\n </sd-section>\r\n }\r\n <!-- <sd-popup-filter [filterRegister]=\"filterRegister!\" [columns]=\"columns\" [externalFilters]=\"externalFilters\">\r\n </sd-popup-filter> -->\r\n}\r\n", styles: [":host{display:block;padding-left:0;padding-right:0}::ng-deep .sd-custom-panel-filter-configuration{width:240px;max-height:550px;overflow-y:auto}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i2.MatMenu, selector: "mat-menu", inputs: ["backdropClass", "aria-label", "aria-labelledby", "aria-describedby", "xPosition", "yPosition", "overlapTrigger", "hasBackdrop", "class", "classList"], outputs: ["closed", "close"], exportAs: ["matMenu"] }, { kind: "component", type: i2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i2.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData", "matMenuTriggerRestoreFocus"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: SdSection, selector: "sd-section", inputs: ["title", "subTitle", "icon", "iconColor", "collapsed", "collapsable", "hideHeader"] }, { kind: "component", type: SdInput, selector: "sd-input", inputs: ["autoId", "name", "appearance", "size", "form", "label", "helperText", "placeholder", "type", "hideInlineError", "blurOnEnter", "model", "required", "readonly", "minlength", "maxlength", "pattern", "patternErrorMessage", "validator", "inlineError", "disabled", "viewed", "hyperlink", "tooltip"], outputs: ["modelChange", "sdChange", "sdFocus", "sdBlur", "sdFocusForceBlur", "keyupEnter"] }, { kind: "component", type: SdInputNumber, selector: "sd-input-number", inputs: ["autoId", "name", "size", "form", "label", "helperText", "placeholder", "hideInlineError", "blurOnEnter", "model", "required", "type", "precision", "readonly", "min", "max", "validator", "inlineError", "disabled", "viewed", "hyperlink", "appearance"], outputs: ["modelChange", "sdChange", "sdFocus", "sdBlur", "sdFocusForceBlur", "keyupEnter"] }, { kind: "component", type: SdSelect, selector: "sd-select", inputs: ["autoId", "name", "appearance", "hideInlineError", "size", "form", "label", "helperText", "placeholder", "model", "items", "valueField", "displayField", "disabledField", "cacheChecksum", "required", "validator", "inlineError", "disabled", "viewed", "hyperlink", "multiple", "limit"], outputs: ["modelChange", "sdChange", "sdSelection"] }, { kind: "component", type: SdDate, selector: "sd-date", inputs: ["autoId", "name", "appearance", "hideInlineError", "min", "max", "size", "form", "disabled", "viewed", "hyperlink", "required", "inlineError", "label", "helperText", "placeholder", "minDate", "maxDate", "model"], outputs: ["sdChange", "sdFocus", "modelChange"] }, { kind: "component", type: SdDatetime, selector: "sd-datetime", inputs: ["autoId", "name", "appearance", "hideInlineError", "min", "max", "size", "form", "disabled", "viewed", "hyperlink", "required", "inlineError", "label", "helperText", "placeholder", "minDate", "maxDate", "model"], outputs: ["sdChange", "sdFocus", "modelChange"] }, { kind: "component", type: SdDateRange$1, selector: "sd-date-range", inputs: ["autoId", "name", "appearance", "size", "form", "disabled", "required", "label", "helperText", "hideInlineError", "min", "max", "model"], outputs: ["modelChange", "sdChange"] }, { kind: "component", type: SdButton, selector: "sd-button", inputs: ["autoId", "type", "color", "title", "width", "size", "tooltip", "prefixIcon", "suffixIcon", "fontSet", "disabled", "loading"], outputs: ["click"] }, { kind: "pipe", type: FilterValuesPipe, name: "filterValues" }, { kind: "component", type: SdCheckbox, selector: "sd-checkbox", inputs: ["autoId", "name", "form", "label", "color", "disabled", "model", "inlineError"], outputs: ["modelChange", "sdChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
426
426
  }
427
427
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: ExternalFilterComponent, decorators: [{
428
428
  type: Component,
@@ -767,7 +767,7 @@ class ConfigComponent {
767
767
  this.dragDisabled = true;
768
768
  }
769
769
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: ConfigComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i1$2.SdConfirmService }, { token: ConfigService }], target: i0.ɵɵFactoryTarget.Component });
770
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: ConfigComponent, isStandalone: true, selector: "config", inputs: { tableOption: "tableOption" }, host: { listeners: { "window:mouseup": "mouseUp($event)" } }, providers: [ConfigService], viewQueries: [{ propertyName: "modal", first: true, predicate: SdModal, descendants: true }, { propertyName: "table", first: true, predicate: ["table"], descendants: true }], ngImport: i0, template: "<sd-modal width=\"sm\" [title]=\"'Thi\u1EBFt l\u1EADp b\u1EA3ng'\" #modal>\r\n @if (configuration) {\r\n <div class=\"c-container\">\r\n <div class=\"c-table\" style=\"max-height: 70vh\">\r\n <table\r\n #table\r\n mat-table\r\n [dataSource]=\"configuration.columns!\"\r\n cdkDropList\r\n [cdkDropListData]=\"configuration.columns\"\r\n (cdkDropListDropped)=\"dropTable($event)\">\r\n >\r\n <!-- <ng-container matColumnDef=\"stt\">\r\n <th mat-header-cell class=\"c-th text-center px-4\" *matHeaderCellDef style=\"width: 50px\">#</th>\r\n <td class=\"text-center px-4\" mat-cell *matCellDef=\"let item; let idx = index\"></td>\r\n </ng-container> -->\r\n <ng-container matColumnDef=\"invisible\">\r\n <th mat-header-cell class=\"c-th text-center px-4\" *matHeaderCellDef style=\"width: 96px\">\r\n {{ 'Hi\u1EC3n th\u1ECB' }}\r\n </th>\r\n <td class=\"text-center px-4\" mat-cell *matCellDef=\"let item\">\r\n <div class=\"d-flex\" style=\"gap: 8px\">\r\n <div class=\"c-handle\" (mousedown)=\"handleMouseDown()\" (mouseup)=\"handleMouseUp()\">\r\n <svg xmlns=\"http://www.w3.org/2000/svg\" height=\"24px\" viewBox=\"0 0 24 24\" width=\"24px\" fill=\"#5f6368\">\r\n <path d=\"M0 0h24v24H0V0z\" fill=\"none\" />\r\n <path\r\n d=\"M11 18c0 1.1-.9 2-2 2s-2-.9-2-2 .9-2 2-2 2 .9 2 2zm-2-8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0-6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm6 4c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z\" />\r\n </svg>\r\n </div>\r\n <sd-switch [model]=\"!item.invisible\" (modelChange)=\"item.invisible = !item.invisible\" />\r\n </div>\r\n </td>\r\n </ng-container>\r\n <ng-container matColumnDef=\"title\">\r\n <th mat-header-cell class=\"c-th px-4\" *matHeaderCellDef>\r\n {{ 'Ti\u00EAu \u0111\u1EC1 c\u1ED9t' }}\r\n </th>\r\n <td class=\"px-4\" mat-cell *matCellDef=\"let item\">\r\n <sd-input class=\"pb-5\" [placeholder]=\"item?.origin?.title\" [(model)]=\"item.title\" hideInlineError></sd-input>\r\n </td>\r\n </ng-container>\r\n <ng-container matColumnDef=\"width\">\r\n <th mat-header-cell class=\"c-th px-4\" *matHeaderCellDef style=\"width: 80px\">\r\n {{ 'R\u1ED9ng' }}\r\n </th>\r\n <td class=\"px-4\" mat-cell *matCellDef=\"let item\">\r\n <sd-input class=\"pb-5\" [placeholder]=\"item?.origin?.width\" [(model)]=\"item.width\" hideInlineError></sd-input>\r\n </td>\r\n </ng-container>\r\n <ng-container matColumnDef=\"fixed\">\r\n <th mat-header-cell class=\"c-th text-center px-4\" *matHeaderCellDef style=\"width: 80px\">\r\n {{ 'C\u1ED1 \u0111\u1ECBnh' }}\r\n </th>\r\n <td class=\"text-center px-4\" mat-cell *matCellDef=\"let item\">\r\n <sd-switch [(model)]=\"item.fixed\" />\r\n </td>\r\n </ng-container>\r\n <tr mat-header-row *matHeaderRowDef=\"['invisible', 'title', 'width', 'fixed']; sticky: true\"></tr>\r\n <tr\r\n mat-row\r\n *matRowDef=\"let row; columns: ['invisible', 'title', 'width', 'fixed']\"\r\n cdkDrag\r\n [cdkDragData]=\"row\"\r\n cdkDragLockAxis=\"y\"\r\n [cdkDragDisabled]=\"dragDisabled\"></tr>\r\n </table>\r\n </div>\r\n </div>\r\n }\r\n <ng-container sdFooter>\r\n <sd-button class=\"mr-8\" (click)=\"close()\" title=\"B\u1ECF qua\" color=\"secondary\"> </sd-button>\r\n <sd-button class=\"mr-8\" (click)=\"onReset()\" title=\"M\u1EB7c \u0111\u1ECBnh\" color=\"primary\"> </sd-button>\r\n <sd-button (click)=\"onSave()\" title=\"\u00C1p d\u1EE5ng\" type=\"fill\" color=\"primary\"> </sd-button>\r\n </ng-container>\r\n</sd-modal>\r\n", styles: [".c-table{position:relative;overflow:auto}.c-table table{width:100%}.c-table .c-th{font-weight:500;font-size:14px;line-height:20px;color:#000}.c-container{position:relative;min-height:200px}.c-handle{color:#ccc;cursor:move}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: MatTableModule }, { kind: "component", type: i3$1.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { kind: "directive", type: i3$1.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i3$1.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { kind: "directive", type: i3$1.MatColumnDef, selector: "[matColumnDef]", inputs: ["matColumnDef"] }, { kind: "directive", type: i3$1.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i3$1.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { kind: "directive", type: i3$1.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i3$1.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "component", type: i3$1.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { kind: "component", type: i3$1.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { kind: "ngmodule", type: MatSlideToggleModule }, { kind: "ngmodule", type: CdkTableModule }, { kind: "ngmodule", type: DragDropModule }, { kind: "directive", type: i4.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep", "cdkDropListElementContainer"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { kind: "directive", type: i4.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer", "cdkDragScale"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "component", type: SdButton, selector: "sd-button", inputs: ["autoId", "type", "color", "title", "width", "size", "tooltip", "prefixIcon", "suffixIcon", "fontSet", "disabled", "loading"], outputs: ["click"] }, { kind: "component", type: SdInput, selector: "sd-input", inputs: ["autoId", "name", "appearance", "size", "form", "label", "helperText", "placeholder", "type", "hideInlineError", "blurOnEnter", "model", "required", "readonly", "minlength", "maxlength", "pattern", "patternErrorMessage", "validator", "inlineError", "disabled", "tooltip"], outputs: ["modelChange", "sdChange", "sdFocus", "sdBlur", "sdFocusForceBlur", "keyupEnter"] }, { kind: "component", type: SdModal, selector: "sd-modal", inputs: ["title", "color", "width", "height", "view", "lazyLoadContent"], outputs: ["sdClosed"] }, { kind: "component", type: SdSwitch, selector: "sd-switch", inputs: ["autoId", "name", "size", "form", "label", "color", "disabled", "model", "hideInlineError", "required"], outputs: ["modelChange", "sdChange"] }] });
770
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: ConfigComponent, isStandalone: true, selector: "config", inputs: { tableOption: "tableOption" }, host: { listeners: { "window:mouseup": "mouseUp($event)" } }, providers: [ConfigService], viewQueries: [{ propertyName: "modal", first: true, predicate: SdModal, descendants: true }, { propertyName: "table", first: true, predicate: ["table"], descendants: true }], ngImport: i0, template: "<sd-modal width=\"sm\" [title]=\"'Thi\u1EBFt l\u1EADp b\u1EA3ng'\" #modal>\r\n @if (configuration) {\r\n <div class=\"c-container\">\r\n <div class=\"c-table\" style=\"max-height: 70vh\">\r\n <table\r\n #table\r\n mat-table\r\n [dataSource]=\"configuration.columns!\"\r\n cdkDropList\r\n [cdkDropListData]=\"configuration.columns\"\r\n (cdkDropListDropped)=\"dropTable($event)\">\r\n >\r\n <!-- <ng-container matColumnDef=\"stt\">\r\n <th mat-header-cell class=\"c-th text-center px-4\" *matHeaderCellDef style=\"width: 50px\">#</th>\r\n <td class=\"text-center px-4\" mat-cell *matCellDef=\"let item; let idx = index\"></td>\r\n </ng-container> -->\r\n <ng-container matColumnDef=\"invisible\">\r\n <th mat-header-cell class=\"c-th text-center px-4\" *matHeaderCellDef style=\"width: 96px\">\r\n {{ 'Hi\u1EC3n th\u1ECB' }}\r\n </th>\r\n <td class=\"text-center px-4\" mat-cell *matCellDef=\"let item\">\r\n <div class=\"d-flex\" style=\"gap: 8px\">\r\n <div class=\"c-handle\" (mousedown)=\"handleMouseDown()\" (mouseup)=\"handleMouseUp()\">\r\n <svg xmlns=\"http://www.w3.org/2000/svg\" height=\"24px\" viewBox=\"0 0 24 24\" width=\"24px\" fill=\"#5f6368\">\r\n <path d=\"M0 0h24v24H0V0z\" fill=\"none\" />\r\n <path\r\n d=\"M11 18c0 1.1-.9 2-2 2s-2-.9-2-2 .9-2 2-2 2 .9 2 2zm-2-8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0-6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm6 4c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z\" />\r\n </svg>\r\n </div>\r\n <sd-switch [model]=\"!item.invisible\" (modelChange)=\"item.invisible = !item.invisible\" />\r\n </div>\r\n </td>\r\n </ng-container>\r\n <ng-container matColumnDef=\"title\">\r\n <th mat-header-cell class=\"c-th px-4\" *matHeaderCellDef>\r\n {{ 'Ti\u00EAu \u0111\u1EC1 c\u1ED9t' }}\r\n </th>\r\n <td class=\"px-4\" mat-cell *matCellDef=\"let item\">\r\n <sd-input class=\"pb-5\" [placeholder]=\"item?.origin?.title\" [(model)]=\"item.title\" hideInlineError></sd-input>\r\n </td>\r\n </ng-container>\r\n <ng-container matColumnDef=\"width\">\r\n <th mat-header-cell class=\"c-th px-4\" *matHeaderCellDef style=\"width: 80px\">\r\n {{ 'R\u1ED9ng' }}\r\n </th>\r\n <td class=\"px-4\" mat-cell *matCellDef=\"let item\">\r\n <sd-input class=\"pb-5\" [placeholder]=\"item?.origin?.width\" [(model)]=\"item.width\" hideInlineError></sd-input>\r\n </td>\r\n </ng-container>\r\n <ng-container matColumnDef=\"fixed\">\r\n <th mat-header-cell class=\"c-th text-center px-4\" *matHeaderCellDef style=\"width: 80px\">\r\n {{ 'C\u1ED1 \u0111\u1ECBnh' }}\r\n </th>\r\n <td class=\"text-center px-4\" mat-cell *matCellDef=\"let item\">\r\n <sd-switch [(model)]=\"item.fixed\" />\r\n </td>\r\n </ng-container>\r\n <tr mat-header-row *matHeaderRowDef=\"['invisible', 'title', 'width', 'fixed']; sticky: true\"></tr>\r\n <tr\r\n mat-row\r\n *matRowDef=\"let row; columns: ['invisible', 'title', 'width', 'fixed']\"\r\n cdkDrag\r\n [cdkDragData]=\"row\"\r\n cdkDragLockAxis=\"y\"\r\n [cdkDragDisabled]=\"dragDisabled\"></tr>\r\n </table>\r\n </div>\r\n </div>\r\n }\r\n <ng-container sdFooter>\r\n <sd-button class=\"mr-8\" (click)=\"close()\" title=\"B\u1ECF qua\" color=\"secondary\"> </sd-button>\r\n <sd-button class=\"mr-8\" (click)=\"onReset()\" title=\"M\u1EB7c \u0111\u1ECBnh\" color=\"primary\"> </sd-button>\r\n <sd-button (click)=\"onSave()\" title=\"\u00C1p d\u1EE5ng\" type=\"fill\" color=\"primary\"> </sd-button>\r\n </ng-container>\r\n</sd-modal>\r\n", styles: [".c-table{position:relative;overflow:auto}.c-table table{width:100%}.c-table .c-th{font-weight:500;font-size:14px;line-height:20px;color:#000}.c-container{position:relative;min-height:200px}.c-handle{color:#ccc;cursor:move}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: MatTableModule }, { kind: "component", type: i3$1.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { kind: "directive", type: i3$1.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i3$1.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { kind: "directive", type: i3$1.MatColumnDef, selector: "[matColumnDef]", inputs: ["matColumnDef"] }, { kind: "directive", type: i3$1.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i3$1.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { kind: "directive", type: i3$1.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i3$1.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "component", type: i3$1.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { kind: "component", type: i3$1.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { kind: "ngmodule", type: MatSlideToggleModule }, { kind: "ngmodule", type: CdkTableModule }, { kind: "ngmodule", type: DragDropModule }, { kind: "directive", type: i4.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep", "cdkDropListElementContainer"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { kind: "directive", type: i4.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer", "cdkDragScale"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "component", type: SdButton, selector: "sd-button", inputs: ["autoId", "type", "color", "title", "width", "size", "tooltip", "prefixIcon", "suffixIcon", "fontSet", "disabled", "loading"], outputs: ["click"] }, { kind: "component", type: SdInput, selector: "sd-input", inputs: ["autoId", "name", "appearance", "size", "form", "label", "helperText", "placeholder", "type", "hideInlineError", "blurOnEnter", "model", "required", "readonly", "minlength", "maxlength", "pattern", "patternErrorMessage", "validator", "inlineError", "disabled", "viewed", "hyperlink", "tooltip"], outputs: ["modelChange", "sdChange", "sdFocus", "sdBlur", "sdFocusForceBlur", "keyupEnter"] }, { kind: "component", type: SdModal, selector: "sd-modal", inputs: ["title", "color", "width", "height", "view", "lazyLoadContent"], outputs: ["sdClosed"] }, { kind: "component", type: SdSwitch, selector: "sd-switch", inputs: ["autoId", "name", "size", "form", "label", "color", "disabled", "model", "hideInlineError", "required"], outputs: ["modelChange", "sdChange"] }] });
771
771
  }
772
772
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: ConfigComponent, decorators: [{
773
773
  type: Component,
@@ -1371,7 +1371,7 @@ class SdPopupExport {
1371
1371
  return '';
1372
1372
  };
1373
1373
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: SdPopupExport, deps: [{ token: i0.ChangeDetectorRef }, { token: i1$1.SdLoadingService }, { token: i1$1.SdExcelService }, { token: i1$1.SdNotifyService }, { token: i1$1.SdConfirmService }], target: i0.ɵɵFactoryTarget.Component });
1374
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.17", type: SdPopupExport, isStandalone: true, selector: "sd-popup-export", inputs: { _tableOption: ["tableOption", "_tableOption"], configuration: "configuration" }, outputs: { export: "export" }, viewQueries: [{ propertyName: "modal", first: true, predicate: ["modal"], descendants: true }, { propertyName: "listGroups", first: true, predicate: ["listGroups"], descendants: true }], ngImport: i0, template: "<sd-modal width=\"907px\" [title]=\"'Exported template'\" #modal>\n <div class=\"row\">\n <div *ngIf=\"!files?.length\" class=\"col-12\">\n <div class=\"c-empty\">\n <img class=\"c-empty-image\" alt=\"empty-image\" />\n <div class=\"T14R\">{{ 'There are no exported templates' }}</div>\n </div>\n </div>\n <ng-container *ngIf=\"files?.length\">\n <div class=\"col-12\">\n <div class=\"c-table\" style=\"max-height: 50vh\">\n <table mat-table [dataSource]=\"files\">\n <ng-container matColumnDef=\"stt\">\n <th mat-header-cell class=\"c-th text-center px-5\" *matHeaderCellDef style=\"width: 50px\">#</th>\n <td class=\"text-center px-5\" mat-cell *matCellDef=\"let item; let idx = index\">\n {{ idx + 1 }}\n </td>\n </ng-container>\n <ng-container matColumnDef=\"fileName\">\n <th mat-header-cell class=\"c-th px-5\" *matHeaderCellDef>\n {{ 'File name' }}\n </th>\n <td class=\"px-5\" mat-cell *matCellDef=\"let item\">\n {{ item.fileName }}\n </td>\n </ng-container>\n <ng-container matColumnDef=\"action\">\n <th mat-header-cell class=\"c-th px-5\" *matHeaderCellDef style=\"width: 80px\"></th>\n <td class=\"px-5\" mat-cell *matCellDef=\"let item\">\n <div class=\"d-flex\">\n <button mat-icon-button aria-label=\"delete\" (click)=\"removeFile(item)\">\n <mat-icon>delete</mat-icon>\n </button>\n <button mat-icon-button aria-label=\"download\" (click)=\"onExport(item)\">\n <mat-icon>download</mat-icon>\n </button>\n </div>\n </td>\n </ng-container>\n <tr mat-header-row *matHeaderRowDef=\"['stt', 'fileName', 'action']; sticky: true\"></tr>\n <tr mat-row *matRowDef=\"let row; columns: ['stt', 'fileName', 'action']\"></tr>\n </table>\n </div>\n </div>\n <div *ngIf=\"files.length < 5\" class=\"col-12 mt-10\">\n <sd-button class=\"mr-4\" [title]=\"'New template'\" (click)=\"enableCreating = true\" color=\"info\" [disabled]=\"enableCreating\">\n </sd-button>\n <sd-button *ngIf=\"exportOption?.enableUpload\" [title]=\"'Upload template'\" (click)=\"uploadTemplate()\" type=\"outline\">\n </sd-button>\n </div>\n </ng-container>\n <ng-container *ngIf=\"enableCreating || !files?.length\">\n <div class=\"col-12 mt-20\">\n <div class=\"T14R\">{{ 'Select columns for creating template' }}:</div>\n </div>\n <div class=\"col-12\">\n <mat-chip-listbox selectable=\"true\" multiple=\"true\">\n <ng-container *ngFor=\"let column of columns\">\n <mat-chip-option [selected]=\"selected[column.field]\" (click)=\"selected[column.field] = !selected[column.field]\">\n {{ column.title }}\n </mat-chip-option>\n </ng-container>\n </mat-chip-listbox>\n </div>\n <div class=\"col-12 row\">\n <div class=\"col-10\">\n <sd-input [form]=\"form\" [label]=\"'Template name'\" [(model)]=\"templateName\" [validator]=\"templateNameValidator\"></sd-input>\n </div>\n <div class=\"col-2 mt-8\">\n <sd-button width=\"100%\" [title]=\"'Save'\" color=\"info\" (click)=\"createTemplate()\"> </sd-button>\n </div>\n </div>\n </ng-container>\n </div>\n</sd-modal>\n", styles: [".c-radio-group{display:flex;flex-direction:column;margin:15px 0}.c-radio-button{margin:5px}.c-empty{display:flex;flex-direction:column;justify-content:center;align-items:center;position:static;height:116px;background:#f6f6f6;border-radius:4px}.c-empty .c-empty-image{content:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAD8AAAA6CAYAAAAHkoFsAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAABCiSURBVHgB7VtLj2VVFV5rn0tXJ902ktjppgEJ0iRAGgUsiQk/wJGPhBgxxJg4ZqYDRjqXmSMTTRyYGGYOYODE+AiI4RFaIDSgNII8BIzBQDdQdc/eru/71j637IKuOt0VGegJ1H2cffbda+31+Na3dpv9D18+Z/BzL/ztgeJezVrlw+6ju7XW8J21Ev/74GNreF+ae6utlFpiiHsZMRLj4k8tHvcLn6uYI2aL9xXjqtX4HA+55q14P8Rv4YePHL7sB7ZHV5k1urVSaxtClKFhyRYSNPOQqcQfzOUhSugHklSv8eq1hjSx8rEOLcfEg6XGBFAN1sA5+B7ThK4KNyVkj9fCNeZvzFzvngoP4WgrDYvighqFxTZCiFbGWHwbsVESqPK1lgKVSIgh9FZiOBRQugI0c0tB43PlZ/d8vmqtsyx1p2sxZ3CV9p37CxXQnOObkBsbWmH1xt2yOjbIi+3HomND427RW6v42nkDCqBjwNLhH6HPQv+pUFAMbXARTApr2tOdnyW8aefhudxFp7O6XDoExcqrVDMaNELDraM83cpQESwaNtPo5iWUJl+GKcQOx/8GN+dGw/fxeaB6EGagoT28ZmkSPie/azTxlr6o19ji2GvohP6JjY3Fj3ABbiq3daDS4vka30FYrzLnUBGMJuag2dM9sPvQUxgNrKqEWe2p2c8Sfuw+Df+GAuCvGayoBAaxSj+t8dpk2V6pkDpIga7flE+UDJaDy6ocOoxnOabRZaDHSkVWxYePR/jC5TnN03KxtgpEIQOc06kU7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KvxdVCdOrna7KbncR9d3HswK0pLLp8+w2KrwL7QdfF9oaOU6dX0v0XPPgzp5fcwNep5BobVXAg7Ekd6tMMVlMpmVWaKvEnGnCLOtYpbgkUFOBxMia01YNgb2+Zk36u4dPtu0zuFAb9zfRH4ELdZPkg6KvkCpeV0jQtvwzE5XrBAFj8tdVvL29Ek70ik+nllipM21ZnvLhOR4SfUoUPix/dOL48b+cT56LP4omn83jVMQB6fsANiXJTXUUrBMevSTN/n3juTpGdbIwaHjCBTxpz/j6yrh/DIQCMbPpdI6zR6HUVdnBUHBzxeODOy19VqrzZGC72NP3mQXykFDJlgboE36u6vErU/QssOXcDxWoNEgyZCJI4rlsgGbj0voZoTyZrfP7OceQVSZ1ttzcawJzatgkLN2iF5PatfuyXxmEmnRjVny975b4RznReBZDViLBrJOiSVpSK/zHFkxbaowk2LEt1T8tjuTRJbvw6Hlm77a1D6OFKwAKbabdmdJ9dl5cDKzUlv8mR2J0lKas0HRnalqo6dfzRcg75leyPxVMiZrZuWHATbbHl9ELtv9fH339G/7DwlISq4BTAAAAAElFTkSuQmCC)}.c-table{position:relative;overflow:auto}.c-table table{width:100%}.c-table .c-th{font-weight:500;font-size:14px;line-height:20px;color:#000}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: MatTableModule }, { kind: "component", type: i3$1.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { kind: "directive", type: i3$1.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i3$1.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { kind: "directive", type: i3$1.MatColumnDef, selector: "[matColumnDef]", inputs: ["matColumnDef"] }, { kind: "directive", type: i3$1.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i3$1.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { kind: "directive", type: i3$1.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i3$1.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "component", type: i3$1.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { kind: "component", type: i3$1.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatChipsModule }, { kind: "component", type: i5.MatChipListbox, selector: "mat-chip-listbox", inputs: ["multiple", "aria-orientation", "selectable", "compareWith", "required", "hideSingleSelectionIndicator", "value"], outputs: ["change"] }, { kind: "component", type: i5.MatChipOption, selector: "mat-basic-chip-option, [mat-basic-chip-option], mat-chip-option, [mat-chip-option]", inputs: ["selectable", "selected"], outputs: ["selectionChange"] }, { kind: "component", type: SdButton, selector: "sd-button", inputs: ["autoId", "type", "color", "title", "width", "size", "tooltip", "prefixIcon", "suffixIcon", "fontSet", "disabled", "loading"], outputs: ["click"] }, { kind: "component", type: SdInput, selector: "sd-input", inputs: ["autoId", "name", "appearance", "size", "form", "label", "helperText", "placeholder", "type", "hideInlineError", "blurOnEnter", "model", "required", "readonly", "minlength", "maxlength", "pattern", "patternErrorMessage", "validator", "inlineError", "disabled", "tooltip"], outputs: ["modelChange", "sdChange", "sdFocus", "sdBlur", "sdFocusForceBlur", "keyupEnter"] }, { kind: "component", type: SdModal, selector: "sd-modal", inputs: ["title", "color", "width", "height", "view", "lazyLoadContent"], outputs: ["sdClosed"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1374
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.17", type: SdPopupExport, isStandalone: true, selector: "sd-popup-export", inputs: { _tableOption: ["tableOption", "_tableOption"], configuration: "configuration" }, outputs: { export: "export" }, viewQueries: [{ propertyName: "modal", first: true, predicate: ["modal"], descendants: true }, { propertyName: "listGroups", first: true, predicate: ["listGroups"], descendants: true }], ngImport: i0, template: "<sd-modal width=\"907px\" [title]=\"'Exported template'\" #modal>\n <div class=\"row\">\n <div *ngIf=\"!files?.length\" class=\"col-12\">\n <div class=\"c-empty\">\n <img class=\"c-empty-image\" alt=\"empty-image\" />\n <div class=\"T14R\">{{ 'There are no exported templates' }}</div>\n </div>\n </div>\n <ng-container *ngIf=\"files?.length\">\n <div class=\"col-12\">\n <div class=\"c-table\" style=\"max-height: 50vh\">\n <table mat-table [dataSource]=\"files\">\n <ng-container matColumnDef=\"stt\">\n <th mat-header-cell class=\"c-th text-center px-5\" *matHeaderCellDef style=\"width: 50px\">#</th>\n <td class=\"text-center px-5\" mat-cell *matCellDef=\"let item; let idx = index\">\n {{ idx + 1 }}\n </td>\n </ng-container>\n <ng-container matColumnDef=\"fileName\">\n <th mat-header-cell class=\"c-th px-5\" *matHeaderCellDef>\n {{ 'File name' }}\n </th>\n <td class=\"px-5\" mat-cell *matCellDef=\"let item\">\n {{ item.fileName }}\n </td>\n </ng-container>\n <ng-container matColumnDef=\"action\">\n <th mat-header-cell class=\"c-th px-5\" *matHeaderCellDef style=\"width: 80px\"></th>\n <td class=\"px-5\" mat-cell *matCellDef=\"let item\">\n <div class=\"d-flex\">\n <button mat-icon-button aria-label=\"delete\" (click)=\"removeFile(item)\">\n <mat-icon>delete</mat-icon>\n </button>\n <button mat-icon-button aria-label=\"download\" (click)=\"onExport(item)\">\n <mat-icon>download</mat-icon>\n </button>\n </div>\n </td>\n </ng-container>\n <tr mat-header-row *matHeaderRowDef=\"['stt', 'fileName', 'action']; sticky: true\"></tr>\n <tr mat-row *matRowDef=\"let row; columns: ['stt', 'fileName', 'action']\"></tr>\n </table>\n </div>\n </div>\n <div *ngIf=\"files.length < 5\" class=\"col-12 mt-10\">\n <sd-button class=\"mr-4\" [title]=\"'New template'\" (click)=\"enableCreating = true\" color=\"info\" [disabled]=\"enableCreating\">\n </sd-button>\n <sd-button *ngIf=\"exportOption?.enableUpload\" [title]=\"'Upload template'\" (click)=\"uploadTemplate()\" type=\"outline\">\n </sd-button>\n </div>\n </ng-container>\n <ng-container *ngIf=\"enableCreating || !files?.length\">\n <div class=\"col-12 mt-20\">\n <div class=\"T14R\">{{ 'Select columns for creating template' }}:</div>\n </div>\n <div class=\"col-12\">\n <mat-chip-listbox selectable=\"true\" multiple=\"true\">\n <ng-container *ngFor=\"let column of columns\">\n <mat-chip-option [selected]=\"selected[column.field]\" (click)=\"selected[column.field] = !selected[column.field]\">\n {{ column.title }}\n </mat-chip-option>\n </ng-container>\n </mat-chip-listbox>\n </div>\n <div class=\"col-12 row\">\n <div class=\"col-10\">\n <sd-input [form]=\"form\" [label]=\"'Template name'\" [(model)]=\"templateName\" [validator]=\"templateNameValidator\"></sd-input>\n </div>\n <div class=\"col-2 mt-8\">\n <sd-button width=\"100%\" [title]=\"'Save'\" color=\"info\" (click)=\"createTemplate()\"> </sd-button>\n </div>\n </div>\n </ng-container>\n </div>\n</sd-modal>\n", styles: [".c-radio-group{display:flex;flex-direction:column;margin:15px 0}.c-radio-button{margin:5px}.c-empty{display:flex;flex-direction:column;justify-content:center;align-items:center;position:static;height:116px;background:#f6f6f6;border-radius:4px}.c-empty .c-empty-image{content:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAD8AAAA6CAYAAAAHkoFsAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAABCiSURBVHgB7VtLj2VVFV5rn0tXJ902ktjppgEJ0iRAGgUsiQk/wJGPhBgxxJg4ZqYDRjqXmSMTTRyYGGYOYODE+AiI4RFaIDSgNII8BIzBQDdQdc/eru/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b4RznReBZDViLBrJOiSVpSK/zHFkxbaowk2LEt1T8tjuTRJbvw6Hlm77a1D6OFKwAKbabdmdJ9dl5cDKzUlv8mR2J0lKas0HRnalqo6dfzRcg75leyPxVMiZrZuWHATbbHl9ELtv9fH339G/7DwlISq4BTAAAAAElFTkSuQmCC)}.c-table{position:relative;overflow:auto}.c-table table{width:100%}.c-table .c-th{font-weight:500;font-size:14px;line-height:20px;color:#000}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: MatTableModule }, { kind: "component", type: i3$1.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { kind: "directive", type: i3$1.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i3$1.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { kind: "directive", type: i3$1.MatColumnDef, selector: "[matColumnDef]", inputs: ["matColumnDef"] }, { kind: "directive", type: i3$1.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i3$1.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { kind: "directive", type: i3$1.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i3$1.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "component", type: i3$1.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { kind: "component", type: i3$1.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatChipsModule }, { kind: "component", type: i5.MatChipListbox, selector: "mat-chip-listbox", inputs: ["multiple", "aria-orientation", "selectable", "compareWith", "required", "hideSingleSelectionIndicator", "value"], outputs: ["change"] }, { kind: "component", type: i5.MatChipOption, selector: "mat-basic-chip-option, [mat-basic-chip-option], mat-chip-option, [mat-chip-option]", inputs: ["selectable", "selected"], outputs: ["selectionChange"] }, { kind: "component", type: SdButton, selector: "sd-button", inputs: ["autoId", "type", "color", "title", "width", "size", "tooltip", "prefixIcon", "suffixIcon", "fontSet", "disabled", "loading"], outputs: ["click"] }, { kind: "component", type: SdInput, selector: "sd-input", inputs: ["autoId", "name", "appearance", "size", "form", "label", "helperText", "placeholder", "type", "hideInlineError", "blurOnEnter", "model", "required", "readonly", "minlength", "maxlength", "pattern", "patternErrorMessage", "validator", "inlineError", "disabled", "viewed", "hyperlink", "tooltip"], outputs: ["modelChange", "sdChange", "sdFocus", "sdBlur", "sdFocusForceBlur", "keyupEnter"] }, { kind: "component", type: SdModal, selector: "sd-modal", inputs: ["title", "color", "width", "height", "view", "lazyLoadContent"], outputs: ["sdClosed"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1375
1375
  }
1376
1376
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: SdPopupExport, decorators: [{
1377
1377
  type: Component,
@@ -2096,7 +2096,8 @@ class SdTable extends SdBaseSecureComponent {
2096
2096
  option.filter.hideInlineFilter = option?.filter?.hideInlineFilter ?? this.tableConfiguration?.filter?.hideInlineFilter;
2097
2097
  option.filter.externalFilterPerRow = option?.filter?.externalFilterPerRow ?? this.tableConfiguration?.filter?.externalFilterPerRow;
2098
2098
  option.filter.manualFilter = option?.filter?.manualFilter ?? this.tableConfiguration?.filter?.manualFilter;
2099
- option.filter.hideExternalFilterToolbar = option?.filter?.hideExternalFilterToolbar ?? this.tableConfiguration?.filter?.hideExternalFilterToolbar;
2099
+ option.filter.hideExternalFilterToolbar =
2100
+ option?.filter?.hideExternalFilterToolbar ?? this.tableConfiguration?.filter?.hideExternalFilterToolbar;
2100
2101
  for (const column of option.columns || []) {
2101
2102
  if (column.filter?.operator?.enable) {
2102
2103
  if (!column.filter?.operator?.list?.length) {
@@ -2358,7 +2359,8 @@ class SdTable extends SdBaseSecureComponent {
2358
2359
  total: 0,
2359
2360
  };
2360
2361
  }
2361
- const data = await items(filterReq).catch(err => {
2362
+ const pagingReq = this.#convertPagingReq(filterReq);
2363
+ const data = await items(filterReq, pagingReq).catch(err => {
2362
2364
  console.error(err);
2363
2365
  return {
2364
2366
  items: [],
@@ -2431,9 +2433,10 @@ class SdTable extends SdBaseSecureComponent {
2431
2433
  return await result;
2432
2434
  }
2433
2435
  else {
2434
- const filterInfo = this.#filterExportInfo(pageNumber, pageSize);
2436
+ const filterReq = this.#filterExportInfo(pageNumber, pageSize);
2435
2437
  if (this.tableOption.type === 'server') {
2436
- const result = this.tableOption.items(filterInfo);
2438
+ const pagingReq = this.#convertPagingReq(filterReq);
2439
+ const result = this.tableOption.items(filterReq, pagingReq);
2437
2440
  return await result;
2438
2441
  }
2439
2442
  else {
@@ -2450,7 +2453,7 @@ class SdTable extends SdBaseSecureComponent {
2450
2453
  else {
2451
2454
  exportedItems = this.tableOption.items;
2452
2455
  }
2453
- return this.#filterLocal(exportedItems, filterInfo);
2456
+ return this.#filterLocal(exportedItems, filterReq);
2454
2457
  }
2455
2458
  }
2456
2459
  };
@@ -2882,22 +2885,124 @@ class SdTable extends SdBaseSecureComponent {
2882
2885
  }
2883
2886
  }
2884
2887
  };
2888
+ #getNestedValue = (obj, path) => {
2889
+ if (!path || !obj)
2890
+ return undefined;
2891
+ const keys = path.split('.');
2892
+ let result = obj;
2893
+ for (const key of keys) {
2894
+ if (result === null || result === undefined) {
2895
+ return undefined;
2896
+ }
2897
+ result = result[key];
2898
+ }
2899
+ return result;
2900
+ };
2885
2901
  #format = async (rawItems, columns) => {
2886
2902
  const items = rawItems.map(MapToSdTableItem);
2903
+ // Cache for parsed field paths
2904
+ const fieldPathCache = new Map();
2905
+ /**
2906
+ * Get nested property value from object using dot notation
2907
+ */
2908
+ const getNestedValue = (obj, path) => {
2909
+ if (!path || obj == null)
2910
+ return undefined;
2911
+ let keys = fieldPathCache.get(path);
2912
+ if (!keys) {
2913
+ keys = path.split('.');
2914
+ fieldPathCache.set(path, keys);
2915
+ }
2916
+ if (keys.length === 1)
2917
+ return obj[keys[0]];
2918
+ let result = obj;
2919
+ for (const key of keys) {
2920
+ if (result == null)
2921
+ return undefined;
2922
+ result = result[key];
2923
+ }
2924
+ return result;
2925
+ };
2926
+ /**
2927
+ * Format date display based on column type
2928
+ */
2929
+ const formatDateDisplay = (value, type) => {
2930
+ const date = DateUtilities.toFormat(value, 'dd/MM/yyyy');
2931
+ const time = DateUtilities.toFormat(value, 'HH:mm:ss');
2932
+ if (type === 'datetime') {
2933
+ return time && date ? `<div class="T14R">${date}<span class="T14R text-black400 ml-4">${time}</span></div>` : '';
2934
+ }
2935
+ if (type === 'date')
2936
+ return date || '';
2937
+ if (type === 'time')
2938
+ return time || '';
2939
+ return '';
2940
+ };
2941
+ /**
2942
+ * Process values display (supports arrays)
2943
+ */
2944
+ const processValuesDisplay = (value, rowData, column, field) => {
2945
+ if (column.type === 'lazy-values' && typeof column.option.mapValue === 'function') {
2946
+ const val = column.option.mapValue(value, rowData);
2947
+ const vals = (Array.isArray(val) ? val : [val]).filter(e => e?.toString());
2948
+ return vals.map(val => this.#cacheObjValues[field]?.[val]?.[column.option.displayField] || val).join(', ');
2949
+ }
2950
+ const vals = (Array.isArray(value) ? value : [value]).filter(e => e?.toString());
2951
+ return vals.map(val => this.#cacheObjValues[field]?.[val]?.[column.option.displayField] || val).join(', ');
2952
+ };
2953
+ /**
2954
+ * Create badge configuration
2955
+ */
2956
+ const createBadge = (column, value, rowData) => {
2957
+ if (column.useBadge) {
2958
+ const badge = column.useBadge(value, rowData);
2959
+ if (badge) {
2960
+ return {
2961
+ badge: {
2962
+ type: badge.type ?? 'round',
2963
+ color: badge.color,
2964
+ icon: badge.icon,
2965
+ },
2966
+ title: badge.title,
2967
+ };
2968
+ }
2969
+ return undefined;
2970
+ }
2971
+ if ((column.type === 'string' || column.type === 'number' || column.type === 'values') && column.badge) {
2972
+ return {
2973
+ badge: {
2974
+ type: column.badgeType || 'icon',
2975
+ color: column.badge(value, rowData),
2976
+ icon: column.badgeIcon?.(value, rowData),
2977
+ },
2978
+ title: null,
2979
+ };
2980
+ }
2981
+ if (column.type === 'boolean') {
2982
+ return {
2983
+ badge: {
2984
+ type: 'round',
2985
+ color: value ? 'success' : 'error',
2986
+ },
2987
+ };
2988
+ }
2989
+ return undefined;
2990
+ };
2887
2991
  const execute = async (column) => {
2888
- // Clickable
2889
2992
  const { field, click, tooltip, htmlTemplate, transform } = column;
2993
+ // Load lazy-values
2890
2994
  if (!transform && !htmlTemplate && column.type === 'lazy-values' && typeof column.option.views === 'function') {
2891
- const { option: { views, mapValue }, } = column;
2995
+ const { option: { views, mapValue, valueField, displayField }, } = column;
2892
2996
  this.#cacheObjValues[field] = this.#cacheObjValues[field] || {};
2893
2997
  const values = ArrayUtilities.distinct(items
2894
2998
  .map(item => {
2999
+ const value = getNestedValue(item.data, field);
2895
3000
  if (typeof mapValue === 'function') {
2896
- return mapValue(item.data?.[field], item.data);
3001
+ return mapValue(value, item.data);
2897
3002
  }
2898
- return item.data?.[field];
3003
+ return value;
2899
3004
  })
2900
- .filter(val => !!val?.toString())
3005
+ .filter(val => val?.toString())
2901
3006
  .reduce((current, next) => [...current, ...(Array.isArray(next) ? next : [next])], [])
2902
3007
  .filter(val => !Object.keys(this.#cacheObjValues[field]).includes(val)));
2903
3008
  if (values.length) {
@@ -2905,17 +3010,19 @@ class SdTable extends SdBaseSecureComponent {
2905
3010
  console.error(err);
2906
3011
  return [];
2907
3012
  }))
2908
- .filter((item) => values.includes(item?.[column.option.valueField]))
3013
+ .filter((item) => values.includes(item?.[valueField]))
2909
3014
  .map((e) => ({
2910
- [column.option.valueField]: e?.[column.option.valueField],
2911
- [column.option.displayField]: e?.[column.option.displayField],
3015
+ [valueField]: e?.[valueField],
3016
+ [displayField]: e?.[displayField],
2912
3017
  }));
2913
- Object.assign(this.#cacheObjValues[field], ArrayUtilities.toObject(column.option.valueField, lazyItems) || {});
3018
+ Object.assign(this.#cacheObjValues[field], ArrayUtilities.toObject(valueField, lazyItems) || {});
2914
3019
  }
2915
3020
  }
3021
+ // Process each item
2916
3022
  for (const item of items) {
2917
3023
  const rowData = item.data;
2918
- const value = rowData?.[field];
3024
+ const value = getNestedValue(rowData, field);
3025
+ // Initialize display
2919
3026
  item.meta.display[field] = {
2920
3027
  badge: undefined,
2921
3028
  cellStyle: column.align === 'right' ? { 'text-align': 'right!important' } : undefined,
@@ -2925,57 +3032,34 @@ class SdTable extends SdBaseSecureComponent {
2925
3032
  click: typeof click === 'function' ? () => click(value, rowData) : undefined,
2926
3033
  };
2927
3034
  const display = item.meta.display[field];
2928
- // Display
3035
+ // Process display data
2929
3036
  if (typeof htmlTemplate === 'function') {
2930
3037
  display.isHtml = true;
2931
3038
  display.data = htmlTemplate(value, rowData);
2932
3039
  }
2933
3040
  else if (typeof transform === 'function') {
2934
3041
  const newValue = transform(value, rowData);
2935
- if (newValue instanceof Promise) {
2936
- display.data = await newValue;
2937
- }
2938
- else {
2939
- display.data = newValue;
2940
- }
3042
+ display.data = newValue instanceof Promise ? await newValue : newValue;
2941
3043
  }
2942
3044
  else {
3045
+ // Date/Time
2943
3046
  if (column.type === 'date' || column.type === 'datetime' || column.type === 'time') {
2944
- const date = DateUtilities.toFormat(value, 'dd/MM/yyyy');
2945
- let time = DateUtilities.toFormat(value, 'HH:mm:ss');
2946
- // if (time?.endsWith('00')) {
2947
- // time = DateUtilities.toFormat(value, 'HH:mm');
2948
- // }
2949
- if (column.type === 'date' || column.type === 'datetime') {
2950
- if (column.type === 'datetime') {
2951
- display.isHtml = true;
2952
- display.data = time && date ? `<div class="T14R">${date}<span class="T14R text-black400 ml-4">${time}</span></div>` : '';
2953
- }
2954
- else {
2955
- display.data = date;
2956
- }
2957
- }
2958
- if (column.type === 'time') {
2959
- display.data = time;
2960
- }
3047
+ const formatted = formatDateDisplay(value, column.type);
3048
+ display.data = formatted;
3049
+ display.isHtml = column.type === 'datetime';
2961
3050
  }
3051
+ // Values/Lazy-values
2962
3052
  if (column.type === 'values' || column.type === 'lazy-values') {
2963
- if (column.type === 'lazy-values' && typeof column.option.mapValue === 'function') {
2964
- const val = column.option.mapValue(value, rowData);
2965
- const vals = (Array.isArray(val) ? val : [val]).filter(e => !!e?.toString());
2966
- display.data = vals.map(val => this.#cacheObjValues[field]?.[val]?.[column.option.displayField] || val)?.join(', ');
2967
- }
2968
- else {
2969
- const vals = (Array.isArray(value) ? value : [value]).filter(e => !!e?.toString());
2970
- display.data = vals.map(val => this.#cacheObjValues[field]?.[val]?.[column.option.displayField] || val)?.join(', ');
2971
- }
3053
+ display.data = processValuesDisplay(value, rowData, column, field);
2972
3054
  }
3055
+ // Number
2973
3056
  if (column.type === 'number' && NumberUtilities.isNumber(value)) {
2974
3057
  display.data = this.formatNumberPipe.transform(value);
2975
3058
  }
3059
+ // Boolean
2976
3060
  if (column.type === 'boolean') {
2977
3061
  const { option } = column;
2978
- if (value !== undefined && value !== null && value !== '') {
3062
+ if (value != null && value !== '') {
2979
3063
  display.data = value === true ? option?.displayOnTrue || 'True' : option?.displayOnFalse || 'False';
2980
3064
  }
2981
3065
  else {
@@ -2983,31 +3067,14 @@ class SdTable extends SdBaseSecureComponent {
2983
3067
  }
2984
3068
  }
2985
3069
  // Badge
2986
- if (column.useBadge) {
2987
- const badge = column.useBadge(value, rowData);
2988
- if (badge) {
2989
- display.badge = {
2990
- type: badge.type ?? 'round',
2991
- color: badge.color,
2992
- icon: badge.icon,
2993
- };
2994
- display.data = badge.title ?? display.data;
3070
+ const badgeResult = createBadge(column, value, rowData);
3071
+ if (badgeResult) {
3072
+ display.badge = badgeResult.badge;
3073
+ if (badgeResult.title) {
3074
+ display.data = badgeResult.title;
2995
3075
  }
2996
3076
  }
2997
- else if ((column.type === 'string' || column.type === 'number' || column.type === 'values') && column.badge) {
2998
- display.badge = {
2999
- type: !column?.badgeType ? 'icon' : column.badgeType,
3000
- color: column.badge(value, rowData),
3001
- icon: column.badgeIcon?.(value, rowData),
3002
- };
3003
- }
3004
- else if (column.type === 'boolean') {
3005
- display.badge = {
3006
- type: 'icon',
3007
- color: value ? 'success' : 'error',
3008
- icon: null,
3009
- };
3010
- }
3077
+ // Handle empty values
3011
3078
  if (display.data === null || display.data === undefined || display.data === '') {
3012
3079
  display.data = SD_EMPTY_STR;
3013
3080
  display.badge = undefined;
@@ -3015,6 +3082,7 @@ class SdTable extends SdBaseSecureComponent {
3015
3082
  }
3016
3083
  }
3017
3084
  };
3085
+ // Execute for all columns
3018
3086
  for (const column of columns.filter(e => !e.hidden)) {
3019
3087
  if (column.type === 'children') {
3020
3088
  for (const childColumn of column.children?.filter(e => !e.hidden) || []) {
@@ -3033,6 +3101,228 @@ class SdTable extends SdBaseSecureComponent {
3033
3101
  trackBy = (index, item) => {
3034
3102
  return item.meta.id;
3035
3103
  };
3104
+ #convertPagingReq = (filterReq) => {
3105
+ const { columns, filter } = this.tableOption;
3106
+ const externalFilters = filter?.externalFilters || [];
3107
+ const req = {
3108
+ filters: [],
3109
+ orders: [],
3110
+ pageNumber: filterReq.pageNumber,
3111
+ pageSize: filterReq.pageSize,
3112
+ };
3113
+ const { filters, orders } = req;
3114
+ const { rawColumnFilter, columnOperator, rawExternalFilter, orderBy, orderDirection } = filterReq;
3115
+ // Xử lý external filter
3116
+ for (const externalFilter of externalFilters || []) {
3117
+ const { field } = externalFilter;
3118
+ const value = rawExternalFilter?.[field];
3119
+ // Nếu có giá trị thì mới xử lý filter
3120
+ if (value !== undefined && value !== null && value !== '') {
3121
+ if (externalFilter.type === 'string') {
3122
+ // Nếu filter là equal và có dấu , ngăn cách thì hiểu là tìm nhiều ngăn cách bởi dấu phẩy
3123
+ if (externalFilter.defaultOperator === 'EQUAL' && value?.includes(',')) {
3124
+ filters.push({
3125
+ field,
3126
+ operator: 'IN',
3127
+ data: value.split(',').map(val => val.trim()),
3128
+ });
3129
+ }
3130
+ else {
3131
+ filters.push({
3132
+ field,
3133
+ operator: externalFilter.defaultOperator || 'CONTAIN',
3134
+ data: value,
3135
+ });
3136
+ }
3137
+ }
3138
+ else if (externalFilter.type === 'boolean') {
3139
+ filters.push({
3140
+ field,
3141
+ operator: 'EQUAL',
3142
+ data: value === true || value === 1 || value === 'true' || value === '1',
3143
+ });
3144
+ }
3145
+ else if (externalFilter.type === 'daterange') {
3146
+ if (typeof value === 'object' && 'from' in value && 'to' in value) {
3147
+ if (value?.from) {
3148
+ filters.push({
3149
+ field,
3150
+ operator: 'GREATER_OR_EQUAL',
3151
+ data: DateUtilities.begin(value?.from).toISOString(),
3152
+ });
3153
+ }
3154
+ if (value?.to) {
3155
+ filters.push({
3156
+ field,
3157
+ operator: 'LESS_THAN',
3158
+ data: DateUtilities.begin(DateUtilities.addDays(value?.to, 1)).toISOString(),
3159
+ });
3160
+ }
3161
+ }
3162
+ }
3163
+ else if (externalFilter.type === 'date' || externalFilter.type === 'datetime') {
3164
+ if (DateUtilities.isDate(value)) {
3165
+ if (externalFilter.type === 'date') {
3166
+ if (externalFilter.defaultOperator === 'GREATER_OR_EQUAL') {
3167
+ filters.push({
3168
+ field,
3169
+ operator: 'GREATER_OR_EQUAL',
3170
+ data: DateUtilities.begin(value).toISOString(),
3171
+ });
3172
+ }
3173
+ if (externalFilter.defaultOperator === 'LESS_OR_EQUAL') {
3174
+ filters.push({
3175
+ field,
3176
+ operator: 'LESS_THAN',
3177
+ data: DateUtilities.begin(DateUtilities.addDays(value, 1)).toISOString(),
3178
+ });
3179
+ }
3180
+ }
3181
+ else {
3182
+ if (externalFilter.defaultOperator === 'GREATER_OR_EQUAL') {
3183
+ filters.push({
3184
+ field,
3185
+ operator: 'GREATER_OR_EQUAL',
3186
+ data: new Date(value).toISOString(),
3187
+ });
3188
+ }
3189
+ if (externalFilter.defaultOperator === 'LESS_OR_EQUAL') {
3190
+ filters.push({
3191
+ field,
3192
+ operator: 'LESS_OR_EQUAL',
3193
+ data: new Date(value).toISOString(),
3194
+ });
3195
+ }
3196
+ }
3197
+ }
3198
+ }
3199
+ else {
3200
+ if (Array.isArray(value)) {
3201
+ if (value.length) {
3202
+ filters.push({
3203
+ field,
3204
+ operator: 'IN',
3205
+ data: value,
3206
+ });
3207
+ }
3208
+ }
3209
+ else if (typeof value === 'object' && 'from' in value && 'to' in value) {
3210
+ if (value?.from) {
3211
+ filters.push({
3212
+ field,
3213
+ operator: 'GREATER_OR_EQUAL',
3214
+ data: DateUtilities.begin(value?.from).toISOString(),
3215
+ });
3216
+ }
3217
+ if (value?.to) {
3218
+ filters.push({
3219
+ field,
3220
+ operator: 'LESS_THAN',
3221
+ data: DateUtilities.begin(DateUtilities.addDays(value?.to, 1)).toISOString(),
3222
+ });
3223
+ }
3224
+ }
3225
+ else {
3226
+ filters.push({
3227
+ field,
3228
+ operator: externalFilter.defaultOperator || 'EQUAL',
3229
+ data: value,
3230
+ });
3231
+ }
3232
+ }
3233
+ }
3234
+ }
3235
+ // Xử lý column filter
3236
+ // Xử lý column filter
3237
+ for (const column of columns || []) {
3238
+ const { field } = column;
3239
+ const value = rawColumnFilter?.[field];
3240
+ const operator = columnOperator?.[field] || column.filter?.operator?.default;
3241
+ // Nếu có giá trị thì mới xử lý filter
3242
+ if (value !== undefined && value !== null && value !== '') {
3243
+ if (column.type === 'string') {
3244
+ filters.push({
3245
+ field,
3246
+ operator: operator || 'CONTAIN',
3247
+ data: value,
3248
+ });
3249
+ }
3250
+ else if (column.type === 'boolean') {
3251
+ filters.push({
3252
+ field,
3253
+ operator: 'EQUAL',
3254
+ data: value === true || value === 1 || value === 'true' || value === '1',
3255
+ });
3256
+ }
3257
+ else if (column.type === 'date' || column.type === 'datetime') {
3258
+ if (value && typeof value === 'object' && 'from' in value && 'to' in value) {
3259
+ if (value?.from && value?.to) {
3260
+ filters.push({
3261
+ field,
3262
+ operator: 'BETWEEN',
3263
+ data: {
3264
+ from: DateUtilities.begin(value?.from).toISOString(),
3265
+ to: DateUtilities.end(value?.to).toISOString(),
3266
+ },
3267
+ });
3268
+ }
3269
+ else if (value?.from) {
3270
+ filters.push({
3271
+ field,
3272
+ operator: 'GREATER_OR_EQUAL',
3273
+ data: DateUtilities.begin(value?.from).toISOString(),
3274
+ });
3275
+ }
3276
+ else if (value?.to) {
3277
+ filters.push({
3278
+ field,
3279
+ operator: 'LESS_THAN',
3280
+ data: DateUtilities.begin(DateUtilities.addDays(value?.to, 1)).toISOString(),
3281
+ });
3282
+ }
3283
+ }
3284
+ else {
3285
+ if (DateUtilities.isDate(value)) {
3286
+ filters.push({
3287
+ field,
3288
+ operator: 'BETWEEN',
3289
+ data: {
3290
+ from: DateUtilities.begin(value).toISOString(),
3291
+ to: DateUtilities.end(value).toISOString(),
3292
+ },
3293
+ });
3294
+ }
3295
+ }
3296
+ }
3297
+ else {
3298
+ if (Array.isArray(value)) {
3299
+ if (value.length) {
3300
+ filters.push({
3301
+ field,
3302
+ operator: 'IN',
3303
+ data: value,
3304
+ });
3305
+ }
3306
+ }
3307
+ else {
3308
+ filters.push({
3309
+ field,
3310
+ operator: operator || 'EQUAL',
3311
+ data: value,
3312
+ });
3313
+ }
3314
+ }
3315
+ }
3316
+ }
3317
+ // Xử lý orders
3318
+ if (orderBy && orderDirection) {
3319
+ orders.push({
3320
+ field: orderBy,
3321
+ direction: orderDirection,
3322
+ });
3323
+ }
3324
+ return req;
3325
+ };
3036
3326
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: SdTable, deps: [{ token: i0.ChangeDetectorRef }, { token: i1$4.SdFormatNumberPipe }, { token: SD_TABLE_CONFIGURATION, optional: true }, { token: ConfigService }, { token: i1$1.SdExcelService }, { token: i1$1.SdNotifyService }, { token: SdTableFilterService }], target: i0.ɵɵFactoryTarget.Component });
3037
3327
  static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: SdTable, isStandalone: true, selector: "sd-table", inputs: { _autoId: ["autoId", "_autoId"], option: "option" }, providers: [
3038
3328
  DatePipe,
@@ -3255,7 +3545,6 @@ const SdConvertToPagingReq = (filterRequest, args) => {
3255
3545
  });
3256
3546
  }
3257
3547
  else if (column.type === 'date' || column.type === 'datetime') {
3258
- console.log(value);
3259
3548
  if (typeof value === 'object' && 'from' in value && 'to' in value) {
3260
3549
  if (value?.from && value?.to) {
3261
3550
  filters.push({