You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I currently have 2 slickgrids in the same view. I want to save both their states to the database. The problem however is that the gridStateService still seems to be a singular object. So only the state of the 2nd grid is saved correctly.
Expected Behavior
I expected that both grids have their own gridStateService, so both states can be saved.
Current Behavior
Only the 2nd grid saves it's state correctly. I've been testing some of the variables and the result was:
this.gridRequest.exportService === this.gridAvailability.exportService -> false
this.gridRequest.extensionService === this.gridAvailability.extensionService -> false
this.gridRequest.filterService === this.gridAvailability.filterService -> false
this.gridRequest.gridEventService === this.gridAvailability.gridEventService -> false
this.gridRequest.groupingService === this.gridAvailability.groupingService -> false
this.gridRequest.gridStateService === this.gridAvailability.gridStateService -> true
this.gridRequest.sortService === this.gridAvailability.sortService -> false
this.gridRequest.gridService === this.gridAvailability.gridService -> false
It seems that the gridStateService is shared amongst the 2 grid, causing this problem.
The text was updated successfully, but these errors were encountered:
Good catch, it seems we forgot to add the @singleton(true) on top of the Service like all other services, for example this line is for the GridService. I'll have to review all Services to make sure they are singleton
I'm submitting a Bug report
Your Environment
Context
I currently have 2 slickgrids in the same view. I want to save both their states to the database. The problem however is that the gridStateService still seems to be a singular object. So only the state of the 2nd grid is saved correctly.
Expected Behavior
I expected that both grids have their own gridStateService, so both states can be saved.
Current Behavior
Only the 2nd grid saves it's state correctly. I've been testing some of the variables and the result was:
this.gridRequest.exportService === this.gridAvailability.exportService -> false
this.gridRequest.extensionService === this.gridAvailability.extensionService -> false
this.gridRequest.filterService === this.gridAvailability.filterService -> false
this.gridRequest.gridEventService === this.gridAvailability.gridEventService -> false
this.gridRequest.groupingService === this.gridAvailability.groupingService -> false
this.gridRequest.gridStateService === this.gridAvailability.gridStateService -> true
this.gridRequest.sortService === this.gridAvailability.sortService -> false
this.gridRequest.gridService === this.gridAvailability.gridService -> false
It seems that the gridStateService is shared amongst the 2 grid, causing this problem.
The text was updated successfully, but these errors were encountered: