I'm assuming your filtering by IsDeleted = true when the checkbox is selected, and not filtering at all when the checkbox isn't selected.
If your isDeleted is a true/false column, you could try replacing your "&& isDeleted=false" at the end of either if statement with something like:
&& If(CheckBox.Value, isDeleted, true)
This could be relatively easily modified to account for other possibilities, such as all records whether they are deleted or not, or only getting not deleted records when it's not selected.
Hope this helps!