@trudb/tru-common-lib 0.2.226 → 0.2.228
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.
|
@@ -3996,13 +3996,14 @@ class TruDetailViewBase {
|
|
|
3996
3996
|
toolbarContainerRef.instance.getEntities = () => { return [this.entity]; };
|
|
3997
3997
|
});
|
|
3998
3998
|
};
|
|
3999
|
-
onAddEntity = (newEntity) => {
|
|
3999
|
+
onAddEntity = (newEntity, dataNotification = false) => {
|
|
4000
4000
|
if (!newEntity)
|
|
4001
4001
|
newEntity = this.dataContext.entityAccess().add(this.entityType);
|
|
4002
4002
|
if (this.view.parentTableRefName)
|
|
4003
4003
|
newEntity[this.view.parentTableRefName] = this.entity[this.view.parentTableRefName];
|
|
4004
4004
|
this.entities.unshift(newEntity);
|
|
4005
|
-
|
|
4005
|
+
if (!dataNotification)
|
|
4006
|
+
this.navigateTo(0);
|
|
4006
4007
|
};
|
|
4007
4008
|
onCloneEntity = () => {
|
|
4008
4009
|
let windowEventArgs = this.desktopManager.addModalWindow(this.tableName, this.tableName, this.tableName, 'TruCloneView', this.entities, this.navigationIndex, this.dataContext, false, false, false);
|
|
@@ -7805,7 +7806,7 @@ class TruDataGrid {
|
|
|
7805
7806
|
});
|
|
7806
7807
|
if (!entityAlreadyInGrid) {
|
|
7807
7808
|
rowNodesToAdd.push(this.enhanceRowDataForEntity(entity));
|
|
7808
|
-
this.api.applyTransaction({ add: rowNodesToAdd });
|
|
7809
|
+
this.api.applyTransaction({ add: rowNodesToAdd, addIndex: 0 });
|
|
7809
7810
|
}
|
|
7810
7811
|
}
|
|
7811
7812
|
}));
|