SearchValue value no longer displayed when go-back to component ( even if stateStorage="session") #16401
Labels
Status: Needs Triage
Issue will be reviewed by Core Team and a relevant label will be added as soon as possible
Describe the bug
Hi,
Hi found a bug on the PrimeNG datatable pInputText field (for filter with search value).
<input pInputText type="text" [(ngModel)]="searchValue" (input)="dt.filterGlobal($event.target.value, 'contains')" placeholder="Rechercher" />
I use [stateStorage]="session", it saves the sort column but also this search value filter in the sessionStorage.
However, when I leave and then come-back to the component, this filter is applied based on the searchValue, but the searchValue is no longer displayed in the input, why ?
Thanks for your help,
Best regards,
JC AUDARD
Environment
Windows 10 Professionnel
Node JS 18.13.0
Angular 17
PrimeNG 17.18.10
Reproducer
No response
Angular version
17.3.0
PrimeNG version
17.18.10
Build / Runtime
Angular CLI App
Language
TypeScript
Node version (for AoT issues node --version)
18.13.0
Browser(s)
Firefox
Steps to reproduce the behavior
Go to a datatable (configureded with [stateStorage]="session") and apply a filter with the search field on the right.
Leave the component , go to another component
Go-back to the component, the filter input text is empty even if the filter is applied (because saved in session)
Expected behavior
The filter input text should be filled with the searchValue
The text was updated successfully, but these errors were encountered: