@zeedhi/teknisa-components-common 1.101.0 → 1.102.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 +706 -687
- package/coverage/coverage-final.json +45 -45
- package/coverage/lcov-report/index.html +17 -17
- package/coverage/lcov-report/tests/__helpers__/component-event-helper.ts.html +1 -1
- package/coverage/lcov-report/tests/__helpers__/flush-promises-helper.ts.html +1 -1
- package/coverage/lcov-report/tests/__helpers__/get-child-helper.ts.html +7 -7
- 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.info +1213 -1175
- package/dist/tek-components-common.esm.js +236 -163
- package/dist/tek-components-common.umd.js +235 -161
- package/package.json +2 -2
- package/tests/unit/components/tek-grid/grid.spec.ts +197 -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 +1 -0
- package/types/components/tek-grid/interfaces.d.ts +1 -0
- package/types/components/tek-grid/layout-options.d.ts +2 -0
- package/types/components/tek-tree-grid/interfaces.d.ts +1 -0
- package/types/components/tek-tree-grid/tree-grid.d.ts +1 -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',
|
|
@@ -1241,6 +1276,8 @@
|
|
|
1241
1276
|
TEKGRID_BETWEEN: 'is between',
|
|
1242
1277
|
TEKGRID_AND: 'and',
|
|
1243
1278
|
TEKGRID_OR: 'or',
|
|
1279
|
+
TEKGRID_HIDE: 'Hide Actions',
|
|
1280
|
+
TEKGRID_SHOW: 'Show Actions',
|
|
1244
1281
|
TEKGRID_ADD: 'Add',
|
|
1245
1282
|
TEKGRID_DELETE: 'Delete',
|
|
1246
1283
|
TEKGRID_REFRESH: 'Refresh',
|
|
@@ -1312,6 +1349,8 @@
|
|
|
1312
1349
|
TEKGRID_BETWEEN: 'está entre',
|
|
1313
1350
|
TEKGRID_AND: 'e',
|
|
1314
1351
|
TEKGRID_OR: 'o',
|
|
1352
|
+
TEKGRID_HIDE: 'Ocultar Acciones',
|
|
1353
|
+
TEKGRID_SHOW: 'Mostrar Acciones',
|
|
1315
1354
|
TEKGRID_ADD: 'Añadir',
|
|
1316
1355
|
TEKGRID_DELETE: 'Eliminar',
|
|
1317
1356
|
TEKGRID_REFRESH: 'Actualizar',
|
|
@@ -1372,7 +1411,9 @@
|
|
|
1372
1411
|
|
|
1373
1412
|
class GridController {
|
|
1374
1413
|
constructor(grid) {
|
|
1414
|
+
this.openToolbar = true;
|
|
1375
1415
|
this.grid = grid;
|
|
1416
|
+
this.openToolbar = this.grid.toolbarOpened;
|
|
1376
1417
|
}
|
|
1377
1418
|
get gridTitle() {
|
|
1378
1419
|
return this.grid.title;
|
|
@@ -1392,6 +1433,18 @@
|
|
|
1392
1433
|
get showSearchInput() {
|
|
1393
1434
|
return this.grid.showSearch;
|
|
1394
1435
|
}
|
|
1436
|
+
get showToolbar() {
|
|
1437
|
+
return this.openToolbar;
|
|
1438
|
+
}
|
|
1439
|
+
set showToolbar(value) {
|
|
1440
|
+
this.openToolbar = value;
|
|
1441
|
+
}
|
|
1442
|
+
get toolbarStyle() {
|
|
1443
|
+
return !this.openToolbar ? 'is-rotated' : '';
|
|
1444
|
+
}
|
|
1445
|
+
get tooltipName() {
|
|
1446
|
+
return !this.openToolbar ? 'TEKGRID_SHOW' : 'TEKGRID_HIDE';
|
|
1447
|
+
}
|
|
1395
1448
|
get showReloadButton() {
|
|
1396
1449
|
return this.grid.showReload;
|
|
1397
1450
|
}
|
|
@@ -2226,6 +2279,7 @@
|
|
|
2226
2279
|
this.editNewRowsOnly = false;
|
|
2227
2280
|
this.showCheckboxAllFilter = core.Config.gridShowCheckboxAllFilter || false;
|
|
2228
2281
|
this.defaultFilter = {};
|
|
2282
|
+
this.toolbarOpened = true;
|
|
2229
2283
|
this.defaultLazy = false;
|
|
2230
2284
|
this.groups = [];
|
|
2231
2285
|
this.summary = {};
|
|
@@ -2259,6 +2313,7 @@
|
|
|
2259
2313
|
this.showSummaryTotal = this.getInitValue('showSummaryTotal', props.showSummaryTotal, this.showSummaryTotal);
|
|
2260
2314
|
this.showCheckboxAllFilter = this.getInitValue('showCheckboxAllFilter', props.showCheckboxAllFilter, this.showCheckboxAllFilter);
|
|
2261
2315
|
this.defaultFilter = this.getInitValue('defaultFilter', props.defaultFilter, this.defaultFilter);
|
|
2316
|
+
this.toolbarOpened = this.getInitValue('toolbarOpened', props.toolbarOpened, this.toolbarOpened);
|
|
2262
2317
|
this.editNewRowsOnly = this.getInitValue('editNewRowsOnly', props.editNewRowsOnly, this.editNewRowsOnly);
|
|
2263
2318
|
this.mainGrid = this.getInitValue('mainGrid', props.mainGrid, this.mainGrid);
|
|
2264
2319
|
this.actions = props.actions || this.actions;
|
|
@@ -3443,6 +3498,13 @@
|
|
|
3443
3498
|
this.layouts[layout.name] = layout;
|
|
3444
3499
|
this.saveLayouts();
|
|
3445
3500
|
}
|
|
3501
|
+
discardChanges() {
|
|
3502
|
+
const layoutSelected = this.layouts[this.currentLayoutName];
|
|
3503
|
+
if (this.viewApplyLayout) {
|
|
3504
|
+
this.viewApplyLayout(layoutSelected);
|
|
3505
|
+
}
|
|
3506
|
+
this.layoutEdited = false;
|
|
3507
|
+
}
|
|
3446
3508
|
applyLayout(name, save = true) {
|
|
3447
3509
|
this.currentLayoutName = name;
|
|
3448
3510
|
const layoutSelected = this.layouts[name];
|
|
@@ -3600,6 +3662,7 @@
|
|
|
3600
3662
|
* Show refresh button
|
|
3601
3663
|
*/
|
|
3602
3664
|
this.showReload = true;
|
|
3665
|
+
this.toolbarOpened = true;
|
|
3603
3666
|
/**
|
|
3604
3667
|
* Export config
|
|
3605
3668
|
*/
|
|
@@ -3660,6 +3723,7 @@
|
|
|
3660
3723
|
this.exportConfig = this.getInitValue('exportConfig', props.exportConfig, this.exportConfig);
|
|
3661
3724
|
this.showCheckboxAllFilter = this.getInitValue('showCheckboxAllFilter', props.showCheckboxAllFilter, this.showCheckboxAllFilter);
|
|
3662
3725
|
this.defaultFilter = this.getInitValue('defaultFilter', props.defaultFilter, this.defaultFilter);
|
|
3726
|
+
this.toolbarOpened = this.getInitValue('toolbarOpened', props.toolbarOpened, this.toolbarOpened);
|
|
3663
3727
|
this.exportActions = props.exportActions || this.exportActions;
|
|
3664
3728
|
this.actions = props.actions || this.actions;
|
|
3665
3729
|
this.toolbarSlotProps = props.toolbarSlot !== undefined;
|
|
@@ -4325,6 +4389,9 @@
|
|
|
4325
4389
|
LAYOUT: 'Layout: ',
|
|
4326
4390
|
NEW_LAYOUT: 'Novo layout',
|
|
4327
4391
|
DEFAULT_LAYOUT: 'Padrão',
|
|
4392
|
+
LAYOUT_MODIFIED: 'O layout atual foi modificado. Crie um novo layout, sobrescreva um existente ou descarte as alterações',
|
|
4393
|
+
LAYOUT_NOT_MODIFIED: 'Crie um novo layout ou aplique um dos layouts já existentes',
|
|
4394
|
+
LAYOUT_DISCART_CHANGES: 'Descartar alterações',
|
|
4328
4395
|
},
|
|
4329
4396
|
},
|
|
4330
4397
|
'en-US': {
|
|
@@ -4340,6 +4407,9 @@
|
|
|
4340
4407
|
LAYOUT: 'Layout: ',
|
|
4341
4408
|
NEW_LAYOUT: 'New layout',
|
|
4342
4409
|
DEFAULT_LAYOUT: 'Default',
|
|
4410
|
+
LAYOUT_MODIFIED: 'The current layout has been modified. Create a new layout, overwrite an existing one or discard changes',
|
|
4411
|
+
LAYOUT_NOT_MODIFIED: 'Create a new layout or apply one of the existing layouts',
|
|
4412
|
+
LAYOUT_DISCART_CHANGES: 'Discard changes',
|
|
4343
4413
|
},
|
|
4344
4414
|
},
|
|
4345
4415
|
'es-CL': {
|
|
@@ -4355,6 +4425,9 @@
|
|
|
4355
4425
|
LAYOUT: 'Disposición: ',
|
|
4356
4426
|
NEW_LAYOUT: 'Nueva disposición',
|
|
4357
4427
|
DEFAULT_LAYOUT: 'Default',
|
|
4428
|
+
LAYOUT_MODIFIED: 'La disposición actual ha sido modificada. Cree una nueva disposición, sobrescriba una existente o descarte los cambios',
|
|
4429
|
+
LAYOUT_NOT_MODIFIED: 'Cree una nueva disposición o aplique una de las disposiciones existentes',
|
|
4430
|
+
LAYOUT_DISCART_CHANGES: 'Descartar los cambios',
|
|
4358
4431
|
},
|
|
4359
4432
|
},
|
|
4360
4433
|
});
|
|
@@ -4383,6 +4456,7 @@
|
|
|
4383
4456
|
exports.TekGrid = TekGrid;
|
|
4384
4457
|
exports.TekGridColumn = TekGridColumn;
|
|
4385
4458
|
exports.TekGridColumnsButton = TekGridColumnsButton;
|
|
4459
|
+
exports.TekGridColumnsButtonController = TekGridColumnsButtonController;
|
|
4386
4460
|
exports.TekGridFilterButton = TekGridFilterButton;
|
|
4387
4461
|
exports.TekGridLayoutOptions = TekGridLayoutOptions;
|
|
4388
4462
|
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.102.0",
|
|
4
4
|
"description": "Teknisa Components Common",
|
|
5
5
|
"author": "Zeedhi <zeedhi@teknisa.com>",
|
|
6
6
|
"license": "ISC",
|
|
@@ -32,5 +32,5 @@
|
|
|
32
32
|
"peerDependencies": {
|
|
33
33
|
"@zeedhi/core": "~1.97.0"
|
|
34
34
|
},
|
|
35
|
-
"gitHead": "
|
|
35
|
+
"gitHead": "b97e803072580b43c8e2e83a1f467186616e42ae"
|
|
36
36
|
}
|