@zeedhi/common 1.110.1 → 1.111.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/dist/zd-common.esm.js
CHANGED
|
@@ -6820,6 +6820,10 @@ class GridEditable extends Grid {
|
|
|
6820
6820
|
};
|
|
6821
6821
|
this.viewEnterEdit = null;
|
|
6822
6822
|
this.showCancelColumn = false;
|
|
6823
|
+
/**
|
|
6824
|
+
* Define se o evento rowClick deve ser chamado ao clicar em uma célula editável
|
|
6825
|
+
*/
|
|
6826
|
+
this.preventRowClickOnEditing = true;
|
|
6823
6827
|
this.newRowIdentifier = '__added_row';
|
|
6824
6828
|
this.positionIdentifier = '__position';
|
|
6825
6829
|
this.pageIdentifier = '__page';
|
|
@@ -6829,6 +6833,7 @@ class GridEditable extends Grid {
|
|
|
6829
6833
|
this.editingNewRows = this.getInitValue('editingNewRows', props.editingNewRows, this.editingNewRows);
|
|
6830
6834
|
this.singleEdit = this.getInitValue('singleEdit', props.singleEdit, this.singleEdit);
|
|
6831
6835
|
this.showCancelColumn = this.getInitValue('showCancelColumn', props.showCancelColumn, this.showCancelColumn);
|
|
6836
|
+
this.preventRowClickOnEditing = this.getInitValue('preventRowClickOnEditing', props.preventRowClickOnEditing, this.preventRowClickOnEditing);
|
|
6832
6837
|
this.createAccessors();
|
|
6833
6838
|
this.addCancelColumn();
|
|
6834
6839
|
this.registerDatasourceCallback();
|
|
@@ -6957,7 +6962,7 @@ class GridEditable extends Grid {
|
|
|
6957
6962
|
*/
|
|
6958
6963
|
cellClick(row, column, event, element, canEdit = true) {
|
|
6959
6964
|
if (column.editable && canEdit) {
|
|
6960
|
-
this.preventRowClick =
|
|
6965
|
+
this.preventRowClick = (this.preventRowClickOnEditing !== false);
|
|
6961
6966
|
this.datasource.currentRow = row;
|
|
6962
6967
|
this.inlineEdit(row, column, event, element);
|
|
6963
6968
|
return;
|
|
@@ -7088,6 +7093,15 @@ class GridEditable extends Grid {
|
|
|
7088
7093
|
component, event, element, row, column,
|
|
7089
7094
|
});
|
|
7090
7095
|
}
|
|
7096
|
+
}, click: ({ event, element, component }) => {
|
|
7097
|
+
if (this.preventRowClickOnEditing === false) {
|
|
7098
|
+
this.rowClick(row, event, element);
|
|
7099
|
+
}
|
|
7100
|
+
if (compEvents.click) {
|
|
7101
|
+
compEvents.click({
|
|
7102
|
+
component, event, element,
|
|
7103
|
+
});
|
|
7104
|
+
}
|
|
7091
7105
|
} });
|
|
7092
7106
|
this.updateOriginalRow(key, row);
|
|
7093
7107
|
return Object.assign(Object.assign({}, componentProps), { name: compName, parent: this, align: column.align, showLabel: false, showHelper: false, dense: true, value: colValue, events: newEvents, autofill: false, allowDuplicate: true, autoRegister: false });
|
package/dist/zd-common.umd.js
CHANGED
|
@@ -6827,6 +6827,10 @@
|
|
|
6827
6827
|
};
|
|
6828
6828
|
this.viewEnterEdit = null;
|
|
6829
6829
|
this.showCancelColumn = false;
|
|
6830
|
+
/**
|
|
6831
|
+
* Define se o evento rowClick deve ser chamado ao clicar em uma célula editável
|
|
6832
|
+
*/
|
|
6833
|
+
this.preventRowClickOnEditing = true;
|
|
6830
6834
|
this.newRowIdentifier = '__added_row';
|
|
6831
6835
|
this.positionIdentifier = '__position';
|
|
6832
6836
|
this.pageIdentifier = '__page';
|
|
@@ -6836,6 +6840,7 @@
|
|
|
6836
6840
|
this.editingNewRows = this.getInitValue('editingNewRows', props.editingNewRows, this.editingNewRows);
|
|
6837
6841
|
this.singleEdit = this.getInitValue('singleEdit', props.singleEdit, this.singleEdit);
|
|
6838
6842
|
this.showCancelColumn = this.getInitValue('showCancelColumn', props.showCancelColumn, this.showCancelColumn);
|
|
6843
|
+
this.preventRowClickOnEditing = this.getInitValue('preventRowClickOnEditing', props.preventRowClickOnEditing, this.preventRowClickOnEditing);
|
|
6839
6844
|
this.createAccessors();
|
|
6840
6845
|
this.addCancelColumn();
|
|
6841
6846
|
this.registerDatasourceCallback();
|
|
@@ -6964,7 +6969,7 @@
|
|
|
6964
6969
|
*/
|
|
6965
6970
|
cellClick(row, column, event, element, canEdit = true) {
|
|
6966
6971
|
if (column.editable && canEdit) {
|
|
6967
|
-
this.preventRowClick =
|
|
6972
|
+
this.preventRowClick = (this.preventRowClickOnEditing !== false);
|
|
6968
6973
|
this.datasource.currentRow = row;
|
|
6969
6974
|
this.inlineEdit(row, column, event, element);
|
|
6970
6975
|
return;
|
|
@@ -7095,6 +7100,15 @@
|
|
|
7095
7100
|
component, event, element, row, column,
|
|
7096
7101
|
});
|
|
7097
7102
|
}
|
|
7103
|
+
}, click: ({ event, element, component }) => {
|
|
7104
|
+
if (this.preventRowClickOnEditing === false) {
|
|
7105
|
+
this.rowClick(row, event, element);
|
|
7106
|
+
}
|
|
7107
|
+
if (compEvents.click) {
|
|
7108
|
+
compEvents.click({
|
|
7109
|
+
component, event, element,
|
|
7110
|
+
});
|
|
7111
|
+
}
|
|
7098
7112
|
} });
|
|
7099
7113
|
this.updateOriginalRow(key, row);
|
|
7100
7114
|
return Object.assign(Object.assign({}, componentProps), { name: compName, parent: this, align: column.align, showLabel: false, showHelper: false, dense: true, value: colValue, events: newEvents, autofill: false, allowDuplicate: true, autoRegister: false });
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zeedhi/common",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.111.0",
|
|
4
4
|
"description": "Zeedhi Common",
|
|
5
5
|
"author": "Zeedhi <zeedhi@teknisa.com>",
|
|
6
6
|
"license": "ISC",
|
|
@@ -43,5 +43,5 @@
|
|
|
43
43
|
"lodash.times": "4.3.*",
|
|
44
44
|
"mockdate": "3.0.*"
|
|
45
45
|
},
|
|
46
|
-
"gitHead": "
|
|
46
|
+
"gitHead": "f75c602a03ad29224ec2058a01a9b02f2e37cc6f"
|
|
47
47
|
}
|
|
@@ -48,6 +48,10 @@ export declare class GridEditable extends Grid implements IGridEditable {
|
|
|
48
48
|
protected viewEnterEdit: ((rowKey: string, columnName: string) => void) | null;
|
|
49
49
|
setViewEnterEdit(viewEnterEdit: (rowKey: string, columnName: string) => void): void;
|
|
50
50
|
showCancelColumn: boolean;
|
|
51
|
+
/**
|
|
52
|
+
* Define se o evento rowClick deve ser chamado ao clicar em uma célula editável
|
|
53
|
+
*/
|
|
54
|
+
preventRowClickOnEditing: boolean;
|
|
51
55
|
constructor(props: IGridEditable);
|
|
52
56
|
onMounted(element: any): void;
|
|
53
57
|
onBeforeDestroy(): void;
|