@zeedhi/teknisa-components-common 1.101.1 → 1.103.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/coverage/clover.xml +683 -746
- package/coverage/coverage-final.json +45 -45
- package/coverage/lcov-report/components/crud/crud-add-button.ts.html +250 -0
- package/coverage/lcov-report/components/crud/crud-button.ts.html +292 -0
- package/coverage/lcov-report/components/crud/crud-cancel-button.ts.html +259 -0
- package/coverage/lcov-report/components/crud/crud-delete-button.ts.html +322 -0
- package/coverage/lcov-report/components/crud/crud-form.ts.html +382 -0
- package/coverage/lcov-report/components/crud/crud-save-button.ts.html +253 -0
- package/coverage/lcov-report/components/crud/index.html +191 -0
- package/coverage/lcov-report/components/index.html +116 -0
- package/coverage/lcov-report/components/index.ts.html +394 -0
- package/coverage/lcov-report/components/tek-breadcrumb-header/breadcrumb-header.ts.html +172 -0
- package/coverage/lcov-report/components/tek-breadcrumb-header/index.html +116 -0
- package/coverage/lcov-report/components/tek-card-title/card-title.ts.html +175 -0
- package/coverage/lcov-report/components/tek-card-title/index.html +116 -0
- package/coverage/lcov-report/components/tek-datasource/index.html +146 -0
- package/coverage/lcov-report/components/tek-datasource/interfaces.ts.html +193 -0
- package/coverage/lcov-report/components/tek-datasource/memory-datasource.ts.html +1015 -0
- package/coverage/lcov-report/components/tek-datasource/rest-datasource.ts.html +751 -0
- package/coverage/lcov-report/components/tek-drag-grid/index.html +116 -0
- package/coverage/lcov-report/components/tek-drag-grid/tek-drag-grid.ts.html +409 -0
- package/coverage/lcov-report/components/tek-grid/filter-helper.ts.html +145 -0
- package/coverage/lcov-report/components/tek-grid/grid-column.ts.html +775 -0
- package/coverage/lcov-report/components/tek-grid/grid-columns-button-controller.ts.html +169 -0
- package/coverage/lcov-report/components/tek-grid/grid-columns-button.ts.html +190 -0
- package/coverage/lcov-report/components/tek-grid/grid-filter-button.ts.html +1282 -0
- package/coverage/lcov-report/components/tek-grid/grid.ts.html +3157 -0
- package/coverage/lcov-report/components/tek-grid/index.html +221 -0
- package/coverage/lcov-report/components/tek-grid/interfaces.ts.html +733 -0
- package/coverage/lcov-report/components/tek-grid/layout-options.ts.html +826 -0
- package/coverage/lcov-report/components/tek-image/image.ts.html +313 -0
- package/coverage/lcov-report/components/tek-image/index.html +116 -0
- package/coverage/lcov-report/components/tek-iterable-carousel/index.html +116 -0
- package/coverage/lcov-report/components/tek-iterable-carousel/iterable-carousel.ts.html +175 -0
- package/coverage/lcov-report/components/tek-iterable-component-render/index.html +116 -0
- package/coverage/lcov-report/components/tek-iterable-component-render/iterable-component-render.ts.html +118 -0
- package/coverage/lcov-report/components/tek-loading/index.html +116 -0
- package/coverage/lcov-report/components/tek-loading/loading.ts.html +196 -0
- package/coverage/lcov-report/components/tek-notifications/index.html +116 -0
- package/coverage/lcov-report/components/tek-notifications/notifications.ts.html +271 -0
- package/coverage/lcov-report/components/tek-product-card/index.html +116 -0
- package/coverage/lcov-report/components/tek-product-card/product-card.ts.html +391 -0
- package/coverage/lcov-report/components/tek-tree-grid/index.html +116 -0
- package/coverage/lcov-report/components/tek-tree-grid/tree-grid.ts.html +1255 -0
- package/coverage/lcov-report/components/tek-user-info/TekUserInfoController.ts.html +367 -0
- package/coverage/lcov-report/components/tek-user-info/index.html +146 -0
- package/coverage/lcov-report/components/tek-user-info/tek-user-info-list.ts.html +268 -0
- package/coverage/lcov-report/components/tek-user-info/tek-user-info.ts.html +1096 -0
- package/coverage/lcov-report/error/delete-rows-error.ts.html +118 -0
- package/coverage/lcov-report/error/index.html +116 -0
- package/coverage/lcov-report/index.html +17 -17
- package/coverage/lcov-report/tests/__helpers__/component-event-helper.ts.html +2 -2
- package/coverage/lcov-report/tests/__helpers__/flush-promises-helper.ts.html +2 -2
- package/coverage/lcov-report/tests/__helpers__/get-child-helper.ts.html +9 -9
- package/coverage/lcov-report/tests/__helpers__/index.html +1 -1
- package/coverage/lcov-report/tests/__helpers__/index.ts.html +1 -1
- package/coverage/lcov-report/tests/__helpers__/mock-created-helper.ts.html +1 -1
- package/coverage/lcov-report/utils/grid-base/export-options/button-option.ts.html +166 -0
- package/coverage/lcov-report/utils/grid-base/export-options/index.html +146 -0
- package/coverage/lcov-report/utils/grid-base/export-options/index.ts.html +94 -0
- package/coverage/lcov-report/utils/grid-base/export-options/multi-option.ts.html +355 -0
- package/coverage/lcov-report/utils/grid-base/grid-base.ts.html +1960 -0
- package/coverage/lcov-report/utils/grid-base/grid-controller.ts.html +457 -0
- package/coverage/lcov-report/utils/grid-base/index.html +131 -0
- package/coverage/lcov-report/utils/index.html +116 -0
- package/coverage/lcov-report/utils/index.ts.html +100 -0
- package/coverage/lcov-report/utils/report-filter/index.html +116 -0
- package/coverage/lcov-report/utils/report-filter/report-filter.ts.html +256 -0
- package/coverage/lcov.info +1173 -1286
- package/dist/tek-components-common.esm.js +249 -171
- package/dist/tek-components-common.umd.js +248 -169
- package/package.json +3 -3
- package/tests/unit/components/tek-grid/grid.spec.ts +224 -104
- package/tests/unit/components/tek-grid/layout_options.spec.ts +70 -0
- package/tests/unit/components/tree-grid/tree-grid.spec.ts +1 -1
- package/tests/unit/utils/grid-base/grid-controller.spec.ts +8 -0
- package/types/components/index.d.ts +1 -0
- package/types/components/tek-grid/grid.d.ts +2 -0
- package/types/components/tek-grid/interfaces.d.ts +2 -0
- package/types/components/tek-grid/layout-options.d.ts +2 -0
- package/types/components/tek-tree-grid/interfaces.d.ts +2 -0
- package/types/components/tek-tree-grid/tree-grid.d.ts +2 -0
- package/types/utils/grid-base/grid-base.d.ts +166 -154
- package/types/utils/grid-base/grid-controller.d.ts +5 -0
- package/types/components/tek-ag-grid/default-icons.d.ts +0 -53
- package/types/components/tek-ag-grid/interfaces.d.ts +0 -9
- package/types/components/tek-ag-grid/tek-ag-grid.d.ts +0 -35
- package/types/components/tek-datasource/datasource.d.ts +0 -94
- package/types/components/tek-grid/default-icons.d.ts +0 -53
- package/types/components/tek-grid/filter-dynamic-values.d.ts +0 -9
- package/types/components/tek-grid/grid-controller.d.ts +0 -19
- package/types/components/tek-grid/grid_column.d.ts +0 -14
- package/types/components/tek-grid/grid_controller.d.ts +0 -15
- package/types/components/tek-grid/tek-grid.d.ts +0 -35
- package/types/components/tek-login/interfaces.d.ts +0 -3
- package/types/components/tek-login/login-children.d.ts +0 -3
- package/types/components/tek-login/login.d.ts +0 -58
- package/types/components/tek-login/login_children.d.ts +0 -3
|
@@ -812,6 +812,7 @@
|
|
|
812
812
|
this.exportConfigButtons = [];
|
|
813
813
|
this.atoms = {
|
|
814
814
|
TITLE: '_gridTitle',
|
|
815
|
+
HIDE_BUTTON: '_hideButton',
|
|
815
816
|
ADD_BUTTON: '_addButton',
|
|
816
817
|
DELETE_BUTTON: '_deleteButton',
|
|
817
818
|
REFRESH_BUTTON: '_refreshButton',
|
|
@@ -853,194 +854,218 @@
|
|
|
853
854
|
title: this.grid.title,
|
|
854
855
|
},
|
|
855
856
|
{
|
|
856
|
-
name: `${this.grid.name}
|
|
857
|
-
component: '
|
|
857
|
+
name: `${this.grid.name}_hideTooltip`,
|
|
858
|
+
component: 'ZdTooltip',
|
|
859
|
+
label: `{{GridController_${this.grid.componentId}.tooltipName}}`,
|
|
860
|
+
bottom: true,
|
|
861
|
+
children: [
|
|
862
|
+
{
|
|
863
|
+
name: `${this.grid.name}_hideButton`,
|
|
864
|
+
component: 'ZdIcon',
|
|
865
|
+
iconName: 'mdi-chevron-right',
|
|
866
|
+
isVisible: `{{GridController_${this.grid.componentId}.isNotEditing}}`,
|
|
867
|
+
cssClass: `{{GridController_${this.grid.componentId}.toolbarStyle}}`,
|
|
868
|
+
events: {
|
|
869
|
+
click: this.hideButtonClick.bind(this),
|
|
870
|
+
},
|
|
871
|
+
},
|
|
872
|
+
],
|
|
858
873
|
},
|
|
859
874
|
{
|
|
860
|
-
name: `${this.grid.name}
|
|
875
|
+
name: `${this.grid.name}_toolbarDiv`,
|
|
861
876
|
component: 'ZdTag',
|
|
862
|
-
tag: '
|
|
863
|
-
cssStyle: 'display: flex',
|
|
864
|
-
isVisible: `{{GridController_${this.grid.componentId}.
|
|
877
|
+
tag: 'div',
|
|
878
|
+
cssStyle: 'display: flex; align-items: center',
|
|
879
|
+
isVisible: `{{GridController_${this.grid.componentId}.showToolbar}}`,
|
|
865
880
|
children: [
|
|
866
881
|
{
|
|
867
|
-
name: `${this.grid.name}
|
|
868
|
-
component: '
|
|
869
|
-
|
|
870
|
-
|
|
882
|
+
name: `${this.grid.name}_notEditingSpan`,
|
|
883
|
+
component: 'ZdTag',
|
|
884
|
+
tag: 'span',
|
|
885
|
+
cssStyle: 'display: flex',
|
|
886
|
+
isVisible: `{{GridController_${this.grid.componentId}.isNotEditing}}`,
|
|
871
887
|
children: [
|
|
872
888
|
{
|
|
873
|
-
name: `${this.grid.name}
|
|
874
|
-
component: '
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
889
|
+
name: `${this.grid.name}_add_tooltip`,
|
|
890
|
+
component: 'ZdTooltip',
|
|
891
|
+
label: 'TEKGRID_ADD',
|
|
892
|
+
bottom: true,
|
|
893
|
+
children: [
|
|
894
|
+
{
|
|
895
|
+
name: `${this.grid.name}_addButton`,
|
|
896
|
+
component: 'ZdButton',
|
|
897
|
+
icon: true,
|
|
898
|
+
iconName: 'add',
|
|
899
|
+
isVisible: `{{GridController_${this.grid.componentId}.showAddButton}}`,
|
|
900
|
+
events: {
|
|
901
|
+
click: this.addButtonClick.bind(this),
|
|
902
|
+
},
|
|
903
|
+
},
|
|
904
|
+
],
|
|
881
905
|
},
|
|
882
|
-
],
|
|
883
|
-
},
|
|
884
|
-
{
|
|
885
|
-
name: `${this.grid.name}_delete_tooltip`,
|
|
886
|
-
component: 'ZdTooltip',
|
|
887
|
-
label: 'TEKGRID_DELETE',
|
|
888
|
-
bottom: true,
|
|
889
|
-
children: [
|
|
890
906
|
{
|
|
891
|
-
name: `${this.grid.name}
|
|
892
|
-
component: '
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
907
|
+
name: `${this.grid.name}_delete_tooltip`,
|
|
908
|
+
component: 'ZdTooltip',
|
|
909
|
+
label: 'TEKGRID_DELETE',
|
|
910
|
+
bottom: true,
|
|
911
|
+
children: [
|
|
912
|
+
{
|
|
913
|
+
name: `${this.grid.name}_deleteButton`,
|
|
914
|
+
component: 'ZdButton',
|
|
915
|
+
icon: true,
|
|
916
|
+
iconName: 'delete',
|
|
917
|
+
isVisible: `{{GridController_${this.grid.componentId}.showDeleteButton}}`,
|
|
918
|
+
disabled: `{{GridController_${this.grid.componentId}.disableDeleteButton}}`,
|
|
919
|
+
events: {
|
|
920
|
+
click: this.deleteButtonClick.bind(this),
|
|
921
|
+
},
|
|
922
|
+
},
|
|
923
|
+
],
|
|
924
|
+
},
|
|
925
|
+
{
|
|
926
|
+
name: `${this.grid.name}_divider1`,
|
|
927
|
+
component: 'ZdDivider',
|
|
928
|
+
cssClass: 'toolbar-divider',
|
|
929
|
+
vertical: true,
|
|
930
|
+
isVisible: `{{GridController_${this.grid.componentId}.showDivider1}}`,
|
|
931
|
+
},
|
|
932
|
+
{
|
|
933
|
+
name: `${this.grid.name}_refresh_tooltip`,
|
|
934
|
+
component: 'ZdTooltip',
|
|
935
|
+
label: 'TEKGRID_REFRESH',
|
|
936
|
+
bottom: true,
|
|
937
|
+
children: [
|
|
938
|
+
{
|
|
939
|
+
name: `${this.grid.name}_refreshButton`,
|
|
940
|
+
component: 'ZdButton',
|
|
941
|
+
icon: true,
|
|
942
|
+
iconName: 'refresh',
|
|
943
|
+
isVisible: `{{GridController_${this.grid.componentId}.showReloadButton}}`,
|
|
944
|
+
events: {
|
|
945
|
+
click: this.reloadGrid.bind(this),
|
|
946
|
+
},
|
|
947
|
+
},
|
|
948
|
+
],
|
|
949
|
+
},
|
|
950
|
+
{
|
|
951
|
+
name: `${this.grid.name}_divider2`,
|
|
952
|
+
component: 'ZdDivider',
|
|
953
|
+
cssClass: 'toolbar-divider',
|
|
954
|
+
vertical: true,
|
|
955
|
+
isVisible: `{{GridController_${this.grid.componentId}.showDivider2}}`,
|
|
956
|
+
},
|
|
957
|
+
{
|
|
958
|
+
name: `${this.grid.name}_columns_button_tooltip`,
|
|
959
|
+
component: 'ZdTooltip',
|
|
960
|
+
label: 'TEKGRID_COLUMNS',
|
|
961
|
+
bottom: true,
|
|
962
|
+
children: [
|
|
963
|
+
{
|
|
964
|
+
name: `${this.grid.name}_columnsButton`,
|
|
965
|
+
component: 'TekGridColumnsButton',
|
|
966
|
+
isVisible: `{{GridController_${this.grid.componentId}.showColumnsButton}}`,
|
|
967
|
+
iterableComponentName: this.grid.name,
|
|
968
|
+
hideGroups: !(this.grid instanceof TekGrid),
|
|
969
|
+
ignoreColumns: `{{GridController_${this.grid.componentId}.columnsButtonIgnore}}`,
|
|
970
|
+
},
|
|
971
|
+
],
|
|
972
|
+
},
|
|
973
|
+
{
|
|
974
|
+
name: `${this.grid.name}_layout_options`,
|
|
975
|
+
component: 'TekGridLayoutOptions',
|
|
976
|
+
isVisible: `{{GridController_${this.grid.componentId}.showLayoutOptionsButton}}`,
|
|
977
|
+
},
|
|
978
|
+
{
|
|
979
|
+
name: `${this.grid.name}_dividerActions`,
|
|
980
|
+
component: 'ZdDivider',
|
|
981
|
+
cssClass: 'toolbar-divider',
|
|
982
|
+
vertical: true,
|
|
983
|
+
isVisible: `{{GridController_${this.grid.componentId}.showActionAndExportButton}}`,
|
|
984
|
+
},
|
|
985
|
+
{
|
|
986
|
+
name: `${this.grid.name}_export_dropdown`,
|
|
987
|
+
component: 'ZdDropdown',
|
|
988
|
+
cssClass: 'tekgrid-actions-dropdown',
|
|
989
|
+
offsetY: true,
|
|
990
|
+
activator: {
|
|
991
|
+
name: `${this.grid.name}_exportButton`,
|
|
992
|
+
component: 'ZdButton',
|
|
993
|
+
icon: true,
|
|
994
|
+
iconName: 'fileDownload',
|
|
995
|
+
isVisible: `{{GridController_${this.grid.componentId}.showExportButton}}`,
|
|
899
996
|
},
|
|
997
|
+
children: this.grid.exportActions || this.exportConfigButtons,
|
|
900
998
|
},
|
|
901
|
-
],
|
|
902
|
-
},
|
|
903
|
-
{
|
|
904
|
-
name: `${this.grid.name}_divider1`,
|
|
905
|
-
component: 'ZdDivider',
|
|
906
|
-
cssClass: 'toolbar-divider',
|
|
907
|
-
vertical: true,
|
|
908
|
-
isVisible: `{{GridController_${this.grid.componentId}.showDivider1}}`,
|
|
909
|
-
},
|
|
910
|
-
{
|
|
911
|
-
name: `${this.grid.name}_refresh_tooltip`,
|
|
912
|
-
component: 'ZdTooltip',
|
|
913
|
-
label: 'TEKGRID_REFRESH',
|
|
914
|
-
bottom: true,
|
|
915
|
-
children: [
|
|
916
999
|
{
|
|
917
|
-
name: `${this.grid.name}
|
|
918
|
-
component: '
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
1000
|
+
name: `${this.grid.name}_actions_dropdown`,
|
|
1001
|
+
component: 'ZdDropdown',
|
|
1002
|
+
cssClass: 'tekgrid-actions-dropdown',
|
|
1003
|
+
offsetY: true,
|
|
1004
|
+
activator: {
|
|
1005
|
+
name: `${this.grid.name}_actionsButton`,
|
|
1006
|
+
component: 'ZdButton',
|
|
1007
|
+
icon: true,
|
|
1008
|
+
iconName: 'more',
|
|
1009
|
+
isVisible: `{{GridController_${this.grid.componentId}.showActionsButton}}`,
|
|
924
1010
|
},
|
|
1011
|
+
children: this.grid.actions,
|
|
925
1012
|
},
|
|
926
|
-
],
|
|
927
|
-
},
|
|
928
|
-
{
|
|
929
|
-
name: `${this.grid.name}_divider2`,
|
|
930
|
-
component: 'ZdDivider',
|
|
931
|
-
cssClass: 'toolbar-divider',
|
|
932
|
-
vertical: true,
|
|
933
|
-
isVisible: `{{GridController_${this.grid.componentId}.showDivider2}}`,
|
|
934
|
-
},
|
|
935
|
-
{
|
|
936
|
-
name: `${this.grid.name}_columns_button_tooltip`,
|
|
937
|
-
component: 'ZdTooltip',
|
|
938
|
-
label: 'TEKGRID_COLUMNS',
|
|
939
|
-
bottom: true,
|
|
940
|
-
children: [
|
|
941
1013
|
{
|
|
942
|
-
name: `${this.grid.name}
|
|
943
|
-
component: '
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
ignoreColumns: `{{GridController_${this.grid.componentId}.columnsButtonIgnore}}`,
|
|
1014
|
+
name: `${this.grid.name}_divider3`,
|
|
1015
|
+
component: 'ZdDivider',
|
|
1016
|
+
cssClass: 'toolbar-divider',
|
|
1017
|
+
vertical: true,
|
|
1018
|
+
isVisible: `{{GridController_${this.grid.componentId}.showDivider3}}`,
|
|
948
1019
|
},
|
|
949
1020
|
],
|
|
950
1021
|
},
|
|
951
1022
|
{
|
|
952
|
-
name: `${this.grid.name}
|
|
953
|
-
component: '
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
cssClass: 'toolbar-divider',
|
|
960
|
-
vertical: true,
|
|
961
|
-
isVisible: `{{GridController_${this.grid.componentId}.showActionAndExportButton}}`,
|
|
962
|
-
},
|
|
963
|
-
{
|
|
964
|
-
name: `${this.grid.name}_export_dropdown`,
|
|
965
|
-
component: 'ZdDropdown',
|
|
966
|
-
cssClass: 'tekgrid-actions-dropdown',
|
|
967
|
-
offsetY: true,
|
|
968
|
-
activator: {
|
|
969
|
-
name: `${this.grid.name}_exportButton`,
|
|
970
|
-
component: 'ZdButton',
|
|
971
|
-
icon: true,
|
|
972
|
-
iconName: 'fileDownload',
|
|
973
|
-
isVisible: `{{GridController_${this.grid.componentId}.showExportButton}}`,
|
|
1023
|
+
name: `${this.grid.name}_saveButton`,
|
|
1024
|
+
component: 'ZdButton',
|
|
1025
|
+
label: 'TEKGRID_SAVE',
|
|
1026
|
+
isVisible: `{{GridController_${this.grid.componentId}.showEditButtons}}`,
|
|
1027
|
+
small: true,
|
|
1028
|
+
events: {
|
|
1029
|
+
click: this.saveChanges.bind(this),
|
|
974
1030
|
},
|
|
975
|
-
children: this.grid.exportActions || this.exportConfigButtons,
|
|
976
1031
|
},
|
|
977
1032
|
{
|
|
978
|
-
name: `${this.grid.name}
|
|
979
|
-
component: '
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
isVisible: `{{GridController_${this.grid.componentId}.showActionsButton}}`,
|
|
1033
|
+
name: `${this.grid.name}_cancelButton`,
|
|
1034
|
+
component: 'ZdButton',
|
|
1035
|
+
label: 'TEKGRID_CANCEL',
|
|
1036
|
+
outline: true,
|
|
1037
|
+
cssClass: 'zd-mx-2',
|
|
1038
|
+
isVisible: `{{GridController_${this.grid.componentId}.showEditButtons}}`,
|
|
1039
|
+
small: true,
|
|
1040
|
+
events: {
|
|
1041
|
+
click: this.cancelChanges.bind(this),
|
|
988
1042
|
},
|
|
989
|
-
children: this.grid.actions,
|
|
990
1043
|
},
|
|
991
1044
|
{
|
|
992
|
-
name: `${this.grid.name}
|
|
993
|
-
component: '
|
|
994
|
-
cssClass: '
|
|
995
|
-
|
|
996
|
-
isVisible: `{{GridController_${this.grid.componentId}.
|
|
1045
|
+
name: `${this.grid.name}_gridSearch`,
|
|
1046
|
+
component: 'ZdSearch',
|
|
1047
|
+
cssClass: 'zd-grid-search',
|
|
1048
|
+
iterableComponentName: `${this.grid.name}`,
|
|
1049
|
+
isVisible: `{{GridController_${this.grid.componentId}.showSearchInput}}`,
|
|
997
1050
|
},
|
|
998
|
-
],
|
|
999
|
-
},
|
|
1000
|
-
{
|
|
1001
|
-
name: `${this.grid.name}_saveButton`,
|
|
1002
|
-
component: 'ZdButton',
|
|
1003
|
-
label: 'TEKGRID_SAVE',
|
|
1004
|
-
isVisible: `{{GridController_${this.grid.componentId}.showEditButtons}}`,
|
|
1005
|
-
small: true,
|
|
1006
|
-
events: {
|
|
1007
|
-
click: this.saveChanges.bind(this),
|
|
1008
|
-
},
|
|
1009
|
-
},
|
|
1010
|
-
{
|
|
1011
|
-
name: `${this.grid.name}_cancelButton`,
|
|
1012
|
-
component: 'ZdButton',
|
|
1013
|
-
label: 'TEKGRID_CANCEL',
|
|
1014
|
-
outline: true,
|
|
1015
|
-
cssClass: 'zd-mx-2',
|
|
1016
|
-
isVisible: `{{GridController_${this.grid.componentId}.showEditButtons}}`,
|
|
1017
|
-
small: true,
|
|
1018
|
-
events: {
|
|
1019
|
-
click: this.cancelChanges.bind(this),
|
|
1020
|
-
},
|
|
1021
|
-
},
|
|
1022
|
-
{
|
|
1023
|
-
name: `${this.grid.name}_gridSearch`,
|
|
1024
|
-
component: 'ZdSearch',
|
|
1025
|
-
cssClass: 'zd-grid-search',
|
|
1026
|
-
isVisible: `{{GridController_${this.grid.componentId}.showSearchInput}}`,
|
|
1027
|
-
},
|
|
1028
|
-
{
|
|
1029
|
-
name: `${this.grid.name}_filter_tooltip`,
|
|
1030
|
-
component: 'ZdTooltip',
|
|
1031
|
-
label: 'TEKGRID_FILTER',
|
|
1032
|
-
bottom: true,
|
|
1033
|
-
children: [
|
|
1034
1051
|
{
|
|
1035
|
-
name: `${this.grid.name}
|
|
1036
|
-
component: '
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1052
|
+
name: `${this.grid.name}_filter_tooltip`,
|
|
1053
|
+
component: 'ZdTooltip',
|
|
1054
|
+
label: 'TEKGRID_FILTER',
|
|
1055
|
+
bottom: true,
|
|
1056
|
+
children: [
|
|
1057
|
+
{
|
|
1058
|
+
name: `${this.grid.name}_filterButton`,
|
|
1059
|
+
component: 'TekGridFilterButton',
|
|
1060
|
+
grid: this.grid,
|
|
1061
|
+
gridName: this.grid.name,
|
|
1062
|
+
showCheckboxAll: this.grid.showCheckboxAllFilter,
|
|
1063
|
+
isVisible: `{{GridController_${this.grid.componentId}.showFilterButton}}`,
|
|
1064
|
+
events: {
|
|
1065
|
+
onCreated: this.loadFilterButton.bind(this),
|
|
1066
|
+
},
|
|
1067
|
+
},
|
|
1068
|
+
],
|
|
1044
1069
|
},
|
|
1045
1070
|
],
|
|
1046
1071
|
},
|
|
@@ -1049,6 +1074,14 @@
|
|
|
1049
1074
|
loadFilterButton({ component }) {
|
|
1050
1075
|
this.filterButton = component;
|
|
1051
1076
|
}
|
|
1077
|
+
hideButtonClick({ event }) {
|
|
1078
|
+
if (!event.defaultPrevented) {
|
|
1079
|
+
const instance = core.Metadata.getInstance(`${this.grid.name}_toolbarDiv`);
|
|
1080
|
+
if (instance) {
|
|
1081
|
+
instance.isVisible = !instance.isVisible;
|
|
1082
|
+
}
|
|
1083
|
+
}
|
|
1084
|
+
}
|
|
1052
1085
|
addButtonClick({ event }) {
|
|
1053
1086
|
if (this.grid.editNewRowsOnly) {
|
|
1054
1087
|
this.grid.editingNewRows = true;
|
|
@@ -1170,6 +1203,8 @@
|
|
|
1170
1203
|
TEKGRID_BETWEEN: 'está entre',
|
|
1171
1204
|
TEKGRID_AND: 'e',
|
|
1172
1205
|
TEKGRID_OR: 'ou',
|
|
1206
|
+
TEKGRID_HIDE: 'Esconder Ações',
|
|
1207
|
+
TEKGRID_SHOW: 'Mostrar Ações',
|
|
1173
1208
|
TEKGRID_ADD: 'Adicionar',
|
|
1174
1209
|
TEKGRID_DELETE: 'Excluir',
|
|
1175
1210
|
TEKGRID_REFRESH: 'Atualizar',
|
|
@@ -1222,7 +1257,6 @@
|
|
|
1222
1257
|
TEKGRID_HELPERVALUE_CURRENT_MONTH: 'Mês Atual',
|
|
1223
1258
|
TEKGRID_HELPERVALUE_CURRENT_YEAR: 'Ano Atual',
|
|
1224
1259
|
TEKGRID_WITH_GROUPS: '(Com grupos)',
|
|
1225
|
-
TEKGRID_WITHOUT_GROUPS: '(Sem grupos)',
|
|
1226
1260
|
TEKGRID_GRID_MIRROR: '(Espelho do grid)',
|
|
1227
1261
|
},
|
|
1228
1262
|
},
|
|
@@ -1241,6 +1275,8 @@
|
|
|
1241
1275
|
TEKGRID_BETWEEN: 'is between',
|
|
1242
1276
|
TEKGRID_AND: 'and',
|
|
1243
1277
|
TEKGRID_OR: 'or',
|
|
1278
|
+
TEKGRID_HIDE: 'Hide Actions',
|
|
1279
|
+
TEKGRID_SHOW: 'Show Actions',
|
|
1244
1280
|
TEKGRID_ADD: 'Add',
|
|
1245
1281
|
TEKGRID_DELETE: 'Delete',
|
|
1246
1282
|
TEKGRID_REFRESH: 'Refresh',
|
|
@@ -1293,7 +1329,6 @@
|
|
|
1293
1329
|
TEKGRID_HELPERVALUE_CURRENT_MONTH: 'Current Month',
|
|
1294
1330
|
TEKGRID_HELPERVALUE_CURRENT_YEAR: 'Current Year',
|
|
1295
1331
|
TEKGRID_WITH_GROUPS: '(With groups)',
|
|
1296
|
-
TEKGRID_WITHOUT_GROUPS: '(No groups)',
|
|
1297
1332
|
TEKGRID_GRID_MIRROR: '(Grid mirror)',
|
|
1298
1333
|
},
|
|
1299
1334
|
},
|
|
@@ -1312,6 +1347,8 @@
|
|
|
1312
1347
|
TEKGRID_BETWEEN: 'está entre',
|
|
1313
1348
|
TEKGRID_AND: 'e',
|
|
1314
1349
|
TEKGRID_OR: 'o',
|
|
1350
|
+
TEKGRID_HIDE: 'Ocultar Acciones',
|
|
1351
|
+
TEKGRID_SHOW: 'Mostrar Acciones',
|
|
1315
1352
|
TEKGRID_ADD: 'Añadir',
|
|
1316
1353
|
TEKGRID_DELETE: 'Eliminar',
|
|
1317
1354
|
TEKGRID_REFRESH: 'Actualizar',
|
|
@@ -1364,7 +1401,6 @@
|
|
|
1364
1401
|
TEKGRID_HELPERVALUE_CURRENT_MONTH: 'Mes actual',
|
|
1365
1402
|
TEKGRID_HELPERVALUE_CURRENT_YEAR: 'Año actual',
|
|
1366
1403
|
TEKGRID_WITH_GROUPS: '(Con grupos)',
|
|
1367
|
-
TEKGRID_WITHOUT_GROUPS: '(No grupos)',
|
|
1368
1404
|
TEKGRID_GRID_MIRROR: '(Espejo de grid)',
|
|
1369
1405
|
},
|
|
1370
1406
|
},
|
|
@@ -1372,7 +1408,9 @@
|
|
|
1372
1408
|
|
|
1373
1409
|
class GridController {
|
|
1374
1410
|
constructor(grid) {
|
|
1411
|
+
this.openToolbar = true;
|
|
1375
1412
|
this.grid = grid;
|
|
1413
|
+
this.openToolbar = this.grid.toolbarOpened;
|
|
1376
1414
|
}
|
|
1377
1415
|
get gridTitle() {
|
|
1378
1416
|
return this.grid.title;
|
|
@@ -1392,6 +1430,18 @@
|
|
|
1392
1430
|
get showSearchInput() {
|
|
1393
1431
|
return this.grid.showSearch;
|
|
1394
1432
|
}
|
|
1433
|
+
get showToolbar() {
|
|
1434
|
+
return this.openToolbar;
|
|
1435
|
+
}
|
|
1436
|
+
set showToolbar(value) {
|
|
1437
|
+
this.openToolbar = value;
|
|
1438
|
+
}
|
|
1439
|
+
get toolbarStyle() {
|
|
1440
|
+
return !this.openToolbar ? 'is-rotated' : '';
|
|
1441
|
+
}
|
|
1442
|
+
get tooltipName() {
|
|
1443
|
+
return !this.openToolbar ? 'TEKGRID_SHOW' : 'TEKGRID_HIDE';
|
|
1444
|
+
}
|
|
1395
1445
|
get showReloadButton() {
|
|
1396
1446
|
return this.grid.showReload;
|
|
1397
1447
|
}
|
|
@@ -2190,7 +2240,7 @@
|
|
|
2190
2240
|
{
|
|
2191
2241
|
type: 'xls',
|
|
2192
2242
|
label: core.I18n.translate('TEKGRID_EXPORT_AS', {
|
|
2193
|
-
type:
|
|
2243
|
+
type: 'XLS',
|
|
2194
2244
|
}),
|
|
2195
2245
|
},
|
|
2196
2246
|
{
|
|
@@ -2226,6 +2276,8 @@
|
|
|
2226
2276
|
this.editNewRowsOnly = false;
|
|
2227
2277
|
this.showCheckboxAllFilter = core.Config.gridShowCheckboxAllFilter || false;
|
|
2228
2278
|
this.defaultFilter = {};
|
|
2279
|
+
this.toolbarOpened = true;
|
|
2280
|
+
this.reportTitle = '';
|
|
2229
2281
|
this.defaultLazy = false;
|
|
2230
2282
|
this.groups = [];
|
|
2231
2283
|
this.summary = {};
|
|
@@ -2259,8 +2311,10 @@
|
|
|
2259
2311
|
this.showSummaryTotal = this.getInitValue('showSummaryTotal', props.showSummaryTotal, this.showSummaryTotal);
|
|
2260
2312
|
this.showCheckboxAllFilter = this.getInitValue('showCheckboxAllFilter', props.showCheckboxAllFilter, this.showCheckboxAllFilter);
|
|
2261
2313
|
this.defaultFilter = this.getInitValue('defaultFilter', props.defaultFilter, this.defaultFilter);
|
|
2314
|
+
this.toolbarOpened = this.getInitValue('toolbarOpened', props.toolbarOpened, this.toolbarOpened);
|
|
2262
2315
|
this.editNewRowsOnly = this.getInitValue('editNewRowsOnly', props.editNewRowsOnly, this.editNewRowsOnly);
|
|
2263
2316
|
this.mainGrid = this.getInitValue('mainGrid', props.mainGrid, this.mainGrid);
|
|
2317
|
+
this.reportTitle = this.getInitValue('reportTitle', props.reportTitle, this.reportTitle);
|
|
2264
2318
|
this.actions = props.actions || this.actions;
|
|
2265
2319
|
this.toolbarSlotProps = props.toolbarSlot !== undefined;
|
|
2266
2320
|
if (this.deleteButton === 'selection') {
|
|
@@ -2390,9 +2444,13 @@
|
|
|
2390
2444
|
}
|
|
2391
2445
|
getReport(type, portrait, rowObj = {}) {
|
|
2392
2446
|
return __awaiter(this, void 0, void 0, function* () {
|
|
2393
|
-
const report = new common.Report(this, this.title);
|
|
2447
|
+
const report = new common.Report(this, this.title || this.reportTitle);
|
|
2394
2448
|
const reportGroups = this.buildReportGroups();
|
|
2395
2449
|
const reportAggregations = this.buildReportAggregations();
|
|
2450
|
+
let typeValue = type;
|
|
2451
|
+
if (reportGroups.length === 0 && type.substring(0, 3) === 'xls') {
|
|
2452
|
+
typeValue = 'xls';
|
|
2453
|
+
}
|
|
2396
2454
|
let filter;
|
|
2397
2455
|
if (this.datasource instanceof TekRestDatasource
|
|
2398
2456
|
|| this.datasource instanceof TekMemoryDatasource) {
|
|
@@ -2434,7 +2492,7 @@
|
|
|
2434
2492
|
beforeOpen = this.events.beforeOpenReport;
|
|
2435
2493
|
}
|
|
2436
2494
|
return report
|
|
2437
|
-
.getReport(
|
|
2495
|
+
.getReport(typeValue, portrait, {
|
|
2438
2496
|
metaData: merge__default["default"](rowObj, {
|
|
2439
2497
|
filter,
|
|
2440
2498
|
groups: reportGroups,
|
|
@@ -3443,6 +3501,13 @@
|
|
|
3443
3501
|
this.layouts[layout.name] = layout;
|
|
3444
3502
|
this.saveLayouts();
|
|
3445
3503
|
}
|
|
3504
|
+
discardChanges() {
|
|
3505
|
+
const layoutSelected = this.layouts[this.currentLayoutName];
|
|
3506
|
+
if (this.viewApplyLayout) {
|
|
3507
|
+
this.viewApplyLayout(layoutSelected);
|
|
3508
|
+
}
|
|
3509
|
+
this.layoutEdited = false;
|
|
3510
|
+
}
|
|
3446
3511
|
applyLayout(name, save = true) {
|
|
3447
3512
|
this.currentLayoutName = name;
|
|
3448
3513
|
const layoutSelected = this.layouts[name];
|
|
@@ -3600,6 +3665,7 @@
|
|
|
3600
3665
|
* Show refresh button
|
|
3601
3666
|
*/
|
|
3602
3667
|
this.showReload = true;
|
|
3668
|
+
this.toolbarOpened = true;
|
|
3603
3669
|
/**
|
|
3604
3670
|
* Export config
|
|
3605
3671
|
*/
|
|
@@ -3620,7 +3686,7 @@
|
|
|
3620
3686
|
{
|
|
3621
3687
|
type: 'xls',
|
|
3622
3688
|
label: core.I18n.translate('TEKGRID_EXPORT_AS', {
|
|
3623
|
-
type:
|
|
3689
|
+
type: 'XLS',
|
|
3624
3690
|
}),
|
|
3625
3691
|
},
|
|
3626
3692
|
{
|
|
@@ -3643,6 +3709,7 @@
|
|
|
3643
3709
|
this.toolbarSlotProps = false;
|
|
3644
3710
|
this.showCheckboxAllFilter = false;
|
|
3645
3711
|
this.defaultFilter = {};
|
|
3712
|
+
this.reportTitle = '';
|
|
3646
3713
|
this.title = this.getInitValue('title', props.title, this.title);
|
|
3647
3714
|
this.addButton = this.getInitValue('addButton', props.addButton, this.addButton);
|
|
3648
3715
|
this.deleteButton = this.getInitValue('deleteButton', props.deleteButton, this.deleteButton);
|
|
@@ -3660,7 +3727,9 @@
|
|
|
3660
3727
|
this.exportConfig = this.getInitValue('exportConfig', props.exportConfig, this.exportConfig);
|
|
3661
3728
|
this.showCheckboxAllFilter = this.getInitValue('showCheckboxAllFilter', props.showCheckboxAllFilter, this.showCheckboxAllFilter);
|
|
3662
3729
|
this.defaultFilter = this.getInitValue('defaultFilter', props.defaultFilter, this.defaultFilter);
|
|
3730
|
+
this.toolbarOpened = this.getInitValue('toolbarOpened', props.toolbarOpened, this.toolbarOpened);
|
|
3663
3731
|
this.exportActions = props.exportActions || this.exportActions;
|
|
3732
|
+
this.reportTitle = this.getInitValue('reportTitle', props.reportTitle, this.reportTitle);
|
|
3664
3733
|
this.actions = props.actions || this.actions;
|
|
3665
3734
|
this.toolbarSlotProps = props.toolbarSlot !== undefined;
|
|
3666
3735
|
if (this.deleteButton === 'selection') {
|
|
@@ -3740,7 +3809,7 @@
|
|
|
3740
3809
|
}
|
|
3741
3810
|
getReport(type, portrait, rowObj = {}) {
|
|
3742
3811
|
return __awaiter(this, void 0, void 0, function* () {
|
|
3743
|
-
const report = new common.Report(this, this.title);
|
|
3812
|
+
const report = new common.Report(this, this.title || this.reportTitle);
|
|
3744
3813
|
const reportGroups = {};
|
|
3745
3814
|
const reportAggregations = {};
|
|
3746
3815
|
let filter;
|
|
@@ -4325,6 +4394,9 @@
|
|
|
4325
4394
|
LAYOUT: 'Layout: ',
|
|
4326
4395
|
NEW_LAYOUT: 'Novo layout',
|
|
4327
4396
|
DEFAULT_LAYOUT: 'Padrão',
|
|
4397
|
+
LAYOUT_MODIFIED: 'O layout atual foi modificado. Crie um novo layout, sobrescreva um existente ou descarte as alterações',
|
|
4398
|
+
LAYOUT_NOT_MODIFIED: 'Crie um novo layout ou aplique um dos layouts já existentes',
|
|
4399
|
+
LAYOUT_DISCART_CHANGES: 'Descartar alterações',
|
|
4328
4400
|
},
|
|
4329
4401
|
},
|
|
4330
4402
|
'en-US': {
|
|
@@ -4340,6 +4412,9 @@
|
|
|
4340
4412
|
LAYOUT: 'Layout: ',
|
|
4341
4413
|
NEW_LAYOUT: 'New layout',
|
|
4342
4414
|
DEFAULT_LAYOUT: 'Default',
|
|
4415
|
+
LAYOUT_MODIFIED: 'The current layout has been modified. Create a new layout, overwrite an existing one or discard changes',
|
|
4416
|
+
LAYOUT_NOT_MODIFIED: 'Create a new layout or apply one of the existing layouts',
|
|
4417
|
+
LAYOUT_DISCART_CHANGES: 'Discard changes',
|
|
4343
4418
|
},
|
|
4344
4419
|
},
|
|
4345
4420
|
'es-CL': {
|
|
@@ -4355,6 +4430,9 @@
|
|
|
4355
4430
|
LAYOUT: 'Disposición: ',
|
|
4356
4431
|
NEW_LAYOUT: 'Nueva disposición',
|
|
4357
4432
|
DEFAULT_LAYOUT: 'Default',
|
|
4433
|
+
LAYOUT_MODIFIED: 'La disposición actual ha sido modificada. Cree una nueva disposición, sobrescriba una existente o descarte los cambios',
|
|
4434
|
+
LAYOUT_NOT_MODIFIED: 'Cree una nueva disposición o aplique una de las disposiciones existentes',
|
|
4435
|
+
LAYOUT_DISCART_CHANGES: 'Descartar los cambios',
|
|
4358
4436
|
},
|
|
4359
4437
|
},
|
|
4360
4438
|
});
|
|
@@ -4383,6 +4461,7 @@
|
|
|
4383
4461
|
exports.TekGrid = TekGrid;
|
|
4384
4462
|
exports.TekGridColumn = TekGridColumn;
|
|
4385
4463
|
exports.TekGridColumnsButton = TekGridColumnsButton;
|
|
4464
|
+
exports.TekGridColumnsButtonController = TekGridColumnsButtonController;
|
|
4386
4465
|
exports.TekGridFilterButton = TekGridFilterButton;
|
|
4387
4466
|
exports.TekGridLayoutOptions = TekGridLayoutOptions;
|
|
4388
4467
|
exports.TekMemoryDatasource = TekMemoryDatasource;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zeedhi/teknisa-components-common",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.103.0",
|
|
4
4
|
"description": "Teknisa Components Common",
|
|
5
5
|
"author": "Zeedhi <zeedhi@teknisa.com>",
|
|
6
6
|
"license": "ISC",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"@types/lodash.merge": "4.6.*"
|
|
31
31
|
},
|
|
32
32
|
"peerDependencies": {
|
|
33
|
-
"@zeedhi/core": "
|
|
33
|
+
"@zeedhi/core": "^1.97.0"
|
|
34
34
|
},
|
|
35
|
-
"gitHead": "
|
|
35
|
+
"gitHead": "f5fd5144d582c73468d08511c491868f5f4b71c8"
|
|
36
36
|
}
|