There will be two issues in the code which might be causing the filter problem , below fixes solve the problem
"enforceFocus" needs to be part of Dialog box, so that its need to be editable on Dialog window
Another issue can be with DataGrid implementation where getRowId needs to be unique for each field.
example as
getRowId={(row) => row.lineNumber +row.errorDescription}